create ACTOR_FLAGS_CHECK_ALL (#2515)

This commit is contained in:
fig02
2025-04-26 19:07:52 -04:00
committed by GitHub
parent bed76a3bf3
commit ea22c2ac38
19 changed files with 40 additions and 43 deletions
+3 -3
View File
@@ -596,7 +596,7 @@ void Attention_Update(Attention* attention, Player* player, Actor* playerFocusAc
attention->reticleFadeAlphaControl = 0;
}
lockOnSfxId = CHECK_FLAG_ALL(playerFocusActor->flags, ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE)
lockOnSfxId = ACTOR_FLAGS_CHECK_ALL(playerFocusActor, ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE)
? NA_SE_SY_LOCK_ON
: NA_SE_SY_LOCK_ON_HUMAN;
Sfx_PlaySfxCentered(lockOnSfxId);
@@ -3468,9 +3468,9 @@ void Attention_FindActorInCategory(PlayState* play, ActorContext* actorCtx, Play
while (actor != NULL) {
if ((actor->update != NULL) && ((Player*)actor != player) &&
CHECK_FLAG_ALL(actor->flags, ACTOR_FLAG_ATTENTION_ENABLED)) {
ACTOR_FLAGS_CHECK_ALL(actor, ACTOR_FLAG_ATTENTION_ENABLED)) {
if ((actorCategory == ACTORCAT_ENEMY) &&
CHECK_FLAG_ALL(actor->flags, ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE) &&
ACTOR_FLAGS_CHECK_ALL(actor, ACTOR_FLAG_ATTENTION_ENABLED | ACTOR_FLAG_HOSTILE) &&
(actor->xyzDistToPlayerSq < SQ(500.0f)) && (actor->xyzDistToPlayerSq < sBgmEnemyDistSq)) {
actorCtx->attention.bgmEnemy = actor;
sBgmEnemyDistSq = actor->xyzDistToPlayerSq;
+1 -1
View File
@@ -82,7 +82,7 @@ void func_80043334(CollisionContext* colCtx, Actor* actor, s32 bgId) {
if (dynaActor != NULL) {
DynaPolyActor_SetActorOnTop(dynaActor);
if (CHECK_FLAG_ALL(actor->flags, ACTOR_FLAG_CAN_PRESS_SWITCHES)) {
if (ACTOR_FLAGS_CHECK_ALL(actor, ACTOR_FLAG_CAN_PRESS_SWITCHES)) {
DynaPolyActor_SetSwitchPressed(dynaActor);
}
}