1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2024-12-27 07:07:09 +00:00

match function (#1737)

This commit is contained in:
fig02 2024-02-08 17:23:22 -05:00 committed by GitHub
parent 488b0e7783
commit f492c04186
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -7937,8 +7937,6 @@ void Player_Action_8084193C(Player* this, PlayState* play) {
f32 speedTarget; f32 speedTarget;
s16 yawTarget; s16 yawTarget;
s32 temp1; s32 temp1;
s16 temp2;
s32 temp3;
func_80841860(play, this); func_80841860(play, this);
@ -7958,26 +7956,21 @@ void Player_Action_8084193C(Player* this, PlayState* play) {
if (temp1 > 0) { if (temp1 > 0) {
func_8083C858(this, play); func_8083C858(this, play);
return; } else if (temp1 < 0) {
}
if (temp1 < 0) {
if (func_80833B2C(this)) { if (func_80833B2C(this)) {
func_8083CB2C(this, yawTarget, play); func_8083CB2C(this, yawTarget, play);
} else { } else {
func_8083CBF0(this, yawTarget, play); func_8083CBF0(this, yawTarget, play);
} }
return; } else if ((this->speedXZ < 3.6f) && (speedTarget < 4.0f)) {
}
if ((this->speedXZ < 3.6f) && (speedTarget < 4.0f)) {
if (!func_8008E9C4(this) && func_80833B2C(this)) { if (!func_8008E9C4(this) && func_80833B2C(this)) {
func_8083CB94(this, play); func_8083CB94(this, play);
} else { } else {
func_80839F90(this, play); func_80839F90(this, play);
} }
return; } else {
} s16 temp2;
s32 temp3;
func_80840138(this, speedTarget, yawTarget); func_80840138(this, speedTarget, yawTarget);
@ -7988,13 +7981,13 @@ void Player_Action_8084193C(Player* this, PlayState* play) {
if (Math_StepToF(&this->speedXZ, 0.0f, 3.0f) != 0) { if (Math_StepToF(&this->speedXZ, 0.0f, 3.0f) != 0) {
this->yaw = yawTarget; this->yaw = yawTarget;
} }
return; } else {
}
speedTarget *= 0.9f; speedTarget *= 0.9f;
Math_AsymStepToF(&this->speedXZ, speedTarget, 2.0f, 3.0f); Math_AsymStepToF(&this->speedXZ, speedTarget, 2.0f, 3.0f);
Math_ScaledStepToS(&this->yaw, yawTarget, temp3 * 0.1f); Math_ScaledStepToS(&this->yaw, yawTarget, temp3 * 0.1f);
} }
}
}
} }
void Player_Action_80841BA8(Player* this, PlayState* play) { void Player_Action_80841BA8(Player* this, PlayState* play) {