Prev: B486 Up: Map Next: B4F1
B48F: Door open animation (3 frames)
Sets CHARS=$CA7A (door tileset) via direct $5C36 write. Draws three
frames (frame_door_opening_frame_1frame_door_opening_frame_2frame_door_opening_frame_3) with scroll calls between each,
animating the door sliding open left-to-right.
door_open B48F LD HL,$5C36 Set CHARS=$CA7A (door tileset)
B492 LD A,$7A
B494 LD (HL),A
B495 INC HL
B496 LD A,$CA
B498 LD (HL),A
B499 LD A,$11 Set PAPER=1 (blue), set scroll params
B49B RST $10
B49C LD A,$01
B49E RST $10
B49F LD L,$80 L = $80 (blank tile)
B4A1 LD D,$00 D = 0 (start row)
B4A3 LD E,$0A E = 10 (start col)
B4A5 LD H,$01 H = 1, C = 17 (rows)
B4A7 LD C,$11 Fill column (door_print_sprite_row)
B4A9 CALL door_print_sprite_row
B4AC LD HL,$B551 Draw door frame 1 (frame_door_opening_frame_1)
B4AF CALL draw_frame
B4B2 CALL door_short_delay Short delay (door_short_delay)
B4B5 LD H,$02 H = 2
B4B7 LD D,$00 D = 0
B4B9 LD E,$0B E = 11
B4BB LD C,$11 C = 17
B4BD LD L,$80 L = $80
B4BF CALL door_print_sprite_row Fill column (door_print_sprite_row)
B4C2 LD HL,$B55F Draw door frame 2 (frame_door_opening_frame_2)
B4C5 CALL draw_frame
B4C8 CALL door_short_delay Short delay (door_short_delay)
B4CB LD H,$02 H = 2
B4CD LD D,$00 D = 0
B4CF LD E,$0D E = 13
B4D1 LD C,$11 C = 17
B4D3 LD L,$80 L = $80
B4D5 CALL door_print_sprite_row Fill column (door_print_sprite_row)
B4D8 LD HL,$B56B Draw door frame 3 (frame_door_opening_frame_3)
B4DB CALL draw_frame
B4DE CALL door_short_delay Short delay (door_short_delay)
B4E1 LD H,$02 H = 2
B4E3 LD D,$00 D = 0
B4E5 LD E,$0F E = 15
B4E7 LD C,$11 C = 17
B4E9 LD L,$80
B4EB CALL door_print_sprite_row
B4EE RET
Prev: B486 Up: Map Next: B4F1