Prev: 64548 Up: Map Next: 64664
64609: Action: Enter
Action_Enter 64609 CALL Parser_ValidateDirectObject Call Parser_ValidateDirectObject.
64612 RET C Return if the direct object is malformed.
64613 CP 2 Jump to Response_PleaseRephraseThat_Duplicate if A is greater than 2.
64615 JP NC,Response_PleaseRephraseThat_Duplicate
Was the player trying to enter ... the cave?
64618 LD HL,60109 Call MatchPhraseTokens with PhraseTokens_Cave.
64621 CALL MatchPhraseTokens
64624 JR NZ,Enter_CheckBoat Jump to Enter_CheckBoat if the token isn't for the cave.
The player is attempting to enter the cave.
Validate that the player isn't already inside the cave.
64626 LD A,(48331) Jump to Response_YouveDoneThatAlready if *CurrentRoom is either room 82: " The Vast Cavern" or room 63: " The Cave".
64629 CP 82
64631 JP Z,Response_YouveDoneThatAlready
64634 CP 63
64636 JP Z,Response_YouveDoneThatAlready
Default to the player entering the cave if they're in " The Cave Mouth".
64639 LD B,63 Load room 63: " The Cave" into B as the destination room.
64641 CP 62 Jump to Enter_SetDestinationRoom if *CurrentRoom is room 62: " The Cave Mouth".
64643 JR Z,Enter_SetDestinationRoom
Else take the player to The Vast Cavern.
64645 LD B,82 Load room 82: " The Vast Cavern" into B as the destination room.
Enter_SetDestinationRoom 64647 LD A,B Copy B into the A register and call 61268.
64648 CALL 61268
64651 RET Return.
Was the player trying to enter ... the boat?
Enter_CheckBoat 64652 LD HL,60111 Call MatchPhraseTokens with PhraseTokens_Boat.
64655 CALL MatchPhraseTokens
Either way, it's a bad outcome.
64658 JP Z,Response_PleaseRephraseThat_Duplicate Jump to Response_PleaseRephraseThat_Duplicate if the token is for the boat.
Nothing else is able to be entered, so provide a generic response.
64661 JP Response_YouCant_Duplicate Jump to Response_YouCant_Duplicate.
Prev: 64548 Up: Map Next: 64664