Prev: C291 Up: Map Next: C2CE
C29A: Draw the lives icon and the number of lives on the panel
Used by the routines at OBJECT_DONE and QUEST_ITEM.
Draws graphic 22, a little Sabreman, at (16, 32) in the buffer through the spare record at PANEL_RECORD, makes six attribute cells bright white -- columns 2 and 3 of character row 18, and 2 to 5 of row 19, the icon and the two digits -- and prints LIVES as two digits in columns 4 and 5 of row 19. Called when a room is drawn (OBJECT_DONE) and when a quest item adds a life (QUEST_ITEM). Knight Lore's print_lives_gfx draws only the icon.
DRAW_LIVES C29A LD IX,PANEL_RECORD graphic 22, unturned, at (16, 32)
C29E LD (IX+$00),$16
C2A2 LD (IX+$07),$00
C2A6 LD (IX+$1A),$10
C2AA LD (IX+$1B),$20
C2AE CALL DRAW_SPRITE
C2B1 LD A,$47 bright white on black: two cells of row 18, four of row 19, from column 2
C2B3 LD DE,$5A42
C2B6 LD B,$02
C2B8 CALL FILL_BYTES
C2BB LD DE,$5A62
C2BE LD B,$04
C2C0 CALL FILL_BYTES
C2C3 LD DE,LIVES the two digits of LIVES, by the score's printer (ADD_SCORE)
C2C6 LD B,$01
C2C8 LD HL,$DD73
C2CB JP PRINT_BCD
Prev: C291 Up: Map Next: C2CE