![]() |
Routines |
| Prev: 37491 | Up: Map | Next: 37521 |
|
A door is held as two 8-byte entities, one for each of the two rooms that it joins, and these are 8 bytes apart with one of them on an address that has bit 3 reset. This flips bit 3 of IX to get the other.
|
||||||||||||
| GetOtherDoorHalf | 37510 | PUSH IX | Copy IX into HL. | |||||||||
| 37512 | POP HL | |||||||||||
| 37513 | LD A,L | Fetch the low byte of the address of this half. | ||||||||||
| 37514 | XOR %00001000 | Flip bit 3. | ||||||||||
| 37516 | LD L,A | Keep the address of the other half of the door in L. | ||||||||||
| 37517 | PUSH HL | Copy HL into IX, as the other half of the door. | ||||||||||
| 37518 | POP IX | |||||||||||
| 37520 | RET | Return. | ||||||||||
| Prev: 37491 | Up: Map | Next: 37521 |