Prev: 24603 Up: Map Next: 24622
24607: Draw Cubby Hole Shelves
Used by the routine at DrawPlayArea.
Draws the five shelves of the cubby holes down one side of the play area, each made of three bricks and each 32 pixels below the last.
Input
DE Pointer to the string for the shelf
HL Screen position of the first shelf
DrawCubbyHoleShelves 24607 LD C,5 Set the shelf counter in C to 5.
DrawCubbyHoleShelves_Loop 24609 LD B,1 Set the brick counter in B to 1 (one row of bricks per shelf).
24611 CALL PrintString_Wrapper Print the shelf using PrintString_Wrapper.
24614 LD A,H A=the Y position, which PrintString_Wrapper has moved down by 8.
24615 ADD A,24 Add 24 to move down to the next shelf (32 pixels below the last).
24617 LD H,A Store the Y position in H.
24618 DEC C Decrease the shelf counter by one.
24619 JR NZ,DrawCubbyHoleShelves_Loop Loop back to DrawCubbyHoleShelves_Loop until all five shelves have been drawn.
24621 RET Return.
Prev: 24603 Up: Map Next: 24622