diff options
author | Astatin <[email protected]> | 2025-02-14 17:16:05 +0900 |
---|---|---|
committer | Astatin <[email protected]> | 2025-02-14 17:16:05 +0900 |
commit | cce14a83a5ef7b8bd3e8affa1cf5d52b00329b0a (patch) | |
tree | 3bbea23771b4cf981796eb9fb50c781b1886e93b /animations | |
parent | ecd565bc8625f7b80ebe197554ab01e1ef9a604b (diff) |
Fix laser animation + make EP work + add leaf to restore EP
Diffstat (limited to 'animations')
-rw-r--r-- | animations/laser.gbasm | 32 |
1 files changed, 22 insertions, 10 deletions
diff --git a/animations/laser.gbasm b/animations/laser.gbasm index 5c70eaf..e466652 100644 --- a/animations/laser.gbasm +++ b/animations/laser.gbasm @@ -1,6 +1,12 @@ +Set_E_Skip_display: + LD E, $01 +RET + Laser_Animation: INC HL + LD E, $00 + LD A, (HL+) ADD $80 LD D, A @@ -8,10 +14,10 @@ Laser_Animation: LD B, A SUB $82 CP D - RET NC + CALL NC, =Set_E_Skip_display ADD $0e CP D - RET C + CALL C, =Set_E_Skip_display LD A, D SUB $80 SUB B @@ -26,10 +32,10 @@ Laser_Animation: LD C, A SUB $82 CP D - RET NC + CALL NC, =Set_E_Skip_display ADD $0d CP D - RET C + CALL C, =Set_E_Skip_display LD A, D SUB $80 SUB C @@ -38,12 +44,14 @@ Laser_Animation: ADD $06 LD C, A - LD E, (HL) - DEC E - DEC E - CP E + LD A, E + LD $tmp_var_1, A + + LD A, (HL) + SUB $02 JP C, =.End_animation - LD (HL), E + LD E, A + LD (HL), A DEC HL DEC HL @@ -86,12 +94,16 @@ Laser_Animation: .Skip_move_animation_tile: + LD A, $tmp_var_1 + CP $01 + RET Z + LD A, $0f AND E CPL INC A ADD $0f - + .ADD_A_TO_DIRECTION_BC .ADD_MOVING_ANIMATION_OFFSET |