![]() |
Routines |
| Prev: 59219 | Up: Map | Next: 59298 |
|
Used by the routine at 58945.
|
||||
|
Also follows previous routine after the energy bar has been drawn.
Checks for an ongoing effect spell being deactivated, and for key presses once a spell has been chosen:
|
||||
| 59262 | LD A,(60134) | Get spell counter | ||
| 59265 | LD C,A | |||
| 59266 | LD A,(60137) | Is there currently an 'effect' spell active (e.g. SHIELD, UNSEEN) | ||
| 59269 | CP 0 | |||
| 59271 | JR Z,59277 | |||
| 59273 | CP C | If there is, is the triggered spell the same as the currently active spell? | ||
| 59274 | JP Z,59373 | If so, casting the spell will deactivate it | ||
|
When a spell is selected, the player can press FIRE to activate/cast the spell, or press UP/DOWN to immediately go back to scrolling through the spell list.
Check for FIRE (activate) or UP/DOWN (back to spell list):
|
||||
| 59277 | LD A,(60210) | Check if FIRE button pressed | ||
| 59280 | CP 1 | If pressed, skip the next few instructions | ||
| 59282 | JR Z,59298 | |||
| 59284 | LD A,(60158) | Check if UP/DOWN pressed | ||
| 59287 | CP 0 | If it's pressed, skip ahead to 60018 | ||
| 59289 | JP NZ,60018 | |||
| 59292 | CALL 56668 | Nothing pressed, so continue to print the active spell's message text | ||
| 59295 | JP 60064 | Nothing more to do at this point so jump straight to a RET statement | ||
| Prev: 59219 | Up: Map | Next: 59298 |