![]() |
Routines |
Prev: 42636 | Up: Map | Next: 42673 |
Used by the routine at Handler_RoomExits.
|
||||||||||||
CheckRoomObjects | 42644 | LD HL,40840 | HL=Table_ItemLocations. | |||||||||
42647 | LD BC,(48071) | BC=*Count_Objects_1. | ||||||||||
CheckRoomObjects_Loop | 42651 | CPIR | Search for the room number in the table. | |||||||||
42653 | RET NZ | Return if no objects are found. | ||||||||||
42654 | PUSH HL | Stash the object location table pointer on the stack. | ||||||||||
42655 | CALL ValidateObject | Call ValidateObject. | ||||||||||
42658 | POP HL | Restore the object location table pointer from the stack. | ||||||||||
42659 | JR NZ,NoRoomObjectsFound | Jump to NoRoomObjectsFound if there are no objects found here. | ||||||||||
42661 | LD E,A | Temporarily store A in E. | ||||||||||
42662 | LD A,B | Are there more objects to check? | ||||||||||
42663 | OR C | |||||||||||
42664 | LD A,E | Restore the A register. | ||||||||||
42665 | JR NZ,CheckRoomObjects_Loop | Jump to CheckRoomObjects_Loop if there are more objects to check. | ||||||||||
Set the "successful" output.
|
||||||||||||
42667 | LD A,1 | Set A to 1 to indicate that objects were found. | ||||||||||
42669 | AND A | Set flags. | ||||||||||
42670 | RET | Return. | ||||||||||
Set the "failure" output.
|
||||||||||||
NoRoomObjectsFound | 42671 | XOR A | Set A to 0 to indicate that no objects were found. | |||||||||
42672 | RET | Return. | ||||||||||
View the equivalent code in;
|
Prev: 42636 | Up: Map | Next: 42673 |