Prev: 43559 Up: Map Next: 43676
43626: Game Over
Used by the routines at GameOver_Controller and GameOver_ControllerRestart.
Shows the "GAME OVER PLAYER" message, with the percentage of the jungle explored, and plays a tune. The message is for player 1 when entered at GameOver_1UP_Messaging and for player 2 when entered at GameOver_2UP.
Before After GameOver_1UP_Messaging
game-over-before game-over-after
Set up altering the "GAME OVER PLAYER X" message for 1UP.
GameOver_1UP_Messaging 43626 LD A,"1"+128 A="1" + 128 (escape character).
Print the messaging and pause to show it for a period of time.
GameOver_Write 43628 LD (43731),A Write ASCII player number to 43731(GameOver_Text).
43631 CALL ClearPlayArea_Attributes Clear the attribute buffer of the play area.
43634 CALL ClearPlayArea Clear the play area.
43637 LD DE,43732 Point DE at the "ADVENTURE COMPLETED" message at AdventureCompleted_Text.
43640 LD HL,30752 Set the print position in HL (L is the X position and H is the Y position) to 30752.
43643 CALL PrintStringColour Print the message.
43646 LD DE,43713 Point DE at the "GAME OVER PLAYER" message at GameOver_Text.
43649 LD HL,24632 Set the print position in HL to 24632.
43652 CALL PrintStringColour Print the message.
43655 CALL PrintRoomsVisited Print the percentage of the jungle explored.
43658 LD DE,48424 Point DE at the game over tune at MusicData_GameOver.
43661 CALL PlayMusic Play the tune.
Introduce a pause by counting down from 65536 twice.
43664 LD B,2 Set the number of delays in B to 2.
43666 LD HL,0 Set the delay counter in HL to 0 (which counts down from 65536).
43669 JP Pause Jump to Pause to pause.
This entry point is used by the routines at GameOver_Controller and GameOver_ControllerRestart.
Set up altering the "GAME OVER PLAYER X" message for 2UP.
GameOver_2UP 43672 LD A,"2"+128 A="2" + 128 (escape character).
43674 JR GameOver_Write Jump to GameOver_Write.
View the equivalent code in;
Prev: 43559 Up: Map Next: 43676