![]() |
Routines |
| Prev: B4FD | Up: Map | Next: B549 |
|
Used by the routine at CheckFlagAndSetDisplay_ProcessPointer.
|
||||
| CheckFlagAndSetDisplay_CheckObjects | B517 | LD A,($A01C) | Check if objects need processing and return if none. | |
| B51A | AND A | |||
| B51B | RET Z | |||
| B51C | PUSH IY | Stash IY, DE and IX on the stack. | ||
| B51E | PUSH DE | |||
| B51F | PUSH IX | |||
| CheckFlagAndSetDisplay_ObjectLoop | B521 | CALL $AEA9 | Call AEA9 (get next object). | |
| B524 | BIT 6,(IY+%00000001) | Check bit 6 of object attribute and jump to CheckFlagAndSetDisplay_RestoreAndReturn if object doesn't need special handling. | ||
| B528 | JR Z,CheckFlagAndSetDisplay_RestoreAndReturn | |||
| B52A | CALL AdjustObjectTableForSum | Call AdjustObjectTableForSum (adjust object table for sum). | ||
| CheckFlagAndSetDisplay_ProcessObject | B52D | PUSH IY | Stash IY on the stack and restore into HL. | |
| B52F | POP HL | |||
| B530 | LD DE,$0008 | HL+=0008 (move to next object). | ||
| B533 | ADD HL,DE | |||
| B534 | CALL ProcessObjectEntry | Call ProcessObjectEntry (process object entry). | ||
| B537 | CP $FF | Compare with FF and jump to CheckFlagAndSetDisplay_ObjectLoop if end of objects. | ||
| B539 | JR Z,CheckFlagAndSetDisplay_ObjectLoop | |||
| B53B | LD HL,$A034 | HL=RoomDisplayParameter and compare with room parameter. | ||
| B53E | CP (HL) | |||
| B53F | JR NZ,CheckFlagAndSetDisplay_ProcessObject | Jump to CheckFlagAndSetDisplay_ProcessObject if object doesn't match room, otherwise set bit 0. | ||
| B541 | OR $01 | |||
| CheckFlagAndSetDisplay_RestoreAndReturn | B543 | POP IX | Restore IX, DE and IY from the stack. | |
| B545 | POP DE | |||
| B546 | POP IY | |||
| B548 | RET | Return. | ||
| Prev: B4FD | Up: Map | Next: B549 |