From 02acd64ff6590bafe10e755aa7fc61c6317c98dc Mon Sep 17 00:00:00 2001 From: JordanLongstaff Date: Tue, 3 Jun 2025 13:18:55 -0400 Subject: [PATCH] Rename carry timer as suggested --- src/overlays/actors/ovl_En_Ru1/z_en_ru1.c | 18 +++++++++--------- src/overlays/actors/ovl_En_Ru1/z_en_ru1.h | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c index 58062c0da2..3a67742720 100644 --- a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c +++ b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.c @@ -1658,7 +1658,7 @@ s32 func_80AEE6D0(EnRu1* this, PlayState* play) { void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { s32 pad[9]; Player* player; - f32* carryTimer = &this->carryTimer; + f32* carryIdleTimer = &this->carryIdleTimer; if (Actor_HasNoParent(&this->actor, play)) { f32 frameCount = Animation_GetLastFrame(&gRutoChildSittingAnim); @@ -1671,17 +1671,17 @@ void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { this->actor.gravity = -((kREG(23) * 0.01f) + 1.3f); func_80AED57C(this); this->action = 28; - *carryTimer = 0.0f; + *carryIdleTimer = 0.0f; } else if (func_80AEE6D0(this, play)) { s32 pad; - *carryTimer = 0.0f; + *carryIdleTimer = 0.0f; } else { player = GET_PLAYER(play); if (player->stateFlags2 & PLAYER_STATE2_IDLE_FIDGET) { - this->carryTimer += 1.0f; + this->carryIdleTimer += 1.0f; if (this->action != 32) { - if (*carryTimer > 30.0f) { + if (*carryIdleTimer > 30.0f) { if (Rand_S16Offset(0, 3) == 0) { f32 frameCount = Animation_GetLastFrame(&gRutoChildSquirmAnim); @@ -1690,23 +1690,23 @@ void EnRu1_UpdateCarriedBehavior(EnRu1* this, PlayState* play) { func_80AED5DC(this); this->action = 32; } - *carryTimer = 0.0f; + *carryIdleTimer = 0.0f; } } else { - if (*carryTimer > 50.0f) { + if (*carryIdleTimer > 50.0f) { f32 frameCount = Animation_GetLastFrame(&gRutoChildSittingAnim); Animation_Change(&this->skelAnime, &gRutoChildSittingAnim, 1.0f, 0, frameCount, ANIMMODE_LOOP, -8.0f); this->action = 31; - *carryTimer = 0.0f; + *carryIdleTimer = 0.0f; } } } else { f32 frameCount = Animation_GetLastFrame(&gRutoChildSittingAnim); Animation_Change(&this->skelAnime, &gRutoChildSittingAnim, 1.0f, 0, frameCount, ANIMMODE_LOOP, -8.0f); - *carryTimer = 0.0f; + *carryIdleTimer = 0.0f; } } } diff --git a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h index 67de2af2c0..31cde27f9e 100644 --- a/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h +++ b/src/overlays/actors/ovl_En_Ru1/z_en_ru1.h @@ -53,7 +53,7 @@ typedef struct EnRu1 { /* 0x035C */ s16 unk_35C; /* 0x0360 */ f32 unk_360; /* 0x0364 */ Vec3f unk_364; - /* 0x0370 */ f32 carryTimer; + /* 0x0370 */ f32 carryIdleTimer; /* 0x0374 */ NpcInteractInfo interactInfo; } EnRu1; // size = 0x039C