Skip to content

Commit

Permalink
Merge pull request #22 from NERS1111/main
Browse files Browse the repository at this point in the history
Fixed chapter switching room IDs
  • Loading branch information
Tenebrosful authored Feb 3, 2023
2 parents 1856898 + 8d29583 commit f528397
Showing 1 changed file with 13 additions and 11 deletions.
24 changes: 13 additions & 11 deletions Deltarune.asl
Original file line number Diff line number Diff line change
Expand Up @@ -569,17 +569,19 @@ update {
vars.fightPointer = current.fight2;
}

if(old.room == 281 && current.room == 413) { // entered chapter 1
if(vars.chapter == 0) vars.fightPointer = current.fight;
else if(vars.chapter == 2) vars.fightPointer = current.fight2;
vars.DebugPrint("Chapter " + vars.chapter + " -> 1");
vars.chapter = 1;
}
else if(old.room == 11 && current.room == 234) { // entered chapter 2
if(vars.chapter == 0) vars.fightPointer = current.fight2;
else if(vars.chapter == 1) vars.fightPointer = current.fight;
vars.DebugPrint("Chapter " + vars.chapter + " -> 2");
vars.chapter = 2;
if(old.room == 279) { // chapter select room
if(current.room == 281) { // chapter 1 initialization room
if(vars.chapter == 0) vars.fightPointer = current.fight;
else if(vars.chapter == 2) vars.fightPointer = current.fight2;
vars.DebugPrint("CHAPTER " + vars.chapter + " -> 1");
vars.chapter = 1;
}
else if(current.room == 11) { // chapter 2 initialization room
if(vars.chapter == 0) vars.fightPointer = current.fight2;
else if(vars.chapter == 1) vars.fightPointer = current.fight;
vars.DebugPrint("CHAPTER " + vars.chapter + " -> 2");
vars.chapter = 2;
}
}
break;
default: if(old.fight != current.fight) { vars.DebugPrint("FIGHT " + old.fight + " -> " + current.fight); vars.fightPointerOld = old.fight; vars.fightPointer = current.fight; } break;
Expand Down

0 comments on commit f528397

Please sign in to comment.