![]() |
Routines |
| Prev: 98D2 | Up: Map | Next: 990C |
|
Used by the routine at SetKeyPositions.
Looks up one of the eight rooms in a table using the bottom three bits of A.
|
||||||||||||||
| GetKeyRoom | 9904 | AND %00000111 | Keep only bits 0-2. | |||||||||||
| 9906 | LD C,A | Keep the index in C. | ||||||||||||
| 9907 | LD B,$00 | B=00. | ||||||||||||
| 9909 | ADD HL,BC | Add BC to HL. | ||||||||||||
| 990A | LD A,(HL) | Fetch the room. | ||||||||||||
| 990B | RET | Return. | ||||||||||||
| Prev: 98D2 | Up: Map | Next: 990C |