Prev: 59648 Up: Map Next: 60160
59904: Room 42: Under the Roof (teleport: 2469)
Used by the routine at 35068.
under_the_roof
The first 128 bytes define the room layout. Each bit-pair (bits 7 and 6, 5 and 4, 3 and 2, or 1 and 0 of each byte) determines the type of tile (background, floor, wall or nasty) that will be drawn at the corresponding location.
Input
Output
59904 DEFB 0,0,0,255,255,255,255,240 Room layout
59912 DEFB 0,0,0,0,195,252,48,0
59920 DEFB 0,0,0,3,243,252,252,0
59928 DEFB 0,0,0,0,0,240,0,0
59936 DEFB 0,0,0,0,0,0,0,0
59944 DEFB 0,0,0,0,0,0,0,0
59952 DEFB 0,0,0,0,0,0,0,0
59960 DEFB 170,85,0,0,0,0,0,0
59968 DEFB 0,0,0,0,0,0,0,0
59976 DEFB 0,0,0,0,0,0,0,0
59984 DEFB 0,0,0,0,0,0,0,0
59992 DEFB 0,0,0,160,0,1,64,0
60000 DEFB 0,0,80,160,1,0,0,0
60008 DEFB 85,80,0,160,64,0,0,0
60016 DEFB 84,0,1,160,0,0,0,0
60024 DEFB 0,0,0,160,0,64,0,0
The next 32 bytes contain the room name.
60032 DEFM " Under the Roof " Room name
The next 54 bytes contain the attributes and graphic data for the tiles used to build the room.
background42 floor42 wall42 nasty42 ramp42 conveyor42
60064 DEFB 8,0,0,0,0,0,0,0,0 Background
60073 DEFB 12,181,170,85,74,37,66,1,2 Floor
60082 DEFB 30,102,182,109,187,102,185,109,182 Wall
60091 DEFB 245,102,170,95,188,99,172,107,164 Nasty
60100 DEFB 15,1,2,4,40,16,40,64,128 Ramp
60109 DEFB 14,165,170,189,102,102,102,102,102 Conveyor
The next 8 bytes define the direction, location and length of the conveyor and ramp.
60118 DEFB 1,204,94,20 Conveyor direction (right), location (x=12, y=6) and length (20)
60122 DEFB 1,196,94,7 Ramp direction (right), location (x=4, y=6) and length (7)
The next byte specifies the border colour.
60126 DEFB 2 Border colour
60127 DEFB 0,0 Unused
The next 8 bytes define the item graphic.
item42
60129 DEFB 255,255,255,255,255,255,255,255 Item graphic (unused)
The next 4 bytes specify the rooms to the left, to the right, above and below.
60137 DEFB 43 Room to the left (Conservatory Roof)
60138 DEFB 41 Room to the right (The Attic)
60139 DEFB 48 Room above (Nomen Luni)
60140 DEFB 36 Room below (A bit of tree)
60141 DEFB 0,0,0 Unused
The next 8 pairs of bytes specify the entities (ropes, arrows, guardians) in this room. The first byte in each pair identifies one of the entity definitions at 40960. The meaning of the second byte depends on the entity type: it determines the base sprite index and x-coordinate of a guardian, the y-coordinate of an arrow, or the x-coordinate of the top of a rope.
60144 DEFB 55,4 Guardian no. 55 (horizontal), base sprite 0, initial x=4 (41400)
60146 DEFB 39,16 Guardian no. 39 (horizontal), base sprite 0, initial x=16 (41272)
60148 DEFB 60,194 Arrow flying left to right at pixel y-coordinate 97 (41440)
60150 DEFB 255,0 Terminator (41976)
60152 DEFB 0,0 Nothing (40960)
60154 DEFB 0,0 Nothing (40960)
60156 DEFB 0,0 Nothing (40960)
60158 DEFB 0,0 Nothing (40960)
Prev: 59648 Up: Map Next: 60160