![]() |
Routines |
| Prev: 42506 | Up: Map | Next: 42549 |
|
Used by the routines at 41600, CheckObjectInInventory, TransformItem, CheckItemInCurrentRoom, 43106 and 43121.
Given an item ID, this routine returns the byte stored for its location (0 for when an item/ event is disabled, 1 for when an item is in the players inventory, or pass back the room ID).
|
||||||||||||
|
Create an offset in DE.
|
||||||||||||
| ItemLocator | 42540 | LD E,A | Load the item ID into DE. | |||||||||
| 42541 | LD D,0 | |||||||||||
| 42543 | LD HL,40840 | Add the item ID offset to Table_ItemLocations. | ||||||||||
| 42546 | ADD HL,DE | |||||||||||
| 42547 | LD A,(HL) | Fetch the item location and store it in A. | ||||||||||
| 42548 | RET | Return. | ||||||||||
|
View the equivalent code in;
|
||||||||||||
| Prev: 42506 | Up: Map | Next: 42549 |