Prev: 30001 Up: Map Next: 30145
30123: Print currently available additional in-game menu command options
Used by the routine at 30001.
Input
A Available in-game menu command flags (part 1 or part 2)
HL Points to 38734 if dealing with flags, part 1. Points to 38777 if dealing with flags, part 2.
30123 LD B,8 Load B with 8 (as there are 8 flags)
30125 PUSH BC Store BC (B = remaining number of flags to process)
30126 RRCA Rotate least significant bit of A (i.e. current flag) into carry flag
30127 PUSH AF Store AF (current flag in carry and remaining flags in A)
30128 CALL 54242 Advance HL to byte after first zero from address in HL onwards
30131 POP AF Restore AF (current flag in carry and remaining flags in A)
30132 JR NC,30141 If current flag is reset then skip ahead to 30141
30134 PUSH HL Store HL (current position in additional menu items texts)
30135 PUSH AF Store AF (current flag in carry and remaining flags in A)
30136 CALL 34762 Print text at HL (current additional menu item)
30139 POP AF Restore AF (current flag in carry and remaining flags in A)
30140 POP HL Restore HL (current position in additional menu items texts)
30141 POP BC Restore BC (B = remaining number of flags to process)
30142 DJNZ 30125 Decrease B and loop back to 30125 for next flag
30144 RET Return
Prev: 30001 Up: Map Next: 30145