diff options
| author | Proloe <hoeloe@hotmail.co.uk> | 2025-04-11 20:44:40 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-04-11 15:44:40 -0400 |
| commit | 698fca8862b791e6458c98e4e3d7849189d0a213 (patch) | |
| tree | 88ddf733d6ea236db98e06619ed9ff63f800d5db | |
| parent | 86e1e8e3aa15939cb5c9baa72b810225823b7577 (diff) | |
Fixed right stick aiming being significantly less precise than left stick aiming. (#5388)
| -rw-r--r-- | soh/src/overlays/actors/ovl_player_actor/z_player.c | 24 |
1 files changed, 10 insertions, 14 deletions
diff --git a/soh/src/overlays/actors/ovl_player_actor/z_player.c b/soh/src/overlays/actors/ovl_player_actor/z_player.c index ddee9d0af..6638893f5 100644 --- a/soh/src/overlays/actors/ovl_player_actor/z_player.c +++ b/soh/src/overlays/actors/ovl_player_actor/z_player.c @@ -12773,9 +12773,8 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) { if (!CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) { temp2 += sControlInput->rel.stick_y * 240.0f * invertYAxisMulti * yAxisMulti; } - if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0) && - fabsf(sControlInput->cur.right_stick_y) > 15.0f) { - temp2 += sControlInput->cur.right_stick_y * 240.0f * invertYAxisMulti * yAxisMulti; + if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) { + temp2 += sControlInput->rel.right_stick_y * 240.0f * invertYAxisMulti * yAxisMulti; } if (fabsf(sControlInput->cur.gyro_x) > 0.01f) { temp2 += (-sControlInput->cur.gyro_x) * 750.0f; @@ -12792,9 +12791,8 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) { if (!CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) { temp2 += sControlInput->rel.stick_x * -16.0f * invertXAxisMulti * xAxisMulti; } - if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0) && - fabsf(sControlInput->cur.right_stick_x) > 15.0f) { - temp2 += sControlInput->cur.right_stick_x * -16.0f * invertXAxisMulti * xAxisMulti; + if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) { + temp2 += sControlInput->rel.right_stick_x * -16.0f * invertXAxisMulti * xAxisMulti; } if (fabsf(sControlInput->cur.gyro_y) > 0.01f) { temp2 += (sControlInput->cur.gyro_y) * 750.0f * invertXAxisMulti; @@ -12810,10 +12808,9 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) { (s32)((1.0f - Math_CosS(sControlInput->rel.stick_y * 200)) * 1500.0f) * invertYAxisMulti * yAxisMulti; } - if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0) && - fabsf(sControlInput->cur.right_stick_y) > 15.0f) { - temp3 += ((sControlInput->cur.right_stick_y >= 0) ? 1 : -1) * - (s32)((1.0f - Math_CosS(sControlInput->cur.right_stick_y * 200)) * 1500.0f) * invertYAxisMulti * + if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) { + temp3 += ((sControlInput->rel.right_stick_y >= 0) ? 1 : -1) * + (s32)((1.0f - Math_CosS(sControlInput->rel.right_stick_y * 200)) * 1500.0f) * invertYAxisMulti * yAxisMulti; } if (fabsf(sControlInput->cur.gyro_x) > 0.01f) { @@ -12831,10 +12828,9 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) { (s32)((1.0f - Math_CosS(sControlInput->rel.stick_x * 200)) * -1500.0f) * invertXAxisMulti * xAxisMulti; } - if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0) && - fabsf(sControlInput->cur.right_stick_x) > 15.0f) { - temp3 += ((sControlInput->cur.right_stick_x >= 0) ? 1 : -1) * - (s32)((1.0f - Math_CosS(sControlInput->cur.right_stick_x * 200)) * -1500.0f) * invertXAxisMulti * + if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) { + temp3 += ((sControlInput->rel.right_stick_x >= 0) ? 1 : -1) * + (s32)((1.0f - Math_CosS(sControlInput->rel.right_stick_x * 200)) * -1500.0f) * invertXAxisMulti * xAxisMulti; } if (fabsf(sControlInput->cur.gyro_y) > 0.01f) { |
