tfv: add battle pose

This commit is contained in:
Vince Weaver 2021-01-18 23:35:44 -05:00
parent a7b576eaec
commit c7226a0f4c
4 changed files with 123 additions and 1 deletions

View File

@ -176,7 +176,7 @@ battle_draw_normal_hero:
lda #20
sta HERO_Y
jsr draw_hero_and_sword
jsr draw_battle_hero_and_sword
battle_done_draw_hero:

View File

@ -117,6 +117,90 @@ draw_hero_sword:
;============================
; draw battle hero and sword
;============================
; bounces in readiness
; draws at HERO_X,HERO_Y
draw_battle_hero_and_sword:
lda HERO_X
sta XPOS
lda HERO_Y
sta YPOS
lda FRAMEL
and #$8
beq hero_bounce1
hero_bounce2:
lda #<tfv_battle1_sprite
sta INL
lda #>tfv_battle1_sprite
sta INH
jsr put_sprite_crop
hero_sword2:
; grsim_put_sprite(tfv_led_sword,ax-5,20);
lda HERO_X
sec
sbc #5
sta XPOS
lda HERO_Y
; clc
; adc #2
sta YPOS
lda #<tfv_led_sword_sprite
sta INL
lda #>tfv_led_sword_sprite
sta INH
jmp put_sprite_crop ; tail call
hero_bounce1:
lda #<tfv_battle2_sprite
sta INL
lda #>tfv_battle2_sprite
sta INH
jsr put_sprite_crop
hero_sword1:
; grsim_put_sprite(tfv_led_sword,ax-5,20);
lda HERO_X
sec
sbc #5
sta XPOS
lda HERO_Y
clc
adc #2
sta YPOS
lda #<tfv_led_sword2_sprite
sta INL
lda #>tfv_led_sword2_sprite
sta INH
jmp put_sprite_crop ; tail call
;===================
; heal hero
;===================

View File

@ -10,6 +10,14 @@
draw_battle_bottom:
; increment frame
; weird place for this but everything calls this once per frame
inc FRAMEL
bne frame_no_oflo
inc FRAMEH
frame_no_oflo:
jsr clear_bottom
jsr normal_text

View File

@ -49,12 +49,42 @@ tfv_walk_left_sprite:
.byte $AA,$2A,$A2,$22
.byte $AA,$82,$AA,$82
;====================
; TFV Battle Sprites
;====================
tfv_battle1_sprite:
.byte $4,$6
.byte $AA,$BD,$DD,$AA
.byte $AB,$DB,$DD,$AA
.byte $AA,$AA,$22,$AA
.byte $AB,$A2,$22,$AA
.byte $AA,$22,$22,$2A
.byte $8A,$82,$AA,$82
tfv_battle2_sprite:
.byte $4,$6
.byte $AA,$DA,$DA,$AA
.byte $BA,$BB,$DD,$AA
.byte $AA,$AD,$2D,$AA
.byte $BA,$2A,$22,$AA
.byte $AA,$2A,$22,$22
.byte $8A,$82,$AA,$82
tfv_led_sword_sprite:
.byte $5,$3
.byte $1A,$AA,$1A,$AA,$AA
.byte $1A,$A1,$1A,$1A,$1A
.byte $AA,$AA,$11,$A1,$1A
tfv_led_sword2_sprite:
.byte $5,$3
.byte $A1,$1A,$A1,$AA,$AA
.byte $A1,$AA,$11,$11,$A1
.byte $AA,$AA,$A1,$AA,$A1
tfv_defeat_sprite:
.byte $7,$3
.byte $AA,$AA,$AA,$2b,$AA,$AA,$AA