![]() |
Routines |
| Prev: 24503 | Up: Map | Next: 24578 |
|
Used by the routine at HandleLevelIntroduction.
Redraws the playing area for the active player, shows the pantry and puts Charlie in his starting position.
|
||||||
StartLife takes a life away, so the life it is about to remove is added back first.
|
||||||
| StartLevel | 24545 | LD HL,24366 | Add one to the lives of the active player (ActivePlayer_Lives). | |||
| 24548 | INC (HL) | |||||
| 24549 | CALL StartLife | Take a life away from the active player using StartLife. | ||||
|
This entry point is used by the routine at HandleEndOfLife.
The level is 255 when there is no second player in a one player game, so there is nothing to start.
|
||||||
| StartLevel_TestLevel | 24552 | LD A,(24365) | Fetch the level of the active player. | |||
| 24555 | INC A | Add one, so that a level of 255 becomes zero. | ||||
| 24556 | RET Z | Return if there is no player to start. | ||||
|
Draw the window, then the pantry, then the remaining lives.
|
||||||
| 24557 | CALL CreateWindow | Draw the window using CreateWindow. | ||||
| 24560 | CALL DrawPantry | Draw the pantry using DrawPantry. | ||||
| 24563 | CALL DisplayPlayerLives | Show the lives of both players using DisplayPlayerLives. | ||||
|
Self modifying code; this updates the command at 29973 to "CP 26".
|
||||||
| 24566 | LD A,26 | Write 26 to 29974. | ||||
| 24568 | LD (29974),A | |||||
| 24571 | LD A,(23672) | Record the current frame at LastFrame, so that the frame update does not run straight away. | ||||
| 24574 | LD (24354),A | |||||
| 24577 | RET | Return. | ||||
| Prev: 24503 | Up: Map | Next: 24578 |