mirror of
https://github.com/zeldaret/oot.git
synced 2025-02-03 10:04:31 +00:00
Standardize "ActorMovement" over "ActorMove" (#2214)
* ActorMove -> ActorMovement * more move -> movement * ANIM_FLAG_ENABLE_MOVEMENT * format
This commit is contained in:
parent
ebd2b8dd50
commit
bb3848262d
14 changed files with 124 additions and 117 deletions
|
@ -91,14 +91,14 @@ typedef enum AnimationTapers {
|
|||
// This flag seems like it was intended to be paired with `ANIM_FLAG_UPDATE_Y` to control
|
||||
// XZ movement based on the current animation.
|
||||
// However, this flag is not checked by the Skelanime system. XZ movement will always occur
|
||||
// regardless of the current state of this flag, as long as the "Actor Move" Anim Task is in use.
|
||||
// regardless of the current state of this flag, as long as the ActorMovement Anim Task is in use.
|
||||
// The name of this flag is speculative based on its usage in Player and in other actors.
|
||||
//
|
||||
// In practice, this flag only affects the scaling of Player's XZ position based on age.
|
||||
#define ANIM_FLAG_UPDATE_XZ (1 << 0)
|
||||
|
||||
// Enables the movement of an actor in the Y-axis based on the current animation.
|
||||
// This only has an effect if the "Actor Move" Anim Task is in use.
|
||||
// This only has an effect if the ActorMovement Anim Task is in use.
|
||||
//
|
||||
// This animation-driven movement does not replace "normal" movement from other sources
|
||||
// such as speed/velocity and collisions. The actor should stop updating other sources of movement
|
||||
|
@ -116,8 +116,13 @@ typedef enum AnimationTapers {
|
|||
// set. The adjustment will be applied in this case regardless of this flag being enabled.
|
||||
#define ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT (1 << 2)
|
||||
|
||||
// (player-only) Call AnimTaskQueue_AddActorMove
|
||||
#define ANIM_FLAG_PLAYER_SETMOVE (1 << 3)
|
||||
// When this flag is set, ActorMovement tasks will be queued.
|
||||
//
|
||||
// Note that individual actors are responsible for implementing the functionality of this flag.
|
||||
// In practice, Player is the only actor who implements this flag.
|
||||
// It is possible to bypass the need for this flag by manually calling `AnimTaskQueue_AddActorMovement`
|
||||
// when it is needed.
|
||||
#define ANIM_FLAG_ENABLE_MOVEMENT (1 << 3)
|
||||
|
||||
// When this flag is set, movement in all axes will not be applied for one frame. The flag
|
||||
// is unset automatically after one use, so movement can resume. The intent is for this flag to be used
|
||||
|
@ -139,7 +144,7 @@ typedef enum AnimationTapers {
|
|||
// frames have their translation occur relative to this new starting point.
|
||||
//
|
||||
// Note that for Player, this flag is only relevant when transitioning from an animation that was also using
|
||||
// animation translation. This is because of how `prevTransl` gets reset in `Player_AnimReplaceApplyFlags`.
|
||||
// ActorMovement. This is because of how `prevTransl` gets reset in `Player_AnimReplaceApplyFlags`.
|
||||
#define ANIM_FLAG_ADJUST_STARTING_POS (1 << 4)
|
||||
|
||||
// Disables "normal" movement from sources like speed/velocity and collisions, which allows the
|
||||
|
@ -170,7 +175,7 @@ typedef struct SkelAnime {
|
|||
s32 (*link)(struct PlayState*, struct SkelAnime*); // Can be Loop, Play once, or Morph
|
||||
} update;
|
||||
/* 0x34 */ s8 initFlags; // Flags used when initializing Link's skeleton
|
||||
/* 0x35 */ u8 moveFlags; // Flags used for animations that move the actor in worldspace.
|
||||
/* 0x35 */ u8 movementFlags; // Flags used for animations that move the actor in worldspace.
|
||||
/* 0x36 */ s16 prevRot; // Previous rotation in worldspace.
|
||||
/* 0x38 */ Vec3s prevTransl; // Previous modelspace translation.
|
||||
/* 0x3E */ Vec3s baseTransl; // Base modelspace translation.
|
||||
|
@ -342,11 +347,11 @@ typedef struct AnimTaskCopyUsingMapInverted {
|
|||
/* 0x0C */ u8* limbCopyMap;
|
||||
} AnimTaskCopyUsingMapInverted; // size = 0x10
|
||||
|
||||
typedef struct AnimTaskActorMove {
|
||||
typedef struct AnimTaskActorMovement {
|
||||
/* 0x00 */ struct Actor* actor;
|
||||
/* 0x04 */ struct SkelAnime* skelAnime;
|
||||
/* 0x08 */ f32 diffScaleY;
|
||||
} AnimTaskActorMove; // size = 0xC
|
||||
} AnimTaskActorMovement; // size = 0xC
|
||||
|
||||
typedef union AnimTaskData {
|
||||
AnimTaskLoadPlayerFrame loadPlayerFrame;
|
||||
|
@ -354,7 +359,7 @@ typedef union AnimTaskData {
|
|||
AnimTaskInterp interp;
|
||||
AnimTaskCopyUsingMap copyUsingMap;
|
||||
AnimTaskCopyUsingMapInverted copyUsingMapInverted;
|
||||
AnimTaskActorMove actorMove;
|
||||
AnimTaskActorMovement actorMovement;
|
||||
} AnimTaskData; // size = 0x3C
|
||||
|
||||
typedef struct AnimTask {
|
||||
|
@ -375,7 +380,7 @@ void AnimTaskQueue_AddCopy(struct PlayState* play, s32 vecCount, Vec3s* dest, Ve
|
|||
void AnimTaskQueue_AddInterp(struct PlayState* play, s32 vecCount, Vec3s* base, Vec3s* mod, f32 weight);
|
||||
void AnimTaskQueue_AddCopyUsingMap(struct PlayState* play, s32 vecCount, Vec3s* dest, Vec3s* src, u8* limbCopyMap);
|
||||
void AnimTaskQueue_AddCopyUsingMapInverted(struct PlayState* play, s32 vecCount, Vec3s* dest, Vec3s* src, u8* limbCopyMap);
|
||||
void AnimTaskQueue_AddActorMove(struct PlayState* play, struct Actor* actor, SkelAnime* skelAnime, f32 moveDiffScaleY);
|
||||
void AnimTaskQueue_AddActorMovement(struct PlayState* play, struct Actor* actor, SkelAnime* skelAnime, f32 moveDiffScaleY);
|
||||
|
||||
void AnimTaskQueue_SetNextGroup(struct PlayState* play);
|
||||
void AnimTaskQueue_DisableTransformTasksForGroup(struct PlayState* play);
|
||||
|
|
|
@ -1263,14 +1263,14 @@ s32 Player_OverrideLimbDrawGameplayCommon(PlayState* play, s32 limbIndex, Gfx**
|
|||
sCurBodyPartPos = &this->bodyPartsPos[0] - 1;
|
||||
|
||||
if (!LINK_IS_ADULT) {
|
||||
if (!(this->skelAnime.moveFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT) ||
|
||||
(this->skelAnime.moveFlags & ANIM_FLAG_UPDATE_XZ)) {
|
||||
if (!(this->skelAnime.movementFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT) ||
|
||||
(this->skelAnime.movementFlags & ANIM_FLAG_UPDATE_XZ)) {
|
||||
pos->x *= 0.64f;
|
||||
pos->z *= 0.64f;
|
||||
}
|
||||
|
||||
if (!(this->skelAnime.moveFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT) ||
|
||||
(this->skelAnime.moveFlags & ANIM_FLAG_UPDATE_Y)) {
|
||||
if (!(this->skelAnime.movementFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT) ||
|
||||
(this->skelAnime.movementFlags & ANIM_FLAG_UPDATE_Y)) {
|
||||
pos->y *= 0.64f;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -818,7 +818,7 @@ void AnimTaskQueue_SetNextGroup(PlayState* play) {
|
|||
* A transformative task is one that will alter the appearance of an animation.
|
||||
* These include Copy, Interp, CopyUsingMap, and CopyUsingMapInverted.
|
||||
*
|
||||
* LoadPlayerFrame and ActorMove, which don't alter the appearance of an existing animation,
|
||||
* LoadPlayerFrame and ActorMovement, which don't alter the appearance of an existing animation,
|
||||
* will always run even if a group has its transformative tasks disabled.
|
||||
*/
|
||||
void AnimTaskQueue_DisableTransformTasksForGroup(PlayState* play) {
|
||||
|
@ -960,13 +960,13 @@ void AnimTaskQueue_AddCopyUsingMapInverted(PlayState* play, s32 vecCount, Vec3s*
|
|||
/**
|
||||
* Creates a task which will move an actor according to the translation of its root limb for the current frame.
|
||||
*/
|
||||
void AnimTaskQueue_AddActorMove(PlayState* play, Actor* actor, SkelAnime* skelAnime, f32 moveDiffScaleY) {
|
||||
void AnimTaskQueue_AddActorMovement(PlayState* play, Actor* actor, SkelAnime* skelAnime, f32 moveDiffScaleY) {
|
||||
AnimTask* task = AnimTaskQueue_NewTask(&play->animTaskQueue, ANIMTASK_ACTOR_MOVE);
|
||||
|
||||
if (task != NULL) {
|
||||
task->data.actorMove.actor = actor;
|
||||
task->data.actorMove.skelAnime = skelAnime;
|
||||
task->data.actorMove.diffScaleY = moveDiffScaleY;
|
||||
task->data.actorMovement.actor = actor;
|
||||
task->data.actorMovement.skelAnime = skelAnime;
|
||||
task->data.actorMovement.diffScaleY = moveDiffScaleY;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1049,9 +1049,10 @@ void AnimTask_CopyUsingMapInverted(PlayState* play, AnimTaskData* data) {
|
|||
|
||||
/**
|
||||
* Move an actor according to the translation of its root limb for the current animation frame.
|
||||
* The actor's current shape yaw will factor into the resulting movement.
|
||||
*/
|
||||
void AnimTask_ActorMove(PlayState* play, AnimTaskData* data) {
|
||||
AnimTaskActorMove* task = &data->actorMove;
|
||||
void AnimTask_ActorMovement(PlayState* play, AnimTaskData* data) {
|
||||
AnimTaskActorMovement* task = &data->actorMovement;
|
||||
Actor* actor = task->actor;
|
||||
Vec3f diff;
|
||||
|
||||
|
@ -1070,8 +1071,8 @@ typedef void (*AnimTaskFunc)(struct PlayState* play, AnimTaskData* data);
|
|||
*/
|
||||
void AnimTaskQueue_Update(PlayState* play, AnimTaskQueue* animTaskQueue) {
|
||||
static AnimTaskFunc animTaskFuncs[] = {
|
||||
AnimTask_LoadPlayerFrame, AnimTask_Copy, AnimTask_Interp, AnimTask_CopyUsingMap,
|
||||
AnimTask_CopyUsingMapInverted, AnimTask_ActorMove,
|
||||
AnimTask_LoadPlayerFrame, AnimTask_Copy, AnimTask_Interp, AnimTask_CopyUsingMap,
|
||||
AnimTask_CopyUsingMapInverted, AnimTask_ActorMovement,
|
||||
};
|
||||
AnimTask* task = animTaskQueue->tasks;
|
||||
|
||||
|
@ -1838,7 +1839,7 @@ void SkelAnime_UpdateTranslation(SkelAnime* skelAnime, Vec3f* diff, s16 angle) {
|
|||
f32 cos;
|
||||
|
||||
// If `ANIM_FLAG_UPDATE_XZ` behaved as expected, it would also be checked here
|
||||
if (skelAnime->moveFlags & ANIM_FLAG_ADJUST_STARTING_POS) {
|
||||
if (skelAnime->movementFlags & ANIM_FLAG_ADJUST_STARTING_POS) {
|
||||
diff->x = diff->z = 0.0f;
|
||||
} else {
|
||||
x = skelAnime->jointTable[0].x;
|
||||
|
@ -1864,8 +1865,8 @@ void SkelAnime_UpdateTranslation(SkelAnime* skelAnime, Vec3f* diff, s16 angle) {
|
|||
skelAnime->prevTransl.z = skelAnime->jointTable[0].z;
|
||||
skelAnime->jointTable[0].z = skelAnime->baseTransl.z;
|
||||
|
||||
if (skelAnime->moveFlags & ANIM_FLAG_UPDATE_Y) {
|
||||
if (skelAnime->moveFlags & ANIM_FLAG_ADJUST_STARTING_POS) {
|
||||
if (skelAnime->movementFlags & ANIM_FLAG_UPDATE_Y) {
|
||||
if (skelAnime->movementFlags & ANIM_FLAG_ADJUST_STARTING_POS) {
|
||||
diff->y = 0.0f;
|
||||
} else {
|
||||
diff->y = skelAnime->jointTable[0].y - skelAnime->prevTransl.y;
|
||||
|
@ -1878,7 +1879,7 @@ void SkelAnime_UpdateTranslation(SkelAnime* skelAnime, Vec3f* diff, s16 angle) {
|
|||
skelAnime->prevTransl.y = skelAnime->jointTable[0].y;
|
||||
}
|
||||
|
||||
skelAnime->moveFlags &= ~ANIM_FLAG_ADJUST_STARTING_POS;
|
||||
skelAnime->movementFlags &= ~ANIM_FLAG_ADJUST_STARTING_POS;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -176,20 +176,20 @@ void DemoEc_UpdateBgFlags(DemoEc* this, PlayState* play) {
|
|||
}
|
||||
|
||||
void func_8096D594(DemoEc* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_8096D5D4(DemoEc* this, PlayState* play) {
|
||||
this->skelAnime.baseTransl = this->skelAnime.jointTable[0];
|
||||
this->skelAnime.prevTransl = this->skelAnime.jointTable[0];
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_8096D64C(DemoEc* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void DemoEc_UpdateEyes(DemoEc* this) {
|
||||
|
|
|
@ -54,12 +54,12 @@ s32 DemoIk_CheckForCue(PlayState* play, u16 cueId, s32 cueChannel) {
|
|||
}
|
||||
|
||||
void DemoIk_SetMove(DemoIk* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void DemoIk_EndMove(DemoIk* this) {
|
||||
this->skelAnime.moveFlags &= ~ANIM_FLAG_UPDATE_XZ;
|
||||
this->skelAnime.movementFlags &= ~ANIM_FLAG_UPDATE_XZ;
|
||||
}
|
||||
|
||||
f32 DemoIk_GetCurFrame(DemoIk* this) {
|
||||
|
|
|
@ -337,8 +337,8 @@ void func_80A795C8(EnIn* this, PlayState* play) {
|
|||
|
||||
void func_80A79690(SkelAnime* skelAnime, EnIn* this, PlayState* play) {
|
||||
if (skelAnime->baseTransl.y < skelAnime->jointTable[0].y) {
|
||||
skelAnime->moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, skelAnime, 1.0f);
|
||||
skelAnime->movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, skelAnime, 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -756,8 +756,8 @@ void EnNb_InitDemo6KInConfrontation(EnNb* this, PlayState* play) {
|
|||
}
|
||||
|
||||
void func_80AB2688(EnNb* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_80AB26C8(EnNb* this) {
|
||||
|
|
|
@ -392,17 +392,17 @@ s32 EnRu1_UpdateSkelAnime(EnRu1* this) {
|
|||
}
|
||||
|
||||
void func_80AEB364(EnRu1* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_80AEB3A4(EnRu1* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
func_80AEB364(this, play);
|
||||
}
|
||||
|
||||
void func_80AEB3CC(EnRu1* this) {
|
||||
this->skelAnime.moveFlags &= ~ANIM_FLAG_UPDATE_XZ;
|
||||
this->skelAnime.movementFlags &= ~ANIM_FLAG_UPDATE_XZ;
|
||||
}
|
||||
|
||||
void func_80AEB3DC(EnRu1* this, PlayState* play) {
|
||||
|
@ -463,8 +463,8 @@ void func_80AEB6E0(EnRu1* this, PlayState* play) {
|
|||
SkelAnime* skelAnime = &this->skelAnime;
|
||||
|
||||
if (skelAnime->baseTransl.y < skelAnime->jointTable[0].y) {
|
||||
skelAnime->moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, skelAnime, 1.0f);
|
||||
skelAnime->movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, skelAnime, 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -474,13 +474,13 @@ void func_80AEB738(EnRu1* this, PlayState* play) {
|
|||
skelAnime->baseTransl = skelAnime->jointTable[0];
|
||||
skelAnime->prevTransl = skelAnime->jointTable[0];
|
||||
if (skelAnime->baseTransl.y < skelAnime->jointTable[0].y) {
|
||||
skelAnime->moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, skelAnime, 1.0f);
|
||||
skelAnime->movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, skelAnime, 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
void func_80AEB7D0(EnRu1* this) {
|
||||
this->skelAnime.moveFlags &= ~(ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y);
|
||||
this->skelAnime.movementFlags &= ~(ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y);
|
||||
}
|
||||
|
||||
f32 func_80AEB7E0(CsCmdActorCue* cue, PlayState* play) {
|
||||
|
|
|
@ -1593,7 +1593,7 @@ void func_8086318C(EnTest* this, PlayState* play) {
|
|||
|
||||
void EnTest_SetupRecoil(EnTest* this) {
|
||||
this->swordState = 0;
|
||||
this->skelAnime.moveFlags = ANIM_FLAG_UPDATE_Y;
|
||||
this->skelAnime.movementFlags = ANIM_FLAG_UPDATE_Y;
|
||||
this->unk_7C8 = 0x13;
|
||||
this->skelAnime.playSpeed = -1.0f;
|
||||
this->skelAnime.startFrame = this->skelAnime.curFrame;
|
||||
|
|
|
@ -253,25 +253,25 @@ void func_80B3C8CC(EnXc* this, PlayState* play) {
|
|||
SkelAnime* skelAnime = &this->skelAnime;
|
||||
|
||||
if (skelAnime->jointTable[0].y >= skelAnime->baseTransl.y) {
|
||||
skelAnime->moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, skelAnime, 1.0f);
|
||||
skelAnime->movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, skelAnime, 1.0f);
|
||||
}
|
||||
}
|
||||
|
||||
void func_80B3C924(EnXc* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_80B3C964(EnXc* this, PlayState* play) {
|
||||
this->skelAnime.baseTransl = this->skelAnime.jointTable[0];
|
||||
this->skelAnime.prevTransl = this->skelAnime.jointTable[0];
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_80B3C9DC(EnXc* this) {
|
||||
this->skelAnime.moveFlags &= ~(ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y);
|
||||
this->skelAnime.movementFlags &= ~(ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y);
|
||||
}
|
||||
|
||||
void func_80B3C9EC(EnXc* this) {
|
||||
|
|
|
@ -345,8 +345,8 @@ void func_80B4B834(CsCmdActorCue* cue, Vec3f* dest) {
|
|||
}
|
||||
|
||||
void func_80B4B874(EnZl1* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_80B4B8B4(EnZl1* this, PlayState* play) {
|
||||
|
|
|
@ -298,8 +298,8 @@ void EnZl4_UpdateFace(EnZl4* this) {
|
|||
}
|
||||
|
||||
void EnZl4_SetMove(EnZl4* this, PlayState* play) {
|
||||
this->skelAnime.moveFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
this->skelAnime.movementFlags |= ANIM_FLAG_UPDATE_XZ;
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime, 1.0f);
|
||||
}
|
||||
|
||||
void func_80B5BB78(EnZl4* this, PlayState* play) {
|
||||
|
|
|
@ -52,11 +52,11 @@ void ObjHsblock_SetupAction(ObjHsblock* this, ObjHsblockActionFunc actionFunc) {
|
|||
this->actionFunc = actionFunc;
|
||||
}
|
||||
|
||||
void func_80B93B68(ObjHsblock* this, PlayState* play, CollisionHeader* collision, s32 moveFlags) {
|
||||
void func_80B93B68(ObjHsblock* this, PlayState* play, CollisionHeader* collision, s32 transformFlags) {
|
||||
s32 pad;
|
||||
CollisionHeader* colHeader = NULL;
|
||||
|
||||
DynaPolyActor_Init(&this->dyna, moveFlags);
|
||||
DynaPolyActor_Init(&this->dyna, transformFlags);
|
||||
CollisionHeader_GetVirtual(collision, &colHeader);
|
||||
this->dyna.bgId = DynaPoly_SetBgActor(play, &play->colCtx.dyna, &this->dyna.actor, colHeader);
|
||||
|
||||
|
|
|
@ -1974,26 +1974,26 @@ void Player_ZeroRootLimbYaw(Player* this) {
|
|||
}
|
||||
|
||||
void func_80832DBC(Player* this) {
|
||||
if (this->skelAnime.moveFlags != 0) {
|
||||
if (this->skelAnime.movementFlags != 0) {
|
||||
func_808322FC(this);
|
||||
this->skelAnime.jointTable[0].x = this->skelAnime.baseTransl.x;
|
||||
this->skelAnime.jointTable[0].z = this->skelAnime.baseTransl.z;
|
||||
if (this->skelAnime.moveFlags & ANIM_FLAG_PLAYER_SETMOVE) {
|
||||
if (this->skelAnime.moveFlags & ANIM_FLAG_UPDATE_Y) {
|
||||
if (this->skelAnime.movementFlags & ANIM_FLAG_ENABLE_MOVEMENT) {
|
||||
if (this->skelAnime.movementFlags & ANIM_FLAG_UPDATE_Y) {
|
||||
this->skelAnime.jointTable[0].y = this->skelAnime.prevTransl.y;
|
||||
}
|
||||
} else {
|
||||
this->skelAnime.jointTable[0].y = this->skelAnime.baseTransl.y;
|
||||
}
|
||||
Player_SkelAnimeResetPrevTranslRot(this);
|
||||
this->skelAnime.moveFlags = 0;
|
||||
this->skelAnime.movementFlags = 0;
|
||||
}
|
||||
}
|
||||
|
||||
void func_80832E48(Player* this, s32 flags) {
|
||||
Vec3f pos;
|
||||
|
||||
this->skelAnime.moveFlags = flags;
|
||||
this->skelAnime.movementFlags = flags;
|
||||
this->skelAnime.prevTransl = this->skelAnime.baseTransl;
|
||||
SkelAnime_UpdateTranslation(&this->skelAnime, &pos, this->actor.shape.rot.y);
|
||||
|
||||
|
@ -2022,14 +2022,14 @@ void func_80832E48(Player* this, s32 flags) {
|
|||
void Player_AnimReplaceApplyFlags(PlayState* play, Player* this, s32 flags) {
|
||||
if (flags & ANIM_REPLACE_APPLY_FLAG_9) {
|
||||
Player_SkelAnimeResetPrevTranslRotAgeScale(this);
|
||||
} else if ((flags & ANIM_REPLACE_APPLY_FLAG_8) || (this->skelAnime.moveFlags != 0)) {
|
||||
} else if ((flags & ANIM_REPLACE_APPLY_FLAG_8) || (this->skelAnime.movementFlags != 0)) {
|
||||
Player_SkelAnimeResetPrevTranslRot(this);
|
||||
} else {
|
||||
this->skelAnime.prevTransl = this->skelAnime.jointTable[0];
|
||||
this->skelAnime.prevRot = this->actor.shape.rot.y;
|
||||
}
|
||||
|
||||
this->skelAnime.moveFlags = flags & 0xFF;
|
||||
this->skelAnime.movementFlags = flags & 0xFF;
|
||||
Player_ZeroSpeedXZ(this);
|
||||
AnimTaskQueue_DisableTransformTasksForGroup(play);
|
||||
}
|
||||
|
@ -2050,7 +2050,7 @@ void Player_AnimReplacePlayOnceAdjusted(PlayState* play, Player* this, LinkAnima
|
|||
|
||||
void Player_AnimReplaceNormalPlayOnceAdjusted(PlayState* play, Player* this, LinkAnimationHeader* anim) {
|
||||
Player_AnimReplacePlayOnceAdjusted(play, this, anim,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS);
|
||||
}
|
||||
|
||||
|
@ -2070,7 +2070,7 @@ void Player_AnimReplacePlayLoopAdjusted(PlayState* play, Player* this, LinkAnima
|
|||
|
||||
void Player_AnimReplaceNormalPlayLoopAdjusted(PlayState* play, Player* this, LinkAnimationHeader* anim) {
|
||||
Player_AnimReplacePlayLoopAdjusted(play, this, anim,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS);
|
||||
}
|
||||
|
||||
|
@ -3076,7 +3076,7 @@ s32 func_80835588(Player* this, PlayState* play) {
|
|||
void Player_SetParallel(Player* this) {
|
||||
this->stateFlags1 |= PLAYER_STATE1_PARALLEL;
|
||||
|
||||
if (!(this->skelAnime.moveFlags & ANIM_FLAG_OVERRIDE_MOVEMENT) &&
|
||||
if (!(this->skelAnime.movementFlags & ANIM_FLAG_OVERRIDE_MOVEMENT) &&
|
||||
(this->actor.bgCheckFlags & BGCHECKFLAG_PLAYER_WALL_INTERACT) && (sShapeYawToTouchedWall < 0x2000)) {
|
||||
// snap to the wall
|
||||
this->yaw = this->actor.shape.rot.y = this->actor.wallYaw + 0x8000;
|
||||
|
@ -3282,10 +3282,10 @@ s32 Player_SetupAction(PlayState* play, Player* this, PlayerActionFunc actionFun
|
|||
void func_80835DAC(PlayState* play, Player* this, PlayerActionFunc actionFunc, s32 flags) {
|
||||
s32 temp;
|
||||
|
||||
temp = this->skelAnime.moveFlags;
|
||||
this->skelAnime.moveFlags = 0;
|
||||
temp = this->skelAnime.movementFlags;
|
||||
this->skelAnime.movementFlags = 0;
|
||||
Player_SetupAction(play, this, actionFunc, flags);
|
||||
this->skelAnime.moveFlags = temp;
|
||||
this->skelAnime.movementFlags = temp;
|
||||
}
|
||||
|
||||
void func_80835DE4(PlayState* play, Player* this, PlayerActionFunc actionFunc, s32 flags) {
|
||||
|
@ -3495,7 +3495,7 @@ s32 Player_UpdateUpperBody(Player* this, PlayState* play) {
|
|||
this->stateFlags3 |= PLAYER_STATE3_FLYING_WITH_HOOKSHOT;
|
||||
Player_AnimPlayOnce(play, this, &gPlayerAnim_link_hook_fly_start);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
func_80832224(this);
|
||||
this->yaw = this->actor.shape.rot.y;
|
||||
|
@ -4281,7 +4281,7 @@ void func_80837948(PlayState* play, Player* this, s32 arg2) {
|
|||
Player_AnimPlayOnceAdjusted(play, this, D_80854190[arg2].unk_00);
|
||||
if ((arg2 != PLAYER_MWA_FLIPSLASH_START) && (arg2 != PLAYER_MWA_JUMPSLASH_START)) {
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_REPLACE_APPLY_FLAG_9 | ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_PLAYER_SETMOVE);
|
||||
ANIM_REPLACE_APPLY_FLAG_9 | ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_ENABLE_MOVEMENT);
|
||||
}
|
||||
|
||||
this->yaw = this->actor.shape.rot.y;
|
||||
|
@ -5192,7 +5192,7 @@ s32 Player_ActionChange_1(Player* this, PlayState* play) {
|
|||
func_80832224(this);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_REPLACE_APPLY_FLAG_9 | ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
|
||||
// If this door is the second half of a double door (spawned as child)
|
||||
|
@ -5504,7 +5504,7 @@ s32 func_8083A6AC(Player* this, PlayState* play) {
|
|||
this->stateFlags1 |= PLAYER_STATE1_21;
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
|
||||
this->av2.actionVar2 = -1;
|
||||
|
@ -5550,7 +5550,8 @@ void func_8083AA10(Player* this, PlayState* play) {
|
|||
return;
|
||||
}
|
||||
|
||||
if (!(this->stateFlags3 & PLAYER_STATE3_1) && !(this->skelAnime.moveFlags & ANIM_FLAG_OVERRIDE_MOVEMENT) &&
|
||||
if (!(this->stateFlags3 & PLAYER_STATE3_1) &&
|
||||
!(this->skelAnime.movementFlags & ANIM_FLAG_OVERRIDE_MOVEMENT) &&
|
||||
(Player_Action_8084411C != this->actionFunc) && (Player_Action_80844A44 != this->actionFunc)) {
|
||||
|
||||
if ((sPrevFloorProperty == FLOOR_PROPERTY_7) || (this->meleeWeaponState != 0)) {
|
||||
|
@ -6618,7 +6619,7 @@ void func_8083D53C(PlayState* play, Player* this) {
|
|||
return;
|
||||
}
|
||||
} else if ((this->stateFlags1 & PLAYER_STATE1_27) && (this->actor.depthInWater < this->ageProperties->unk_24)) {
|
||||
if ((this->skelAnime.moveFlags == 0) && (this->currentBoots != PLAYER_BOOTS_IRON)) {
|
||||
if ((this->skelAnime.movementFlags == 0) && (this->currentBoots != PLAYER_BOOTS_IRON)) {
|
||||
func_8083CD54(play, this, this->actor.shape.rot.y);
|
||||
}
|
||||
func_8083D0A8(play, this, this->actor.velocity.y);
|
||||
|
@ -6863,7 +6864,7 @@ s32 Player_ActionChange_3(Player* this, PlayState* play) {
|
|||
Actor_MountHorse(play, this, &rideActor->actor);
|
||||
Player_AnimPlayOnce(play, this, D_80854578[temp].anim);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
|
||||
this->actor.parent = this->rideActor;
|
||||
|
@ -7033,7 +7034,7 @@ s32 Player_ActionChange_2(Player* this, PlayState* play) {
|
|||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_REPLACE_APPLY_FLAG_9 | ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT |
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
chest->unk_1F4 = 1;
|
||||
Camera_RequestSetting(Play_GetCamera(play, CAM_ID_MAIN), CAM_SET_SLOW_CHEST_CS);
|
||||
} else {
|
||||
|
@ -7212,7 +7213,7 @@ s32 func_8083EC18(Player* this, PlayState* play, u32 wallFlags) {
|
|||
Player_AnimReplaceApplyFlags(
|
||||
play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT |
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -7293,7 +7294,7 @@ s32 Player_TryEnteringCrawlspace(Player* this, PlayState* play, u32 interactWall
|
|||
Player_AnimPlayOnce(play, this, &gPlayerAnim_link_child_tunnel_start);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT |
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
|
||||
return true;
|
||||
|
@ -7384,7 +7385,7 @@ s32 Player_TryLeavingCrawlspace(Player* this, PlayState* play) {
|
|||
Player_AnimPlayOnce(play, this, &gPlayerAnim_link_child_tunnel_end);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT |
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
OnePointCutscene_Init(play, 9601, 999, NULL, CAM_ID_MAIN);
|
||||
} else {
|
||||
|
@ -7395,7 +7396,7 @@ s32 Player_TryLeavingCrawlspace(Player* this, PlayState* play) {
|
|||
0.0f);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT |
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
OnePointCutscene_Init(play, 9602, 999, NULL, CAM_ID_MAIN);
|
||||
}
|
||||
|
@ -10115,7 +10116,7 @@ void func_808467D4(PlayState* play, Player* this) {
|
|||
0.0f);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_REPLACE_APPLY_FLAG_9 | ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
if (LINK_IS_ADULT) {
|
||||
func_80846720(play, this, 0);
|
||||
|
@ -10126,7 +10127,7 @@ void func_808467D4(PlayState* play, Player* this) {
|
|||
void func_808468A8(PlayState* play, Player* this) {
|
||||
Player_SetupAction(play, this, Player_Action_8084F9A0, 0);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
|
||||
|
@ -11287,7 +11288,7 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) {
|
|||
this->stateFlags1 |= PLAYER_STATE1_23;
|
||||
Player_AnimPlayOnce(play, this, &gPlayerAnim_link_uma_wait_1);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
this->av2.actionVar2 = 99;
|
||||
}
|
||||
|
@ -11313,7 +11314,7 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) {
|
|||
func_8084FF7C(this);
|
||||
}
|
||||
|
||||
if (!(this->skelAnime.moveFlags & ANIM_FLAG_OVERRIDE_MOVEMENT)) {
|
||||
if (!(this->skelAnime.movementFlags & ANIM_FLAG_OVERRIDE_MOVEMENT)) {
|
||||
if (((this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) && (sFloorType == FLOOR_TYPE_5) &&
|
||||
(this->currentBoots != PLAYER_BOOTS_IRON)) ||
|
||||
((this->currentBoots == PLAYER_BOOTS_HOVER) &&
|
||||
|
@ -11498,11 +11499,11 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) {
|
|||
|
||||
Player_UpdateCamAndSeqModes(play, this);
|
||||
|
||||
if (this->skelAnime.moveFlags & ANIM_FLAG_PLAYER_SETMOVE) {
|
||||
AnimTaskQueue_AddActorMove(play, &this->actor, &this->skelAnime,
|
||||
(this->skelAnime.moveFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT)
|
||||
? 1.0f
|
||||
: this->ageProperties->unk_08);
|
||||
if (this->skelAnime.movementFlags & ANIM_FLAG_ENABLE_MOVEMENT) {
|
||||
AnimTaskQueue_AddActorMovement(play, &this->actor, &this->skelAnime,
|
||||
(this->skelAnime.movementFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT)
|
||||
? 1.0f
|
||||
: this->ageProperties->unk_08);
|
||||
}
|
||||
|
||||
Player_UpdateShapeYaw(this, play);
|
||||
|
@ -12095,7 +12096,7 @@ void Player_Action_8084B530(Player* this, PlayState* play) {
|
|||
} else if (func_808332B8(this)) {
|
||||
Player_Action_8084D610(this, play);
|
||||
} else if (!Player_CheckHostileLockOn(this) && LinkAnimation_Update(play, &this->skelAnime)) {
|
||||
if (this->skelAnime.moveFlags != 0) {
|
||||
if (this->skelAnime.movementFlags != 0) {
|
||||
func_80832DBC(this);
|
||||
if ((this->talkActor->category == ACTORCAT_NPC) && (this->heldItemAction != PLAYER_IA_FISHING_POLE)) {
|
||||
Player_AnimPlayOnceAdjusted(play, this, &gPlayerAnim_link_normal_talk_free);
|
||||
|
@ -12543,8 +12544,8 @@ void Player_Action_8084C760(Player* this, PlayState* play) {
|
|||
if (LinkAnimation_Update(play, &this->skelAnime)) {
|
||||
if (!(this->stateFlags1 & PLAYER_STATE1_0)) {
|
||||
// While inside a crawlspace, player's skeleton does not move
|
||||
if (this->skelAnime.moveFlags != 0) {
|
||||
this->skelAnime.moveFlags = 0;
|
||||
if (this->skelAnime.movementFlags != 0) {
|
||||
this->skelAnime.movementFlags = 0;
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -14130,7 +14131,7 @@ void Player_Action_808502D0(Player* this, PlayState* play) {
|
|||
|
||||
if (LinkAnimation_Update(play, &this->skelAnime)) {
|
||||
if (!Player_ActionChange_7(this, play)) {
|
||||
u8 sp43 = this->skelAnime.moveFlags;
|
||||
u8 sp43 = this->skelAnime.movementFlags;
|
||||
LinkAnimationHeader* sp3C;
|
||||
|
||||
if (Player_CheckHostileLockOn(this)) {
|
||||
|
@ -14140,7 +14141,7 @@ void Player_Action_808502D0(Player* this, PlayState* play) {
|
|||
}
|
||||
|
||||
func_80832318(this);
|
||||
this->skelAnime.moveFlags = 0;
|
||||
this->skelAnime.movementFlags = 0;
|
||||
|
||||
if ((sp3C == &gPlayerAnim_link_fighter_Lpower_jump_kiru_end) &&
|
||||
(this->modelAnimType != PLAYER_ANIMTYPE_3)) {
|
||||
|
@ -14149,7 +14150,7 @@ void Player_Action_808502D0(Player* this, PlayState* play) {
|
|||
|
||||
func_8083A098(this, sp3C, play);
|
||||
|
||||
this->skelAnime.moveFlags = sp43;
|
||||
this->skelAnime.movementFlags = sp43;
|
||||
this->stateFlags3 |= PLAYER_STATE3_3;
|
||||
}
|
||||
} else if (this->heldItemAction == PLAYER_IA_HAMMER) {
|
||||
|
@ -14709,7 +14710,7 @@ void func_808510D4(PlayState* play, Player* this, void* anim) {
|
|||
|
||||
void func_808510F4(PlayState* play, Player* this, void* anim) {
|
||||
Player_AnimReplacePlayOnce(play, this, anim,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
|
||||
|
@ -14719,7 +14720,7 @@ void func_80851114(PlayState* play, Player* this, void* anim) {
|
|||
|
||||
void func_80851134(PlayState* play, Player* this, void* anim) {
|
||||
Player_AnimReplacePlayLoop(play, this, anim,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
|
||||
|
@ -14967,7 +14968,7 @@ void func_808519EC(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
|||
Player_AnimPlayOnceAdjusted(play, this, this->ageProperties->unk_9C);
|
||||
Player_AnimReplaceApplyFlags(play, this,
|
||||
ANIM_REPLACE_APPLY_FLAG_9 | ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_UPDATE_Y |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
|
||||
|
@ -15079,13 +15080,13 @@ void func_80851E28(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
|||
|
||||
void func_80851E64(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
Player_AnimReplacePlayOnceAdjusted(play, this, &gPlayerAnim_link_swimer_swim_get,
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
|
||||
void func_80851E90(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
Player_AnimReplacePlayOnce(play, this, &gPlayerAnim_clink_op3_negaeri,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
Player_PlayVoiceSfx(this, NA_SE_VO_LI_GROAN);
|
||||
}
|
||||
|
@ -15093,7 +15094,7 @@ void func_80851E90(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
|||
void func_80851ECC(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
if (LinkAnimation_Update(play, &this->skelAnime)) {
|
||||
Player_AnimReplacePlayLoop(play, this, &gPlayerAnim_clink_op3_wait2,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
}
|
||||
|
@ -15121,7 +15122,7 @@ static AnimSfxEntry D_808551BC[] = {
|
|||
void func_80851FB0(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
if (LinkAnimation_Update(play, &this->skelAnime)) {
|
||||
Player_AnimReplacePlayLoop(play, this, &gPlayerAnim_clink_op3_wait3,
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_PLAYER_SETMOVE |
|
||||
ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT | ANIM_FLAG_ENABLE_MOVEMENT |
|
||||
ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
this->av2.actionVar2 = 1;
|
||||
} else if (this->av2.actionVar2 == 0) {
|
||||
|
@ -15147,7 +15148,7 @@ void func_80852048(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
|||
void func_80852080(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
Player_AnimReplacePlayOnceAdjusted(play, this, &gPlayerAnim_clink_demo_futtobi,
|
||||
ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT |
|
||||
ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS |
|
||||
ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
Player_PlayVoiceSfx(this, NA_SE_VO_LI_FALL_L);
|
||||
}
|
||||
|
@ -15197,7 +15198,7 @@ void func_80852234(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
|||
|
||||
void func_8085225C(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
Player_AnimReplaceApplyFlags(
|
||||
play, this, ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
play, this, ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS | ANIM_FLAG_OVERRIDE_MOVEMENT);
|
||||
}
|
||||
|
||||
void func_80852280(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
||||
|
@ -15424,7 +15425,7 @@ void func_80852A54(PlayState* play, Player* this, CsCmdActorCue* cue) {
|
|||
func_808529D0(play, this, cue);
|
||||
}
|
||||
|
||||
this->skelAnime.moveFlags = 0;
|
||||
this->skelAnime.movementFlags = 0;
|
||||
Player_ZeroRootLimbYaw(this);
|
||||
}
|
||||
|
||||
|
@ -15436,7 +15437,7 @@ void func_80852B4C(PlayState* play, Player* this, CsCmdActorCue* cue, struct_808
|
|||
}
|
||||
|
||||
if ((D_80858AA0 & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT) &&
|
||||
!(this->skelAnime.moveFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT)) {
|
||||
!(this->skelAnime.movementFlags & ANIM_FLAG_DISABLE_CHILD_ROOT_ADJUSTMENT)) {
|
||||
this->skelAnime.morphTable[0].y /= this->ageProperties->unk_08;
|
||||
D_80858AA0 = 0;
|
||||
}
|
||||
|
@ -15476,7 +15477,7 @@ void func_80852C50(PlayState* play, Player* this, CsCmdActorCue* cueUnused) {
|
|||
}
|
||||
}
|
||||
|
||||
D_80858AA0 = this->skelAnime.moveFlags;
|
||||
D_80858AA0 = this->skelAnime.movementFlags;
|
||||
|
||||
func_80832DBC(this);
|
||||
PRINTF("TOOL MODE=%d\n", csAction);
|
||||
|
@ -15495,7 +15496,7 @@ void func_80852C50(PlayState* play, Player* this, CsCmdActorCue* cueUnused) {
|
|||
|
||||
void Player_Action_CsAction(Player* this, PlayState* play) {
|
||||
if (this->csAction != this->prevCsAction) {
|
||||
D_80858AA0 = this->skelAnime.moveFlags;
|
||||
D_80858AA0 = this->skelAnime.movementFlags;
|
||||
|
||||
func_80832DBC(this);
|
||||
this->prevCsAction = this->csAction;
|
||||
|
@ -15631,7 +15632,7 @@ void func_80853148(PlayState* play, Actor* actor) {
|
|||
|
||||
if (this->skelAnime.animation == &gPlayerAnim_link_normal_backspace) {
|
||||
Player_AnimReplaceApplyFlags(
|
||||
play, this, ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_PLAYER_SETMOVE | ANIM_FLAG_ADJUST_STARTING_POS);
|
||||
play, this, ANIM_FLAG_UPDATE_XZ | ANIM_FLAG_ENABLE_MOVEMENT | ANIM_FLAG_ADJUST_STARTING_POS);
|
||||
}
|
||||
|
||||
func_80832224(this);
|
||||
|
|
Loading…
Add table
Reference in a new issue