Prev: 31257 Up: Map Next: 31312
31280: Cast Fortify Yourself if possible, otherwise display failure message
Used by the routine at 55726.
Input
HL (Entry at 31283 only) Pointer to a character's current stats
31280 LD HL,25020 Point HL at Magic Knight's current stats
This entry point is used by the routine at 31257.
31283 LD B,4 Load B with 4 (as we are fortifying four stats)
31285 LD C,25 Load C with 25 (increment for stats)
31287 LD A,(HL) Load current stat into A...
31288 CALL 53703 ...increment A by 25, capping at 100...
31291 LD (HL),A ...and store
31292 INC HL Advance HL to next stat
31293 DJNZ 31285 Decrease B (remaining number of stats to fortify) and loop back to 31285
31295 LD A,(25024) Load B with unused bit...
31298 AND 128 ...
31300 LD B,A ...
31301 XOR A Set A (magic level) to zero (see trivia)
31302 OR B Recombine unused bit...
31303 LD (25024),A ...and store
31306 CALL 55651 Flash border and screen (as in cast a spell)
31309 JP 29479 Display "PRESS FIRE TO CONTINUE" window and wait for input and return to main game loop
Prev: 31257 Up: Map Next: 31312