Skip to content

Commit

Permalink
Further fix patch to use nextRoom rather than currentRoom
Browse files Browse the repository at this point in the history
  • Loading branch information
dbjorge committed Apr 7, 2020
1 parent 245e9fc commit 93f5047
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/main/java/stsjorbsmod/patches/ManifestPatch.java
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,8 @@ public static void updateFloorNumPatch(AbstractDungeon __this, SaveFile saveFile
if (AbstractDungeon.player != null) {
__this.floorNum += PlayerManifestField.manifestField.get(AbstractDungeon.player);

int startingManifest =
(AbstractDungeon.player != null && AbstractDungeon.player instanceof Cull &&
__this.currMapNode != null && __this.currMapNode.room instanceof EventRoom) ?
1 :
0;
boolean nextRoomIsEvent = __this.nextRoom != null && __this.nextRoom.room instanceof EventRoom;
int startingManifest = (nextRoomIsEvent && AbstractDungeon.player instanceof Cull) ? 1 : 0;
PlayerManifestField.manifestField.set(AbstractDungeon.player, startingManifest);
}
}
Expand Down

0 comments on commit 93f5047

Please sign in to comment.