Routines
| Prev: CA7F | Up: Map | Next: CAAE |
CA9E: Describe the player's room: in full the first time, briefly after
|
Bit 6 of the room record's first byte marks it as visited: clear, it is set and the room is described in full (D102); set, briefly (D1B2). OPEN PLAIN DOOR, NORTH, SOUTH, NORTH, SOUTH gives the closet's and the sitting room's long texts the first time ('The sun streams in the two broad windows...') and 'You are in a small closet.' / 'You are in Your Room.' the second. (The sitting room's long text came again on the first return: the opening description does not go through here.)
|
||||||||||||||
| CA9E | LD A,($DD01) | Read DD01 in "Pre-check for moving in a direction (verbs..." into A - A = the room number (DD01); HL = the room's record address (DCFF) | ||||||||||||
| CAA1 | LD HL,($DCFF) | Read DCFF in "Pre-check for moving in a direction (verbs..." into HL | ||||||||||||
| CAA4 | BIT 6,(HL) | Test bit 6 of the byte HL points at - Its +0 bit 6 (visited) set: describe it briefly (D1B2) | ||||||||||||
| CAA6 | JP NZ,$D1B2 | If bit 6 of the byte HL points at is set, jump on to the routine "Describe room A briefly (a room seen before)" (D1B2) | ||||||||||||
| CAA9 | SET 6,(HL) | Set bit 6 of the byte HL points at - First visit: mark it visited and describe it in full (D102) | ||||||||||||
| CAAB | JP $D102 | Jump on to the routine "Describe room A in full (the first visit)" (D102) | ||||||||||||
| Prev: CA7F | Up: Map | Next: CAAE |