summaryrefslogtreecommitdiff
path: root/src/code/z_actor.c
diff options
context:
space:
mode:
authorfig02 <fig02srl@gmail.com>2024-09-04 19:26:23 -0400
committerGitHub <noreply@github.com>2024-09-04 19:26:23 -0400
commit6051251c929c2b9f709740674da1a0ab795dfb88 (patch)
treef2373a109b3cfcd3bd9b90519605c586beb45bdc /src/code/z_actor.c
parentdc469461a96589d9b4e4be0d0310b38cc4dfc952 (diff)
istargeted -> islockedon (#2132)
Diffstat (limited to 'src/code/z_actor.c')
-rw-r--r--src/code/z_actor.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/src/code/z_actor.c b/src/code/z_actor.c
index 599500770..00855214a 100644
--- a/src/code/z_actor.c
+++ b/src/code/z_actor.c
@@ -1680,7 +1680,7 @@ s32 Actor_OfferTalkExchange(Actor* actor, PlayState* play, f32 xzRange, f32 yRan
Player* player = GET_PLAYER(play);
if ((player->actor.flags & ACTOR_FLAG_TALK) || ((exchangeItemId != EXCH_ITEM_NONE) && Player_InCsMode(play)) ||
- (!actor->isTargeted &&
+ (!actor->isLockedOn &&
((yRange < fabsf(actor->yDistToPlayer)) || (player->talkActorDistance < actor->xzDistToPlayer) ||
(xzRange < actor->xzDistToPlayer)))) {
return false;
@@ -2334,9 +2334,9 @@ void Actor_UpdateAll(PlayState* play, ActorContext* actorCtx) {
if ((DECR(actor->freezeTimer) == 0) && (actor->flags & (ACTOR_FLAG_4 | ACTOR_FLAG_6))) {
if (actor == player->focusActor) {
- actor->isTargeted = true;
+ actor->isLockedOn = true;
} else {
- actor->isTargeted = false;
+ actor->isLockedOn = false;
}
if ((actor->targetPriority != 0) && (player->focusActor == NULL)) {
@@ -3745,12 +3745,12 @@ s16 Actor_TestFloorInDirection(Actor* actor, PlayState* play, f32 distance, s16
}
/**
- * Returns true if the player is targeting the provided actor
+ * Returns true if the player is locked onto the specified actor
*/
-s32 Actor_IsTargeted(PlayState* play, Actor* actor) {
+s32 Actor_IsLockedOn(PlayState* play, Actor* actor) {
Player* player = GET_PLAYER(play);
- if ((player->stateFlags1 & PLAYER_STATE1_4) && actor->isTargeted) {
+ if ((player->stateFlags1 & PLAYER_STATE1_4) && actor->isLockedOn) {
return true;
} else {
return false;
@@ -3758,12 +3758,12 @@ s32 Actor_IsTargeted(PlayState* play, Actor* actor) {
}
/**
- * Returns true if the player is targeting an actor other than the provided actor
+ * Returns true if the player is locked onto an actor other than the specified actor
*/
-s32 Actor_OtherIsTargeted(PlayState* play, Actor* actor) {
+s32 Actor_OtherIsLockedOn(PlayState* play, Actor* actor) {
Player* player = GET_PLAYER(play);
- if ((player->stateFlags1 & PLAYER_STATE1_4) && !actor->isTargeted) {
+ if ((player->stateFlags1 & PLAYER_STATE1_4) && !actor->isLockedOn) {
return true;
} else {
return false;
@@ -5904,7 +5904,7 @@ s32 func_80037D98(PlayState* play, Actor* actor, s16 arg2, s32* arg3) {
return false;
}
- if ((actor->xyzDistToPlayerSq > SQ(160.0f)) && !actor->isTargeted) {
+ if ((actor->xyzDistToPlayerSq > SQ(160.0f)) && !actor->isLockedOn) {
return false;
}