Routines |
Prev: EEA2 | Up: Map | Next: EEF3 |
EEC1 | CALL $EEA2 | Initialize the sprite buffers. | ||
EEC4 | LD A,(IY+$0F) | Get the current room in A. | ||
EEC7 | LD ($B951),A | |||
EECA | LD B,$00 | Point HL at the start of the object buffer for this room. | ||
EECC | CALL $AA8C | |||
EECF | LD A,(HL) | Put the object ID. | ||
EED0 | CP $FF | Is this an end marker? | ||
EED2 | JR Z,$EEE3 | Jump forward if it is, nothing left to do. | ||
EED4 | INC HL | Put the co-ordinates found in DE. | ||
EED5 | LD E,(HL) | |||
EED6 | INC HL | |||
EED7 | LD D,(HL) | |||
EED8 | INC HL | Move to the buffer for the next item. | ||
EED9 | INC HL | |||
EEDA | LD ($A838),DE | Put the position in the scratch buffer at A838. | ||
EEDE | CALL $A83D | Draw the object, and loop back to see if there is anything further to draw. | ||
EEE1 | JR $EECF | |||
See if there is any custom routines for this room, and if so, execute them.
|
||||
EEE3 | LD E,(IY+$0F) | Put the current room in E and double it to get a word offset. | ||
EEE6 | SLA E | |||
EEE8 | LD D,$00 | |||
EEEA | LD HL,$EEF3 | Add the base address of the room logic table (EEF3). | ||
EEED | ADD HL,DE | |||
EEEE | LD E,(HL) | Put the address found in DE. | ||
EEEF | INC HL | |||
EEF0 | LD D,(HL) | |||
EEF1 | EX DE,HL | Swap DE and HL so HL points to the logic routine. | ||
EEF2 | JP (HL) | Execute it. |
Prev: EEA2 | Up: Map | Next: EEF3 |