![]() |
Routines |
| Prev: 46638 | Up: Map | Next: 46693 |
|
Used by the routines at PrintObjects and CheckRoomObjects.
Validate Object.
|
||||
| ValidateObject | 46667 | PUSH AF | Remember the room and the search position. | |
| 46668 | PUSH BC | |||
| 46669 | INC BC | Advance BC to the next byte. | ||
| 46670 | LD A,(44784) | Read the item count into A. | ||
| 46673 | SUB C | Turn the search position into this item's index. | ||
| 46674 | LD E,A | |||
| 46675 | LD IX,(44758) | Call GetTableEntry to look up the table entry. | ||
| 46679 | CALL GetTableEntry | |||
| 46682 | POP BC | Restore the search position from the stack. | ||
| 46683 | LD A,H | See whether this item has a description. | ||
| 46684 | OR L | Combine L into the working value. | ||
| 46685 | JR Z,ValidateObject_Next | Reject an item that has no description. | ||
| 46687 | POP AF | Restore the room ID from the stack. | ||
| 46688 | AND A | Test A so the following branch can see whether it is zero. | ||
| 46689 | RET | Return. | ||
| ValidateObject_Next | 46690 | POP AF | Restore the room ID from the stack. | |
| 46691 | CP A | Report that this item has no description. | ||
| 46692 | RET | Return. | ||
|
View the equivalent code in;
|
||||
| Prev: 46638 | Up: Map | Next: 46693 |