![]() |
Routines |
| Prev: F5D2 | Up: Map | Next: F606 |
|
Used by the routine at CheckScoreAwardLife.
Creates the extra life award flash effect. Sets the attribute fill colour to 12 and runs 0C screen-flash frames, each calling Draw_Colour_Flash_Rectangle to repaint the attribute area and Advance_Flash_Colour_Cycle to advance the colour cycling animation. The screen is then wiped by ClearScreenBuffer and a second pass of 0C frames plays with the colour cleared.
|
||||
| Extra_Life_Flash | F5DA | LD A,$12 | Set the screen flash colour. | |
| F5DC | LD ($C507),A | Write the flash colour to the attribute fill register. | ||
| F5DF | LD A,$0B | Set the flash loop counter. | ||
| Extra_Life_Flash_Loop1 | F5E1 | PUSH AF | Stash the loop counter on the stack. | |
| F5E2 | CALL Draw_Colour_Flash_Rectangle | Repaint the display with the flash colour. | ||
| F5E5 | CALL Advance_Flash_Colour_Cycle | Advance the colour cycling animation. | ||
| F5E8 | POP AF | Restore the loop counter from the stack. | ||
| F5E9 | DEC A | Decrease the loop counter and loop back for the next frame. | ||
| F5EA | CP $FF | |||
| F5EC | JR NZ,Extra_Life_Flash_Loop1 | |||
|
Wipe the screen, clear the flash colour and run a second pass.
|
||||
| F5EE | CALL ClearScreenBuffer | Wipe the screen. | ||
| F5F1 | LD A,$00 | Clear the attribute fill register. | ||
| F5F3 | LD ($C507),A | |||
| F5F6 | LD A,$0B | Set the second loop counter. | ||
| Extra_Life_Flash_Loop2 | F5F8 | PUSH AF | Stash the loop counter on the stack. | |
| F5F9 | CALL Draw_Colour_Flash_Rectangle | Repaint the display with the cleared colour. | ||
| F5FC | CALL Advance_Flash_Colour_Cycle | Advance the colour cycling animation. | ||
| F5FF | POP AF | Restore the loop counter from the stack. | ||
| F600 | DEC A | Decrease the loop counter and loop back for the next frame. | ||
| F601 | CP $FF | |||
| F603 | JR NZ,Extra_Life_Flash_Loop2 | |||
| F605 | RET | Return. | ||
| Prev: F5D2 | Up: Map | Next: F606 |