From b0f9e2e6d53983faa9d213b40d2bd6a23473e134 Mon Sep 17 00:00:00 2001 From: Astatin Date: Fri, 9 May 2025 17:44:37 +0200 Subject: Refactoring the animations/directions + entities turn function with macros + finishing froge --- playerattacks/hop.gbasm | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) (limited to 'playerattacks') diff --git a/playerattacks/hop.gbasm b/playerattacks/hop.gbasm index 111fb72..d8b280d 100644 --- a/playerattacks/hop.gbasm +++ b/playerattacks/hop.gbasm @@ -52,6 +52,7 @@ Hop_Attack_Loading_VBlank: CALL =Display_Main_Prepared_Block LD A, $mem_bunny_direction + SWAP A AND $07 LD D, A LD A, $mem_viewport_x @@ -68,6 +69,7 @@ Hop_Attack_Loading_VBlank: CALL =Display_Object LD A, $mem_bunny_direction + SWAP A AND $07 LD D, A LD A, $mem_viewport_x @@ -100,8 +102,10 @@ Hop_Attack_Loading_Regular: LD $mem_requested_mode, A CALL =Update_VBlank_Handler LD A, $mem_bunny_direction - OR $38 + OR $08 LD $mem_bunny_direction, A + LD A, $03 + LD $mem_bunny_animation, A LD A, $mem_map_loading_flags SET 3, A LD $mem_map_loading_flags, A @@ -125,6 +129,7 @@ Hop_Attack_Loading_Regular: LD $mem_prepared_loading_block_position_2, A LD A, $mem_bunny_direction + SWAP A AND $07 LD D, A LD A, $mem_viewport_x @@ -141,6 +146,7 @@ Hop_Attack_Loading_Regular: CALL =Preload_Map_Hop LD A, $mem_bunny_direction + SWAP A AND $07 LD D, A LD A, $mem_viewport_x @@ -158,7 +164,10 @@ Hop_Attack_Loading_Regular: Hop_Attack: LD A, $mem_bunny_direction - AND $07 + AND $70 + LD D, A + SWAP A + OR D LD D, A LD A, $mem_bunny_x @@ -192,5 +201,3 @@ Hop_Attack: LD A, $00 LD $mem_loading_step, A RET - - -- cgit v1.2.3-70-g09d2