From c589285826f102b2e41619b39ea1ba66510325d1 Mon Sep 17 00:00:00 2001 From: fig02 Date: Sat, 11 Jul 2020 22:39:34 -0400 Subject: [PATCH] Clean up SkelAnime_GetFrameCount usage (#245) * fix colliderinit typo * clean up SkelAnime_GetFrameCount usage * line breaks --- src/code/z_effect_soft_sprite_old_init.c | 2 +- src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c | 2 +- src/overlays/actors/ovl_En_Ani/z_en_ani.c | 4 +-- src/overlays/actors/ovl_En_Cow/z_en_cow.c | 4 +-- .../actors/ovl_En_Heishi1/z_en_heishi1.c | 26 +++++++++------- .../actors/ovl_En_Heishi2/z_en_heishi2.c | 31 +++++++++++++------ .../actors/ovl_En_Heishi3/z_en_heishi3.c | 19 ++++++++---- .../actors/ovl_En_Hintnuts/z_en_hintnuts.c | 2 +- src/overlays/actors/ovl_En_Sb/z_en_sb.c | 4 +-- .../actors/ovl_En_Wallmas/z_en_wallmas.c | 6 ++-- 10 files changed, 60 insertions(+), 40 deletions(-) diff --git a/src/code/z_effect_soft_sprite_old_init.c b/src/code/z_effect_soft_sprite_old_init.c index dfe2eea150..831ab107fe 100644 --- a/src/code/z_effect_soft_sprite_old_init.c +++ b/src/code/z_effect_soft_sprite_old_init.c @@ -170,7 +170,7 @@ #pragma GLOBAL_ASM("asm/non_matchings/code/z_effect_soft_sprite_old_init/func_80029DBC.s") void EffectSsSolderSrchBall_Spawn(GlobalContext* globalCtx, Vec3f* pos, Vec3f* velocity, Vec3f* accel, s16 arg4, - s16* linkDetected) { + s16* linkDetected) { EffectSsSolderSrchBallInitParams initParams; Math_Vec3f_Copy(&initParams.pos, pos); diff --git a/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c b/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c index b598cb8b69..562d65f2e7 100644 --- a/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c +++ b/src/overlays/actors/ovl_Demo_Sa/z_demo_sa.c @@ -192,7 +192,7 @@ void func_8098E6EC(DemoSa* this, GlobalContext* globalCtx, s32 actionIdx) { void func_8098E76C(DemoSa* this, AnimationHeader* animationHeader, u8 arg2, f32 transitionRate, s32 arg4) { s32 pad[2]; - s16 frameCount = SkelAnime_GetFrameCount(&animationHeader->genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&animationHeader->genericHeader); f32 playbackSpeed; f32 unk0; f32 fc; diff --git a/src/overlays/actors/ovl_En_Ani/z_en_ani.c b/src/overlays/actors/ovl_En_Ani/z_en_ani.c index c202ef79c3..a6dbf29fb3 100644 --- a/src/overlays/actors/ovl_En_Ani/z_en_ani.c +++ b/src/overlays/actors/ovl_En_Ani/z_en_ani.c @@ -212,8 +212,8 @@ void func_809B0994(EnAni* this, GlobalContext* globalCtx) { AnimationHeader* objSegChangeAnime = &D_060070F0; if (globalCtx->csCtx.npcActions[0]->action == 4) { - SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 1.0f, 0.0f, - (f32)SkelAnime_GetFrameCount(objSegFrameCount), 2, -4.0f); + SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 1.0f, 0.0f, SkelAnime_GetFrameCount(objSegFrameCount), + 2, -4.0f); this->unk_2AA += 1; this->actor.shape.shadowDrawFunc = ActorShadow_DrawFunc_Circle; } diff --git a/src/overlays/actors/ovl_En_Cow/z_en_cow.c b/src/overlays/actors/ovl_En_Cow/z_en_cow.c index c025fa487d..d167ecf116 100644 --- a/src/overlays/actors/ovl_En_Cow/z_en_cow.c +++ b/src/overlays/actors/ovl_En_Cow/z_en_cow.c @@ -343,10 +343,10 @@ void func_809DFE98(Actor* thisx, GlobalContext* globalCtx) { if (SkelAnime_FrameUpdateMatrix(&this->skelAnime) != 0) { if (this->skelAnime.animCurrentSeg == &D_06004348) { SkelAnime_ChangeAnim(&this->skelAnime, &D_06004E98, 1.0f, 0.0f, - (f32)SkelAnime_GetFrameCount(&D_06004E98.genericHeader), 2, 1.0f); + SkelAnime_GetFrameCount(&D_06004E98.genericHeader), 2, 1.0f); } else { SkelAnime_ChangeAnim(&this->skelAnime, &D_06004348, 1.0f, 0.0f, - (f32)SkelAnime_GetFrameCount(&D_06004348.genericHeader), 0, 1.0f); + SkelAnime_GetFrameCount(&D_06004348.genericHeader), 0, 1.0f); } } this->actionFunc(this, globalCtx); diff --git a/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c b/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c index 03d4800656..2f5db00f38 100644 --- a/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c +++ b/src/overlays/actors/ovl_En_Heishi1/z_en_heishi1.c @@ -140,9 +140,10 @@ void EnHeishi1_Destroy(Actor* thisx, GlobalContext* globalCtx) { } void EnHeishi1_SetupWalk(EnHeishi1* this, GlobalContext* globalCtx) { - s16 frameCount = (f32)SkelAnime_GetFrameCount(&D_06005880.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005880.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, this->animSpeed, 0.0f, frameCount, 0, this->transitionRate); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, this->animSpeed, 0.0f, (s16)frameCount, 0, + this->transitionRate); this->bodyTurnSpeed = 0.0f; this->moveSpeed = 0.0f; this->headDirection = Math_Rand_ZeroFloat(1.99f); @@ -223,9 +224,9 @@ void EnHeishi1_Walk(EnHeishi1* this, GlobalContext* globalCtx) { } void EnHeishi1_SetupMoveToLink(EnHeishi1* this, GlobalContext* globalCtx) { - s16 frameCount = (f32)SkelAnime_GetFrameCount(&D_06005880.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005880.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, 3.0f, 0.0f, frameCount, 0, -3.0f); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, 3.0f, 0.0f, (s16)frameCount, 0, -3.0f); this->bodyTurnSpeed = 0.0f; this->moveSpeed = 0.0f; func_8010B680(globalCtx, 0x702D, &this->actor); @@ -251,9 +252,10 @@ void EnHeishi1_MoveToLink(EnHeishi1* this, GlobalContext* globalCtx) { void EnHeishi1_SetupWait(EnHeishi1* this, GlobalContext* globalCtx) { s16 rand; - s16 frameCount = (f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, this->animSpeed, 0.0f, frameCount, 0, this->transitionRate); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, this->animSpeed, 0.0f, (s16)frameCount, 0, + this->transitionRate); this->headBehaviorDecided = false; this->headDirection = Math_Rand_ZeroFloat(1.99f); rand = Math_Rand_ZeroFloat(50.0f); @@ -320,9 +322,9 @@ void EnHeishi1_Wait(EnHeishi1* this, GlobalContext* globalCtx) { } void EnHeishi1_SetupTurnTowardLink(EnHeishi1* this, GlobalContext* globalCtx) { - s16 frameCount = (f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, frameCount, 0, -10.0f); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->kickTimer = 30; this->actionFunc = EnHeishi1_TurnTowardLink; } @@ -342,9 +344,9 @@ void EnHeishi1_TurnTowardLink(EnHeishi1* this, GlobalContext* globalCtx) { } void EnHeishi1_SetupKick(EnHeishi1* this, GlobalContext* globalCtx) { - s16 frameCount = (f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, frameCount, 0, -10.0f); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->actionFunc = EnHeishi1_Kick; } @@ -368,9 +370,9 @@ void EnHeishi1_Kick(EnHeishi1* this, GlobalContext* globalCtx) { } void EnHeishi1_SetupWaitNight(EnHeishi1* this, GlobalContext* globalCtx) { - s16 frameCount = (f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, frameCount, 0, -10.0f); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->actionFunc = EnHeishi1_WaitNight; } diff --git a/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c b/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c index 0e07bfbaed..793e8488a0 100644 --- a/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c +++ b/src/overlays/actors/ovl_En_Heishi2/z_en_heishi2.c @@ -153,6 +153,7 @@ void EnHeishi2_Init(Actor* thisx, GlobalContext* globalCtx) { void EnHeishi2_Destroy(Actor* thisx, GlobalContext* globalCtx) { EnHeishi2* this = THIS; + if ((this->collider.dim.radius != 0) || (this->collider.dim.height != 0)) { Collider_DestroyCylinder(globalCtx, &this->collider); } @@ -165,8 +166,9 @@ void func_80A531D8(EnHeishi2* this, GlobalContext* globalCtx) { } void func_80A531E4(EnHeishi2* this, GlobalContext* globalCtx) { - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, - (s16)(f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader), 0, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->actionFunc = func_80A53278; } @@ -262,14 +264,14 @@ void func_80A53538(EnHeishi2* this, GlobalContext* globalCtx) { } void func_80A535BC(EnHeishi2* this, GlobalContext* globalCtx) { - f32 frames = SkelAnime_GetFrameCount(&D_06005500.genericHeader); - this->unk_2EC = frames; - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frames, 2, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005500.genericHeader); + + this->unk_2EC = frameCount; + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frameCount, 2, -10.0f); this->actionFunc = func_80A53638; } void func_80A53638(EnHeishi2* this, GlobalContext* globalCtx) { - Actor* thisx; f32 frameCount; BgSpot15Saku* actor; @@ -299,8 +301,9 @@ void func_80A53638(EnHeishi2* this, GlobalContext* globalCtx) { } void func_80A5372C(EnHeishi2* this, GlobalContext* globalCtx) { - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, - (s16)(f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader), 0, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->unk_2F2[0] = 200; this->cameraId = Gameplay_CreateSubCamera(globalCtx); Gameplay_ChangeCameraStatus(globalCtx, 0, 1); @@ -319,6 +322,7 @@ void func_80A5372C(EnHeishi2* this, GlobalContext* globalCtx) { void func_80A53850(EnHeishi2* this, GlobalContext* globalCtx) { BgSpot15Saku* gate; + SkelAnime_FrameUpdateMatrix(&this->skelAnime); func_800C04D8(globalCtx, this->cameraId, &this->unk_280, &this->unk_28C); gate = (BgSpot15Saku*)this->attachedGate; @@ -334,6 +338,7 @@ void func_80A53850(EnHeishi2* this, GlobalContext* globalCtx) { void func_80A53908(EnHeishi2* this, GlobalContext* globalCtx) { f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->actionFunc = func_80A5399C; } @@ -426,6 +431,7 @@ void func_80A53C0C(EnHeishi2* this, GlobalContext* globalCtx) { void func_80A53C90(EnHeishi2* this, GlobalContext* globalCtx) { f32 frameCount = SkelAnime_GetFrameCount(&D_06005500.genericHeader); + this->unk_2EC = frameCount; SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frameCount, 2, -10.0f); this->actionFunc = func_80A53D0C; @@ -462,8 +468,9 @@ void func_80A53D0C(EnHeishi2* this, GlobalContext* globalCtx) { } void func_80A53DF8(EnHeishi2* this, GlobalContext* globalCtx) { - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, - (s16)(f32)SkelAnime_GetFrameCount(&D_06005C30.genericHeader), 0, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->unk_2F2[0] = 200; this->cameraId = Gameplay_CreateSubCamera(globalCtx); Gameplay_ChangeCameraStatus(globalCtx, 0, 1); @@ -486,6 +493,7 @@ void func_80A53DF8(EnHeishi2* this, GlobalContext* globalCtx) { void func_80A53F30(EnHeishi2* this, GlobalContext* globalCtx) { BgGateShutter* gate; + SkelAnime_FrameUpdateMatrix(&this->skelAnime); func_800C04D8(globalCtx, this->cameraId, &this->unk_280, &this->unk_28C); gate = (BgGateShutter*)this->attachedGate; @@ -586,6 +594,7 @@ void func_80A5427C(EnHeishi2* this, GlobalContext* globalCtx) { void func_80A54320(EnHeishi2* this, GlobalContext* globalCtx) { f32 frameCount = SkelAnime_GetFrameCount(&D_06005500.genericHeader); + this->unk_2EC = frameCount; SkelAnime_ChangeAnim(&this->skelAnime, &D_06005500, 1.0f, 0.0f, frameCount, 2, -10.0f); this->audioFlag = 0; @@ -742,6 +751,7 @@ void func_80A5475C(EnHeishi2* this, GlobalContext* globalCtx) { void func_80A54954(EnHeishi2* this, GlobalContext* globalCtx) { f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->actionFunc = func_80A549E8; } @@ -798,6 +808,7 @@ void EnHeishi2_Update(Actor* thisx, GlobalContext* globalCtx) { s32 EnHeishi2_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) { EnHeishi2* this = THIS; + switch (this->initParams) { case 1: break; diff --git a/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c b/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c index bb93d38ee5..e502b011b8 100644 --- a/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c +++ b/src/overlays/actors/ovl_En_Heishi3/z_en_heishi3.c @@ -78,12 +78,14 @@ void EnHeishi3_Init(Actor* thisx, GlobalContext* globalCtx) { void EnHeishi3_Destroy(Actor* thisx, GlobalContext* globalCtx) { EnHeishi3* this = THIS; + Collider_DestroyCylinder(globalCtx, &this->collider); } void EnHeishi3_SetupGuardType(EnHeishi3* this, GlobalContext* globalCtx) { - f32 frames = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)(f32)frames, 0, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); if (this->unk_278 == 0) { this->actionFunc = EnHeishi3_StandSentinelInGrounds; } else { @@ -157,8 +159,9 @@ void EnHeishi3_StandSentinelInCastle(EnHeishi3* this, GlobalContext* globalCtx) } void EnHeishi3_CatchStart(EnHeishi3* this, GlobalContext* globalCtx) { - f32 frames = SkelAnime_GetFrameCount(&D_06005880.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, 1.0f, 0.0f, (s16)(f32)frames, 0, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005880.genericHeader); + + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005880, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->caughtTimer = 20; this->actionFunc = func_80A55BD4; this->actor.speedXZ = 2.5f; @@ -179,8 +182,9 @@ void func_80A55BD4(EnHeishi3* this, GlobalContext* globalCtx) { } void EnHeishi3_ResetAnimationToIdle(EnHeishi3* this, GlobalContext* globalCtx) { - f32 frames = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); - SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)(f32)frames, 0, -10.0f); + f32 frameCount = SkelAnime_GetFrameCount(&D_06005C30.genericHeader); + + SkelAnime_ChangeAnim(&this->skelAnime, &D_06005C30, 1.0f, 0.0f, (s16)frameCount, 0, -10.0f); this->actionFunc = func_80A55D00; } @@ -200,6 +204,7 @@ void func_80A55D00(EnHeishi3* this, GlobalContext* globalCtx) { void EnHeishi3_Update(Actor* thisx, GlobalContext* globalCtx) { EnHeishi3* this = THIS; s32 pad; + Actor_SetHeight(&this->actor, 60.0f); this->unk_274 += 1; if (this->caughtTimer != 0) { @@ -216,6 +221,7 @@ void EnHeishi3_Update(Actor* thisx, GlobalContext* globalCtx) { s32 EnHeishi3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot, Actor* thisx) { EnHeishi3* this = THIS; + if (limbIndex == 9) { rot->x += this->unk_26E; } @@ -230,6 +236,7 @@ s32 EnHeishi3_OverrideLimbDraw(GlobalContext* globalCtx, s32 limbIndex, Gfx** dL void EnHeishi3_Draw(Actor* thisx, GlobalContext* globalCtx) { EnHeishi3* this = THIS; + func_80093D18(globalCtx->state.gfxCtx); SkelAnime_Draw(globalCtx, this->skelAnime.skeleton, this->skelAnime.limbDrawTbl, EnHeishi3_OverrideLimbDraw, NULL, &this->actor); diff --git a/src/overlays/actors/ovl_En_Hintnuts/z_en_hintnuts.c b/src/overlays/actors/ovl_En_Hintnuts/z_en_hintnuts.c index 0377549f3b..2cea6c8558 100644 --- a/src/overlays/actors/ovl_En_Hintnuts/z_en_hintnuts.c +++ b/src/overlays/actors/ovl_En_Hintnuts/z_en_hintnuts.c @@ -514,7 +514,7 @@ void EnHintnuts_Update(Actor* thisx, GlobalContext* globalCtx) { Actor_SetHeight(&this->actor, this->skelAnime.animCurrentFrame); } else if (this->actionFunc == EnHintnuts_Burrow) { Actor_SetHeight(&this->actor, 20.0f - ((this->skelAnime.animCurrentFrame * 20.0f) / - (f32)SkelAnime_GetFrameCount(&D_060024CC.genericHeader))); + SkelAnime_GetFrameCount(&D_060024CC.genericHeader))); } else { Actor_SetHeight(&this->actor, 20.0f); } diff --git a/src/overlays/actors/ovl_En_Sb/z_en_sb.c b/src/overlays/actors/ovl_En_Sb/z_en_sb.c index 7e7f22c957..fb4dfa9704 100644 --- a/src/overlays/actors/ovl_En_Sb/z_en_sb.c +++ b/src/overlays/actors/ovl_En_Sb/z_en_sb.c @@ -137,10 +137,10 @@ void EnSb_SetupWaitOpen(EnSb* this) { } void EnSb_SetupLunge(EnSb* this) { - f32 frames = SkelAnime_GetFrameCount(&D_06000124.genericHeader); + f32 frameCount = SkelAnime_GetFrameCount(&D_06000124.genericHeader); f32 playbackSpeed = this->actor.waterY > 0.0f ? 1.0f : 0.0f; - SkelAnime_ChangeAnim(&this->skelAnime, &D_06000124, playbackSpeed, 0.0f, frames, 2, 0); + SkelAnime_ChangeAnim(&this->skelAnime, &D_06000124, playbackSpeed, 0.0f, frameCount, 2, 0); this->behavior = SHELLBLADE_LUNGE; this->actionFunc = EnSb_Lunge; Audio_PlayActorSound2(&this->actor, NA_SE_EN_SHELL_MOUTH); diff --git a/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c b/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c index 6c8723749c..d205814c56 100644 --- a/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c +++ b/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c @@ -141,7 +141,7 @@ void EnWallmas_SetupDrop(EnWallmas* this, GlobalContext* globalCtx) { Player* player = PLAYER; AnimationHeader* objSegChangeAnime = &D_0600299C; - SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 0.0f, 20.0f, (f32)SkelAnime_GetFrameCount(&D_0600299C), 2, + SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 0.0f, 20.0f, SkelAnime_GetFrameCount(&D_0600299C), 2, 0.0f); this->unk_2c4 = player->actor.posRot.pos.y; @@ -188,8 +188,8 @@ void EnWallmas_SetupReturnToCeiling(EnWallmas* this) { this->timer = 0; this->actor.speedXZ = 0.0f; - SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 3.0f, 0.0f, - (f32)SkelAnime_GetFrameCount(objSegFrameCount), 2, -3.0f); + SkelAnime_ChangeAnim(&this->skelAnime, objSegChangeAnime, 3.0f, 0.0f, SkelAnime_GetFrameCount(objSegFrameCount), 2, + -3.0f); this->actionFunc = EnWallmas_ReturnToCeiling; }