Prev: 7132 Up: Map Next: 7154
7140: 'D' pressed - drop stinkbomb
The address of this routine is found in the table of keypress handling routines at E550. It is called from the main loop at F6EA when 'D' or 'U' is pressed.
7140 LD A,($7FEB) 7FEB holds the inventory flags
7143 RLCA Does ERIC have any stinkbombs?
7144 RET NC Return if not
7145 CALL $6E50 Is ERIC on a staircase?
7148 RET C Return if so
7149 CALL $E236 If buffer 0xD5 (normally used by BOY WANDER's pellet) is available, prepare it and return here
714C LD A,$07 0x07: animatory state of ERIC dropping a stinkbomb (arm up)
714E LD HL,$F862 Routine at F862: deal with a dropped stinkbomb
7151 JP $E12A Update ERIC's animatory state and drop the stinkbomb
Prev: 7132 Up: Map Next: 7154