Routines |
Prev: BA75 | Up: Map | Next: BABE |
TEMP_C | BA77 | DI | disable interrupts | |
BA78 | LD HL,map_object_table | set HL to first address in map_object_table | ||
BA7B | LD B,$9F | set B to $9F as loop counter | ||
TEMP_C_loop | BA7D | PUSH BC | preserve loop counter | |
BA7E | LD (unknown55),HL | store address of table entry in unknown55 | ||
BA81 | LD A,(HL) | load map object byte from table location | ||
BA82 | CP $23 | if byte is $23, $1D, or $1F, then call routine36 | ||
BA84 | CALL Z,routine36 | |||
BA87 | CP $1D | |||
BA89 | CALL Z,routine36 | |||
BA8C | CP $1F | |||
BA8E | CALL Z,routine36 | |||
BA91 | LD DE,$0141 | add $0141 to address to get address of same entry in map_animation_frame_table | ||
BA94 | ADD HL,DE | |||
BA95 | LD A,(HL) | if byte at that location is $04 then call routine36 | ||
BA96 | CP $04 | |||
BA98 | CALL Z,routine36 | |||
BA9B | XOR A | load address back from unknown55 and compare to value in object_table_entry_pointer. If equal then call routine36 | ||
BA9C | LD HL,(unknown55) | |||
BA9F | LD DE,(object_table_entry_pointer) | |||
BAA3 | SBC HL,DE | |||
BAA5 | CALL Z,routine36 | |||
BAA8 | XOR A | load address back from unknown55 and compare to value in D_ADD. If equal then call routine36 | ||
BAA9 | LD HL,(unknown55) | |||
BAAC | LD DE,(D_ADD) | |||
BAB0 | SBC HL,DE | |||
BAB2 | CALL Z,routine36 | |||
BAB5 | LD HL,(unknown55) | load address back from unknown55 and increment to next entry in map_object_table | ||
BAB8 | INC HL | |||
BAB9 | POP BC | restore loop counter | ||
BABA | DJNZ TEMP_C_loop | execute loop 160 times | ||
BABC | EI | re-enable interrupts and return | ||
BABD | RET |
Prev: BA75 | Up: Map | Next: BABE |