diff options
Diffstat (limited to 'engine')
-rw-r--r-- | engine/events.asm | 2 | ||||
-rw-r--r-- | engine/map_objects.asm | 4 | ||||
-rwxr-xr-x | engine/player_movement.asm | 94 | ||||
-rwxr-xr-x | engine/player_object.asm | 16 | ||||
-rw-r--r-- | engine/std_scripts.asm | 6 |
5 files changed, 61 insertions, 61 deletions
diff --git a/engine/events.asm b/engine/events.asm index 495211141..0e8b29afc 100644 --- a/engine/events.asm +++ b/engine/events.asm @@ -547,7 +547,7 @@ OWPlayerInput: ; 96974 .Action: push af - callba Function80422 + callba StopPlayerForEvent pop af scf ret diff --git a/engine/map_objects.asm b/engine/map_objects.asm index c2e2f9a22..58c30c8fb 100644 --- a/engine/map_objects.asm +++ b/engine/map_objects.asm @@ -1995,7 +1995,7 @@ ApplyMovementToFollower: ; 54b8 ret z cp movement_step_bump ret z - cp movement_turn_step_right + 1 + cp movement_slow_step ret c push af ld hl, wFollowerMovementQueueLength @@ -2509,7 +2509,7 @@ RefreshPlayerSprite: ; 579d ld [wPlayerNextMovement], a ld [wPlayerMovement], a xor a - ld [wd04e], a + ld [wPlayerTurningDirection], a ld [PlayerObjectStepFrame], a call .TryResetPlayerAction callba CheckWarpFacingDown diff --git a/engine/player_movement.asm b/engine/player_movement.asm index d0b89d014..2f6660135 100755 --- a/engine/player_movement.asm +++ b/engine/player_movement.asm @@ -233,12 +233,12 @@ DoPlayerMovement:: ; 80000 ; If the player is turning, change direction first. This also lets ; the player change facing without moving by tapping a direction. - ld a, [wd04e] + ld a, [wPlayerTurningDirection] cp 0 - jr nz, .asm_80169 + jr nz, .not_turning ld a, [WalkingDirection] cp STANDING - jr z, .asm_80169 + jr z, .not_turning ld e, a ld a, [PlayerDirection] @@ -246,7 +246,7 @@ DoPlayerMovement:: ; 80000 rrca and 3 cp e - jr z, .asm_80169 + jr z, .not_turning ld a, STEP_TURN call .DoStep @@ -254,7 +254,7 @@ DoPlayerMovement:: ; 80000 scf ret -.asm_80169 +.not_turning xor a ret ; 8016b @@ -465,10 +465,10 @@ DoPlayerMovement:: ; 80000 ld a, [hl] ld [MovementAnimation], a - ld hl, .InPlace + ld hl, .FinishFacing add hl, de ld a, [hl] - ld [wd04e], a + ld [wPlayerTurningDirection], a ld a, 4 ret @@ -481,53 +481,53 @@ DoPlayerMovement:: ; 80000 dw .SlideStep dw .TurningStep dw .BackJumpStep - dw .InPlace + dw .FinishFacing .SlowStep: - slow_step_down - slow_step_up - slow_step_left - slow_step_right + slow_step DOWN + slow_step UP + slow_step LEFT + slow_step RIGHT .NormalStep: - step_down - step_up - step_left - step_right + step DOWN + step UP + step LEFT + step RIGHT .FastStep: - big_step_down - big_step_up - big_step_left - big_step_right + big_step DOWN + big_step UP + big_step LEFT + big_step RIGHT .JumpStep: - jump_step_down - jump_step_up - jump_step_left - jump_step_right + jump_step DOWN + jump_step UP + jump_step LEFT + jump_step RIGHT .SlideStep: - fast_slide_step_down - fast_slide_step_up - fast_slide_step_left - fast_slide_step_right + fast_slide_step DOWN + fast_slide_step UP + fast_slide_step LEFT + fast_slide_step RIGHT .BackJumpStep: - jump_step_up - jump_step_down - jump_step_right - jump_step_left + jump_step UP + jump_step DOWN + jump_step RIGHT + jump_step LEFT .TurningStep: - turn_step_down - turn_step_up - turn_step_left - turn_step_right -.InPlace: - db $80 + movement_turn_head_down - db $80 + movement_turn_head_up - db $80 + movement_turn_head_left - db $80 + movement_turn_head_right + turn_step DOWN + turn_step UP + turn_step LEFT + turn_step RIGHT +.FinishFacing: + db $80 + DOWN + db $80 + UP + db $80 + LEFT + db $80 + RIGHT ; 802b3 .StandInPlace: ; 802b3 ld a, 0 - ld [wd04e], a + ld [wPlayerTurningDirection], a ld a, movement_step_sleep ld [MovementAnimation], a xor a @@ -536,7 +536,7 @@ DoPlayerMovement:: ; 80000 ._WalkInPlace: ; 802bf ld a, 0 - ld [wd04e], a + ld [wPlayerTurningDirection], a ld a, movement_step_bump ld [MovementAnimation], a xor a @@ -549,7 +549,7 @@ DoPlayerMovement:: ; 80000 call CheckStandingOnIce ret nc - ld a, [wd04e] + ld a, [wPlayerTurningDirection] cp 0 ret z @@ -812,7 +812,7 @@ DoPlayerMovement:: ; 80000 ; 80404 CheckStandingOnIce:: ; 80404 - ld a, [wd04e] + ld a, [wPlayerTurningDirection] cp 0 jr z, .not_ice cp $f0 @@ -833,7 +833,7 @@ CheckStandingOnIce:: ; 80404 ret ; 80422 -Function80422:: ; 80422 +StopPlayerForEvent:: ; 80422 ld hl, wPlayerNextMovement ld a, movement_step_sleep cp [hl] @@ -841,6 +841,6 @@ Function80422:: ; 80422 ld [hl], a ld a, 0 - ld [wd04e], a + ld [wPlayerTurningDirection], a ret ; 80430 diff --git a/engine/player_object.asm b/engine/player_object.asm index bb19a144f..6b38a6328 100755 --- a/engine/player_object.asm +++ b/engine/player_object.asm @@ -598,10 +598,10 @@ Special_SurfStartStep: ; 8379 ret .movement_data - slow_step_down - slow_step_up - slow_step_left - slow_step_right + slow_step DOWN + slow_step UP + slow_step LEFT + slow_step RIGHT FollowNotExact:: ; 839e push bc @@ -827,12 +827,12 @@ QueueFollowerFirstStep: ; 848a jr z, .check_y jr c, .left and a - ld a, movement_step_right + ld a, movement_step + RIGHT ret .left and a - ld a, movement_step_left + ld a, movement_step + LEFT ret .check_y @@ -843,12 +843,12 @@ QueueFollowerFirstStep: ; 848a jr z, .same_xy jr c, .up and a - ld a, movement_step_down + ld a, movement_step + DOWN ret .up and a - ld a, movement_step_up + ld a, movement_step + UP ret .same_xy diff --git a/engine/std_scripts.asm b/engine/std_scripts.asm index 9c9542cf4..0f144f79c 100644 --- a/engine/std_scripts.asm +++ b/engine/std_scripts.asm @@ -1907,8 +1907,8 @@ HappinessCheckScript: end Movement_ContestResults_WalkAfterWarp: ; bcea1 - step_right - step_down - turn_head_up + step RIGHT + step DOWN + turn_head UP step_end ; bcea5 |