Prev: 6460 Up: Map Next: 648A
6469: Room $02 (row 0, column 2): 128 by 128, yellow
5 backgrounds and 18 objects in 4 groups. Positions are cells (U, V, level): U and V 0-7, sixteen units a cell from 72; each level twelve units up from the floor.
The room directory: 128 records, one per room, end to end up to OBJECT_TABLE. BUILD_ROOM finds a room by stepping from one record to the next until the number matches; the rooms are numbered on a 16 by 16 grid, as in Knight Lore.
A record is +0 the room number, +1 the count of bytes from +1 to the end of the record, +2 the room's size (bits 6-7, an index into ROOM_SIZES) and its colour: bits 3-5 on the tape, copied into bits 0-2 at the start of every game (RESET_ROOM_COLOURS) because bits 0-2 are the ink in use, which an activated chamber turns white (LOOSE_VALVE). Then the backgrounds, a byte each (an index into BACKGROUND_TABLE), up to an $FF; then the objects in groups, a header byte (bits 0-2: how many, less one; bits 3-7: the object template, OBJECT_TABLE) and a position byte for each: U in bits 0-2, V in bits 3-5, the level in bits 6-7. A header with template 0 sets the placement nudge (PLACE_NUDGE) from the byte after it, and one with template 31 moves on to the second page of templates. Nothing ends a record but the count at +1 running out, and a group can be cut short by it.
Each room is an entry of its own, laid out from the game's data when the disassembly is built.
ROOM02 6469 DEFB $02,$20,$30 Room $02; 32 bytes from the next; size 0, colour 6
646C DEFB $00 Background 0
646D DEFB $0A Background 10
646E DEFB $0C Background 12
646F DEFB $04 Background 4
6470 DEFB $07 Background 7
6471 DEFB $FF End of the backgrounds
6472 DEFB $0F,$40,$88,$78,$B0,$E7,$DF,$E8 Object template 1 x8 at (0,0,1), (0,1,2), (0,7,1), (0,6,2), (7,4,3), (7,3,3), (0,5,3), (0,2,3)
647A DEFB $D0
647B DEFB $09,$00,$38 Object template 1 x2 at (0,0,0), (0,7,0)
647E DEFB $00,$30 Placement nudge $30 for the objects that follow
6480 DEFB $0B,$20,$18,$19,$21 Object template 1 x4 at (0,4,0), (0,3,0), (1,3,0), (1,4,0)
6485 DEFB $33,$22,$23,$1A,$1B Object template 6 x4 at (2,4,0), (3,4,0), (2,3,0), (3,3,0)
Prev: 6460 Up: Map Next: 648A