Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions soh/src/overlays/actors/ovl_player_actor/z_player.c
Original file line number Diff line number Diff line change
Expand Up @@ -12745,7 +12745,7 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) {

if (!func_8002DD78(this) && !func_808334B4(this) && (arg2 == 0)) { // First person without weapon
// Y Axis
if (!CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) {
if (!(CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0) && CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0))) {
temp2 += sControlInput->rel.stick_y * 240.0f * invertYAxisMulti * yAxisMulti;
}
if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) {
Expand All @@ -12763,7 +12763,7 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) {

// X Axis
temp2 = 0;
if (!CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) {
if (!(CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0) && CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0))) {
temp2 += sControlInput->rel.stick_x * -16.0f * invertXAxisMulti * xAxisMulti;
}
if (CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) {
Expand All @@ -12778,7 +12778,7 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) {
// Y Axis
temp1 = (this->stateFlags1 & PLAYER_STATE1_ON_HORSE) ? 3500 : 14000;

if (!CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) {
if (!(CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0) && CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0))) {
temp3 += ((sControlInput->rel.stick_y >= 0) ? 1 : -1) *
(s32)((1.0f - Math_CosS(sControlInput->rel.stick_y * 200)) * 1500.0f) * invertYAxisMulti *
yAxisMulti;
Expand All @@ -12798,7 +12798,7 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) {
temp1 = 19114;
temp2 = this->actor.focus.rot.y - this->actor.shape.rot.y;
temp3 = 0;
if (!CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) {
if (!(CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0) && CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0))) {
temp3 = ((sControlInput->rel.stick_x >= 0) ? 1 : -1) *
(s32)((1.0f - Math_CosS(sControlInput->rel.stick_x * 200)) * -1500.0f) * invertXAxisMulti *
xAxisMulti;
Expand All @@ -12815,7 +12815,7 @@ s16 func_8084ABD8(PlayState* play, Player* this, s32 arg2, s16 arg3) {
this->actor.focus.rot.y = CLAMP(temp2, -temp1, temp1) + this->actor.shape.rot.y;
}

if (CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0)) {
if (CVarGetInteger(CVAR_SETTING("MoveInFirstPerson"), 0) && CVarGetInteger(CVAR_SETTING("Controls.RightStickAim"), 0)) {
f32 movementSpeed = LINK_IS_ADULT ? 9.0f : 8.25f;
if (CVarGetInteger(CVAR_ENHANCEMENT("MMBunnyHood"), BUNNY_HOOD_VANILLA) != BUNNY_HOOD_VANILLA &&
this->currentMask == PLAYER_MASK_BUNNY) {
Expand Down
Loading