Prev: C15A Up: Map Next: C1E0
C1C0: Set up LEFT vertical wall/floor connector graphics
Prepare the room corner join graphics - one of two sorts, for either 'brick' or 'cavern' levels
The right wall/floor connector is set up later at C2F8
left side wall-floor connector left side wall-floor connector
C1C0 LD A,$06 Graphic type = 6 (corner wall section)
C1C2 LD ($EB43),A
C1C5 LD A,$30 Vertical position (in pixels) from top of room space
C1C7 LD ($EB4A),A
C1CA LD A,$10 Horizontal position (in 4-pixel/half-character steps) from left of room space
C1CC LD ($EB48),A
C1CF LD A,$02
C1D1 LD ($EB50),A Graphic number offset for scenery graphic address (n-1)*2 = 2
The standard corner section is the right-hand one (9E0E). For the left one (as in the above images) we want the mirrored version, the graphics pointer to which is the next address (2 bytes) location
C1D4 LD C,$12 Graphic number offset for corner wall section in graphic address table at 97C3; (n-1)*2 = 34 = 97E5
C1D6 LD A,($EB77) Extra offset (+12 addresses) in table if the player is on a 'cavern' level
C1D9 ADD A,C Addresses offset will now be 18 or 30, e.g. for wall section at 97E5 or 97FD.
C1DA CALL $E0C2 Prep graphic address pointers at pointer table at 97C3, including mirrored graphics of the sections
C1DD CALL $E0B0 Copy the data for these graphics from its buffer at EB43 into a room item data set at 7C00
Prev: C15A Up: Map Next: C1E0