diff --git a/include/z64player.h b/include/z64player.h index 581c7f7b4a..0043cc9546 100644 --- a/include/z64player.h +++ b/include/z64player.h @@ -659,7 +659,7 @@ typedef struct WeaponInfo { #define PLAYER_STATE1_START_CHANGING_HELD_ITEM (1 << 8) // Item change process has begun #define PLAYER_STATE1_9 (1 << 9) #define PLAYER_STATE1_10 (1 << 10) -#define PLAYER_STATE1_ACTOR_CARRY (1 << 11) // Currently carrying an actor +#define PLAYER_STATE1_CARRYING_ACTOR (1 << 11) // Currently carrying an actor #define PLAYER_STATE1_CHARGING_SPIN_ATTACK (1 << 12) // Currently charing a spin attack (by holding down the B button) #define PLAYER_STATE1_13 (1 << 13) #define PLAYER_STATE1_14 (1 << 14) diff --git a/src/code/z_actor.c b/src/code/z_actor.c index e64b9345b8..4405ae21ce 100644 --- a/src/code/z_actor.c +++ b/src/code/z_actor.c @@ -1104,7 +1104,7 @@ int func_8002DD78(Player* player) { int func_8002DDA8(PlayState* play) { Player* player = GET_PLAYER(play); - return (player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) || func_8002DD78(player); + return (player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) || func_8002DD78(player); } s32 func_8002DDE4(PlayState* play) { @@ -1814,7 +1814,7 @@ s32 Actor_OfferGetItem(Actor* actor, PlayState* play, s32 getItemId, f32 xzRange Player_GetExplosiveHeld(player) < 0) { if ((((player->heldActor != NULL) || (actor == player->talkActor)) && (getItemId > GI_NONE) && (getItemId < GI_MAX)) || - (!(player->stateFlags1 & (PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_29)))) { + (!(player->stateFlags1 & (PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_29)))) { if ((actor->xzDistToPlayer < xzRange) && (fabsf(actor->yDistToPlayer) < yRange)) { s16 yawDiff = actor->yawTowardsPlayer - player->actor.shape.rot.y; s32 absYawDiff = ABS(yawDiff); @@ -1883,7 +1883,7 @@ u32 Actor_SetRideActor(PlayState* play, Actor* horse, s32 mountSide) { Player* player = GET_PLAYER(play); if (!(player->stateFlags1 & - (PLAYER_STATE1_DEAD | PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_CHARGING_SPIN_ATTACK | PLAYER_STATE1_13 | + (PLAYER_STATE1_DEAD | PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_CHARGING_SPIN_ATTACK | PLAYER_STATE1_13 | PLAYER_STATE1_14 | PLAYER_STATE1_18 | PLAYER_STATE1_19 | PLAYER_STATE1_20 | PLAYER_STATE1_21))) { player->rideActor = horse; player->mountSide = mountSide; diff --git a/src/code/z_camera.c b/src/code/z_camera.c index be7cc4d272..4f49197df4 100644 --- a/src/code/z_camera.c +++ b/src/code/z_camera.c @@ -6609,7 +6609,7 @@ s32 Camera_Demo5(Camera* camera) { sp4A = playerhead.rot.y - playerTargetGeo.yaw; if (camera->target->category == ACTORCAT_PLAYER) { framesDiff = camera->play->state.frames - sDemo5PrevAction12Frame; - if (player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { // holding object over head. Player_SetCsActionWithHaltedActors(camera->play, camera->target, PLAYER_CSACTION_8); } else if (ABS(framesDiff) > 3000) { diff --git a/src/code/z_player_lib.c b/src/code/z_player_lib.c index f589748f0d..d2642b9eaf 100644 --- a/src/code/z_player_lib.c +++ b/src/code/z_player_lib.c @@ -1686,7 +1686,7 @@ void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Ve Matrix_Get(&sp14C); Matrix_MtxFToYXZRotS(&sp14C, &hookedActor->world.rot, 0); hookedActor->shape.rot = hookedActor->world.rot; - } else if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + } else if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { Vec3s spB8; Matrix_Get(&sp14C); diff --git a/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c b/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c index 5f5c06d0ed..5aa678ef2e 100644 --- a/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c +++ b/src/overlays/actors/ovl_Bg_Spot16_Bombstone/z_bg_spot16_bombstone.c @@ -416,7 +416,7 @@ void func_808B57E0(BgSpot16Bombstone* this, PlayState* play) { OnePointCutscene_Init(play, 4180, sTimer, NULL, CAM_ID_MAIN); } } - } else if (player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + } else if (player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { playerHeldActor = player->heldActor; if (playerHeldActor != NULL && playerHeldActor->category == ACTORCAT_EXPLOSIVE && playerHeldActor->id == ACTOR_EN_BOMBF) { diff --git a/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c b/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c index ecdf5ef649..b9673f51c4 100644 --- a/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c +++ b/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c @@ -816,7 +816,7 @@ void DoorShutter_SetupClosed(DoorShutter* this, PlayState* play) { } this->isActive = false; this->dyna.actor.velocity.y = 0.0f; - if (DoorShutter_SetupDoor(this, play) && !(player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + if (DoorShutter_SetupDoor(this, play) && !(player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { // The door is barred behind the player DoorShutter_SetupAction(this, DoorShutter_WaitPlayerSurprised); Player_SetCsActionWithHaltedActors(play, NULL, PLAYER_CSACTION_2); diff --git a/src/overlays/actors/ovl_En_Bom/z_en_bom.c b/src/overlays/actors/ovl_En_Bom/z_en_bom.c index 611e5062f3..120bbaa1b2 100644 --- a/src/overlays/actors/ovl_En_Bom/z_en_bom.c +++ b/src/overlays/actors/ovl_En_Bom/z_en_bom.c @@ -207,11 +207,11 @@ void EnBom_Explode(EnBom* this, PlayState* play) { if (this->timer == 0) { player = GET_PLAYER(play); - if ((player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (player->heldActor == &this->actor)) { + if ((player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (player->heldActor == &this->actor)) { player->actor.child = NULL; player->heldActor = NULL; player->interactRangeActor = NULL; - player->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + player->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; } Actor_Kill(&this->actor); diff --git a/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c b/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c index aa0030bb8e..87ed4120d4 100644 --- a/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c +++ b/src/overlays/actors/ovl_En_Bombf/z_en_bombf.c @@ -163,7 +163,7 @@ void EnBombf_GrowBomb(EnBombf* this, PlayState* play) { player->heldActor = NULL; player->interactRangeActor = NULL; this->actor.parent = NULL; - player->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + player->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; } } else if (this->bombCollider.base.acFlags & AC_HIT) { this->bombCollider.base.acFlags &= ~AC_HIT; @@ -197,7 +197,7 @@ void EnBombf_GrowBomb(EnBombf* this, PlayState* play) { player->heldActor = NULL; player->interactRangeActor = NULL; this->actor.parent = NULL; - player->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + player->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; this->actor.world.pos = this->actor.home.pos; } } @@ -215,7 +215,7 @@ void EnBombf_GrowBomb(EnBombf* this, PlayState* play) { player->heldActor = NULL; player->interactRangeActor = NULL; this->actor.parent = NULL; - player->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + player->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; this->actor.world.pos = this->actor.home.pos; } } @@ -299,11 +299,11 @@ void EnBombf_Explode(EnBombf* this, PlayState* play) { if (this->timer == 0) { player = GET_PLAYER(play); - if ((player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (player->heldActor == &this->actor)) { + if ((player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (player->heldActor == &this->actor)) { player->actor.child = NULL; player->heldActor = NULL; player->interactRangeActor = NULL; - player->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + player->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; } Actor_Kill(&this->actor); diff --git a/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c b/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c index 7a26d7863c..5bd9228946 100644 --- a/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c +++ b/src/overlays/actors/ovl_En_Dnt_Jiji/z_en_dnt_jiji.c @@ -116,7 +116,7 @@ void EnDntJiji_Wait(EnDntJiji* this, PlayState* play) { SkelAnime_Update(&this->skelAnime); if ((this->timer == 1) && (this->actor.xzDistToPlayer < 150.0f) && !Play_InCsMode(play) && - !(player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + !(player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { OnePointCutscene_Init(play, 2230, -99, &this->actor, CAM_ID_MAIN); this->timer = 0; Player_SetCsActionWithHaltedActors(play, NULL, PLAYER_CSACTION_8); diff --git a/src/overlays/actors/ovl_En_Ta/z_en_ta.c b/src/overlays/actors/ovl_En_Ta/z_en_ta.c index f6a11e4751..65c46c3b10 100644 --- a/src/overlays/actors/ovl_En_Ta/z_en_ta.c +++ b/src/overlays/actors/ovl_En_Ta/z_en_ta.c @@ -622,7 +622,7 @@ s32 EnTa_IsPlayerHoldingSuperCucco(EnTa* this, PlayState* play, s32 cuccoIdx) { Player* player = GET_PLAYER(play); Actor* interactRangeActor; - if (player->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (player->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { interactRangeActor = player->interactRangeActor; if (interactRangeActor != NULL && interactRangeActor->id == ACTOR_EN_NIW && interactRangeActor == &this->superCuccos[cuccoIdx]->actor) { @@ -658,7 +658,7 @@ void EnTa_TalkFoundSuperCucco(EnTa* this, PlayState* play) { if (player->heldActor == &this->superCuccos[lastFoundSuperCuccoIdx]->actor) { player->heldActor = NULL; } - player->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + player->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; this->superCuccos[lastFoundSuperCuccoIdx] = NULL; } this->stateFlags |= TALON_STATE_FLAG_TRACKING_PLAYER; diff --git a/src/overlays/actors/ovl_player_actor/z_player.c b/src/overlays/actors/ovl_player_actor/z_player.c index 15b5847169..bf2851ccb3 100644 --- a/src/overlays/actors/ovl_player_actor/z_player.c +++ b/src/overlays/actors/ovl_player_actor/z_player.c @@ -1686,7 +1686,7 @@ void Player_DetachHeldActor(PlayState* play, Player* this) { this->heldActor = NULL; this->interactRangeActor = NULL; heldActor->parent = NULL; - this->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; } if (Player_GetExplosiveHeld(this) >= 0) { @@ -1696,14 +1696,14 @@ void Player_DetachHeldActor(PlayState* play, Player* this) { } void func_80832440(PlayState* play, Player* this) { - if ((this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (this->heldActor == NULL)) { + if ((this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (this->heldActor == NULL)) { if (this->interactRangeActor != NULL) { if (this->getItemId == GI_NONE) { - this->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; this->interactRangeActor = NULL; } } else { - this->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; } } @@ -2226,7 +2226,7 @@ void Player_InitExplosiveIA(PlayState* play, Player* this) { ExplosiveInfo* explosiveInfo; Actor* spawnedActor; - if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { Player_PutAwayHeldItem(play, this); return; } @@ -2251,7 +2251,7 @@ void Player_InitExplosiveIA(PlayState* play, Player* this) { this->heldActor = spawnedActor; this->getItemId = GI_NONE; this->unk_3BC.y = spawnedActor->shape.rot.y - this->actor.shape.rot.y; - this->stateFlags1 |= PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 |= PLAYER_STATE1_CARRYING_ACTOR; } } @@ -2457,7 +2457,7 @@ void Player_ProcessItemButtons(Player* this, PlayState* play) { } } - if (!(this->stateFlags1 & (PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_29)) && !func_8008F128(this)) { + if (!(this->stateFlags1 & (PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_29)) && !func_8008F128(this)) { if (this->itemAction >= PLAYER_IA_FISHING_POLE) { if (!Player_ItemIsInUse(this, B_BTN_ITEM) && !Player_ItemIsInUse(this, C_BTN_ITEM(0)) && !Player_ItemIsInUse(this, C_BTN_ITEM(1)) && !Player_ItemIsInUse(this, C_BTN_ITEM(2))) { @@ -3074,7 +3074,7 @@ s32 Player_UpperAction_CarryActor(Player* this, PlayState* play) { return true; } - if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { if (LinkAnimation_Update(play, &this->upperSkelAnime)) { LinkAnimation_PlayLoop(play, &this->upperSkelAnime, &gPlayerAnim_link_normal_carryB_wait); } @@ -3218,7 +3218,7 @@ s32 Player_SetupAction(PlayState* play, Player* this, PlayerActionFunc actionFun func_8008EC70(this); } - if (!(flags & 1) && !(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + if (!(flags & 1) && !(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { func_80834644(play, this); this->stateFlags1 &= ~PLAYER_STATE1_22; } @@ -3723,7 +3723,7 @@ void func_80836BEC(Player* this, PlayState* play) { // When carrying another actor, `PLAYER_STATE1_FRIENDLY_ACTOR_FOCUS` will be set even if the actor // is hostile. This is a special case to allow Player to have more freedom of movement and be able // to throw a carried actor at the lock-on actor, even if it is hostile. - if ((this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) || + if ((this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) || !CHECK_FLAG_ALL(this->focusActor->flags, ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE)) { this->stateFlags1 |= PLAYER_STATE1_FRIENDLY_ACTOR_FOCUS; } @@ -4678,7 +4678,7 @@ s32 Player_ActionChange_12(Player* this, PlayState* play) { f32 sp34; f32 temp; - if (!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (this->ledgeClimbType >= PLAYER_LEDGE_CLIMB_2) && + if (!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (this->ledgeClimbType >= PLAYER_LEDGE_CLIMB_2) && (!(this->stateFlags1 & PLAYER_STATE1_27) || (this->ageProperties->unk_14 > this->yDistToLedge))) { sp3C = 0; @@ -5052,7 +5052,7 @@ s32 Player_ActionChange_1(Player* this, PlayState* play) { s32 frontRoom; if ((this->doorType != PLAYER_DOORTYPE_NONE) && - (!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) || + (!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) || ((this->heldActor != NULL) && (this->heldActor->id == ACTOR_EN_RU1)))) { if (CHECK_BTN_ALL(sControlInput->press.button, BTN_A) || (Player_Action_8084F9A0 == this->actionFunc)) { doorActor = this->doorActor; @@ -5319,7 +5319,7 @@ void func_8083A0F4(PlayState* play, Player* this) { } } else { func_80839F90(this, play); - this->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; } } @@ -5538,7 +5538,8 @@ void func_8083AA10(Player* this, PlayState* play) { (sYDistToFloor > 20.0f) && (this->meleeWeaponState == 0) && (ABS(sp5C) < 0x2000) && (this->speedXZ > 3.0f)) { - if ((sPrevFloorProperty == FLOOR_PROPERTY_11) && !(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + if ((sPrevFloorProperty == FLOOR_PROPERTY_11) && + !(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { sp40 = func_808396F4(play, this, &D_8085451C, &sp44, &sp58, &sp54); sp3C = this->actor.world.pos.y; @@ -5865,7 +5866,7 @@ s32 Player_ActionChange_4(Player* this, PlayState* play) { if ((sp34 != NULL) || (sp2C != NULL)) { if ((sp30 == NULL) || (sp30 == sp34) || (sp30 == sp2C)) { - if (!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) || + if (!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) || ((this->heldActor != NULL) && (sp28 || (sp34 == this->heldActor) || (sp2C == this->heldActor) || ((sp34 != NULL) && (sp34->flags & ACTOR_FLAG_16))))) { if ((this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) || (this->stateFlags1 & PLAYER_STATE1_23) || @@ -5913,7 +5914,7 @@ s32 Player_ActionChange_4(Player* this, PlayState* play) { } s32 func_8083B8F4(Player* this, PlayState* play) { - if (!(this->stateFlags1 & (PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_23)) && + if (!(this->stateFlags1 & (PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_23)) && Camera_CheckValidMode(Play_GetCamera(play, CAM_ID_MAIN), CAM_MODE_FIRST_PERSON)) { if ((this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) || (func_808332B8(this) && (this->actor.depthInWater < this->ageProperties->unk_2C))) { @@ -6487,7 +6488,7 @@ s32 func_8083D12C(PlayState* play, Player* this, Input* arg2) { Player_SetupAction(play, this, Player_Action_8084E1EC, 1); if (this->stateFlags1 & PLAYER_STATE1_10) { - this->stateFlags1 |= PLAYER_STATE1_10 | PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_29; + this->stateFlags1 |= PLAYER_STATE1_10 | PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_29; } this->av2.actionVar2 = 2; @@ -6495,7 +6496,7 @@ s32 func_8083D12C(PlayState* play, Player* this, Input* arg2) { func_80832340(play, this); Player_AnimChangeOnceMorph(play, this, - (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) + (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) ? &gPlayerAnim_link_swimer_swim_get : &gPlayerAnim_link_swimer_swim_deep_end); @@ -6955,7 +6956,7 @@ s32 Player_ActionChange_2(Player* this, PlayState* play) { func_80835EA4(play, 9); } - this->stateFlags1 |= PLAYER_STATE1_10 | PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_29; + this->stateFlags1 |= PLAYER_STATE1_10 | PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_29; func_80832224(this); return 1; } @@ -6964,7 +6965,7 @@ s32 Player_ActionChange_2(Player* this, PlayState* play) { this->getItemId = GI_NONE; } } else if (CHECK_BTN_ALL(sControlInput->press.button, BTN_A) && - !(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && !(this->stateFlags2 & PLAYER_STATE2_10)) { + !(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && !(this->stateFlags2 & PLAYER_STATE2_10)) { if (this->getItemId != GI_NONE) { GetItemEntry* giEntry = &sGetItemTable[-this->getItemId - 1]; EnBox* chest = (EnBox*)interactedActor; @@ -6978,7 +6979,7 @@ s32 Player_ActionChange_2(Player* this, PlayState* play) { } Player_SetupWaitForPutAway(play, this, func_8083A434); - this->stateFlags1 |= PLAYER_STATE1_10 | PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_29; + this->stateFlags1 |= PLAYER_STATE1_10 | PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_29; func_8083AE40(this, giEntry->objectId); this->actor.world.pos.x = chest->dyna.actor.world.pos.x - (Math_SinS(chest->dyna.actor.shape.rot.y) * 29.4343f); @@ -7031,7 +7032,7 @@ s32 Player_ActionChange_2(Player* this, PlayState* play) { } func_80832224(this); - this->stateFlags1 |= PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 |= PLAYER_STATE1_CARRYING_ACTOR; return 1; } } @@ -7055,7 +7056,7 @@ s32 func_8083EAF0(Player* this, Actor* actor) { } s32 Player_ActionChange_9(Player* this, PlayState* play) { - if ((this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (this->heldActor != NULL) && + if ((this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (this->heldActor != NULL) && CHECK_BTN_ANY(sControlInput->press.button, BTN_A | BTN_B | BTN_CLEFT | BTN_CDOWN | BTN_CRIGHT)) { if (!func_80835644(play, this, this->heldActor)) { if (!func_8083EAF0(this, this->heldActor)) { @@ -7384,7 +7385,7 @@ void func_8083F72C(Player* this, LinkAnimationHeader* anim, PlayState* play) { s32 Player_ActionChange_5(Player* this, PlayState* play) { DynaPolyActor* wallPolyActor; - if (!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && + if (!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (this->actor.bgCheckFlags & BGCHECKFLAG_PLAYER_WALL_INTERACT) && (sShapeYawToTouchedWall < 0x3000)) { if (((this->speedXZ > 0.0f) && func_8083EC18(this, play, sTouchedWallFlags)) || @@ -7409,7 +7410,7 @@ s32 Player_ActionChange_5(Player* this, PlayState* play) { } Player_SetupWaitForPutAway(play, this, func_8083A0F4); - this->stateFlags1 |= PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 |= PLAYER_STATE1_CARRYING_ACTOR; this->interactRangeActor = &wallPolyActor->actor; this->getItemId = GI_NONE; this->yaw = this->actor.wallYaw + 0x8000; @@ -7803,7 +7804,7 @@ void func_808409CC(PlayState* play, Player* this) { anim = func_80833338(this); } else { this->stateFlags2 |= PLAYER_STATE2_28; - if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { anim = func_80833338(this); } else { sp38 = play->roomCtx.curRoom.behaviorType2; @@ -9095,7 +9096,7 @@ void Player_Action_8084411C(Player* this, PlayState* play) { if (!(this->actor.bgCheckFlags & BGCHECKFLAG_GROUND)) { Actor* heldActor; - if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { heldActor = this->heldActor; if (!func_80835644(play, this, heldActor) && (heldActor->id == ACTOR_EN_NIW) && @@ -9134,7 +9135,7 @@ void Player_Action_8084411C(Player* this, PlayState* play) { if ((this->actor.bgCheckFlags & BGCHECKFLAG_PLAYER_WALL_INTERACT) && !(this->stateFlags2 & PLAYER_STATE2_19) && - !(this->stateFlags1 & (PLAYER_STATE1_ACTOR_CARRY | PLAYER_STATE1_27)) && + !(this->stateFlags1 & (PLAYER_STATE1_CARRYING_ACTOR | PLAYER_STATE1_27)) && (this->speedXZ > 0.0f)) { if ((this->yDistToLedge >= 150.0f) && (this->controlStickDirections[this->controlStickDataIndex] == PLAYER_STICK_DIR_FORWARD)) { @@ -9177,7 +9178,7 @@ void Player_Action_8084411C(Player* this, PlayState* play) { anim = GET_PLAYER_ANIM(PLAYER_ANIMGROUP_short_landing, this->modelAnimType); } else if ((this->fallDistance < 800) && (this->controlStickDirections[this->controlStickDataIndex] == PLAYER_STICK_DIR_FORWARD) && - !(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + !(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { func_8083BC04(this, play); return; } @@ -9654,7 +9655,7 @@ void Player_Action_WaitForPutAway(Player* this, PlayState* play) { // The other conditions listed will force the put away delay function to run instantly if carrying an actor. // This is necessary because the UpperAction for carrying actors will always return true while holding // the actor, so `!Player_UpdateUpperBody` could never pass. - if (((this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (this->heldActor != NULL) && + if (((this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (this->heldActor != NULL) && (this->getItemId == GI_NONE)) || !Player_UpdateUpperBody(this, play)) { this->afterPutAwayFunc(play, this); @@ -9783,7 +9784,7 @@ void Player_Action_80845CA4(Player* this, PlayState* play) { } } - if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { Player_UpdateUpperBody(this, play); } } @@ -9922,7 +9923,7 @@ void Player_Action_80846408(Player* this, PlayState* play) { this->av2.actionVar2--; if (this->av2.actionVar2 == 0) { func_8083A098(this, &gPlayerAnim_link_normal_nocarry_free_end, play); - this->stateFlags1 &= ~PLAYER_STATE1_ACTOR_CARRY; + this->stateFlags1 &= ~PLAYER_STATE1_CARRYING_ACTOR; Player_PlayVoiceSfx(this, NA_SE_VO_LI_DAMAGE_S); } } @@ -10385,10 +10386,10 @@ void Player_UpdateInterface(PlayState* play, Player* this) { } } else if ((Player_Action_8084E3C4 != this->actionFunc) && !(this->stateFlags2 & PLAYER_STATE2_CRAWLING)) { if ((this->doorType != PLAYER_DOORTYPE_NONE) && - (!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) || + (!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) || ((heldActor != NULL) && (heldActor->id == ACTOR_EN_RU1)))) { doAction = DO_ACTION_OPEN; - } else if ((!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) || (heldActor == NULL)) && + } else if ((!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) || (heldActor == NULL)) && (interactRangeActor != NULL) && ((!sp1C && (this->getItemId == GI_NONE)) || ((this->getItemId < 0) && !(this->stateFlags1 & PLAYER_STATE1_27)))) { @@ -10426,7 +10427,7 @@ void Player_UpdateInterface(PlayState* play, Player* this) { doAction = DO_ACTION_DOWN; } else if (this->stateFlags2 & PLAYER_STATE2_DO_ACTION_ENTER) { doAction = DO_ACTION_ENTER; - } else if ((this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) && (this->getItemId == GI_NONE) && + } else if ((this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) && (this->getItemId == GI_NONE) && (heldActor != NULL)) { if ((this->actor.bgCheckFlags & BGCHECKFLAG_GROUND) || (heldActor->id == ACTOR_EN_NIW)) { if (func_8083EAF0(this, heldActor) == 0) { @@ -11478,7 +11479,7 @@ void Player_UpdateCommon(Player* this, PlayState* play, Input* input) { this->exchangeItemId = EXCH_ITEM_NONE; } - if (!(this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + if (!(this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { this->interactRangeActor = NULL; this->getItemDirection = 0x6000; } @@ -13118,7 +13119,7 @@ void Player_Action_8084DC48(Player* this, PlayState* play) { } else if (!func_8083D12C(play, this, sControlInput)) { sp2C = (this->av2.actionVar2 * 0.018f) + 4.0f; - if (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY) { + if (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR) { sControlInput = NULL; } @@ -13136,7 +13137,7 @@ void Player_Action_8084DC48(Player* this, PlayState* play) { void func_8084DF6C(PlayState* play, Player* this) { this->unk_862 = 0; - this->stateFlags1 &= ~(PLAYER_STATE1_10 | PLAYER_STATE1_ACTOR_CARRY); + this->stateFlags1 &= ~(PLAYER_STATE1_10 | PLAYER_STATE1_CARRYING_ACTOR); this->getItemId = GI_NONE; Camera_SetFinishedFlag(Play_GetCamera(play, CAM_ID_MAIN)); } @@ -13357,7 +13358,7 @@ void Player_Action_8084E6D4(Player* this, PlayState* play) { func_80832DBC(this); if (this->getItemId == GI_ICE_TRAP) { - this->stateFlags1 &= ~(PLAYER_STATE1_10 | PLAYER_STATE1_ACTOR_CARRY); + this->stateFlags1 &= ~(PLAYER_STATE1_10 | PLAYER_STATE1_CARRYING_ACTOR); if (this->getItemId != GI_ICE_TRAP) { Actor_Spawn(&play->actorCtx, play, ACTOR_EN_CLEAR_TAG, this->actor.world.pos.x, @@ -14788,7 +14789,7 @@ void func_808514C0(PlayState* play, Player* this, CsCmdActorCue* cue) { LinkAnimation_Update(play, &this->skelAnime); - if (func_8008F128(this) || (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + if (func_8008F128(this) || (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { Player_UpdateUpperBody(this, play); return; } @@ -14837,7 +14838,7 @@ void func_80851688(PlayState* play, Player* this, CsCmdActorCue* cue) { LinkAnimation_Update(play, &this->skelAnime); - if (func_8008F128(this) || (this->stateFlags1 & PLAYER_STATE1_ACTOR_CARRY)) { + if (func_8008F128(this) || (this->stateFlags1 & PLAYER_STATE1_CARRYING_ACTOR)) { Player_UpdateUpperBody(this, play); } }