summaryrefslogtreecommitdiff
path: root/src/d/actor/d_a_am2.cpp
diff options
context:
space:
mode:
authorLagoLunatic <LagoLunatic@users.noreply.github.com>2025-03-08 17:08:50 -0500
committerLagoLunatic <LagoLunatic@users.noreply.github.com>2025-03-08 17:27:16 -0500
commit87dcddd5196591b7b127218591f1b72ad3c2cf3c (patch)
treec5890a0cc138b0722988b1971835fa0d649c8ddd /src/d/actor/d_a_am2.cpp
parente696d982c692ded1540d941aaa57a8cdc0ad4363 (diff)
Use cLib on/off bit inlines for attn flags
The debug maps indicate these inlines were pretty much always used when these flags are ORed or ANDed (but not when checked or set).
Diffstat (limited to 'src/d/actor/d_a_am2.cpp')
-rw-r--r--src/d/actor/d_a_am2.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/d/actor/d_a_am2.cpp b/src/d/actor/d_a_am2.cpp
index adb58c79..ea63cc8c 100644
--- a/src/d/actor/d_a_am2.cpp
+++ b/src/d/actor/d_a_am2.cpp
@@ -646,7 +646,7 @@ static void action_mahi(am2_class* i_this) {
break;
case 0xC:
if (i_this->mCountDownTimers[3] == 0 || i_this->mCountDownTimers[3] > 3) {
- actor->attention_info.flags |= fopAc_Attn_ACTION_CARRY_e;
+ cLib_onBit<u32>(actor->attention_info.flags, fopAc_Attn_ACTION_CARRY_e);
}
if (naraku_check(i_this)) {
if (i_this->mbNotInHomeRoom) {
@@ -785,7 +785,7 @@ static void action_mahi(am2_class* i_this) {
if (fopAcM_CheckStatus(actor, fopAcStts_CARRY_e)) {
fopAcM_cancelCarryNow(actor);
- actor->attention_info.flags &= ~fopAc_Attn_ACTION_CARRY_e;
+ cLib_offBit<u32>(actor->attention_info.flags, fopAc_Attn_ACTION_CARRY_e);
actor->gravity = -4.0f;
actor->speed.y = 20.0f;
}
@@ -797,7 +797,7 @@ static void action_mahi(am2_class* i_this) {
if (i_this->mCurrBckIdx != AM2_BCK_BURUBURU) {
anm_init(i_this, AM2_BCK_BURUBURU, 1.0f, J3DFrameCtrl::LOOP_REPEAT_e, 1.0f, -1);
i_this->mCountDownTimers[3] = 20*30;
- actor->attention_info.flags &= ~fopAc_Attn_ACTION_CARRY_e;
+ cLib_offBit<u32>(actor->attention_info.flags, fopAc_Attn_ACTION_CARRY_e);
fopAcM_seStart(i_this, JA_SE_CM_AM2_RECOVER, 0);
fopAcM_monsSeStart(actor, JA_SE_CV_AM2_AWAKE, 0);
}
@@ -805,7 +805,7 @@ static void action_mahi(am2_class* i_this) {
if (i_this->mCountDownTimers[3] == 1) {
if (fopAcM_CheckStatus(actor, fopAcStts_CARRY_e)) {
fopAcM_cancelCarryNow(actor);
- actor->attention_info.flags &= ~fopAc_Attn_ACTION_CARRY_e;
+ cLib_offBit<u32>(actor->attention_info.flags, fopAc_Attn_ACTION_CARRY_e);
}
fopAcM_OnStatus(actor, fopAcStts_SHOWMAP_e);
actor->gravity = -4.0f;