diff options
| author | Dragorn421 <Dragorn421@users.noreply.github.com> | 2024-10-10 02:22:52 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-10-09 20:22:52 -0400 |
| commit | ba9c60552b7a879d05a15aee102b502333b6bb41 (patch) | |
| tree | 215d0aa10854c0f24b9175e99e873209e76b4046 /src/code | |
| parent | 621b8f38c565c6a801c9f375165e84095d587dd0 (diff) | |
Player doc: some rotation logic/data (#1443)
* Docs: some player rotation logic/data
* Improve misleading comment
* rename temps
* unk_6AE_rotFlags
* format
* disasm metadata
Diffstat (limited to 'src/code')
| -rw-r--r-- | src/code/z_actor.c | 2 | ||||
| -rw-r--r-- | src/code/z_player_lib.c | 24 |
2 files changed, 13 insertions, 13 deletions
diff --git a/src/code/z_actor.c b/src/code/z_actor.c index 71e25d953..cbe84c927 100644 --- a/src/code/z_actor.c +++ b/src/code/z_actor.c @@ -1098,7 +1098,7 @@ int func_8002DD6C(Player* player) { } int func_8002DD78(Player* player) { - return func_8002DD6C(player) && player->unk_834; + return func_8002DD6C(player) && (player->unk_834 != 0); } int func_8002DDA8(PlayState* play) { diff --git a/src/code/z_player_lib.c b/src/code/z_player_lib.c index c9815c313..d7ec54bd0 100644 --- a/src/code/z_player_lib.c +++ b/src/code/z_player_lib.c @@ -1295,22 +1295,22 @@ s32 Player_OverrideLimbDrawGameplayCommon(PlayState* play, s32 limbIndex, Gfx** } if (limbIndex == PLAYER_LIMB_HEAD) { - rot->x += this->unk_6BA; - rot->y -= this->unk_6B8; - rot->z += this->unk_6B6; + rot->x += this->headLimbRot.z; + rot->y -= this->headLimbRot.y; + rot->z += this->headLimbRot.x; } else if (limbIndex == PLAYER_LIMB_UPPER) { - if (this->unk_6B0 != 0) { + if (this->upperLimbYawSecondary != 0) { Matrix_RotateZ(BINANG_TO_RAD(0x44C), MTXMODE_APPLY); - Matrix_RotateY(BINANG_TO_RAD(this->unk_6B0), MTXMODE_APPLY); + Matrix_RotateY(BINANG_TO_RAD(this->upperLimbYawSecondary), MTXMODE_APPLY); } - if (this->unk_6BE != 0) { - Matrix_RotateY(BINANG_TO_RAD(this->unk_6BE), MTXMODE_APPLY); + if (this->upperLimbRot.y != 0) { + Matrix_RotateY(BINANG_TO_RAD(this->upperLimbRot.y), MTXMODE_APPLY); } - if (this->unk_6BC != 0) { - Matrix_RotateX(BINANG_TO_RAD(this->unk_6BC), MTXMODE_APPLY); + if (this->upperLimbRot.x != 0) { + Matrix_RotateX(BINANG_TO_RAD(this->upperLimbRot.x), MTXMODE_APPLY); } - if (this->unk_6C0 != 0) { - Matrix_RotateZ(BINANG_TO_RAD(this->unk_6C0), MTXMODE_APPLY); + if (this->upperLimbRot.z != 0) { + Matrix_RotateZ(BINANG_TO_RAD(this->upperLimbRot.z), MTXMODE_APPLY); } } else if (limbIndex == PLAYER_LIMB_L_THIGH) { s32 pad; @@ -1788,7 +1788,7 @@ void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Ve Matrix_MtxFToYXZRotS(&sp44, &heldActor->world.rot, 0); heldActor->shape.rot = heldActor->world.rot; - if (func_8002DD78(this) != 0) { + if (func_8002DD78(this)) { Matrix_Translate(500.0f, 300.0f, 0.0f, MTXMODE_APPLY); Player_DrawHookshotReticle(play, this, (this->heldItemAction == PLAYER_IA_HOOKSHOT) ? 38600.0f : 77600.0f); |
