diff --git a/include/d/actor/d_a_arrow.h b/include/d/actor/d_a_arrow.h index 682ffd43d7..0974a30648 100644 --- a/include/d/actor/d_a_arrow.h +++ b/include/d/actor/d_a_arrow.h @@ -57,7 +57,7 @@ public: ~daArrow_c(); void setBombArrowExplode() { field_0x950 = 0; } - bool checkBombArrow() const { return mArrowType == true; } + bool checkBombArrow() const { return mArrowType == ARROW_TYPE_BOMB; } u32 getHitAcID() { return mHitAcID; } BOOL checkWait() { return fopAcM_GetParam(this) == 0; } diff --git a/include/d/actor/d_a_e_ym.h b/include/d/actor/d_a_e_ym.h index 3217592e13..36751bd54d 100644 --- a/include/d/actor/d_a_e_ym.h +++ b/include/d/actor/d_a_e_ym.h @@ -159,7 +159,7 @@ private: /* 0x6C4 */ cXyz* mTagPosP; /* 0x6C8 */ u8 mTagNo; /* 0x6C9 */ u8 field_0x6c9; - /* 0x6CA */ u8 mFlyType; + /* 0x6CA */ bool mFlyType; /* 0x6CB */ u8 field_0x6cb; /* 0x6CC */ u8 field_0x6cc; /* 0x6CD */ u8 field_0x6cd; diff --git a/include/d/actor/d_a_midna.h b/include/d/actor/d_a_midna.h index c9e84ee9d4..228217ae43 100644 --- a/include/d/actor/d_a_midna.h +++ b/include/d/actor/d_a_midna.h @@ -387,7 +387,7 @@ public: BOOL checkDemoPortalWarpWait() const { return mDemoMode == 11; } static BOOL checkMidnaRealBody() { - return dKy_darkworld_check() == true || dComIfGs_isTransformLV(3); + return dKy_darkworld_check() == TRUE || dComIfGs_isTransformLV(3); } static bool checkMidnaTired() { diff --git a/include/d/actor/d_a_npc4.h b/include/d/actor/d_a_npc4.h index 8b82886e62..dea2924ff2 100644 --- a/include/d/actor/d_a_npc4.h +++ b/include/d/actor/d_a_npc4.h @@ -107,9 +107,9 @@ public: u8 getArg0(int i_idx) { return mPathInfo->m_points[i_idx].mArg0; } Vec getPntPos(int i_idx) { return mPathInfo->m_points[i_idx].m_position; } BOOL chkClose() { return dPath_ChkClose(mPathInfo); } - BOOL chkReverse() { return mIsReversed == true; } - void onReverse() { mIsReversed = true; } - void offReverse() { mIsReversed = false; } + BOOL chkReverse() { return mIsReversed == TRUE; } + void onReverse() { mIsReversed = TRUE; } + void offReverse() { mIsReversed = FALSE; } dPath* getPathInfo() { return mPathInfo; } void setRange(f32 i_range) { mRange = i_range; } int getNumPnts() { return mPathInfo->m_num; } diff --git a/include/d/actor/d_a_obj_glowSphere.h b/include/d/actor/d_a_obj_glowSphere.h index f620306408..6d22f8bcf2 100644 --- a/include/d/actor/d_a_obj_glowSphere.h +++ b/include/d/actor/d_a_obj_glowSphere.h @@ -123,10 +123,10 @@ public: u8 getArg0() { return fopAcM_GetParamBit(this, 8, 8); } u8 getColor() { return fopAcM_GetParamBit(this, 0x10, 8); } - void onGetFlag() { mGetFlag = true; } - void offGetFlag() { mGetFlag = false; } + void onGetFlag() { mGetFlag = TRUE; } + void offGetFlag() { mGetFlag = FALSE; } void saveGetFlag() { field_0x951 = mGetFlag; } - bool is_getted() { return mGetFlag == true; } + bool is_getted() { return mGetFlag == TRUE; } void reset() { current.pos = home.pos; diff --git a/include/d/actor/d_a_obj_pillar.h b/include/d/actor/d_a_obj_pillar.h index a0dfda5216..674dd2e20d 100644 --- a/include/d/actor/d_a_obj_pillar.h +++ b/include/d/actor/d_a_obj_pillar.h @@ -60,7 +60,7 @@ public: u8 getMdlType() { return field_0x73e & 0xF; } - bool checkRollAttack() { return mIsRollAttack == true; } + bool checkRollAttack() { return mIsRollAttack == TRUE; } void setShake(int i_shake) { mShake = i_shake; } void setAction(u8 i_action) { mAction = i_action; } diff --git a/include/d/actor/d_a_obj_zraMark.h b/include/d/actor/d_a_obj_zraMark.h index 7499078cfa..eb66ae9005 100644 --- a/include/d/actor/d_a_obj_zraMark.h +++ b/include/d/actor/d_a_obj_zraMark.h @@ -111,9 +111,9 @@ public: void informBlast(); u8 getMarkNo() { return fopAcM_GetParam(this) & 0xff; } - void initBlastFlag() { mBlastFlag = false; } - void onBlastFlag() { mBlastFlag = true; } - bool is_blasted() { return mBlastFlag == true; } + void initBlastFlag() { mBlastFlag = FALSE; } + void onBlastFlag() { mBlastFlag = TRUE; } + bool is_blasted() { return mBlastFlag == TRUE; } bool is_branch_pat() { return mType == 0 || mType == 2; } int get_MarkType() { diff --git a/include/d/actor/d_a_tag_lantern.h b/include/d/actor/d_a_tag_lantern.h index c0e0c0d152..c134589bb1 100644 --- a/include/d/actor/d_a_tag_lantern.h +++ b/include/d/actor/d_a_tag_lantern.h @@ -42,13 +42,13 @@ public: BOOL chkClimbDownLadderStatus() { f32 var_f31 = fopAcM_searchPlayerDistanceY(this); - BOOL rt = false; + BOOL rt = FALSE; if (fopAcM_searchPlayerDistanceXZ(this) < scale.x && 0.0f <= var_f31 && var_f31 < scale.y) { rt = dComIfGp_checkItemGet(dItemNo_KANTERA_e, 1) && dComIfGs_getOil() != 0; - field_0x5f8 = rt == true ? 0 : 1; + field_0x5f8 = rt == TRUE ? 0 : 1; } else { - rt = true; + rt = TRUE; } return rt; diff --git a/src/d/actor/d_a_alink_demo.inc b/src/d/actor/d_a_alink_demo.inc index d913297a7e..dcdf96248d 100644 --- a/src/d/actor/d_a_alink_demo.inc +++ b/src/d/actor/d_a_alink_demo.inc @@ -4251,7 +4251,7 @@ int daAlink_c::procDungeonWarpSceneStart() { } #endif - if (fopOvlpM_IsPeek() == true) { + if (fopOvlpM_IsPeek() == TRUE) { return 1; } diff --git a/src/d/actor/d_a_alink_wolf.inc b/src/d/actor/d_a_alink_wolf.inc index 79df1401c0..932c0de2b0 100644 --- a/src/d/actor/d_a_alink_wolf.inc +++ b/src/d/actor/d_a_alink_wolf.inc @@ -3167,7 +3167,7 @@ int daAlink_c::procWolfAutoJumpInit(int param_0) { mpHIO->mWolf.mWlAutoJump.m.mJumpAnm.mStartFrame, mpHIO->mWolf.mWlAutoJump.m.mJumpAnm.mEndFrame, mpHIO->mWolf.mWlAutoJump.m.mJumpAnm.mInterpolation); - if (speedF > mMaxSpeed || param_0 || mpHIO->mWolf.mWlAutoJump.m.mAlwaysMaxSpeedJump == true) { + if (speedF > mMaxSpeed || param_0 || mpHIO->mWolf.mWlAutoJump.m.mAlwaysMaxSpeedJump == TRUE) { speedF = mMaxSpeed; } else if (speedF < minSpeed) { speedF = minSpeed; diff --git a/src/d/actor/d_a_arrow.cpp b/src/d/actor/d_a_arrow.cpp index 769c3273e9..fce9817d4d 100644 --- a/src/d/actor/d_a_arrow.cpp +++ b/src/d/actor/d_a_arrow.cpp @@ -21,14 +21,14 @@ int daArrow_c::createHeap() { J3DModelData* model_data; - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { model_data = (J3DModelData*)dComIfG_getObjectRes("HoZelda", 0x1f); } else { u16 index; - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { index = 0x20; - } else if (mArrowType == 1) { + } else if (mArrowType == ARROW_TYPE_BOMB) { index = 0x1d; } else { index = 0x1c; @@ -92,8 +92,7 @@ void daArrow_c::atHitCallBack(dCcD_GObjInf* i_atObjInf, fopAc_ac_c* i_tgActor, d if (dist_to_hitpos < field_0x998) { field_0x998 = dist_to_hitpos; mHitAcID = fopAcM_GetID(i_tgActor); - - if (mArrowType == 1) { + if (mArrowType == ARROW_TYPE_BOMB) { field_0x9a8 = *hit_pos_p; } else if (i_tgObjInf->ChkTgShield()) { field_0x93e = 1; @@ -207,7 +206,7 @@ void daArrow_c::setArrowAt(f32 param_0) { daAlink_c* player = daAlink_getAlinkActorClass(); f32 radius; - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { radius = 8.0f; } else { radius = 5.0f; @@ -261,7 +260,7 @@ void daArrow_c::arrowShooting() { field_0x950 = link->getBombArrowFlyExplodeTime(); - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { current.angle.x = -link->getBodyAngleX(); current.angle.y = link->shape_angle.y + link->getBodyAngleY(); } else if (dComIfGp_checkPlayerStatus0(0, 0x200000) || fopAcM_GetParam(this) == 2) { @@ -305,11 +304,11 @@ void daArrow_c::arrowShooting() { speed += dst; } - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { field_0x688.SetAtMtrl(dCcD_MTRL_LIGHT); field_0x688.OnAtNoHitMark(); } else { - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { field_0x688.SetAtType(0x80); field_0x688.SetAtSe(22); field_0x688.SetAtAtp(0); @@ -392,7 +391,7 @@ void daArrow_c::setSmokePos() { } void daArrow_c::setKeepMatrix() { - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { daHoZelda_c* actor = (daHoZelda_c*)field_0xa08.getActor(); if (actor != NULL) { mDoMtx_stack_c::copy(actor->getRightHandMtx()); @@ -436,7 +435,7 @@ fopAc_ac_c* daArrow_c::setStopActorMatrix() { } void daArrow_c::setBombMoveEffect() { - if (mArrowType == 1 && field_0x945 == 0 && field_0x943 == 0) { + if (mArrowType == ARROW_TYPE_BOMB && field_0x945 == 0 && field_0x943 == 0) { setSmokePos(); field_0x964 = dComIfGp_particle_set(field_0x964, 0x1e0, &field_0x9cc, &tevStr, &field_0x958, NULL, 0xff, &field_0xa10, -1, NULL, NULL, NULL); @@ -478,7 +477,7 @@ int daArrow_c::procWait() { tevStr.TevColor.b = 0; daAlink_c* link = daAlink_getAlinkActorClass(); - if (mArrowType == 1) { + if (mArrowType == ARROW_TYPE_BOMB) { field_0x688.SetAtAtp(0); if (!link->checkCanoeSlider()) { field_0x688.OnAtSPrmBit(0x20); @@ -496,7 +495,7 @@ int daArrow_c::procWait() { mProcFunc = &daArrow_c::procMove; arrowShooting(); setBombMoveEffect(); - } else if (mArrowType == 1) { + } else if (mArrowType == ARROW_TYPE_BOMB) { setSmokePos(); field_0x964 = dComIfGp_particle_set(field_0x964, 0x1df, &field_0x9cc, &tevStr, &field_0x958, @@ -581,7 +580,7 @@ int daArrow_c::procMove() { current.pos = v2 - (speed * 95.0f); speed *= 80.0f; - if (mArrowType != 4) { + if (mArrowType != ARROW_TYPE_SLING) { mOutLengthRate = 1.1875f; } @@ -619,7 +618,7 @@ int daArrow_c::procMove() { int iVar3; if (field_0x688.ChkAtHit() != 0) { - if (mArrowType == 1 && field_0x943 == 0) { + if (mArrowType == ARROW_TYPE_BOMB && field_0x943 == 0) { if (field_0x945 != 0) { field_0x93f = 1; return TRUE; @@ -631,7 +630,7 @@ int daArrow_c::procMove() { } } - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { if (field_0x688.GetAtHitAc() != NULL && fopAcM_GetName(field_0x688.GetAtHitAc()) == fpcNm_E_PZ_e) { iVar3 = 0; } else { @@ -676,10 +675,10 @@ int daArrow_c::procMove() { } if (iVar3 != 0 && iVar3 != 3) { - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { setLightArrowHitMark(field_0x688.GetAtHitPosP()); setBlur(); - } else if (mArrowType == 4) { + } else if (mArrowType == ARROW_TYPE_SLING) { procSlingHitInit(field_0x56c.GetCrossP(), NULL); } else if (iVar3 == 2) { if (field_0x945) { @@ -708,19 +707,19 @@ int daArrow_c::procMove() { if (line_cross) { current.pos = field_0x56c.GetCross(); - if (field_0x945 != 0 && (mArrowType == 1 || current.pos.y - field_0x9fc.y < -300.0f)) { + if (field_0x945 != 0 && (mArrowType == ARROW_TYPE_BOMB || current.pos.y - field_0x9fc.y < -300.0f)) { field_0x93f = 1; return TRUE; } dKy_Sound_set(current.pos, 3, fopAcM_GetID(this), 10); - if (mArrowType == 1) { + if (mArrowType == ARROW_TYPE_BOMB) { setBombArrowExplode(¤t.pos); return TRUE; } - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { setLightArrowHitMark(¤t.pos); } @@ -728,7 +727,7 @@ int daArrow_c::procMove() { u32 se_id; dComIfG_Bgsp().GetTriPla(field_0x56c, &local_4c); int local_d8 = dComIfG_Bgsp().GetPolyAtt0(field_0x56c); - if (local_d8 == 2 || mArrowType == 4 || local_d8 == 0xe || local_d8 == 10 || local_d8 == 8) { + if (local_d8 == 2 || mArrowType == ARROW_TYPE_SLING || local_d8 == 0xe || local_d8 == 10 || local_d8 == 8) { if (field_0x945 != 0) { field_0x93f = 1; return TRUE; @@ -739,7 +738,7 @@ int daArrow_c::procMove() { cM_atan2s(-local_4c.GetNP()->x, -local_4c.GetNP()->z), 0.0f ); - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { se_id = Z2SE_HIT_PACHINKO; current.angle = angle; procSlingHitInit(¤t.pos, NULL); @@ -789,7 +788,7 @@ int daArrow_c::procMove() { } else { f32 distance = current.pos.abs(mStartPos); if (distance > mFlyMax || fopAcM_GetGravity(this) < 0.0f) { - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { fopAcM_SetGravity(this, -5.0f); } else { fopAcM_SetGravity(this, -2.0f); @@ -806,29 +805,29 @@ int daArrow_c::procMove() { shape_angle.x = speed.atan2sY_XZ(); current.angle.x = -shape_angle.x; - if (mArrowType != 4) { + if (mArrowType != ARROW_TYPE_SLING) { mOutLengthRate = 95.0f / speed.abs(); } } u32 sound_id; - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { sound_id = Z2SE_ZELDA_ARROW_FLY; } else { if (fopAcM_GetParam(this) == 2) { - if (mArrowType == 1) { + if (mArrowType == ARROW_TYPE_BOMB) { sound_id = Z2SE_OBJ_ARROWBOMB_FLYGAIN; } else { sound_id = Z2SE_OBJ_ARROW_FLY_GAIN; } - } else if (mArrowType == 1) { + } else if (mArrowType == ARROW_TYPE_BOMB) { sound_id = Z2SE_OBJ_ARROWBOMB_FLY; } else { sound_id = Z2SE_OBJ_ARROW_FLY_NORMAL; } } - if (mArrowType != 4) { + if (mArrowType != ARROW_TYPE_SLING) { mSoundObjArrow.startLevelSound(sound_id, 0, mReverb); } @@ -883,7 +882,7 @@ int daArrow_c::procReturn() { decAlphaBlur(); if(dComIfG_Bgsp().LineCross(&field_0x56c)) { - if (mArrowType == 1 && field_0x943 == 0) { + if (mArrowType == ARROW_TYPE_BOMB && field_0x943 == 0) { setBombArrowExplode(field_0x56c.GetCrossP()); return TRUE; } @@ -1028,7 +1027,7 @@ int daArrow_c::execute() { (this->*mProcFunc)(); - if (mArrowType == 1 && field_0x93f == 0) { + if (mArrowType == ARROW_TYPE_BOMB && field_0x93f == 0) { if (field_0x950 != 0) { field_0x950--; } else { @@ -1043,7 +1042,7 @@ int daArrow_c::execute() { } } - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { setLightChargeEffect(0); } @@ -1078,7 +1077,7 @@ int daArrow_c::draw() { field_0x940 = 0; } - if (mArrowType == 1) { + if (mArrowType == ARROW_TYPE_BOMB) { if (field_0x943 != 0) { color.r = link->getFreezeR(); color.g = link->getFreezeG(); @@ -1110,7 +1109,7 @@ int daArrow_c::draw() { g_env_light.setLightTevColorType_MAJI(mpModel, &tevStr); mDoExt_modelUpdateDL(mpModel); - if (mArrowType == 1) { + if (mArrowType == ARROW_TYPE_BOMB) { color.r = 0; color.g = 0; color.b = 0; @@ -1138,18 +1137,18 @@ cPhs_Step daArrow_c::create() { mArrowType = fopAcM_GetParamBit(this, 8, 8); fopAcM_SetParam(this, (u8)fopAcM_GetParam(this)); - if (!fopAcM_entrySolidHeap(this, daArrow_createHeap, mArrowType == 1 ? 0xea0 : 0x810)) { + if (!fopAcM_entrySolidHeap(this, daArrow_createHeap, mArrowType == ARROW_TYPE_BOMB ? 0xea0 : 0x810)) { return cPhs_ERROR_e; } - if (mArrowType == 2) { + if (mArrowType == ARROW_TYPE_LIGHT) { field_0xa08.setData(fopAcM_Search((fopAcIt_JudgeFunc)daAlink_searchHorseZelda, NULL)); field_0x946 = 6; field_0x94c = 0x896e; - } else if (mArrowType == 0) { + } else if (mArrowType == ARROW_TYPE_NORMAL) { field_0x946 = 1; field_0x94c = 0x3b8; - } else if (mArrowType == 4) { + } else if (mArrowType == ARROW_TYPE_SLING) { field_0x946 = 1; field_0x94c = 0xa55; } else { @@ -1166,7 +1165,7 @@ cPhs_Step daArrow_c::create() { field_0x7cc.SetStts(&field_0x64c); daAlink_c* player = daAlink_getAlinkActorClass(); - if (mArrowType == 4) { + if (mArrowType == ARROW_TYPE_SLING) { setNormalMatrix(); player->getArrowFlyData(&mFlyMax, &field_0x99c, 0); mOutLengthRate = 0.0f; diff --git a/src/d/actor/d_a_b_zant.cpp b/src/d/actor/d_a_b_zant.cpp index c72558b701..65ba21f832 100644 --- a/src/d/actor/d_a_b_zant.cpp +++ b/src/d/actor/d_a_b_zant.cpp @@ -873,20 +873,20 @@ void daB_ZANT_c::setZantMessage(int i_msgNo) { mMsgID = fopMsgM_messageSet(i_msgNo, 1000); } -int daB_ZANT_c::doZantMessage() { +BOOL daB_ZANT_c::doZantMessage() { if (mpMsg != NULL) { if (mpMsg->mode == 14) { mpMsg->mode = 16; } else if (mpMsg->mode == 18) { mpMsg->mode = 19; mMsgID = fpcM_ERROR_PROCESS_ID_e; - return 1; + return TRUE; } } else { mpMsg = fopMsgM_SearchByID(mMsgID); } - return 0; + return FALSE; } void daB_ZANT_c::setIceLandingEffect(BOOL i_landFootR) { @@ -1395,7 +1395,7 @@ void daB_ZANT_c::executeOpening() { } break; case MODE_MSG_1_WAIT: - if (doZantMessage() == true) { + if (doZantMessage() == TRUE) { mModeTimer = 20; mMode = MODE_WARP_OUT_SE; } @@ -1463,7 +1463,7 @@ void daB_ZANT_c::executeOpening() { } break; case MODE_MSG_2: - if (doZantMessage() == true) { + if (doZantMessage() == TRUE) { setBck(BCK_ZAN_OP_RISE, J3DFrameCtrl::EMode_LOOP, 10.0f, 1.0f); mMode = MODE_FLY_UP; mModeTimer = 90; diff --git a/src/d/actor/d_a_e_ym.cpp b/src/d/actor/d_a_e_ym.cpp index fe4f12bcbd..90a68f7c1c 100644 --- a/src/d/actor/d_a_e_ym.cpp +++ b/src/d/actor/d_a_e_ym.cpp @@ -567,7 +567,7 @@ void daE_YM_c::setAppear() { } void daE_YM_c::setMoveSound(int param_0) { - if (mFlyType == 1) { + if (mFlyType == true) { if (checkBck("E_TM", 10) == 0) { return; } @@ -1016,7 +1016,7 @@ void daE_YM_c::executeDown() { field_0x6cf = 0; switch (mMode) { case 0: - if (mFlyType == 1) { + if (mFlyType == true) { bckSet(6, 0, 5.0f, 0.0f); } else { bckSet(0x10, 2, 5.0f, 1.0f); @@ -1065,7 +1065,7 @@ void daE_YM_c::executeDown() { cLib_addCalcAngleS(&shape_angle.x, -0x8000, 8, 0x1000, 0x10); } if (mAcch.ChkGroundHit()) { - if (mFlyType != 1) { + if (mFlyType != true) { bckSet(6, 0, 0.0f, 1.0f); } if (mMode == 1) { @@ -3319,7 +3319,7 @@ static int daE_YM_Delete(daE_YM_c* i_this) { } int daE_YM_c::CreateHeap() { - if (mFlyType == 1) { + if (mFlyType == true) { J3DModelData* modelData = (J3DModelData*)dComIfG_getObjectRes("E_TM", 0x11); JUT_ASSERT(0x1094, modelData != NULL); mpMorf = new mDoExt_McaMorfSO(modelData, NULL, NULL, (J3DAnmTransform*)dComIfG_getObjectRes("E_TM", 10), diff --git a/src/d/actor/d_a_npc_bans.cpp b/src/d/actor/d_a_npc_bans.cpp index 722a95a7ea..e7d84b00a9 100644 --- a/src/d/actor/d_a_npc_bans.cpp +++ b/src/d/actor/d_a_npc_bans.cpp @@ -442,7 +442,7 @@ cPhs_Step daNpc_Bans_c::create() { int daNpc_Bans_c::CreateHeap() { J3DModelData* modelData = NULL; J3DModel* model = NULL; - u32 idx = mTwilight == true ? TRUE : FALSE; + u32 idx = mTwilight == TRUE ? TRUE : FALSE; int resIdx = l_bmdData[idx][1]; int bmdIdx = l_bmdData[idx][0]; modelData = (J3DModelData*)dComIfG_getObjectRes(l_resNameList[resIdx], bmdIdx); diff --git a/src/d/actor/d_a_npc_doc.cpp b/src/d/actor/d_a_npc_doc.cpp index 5d5093b373..fd71f937ae 100644 --- a/src/d/actor/d_a_npc_doc.cpp +++ b/src/d/actor/d_a_npc_doc.cpp @@ -225,7 +225,7 @@ int daNpc_Doc_c::CreateHeap() { int bmdIdx; enum { IDX0 }; - int idx = mTwilight == true ? IDX0 : IDX0; + int idx = mTwilight == TRUE ? IDX0 : IDX0; resIdx = l_bmdData[idx][1]; bmdIdx = l_bmdData[idx][0]; diff --git a/src/d/actor/d_a_npc_grm.cpp b/src/d/actor/d_a_npc_grm.cpp index 6b4241523f..43b80686aa 100644 --- a/src/d/actor/d_a_npc_grm.cpp +++ b/src/d/actor/d_a_npc_grm.cpp @@ -227,7 +227,7 @@ cPhs_Step daNpc_grM_c::create() { } int daNpc_grM_c::CreateHeap() { - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; J3DModelData* mdlData_p = static_cast( dComIfG_getObjectRes(l_resNameList[l_bmdData[bmdIdx][1]], l_bmdData[bmdIdx][0])); @@ -574,7 +574,7 @@ void daNpc_grM_c::setAttnPos() { void daNpc_grM_c::setCollision() { cXyz pos; if (!mHide) { - if (mTwilight == true && !dComIfGp_event_runCheck()) { + if (mTwilight == TRUE && !dComIfGp_event_runCheck()) { mCyl.SetCoSPrm(105); } else { mCyl.SetCoSPrm(121); diff --git a/src/d/actor/d_a_npc_grmc.cpp b/src/d/actor/d_a_npc_grmc.cpp index 8b9a261d76..f9a426b72d 100644 --- a/src/d/actor/d_a_npc_grmc.cpp +++ b/src/d/actor/d_a_npc_grmc.cpp @@ -288,7 +288,7 @@ cPhs_Step daNpc_grMC_c::create() { } int daNpc_grMC_c::CreateHeap() { - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; J3DModelData* mdlData_p = static_cast(dComIfG_getObjectRes(l_resNameList[l_bmdData[bmdIdx][1]], l_bmdData[bmdIdx][0])); @@ -579,7 +579,7 @@ void daNpc_grMC_c::setCollision() { cXyz pos; if (!mHide) { - if (mTwilight == true && !dComIfGp_event_runCheck()) { + if (mTwilight == TRUE && !dComIfGp_event_runCheck()) { mCyl.SetCoSPrm(105); } else { mCyl.SetCoSPrm(121); diff --git a/src/d/actor/d_a_npc_gwolf.cpp b/src/d/actor/d_a_npc_gwolf.cpp index 746f4766c9..924f3a9876 100644 --- a/src/d/actor/d_a_npc_gwolf.cpp +++ b/src/d/actor/d_a_npc_gwolf.cpp @@ -424,7 +424,7 @@ int daNpc_GWolf_c::draw(int param_1, int param_2, f32 param_3, _GXColorS10* i_co fVar1 = 0.0f; } - if (!(cM3d_IsZero(fVar1) > 0)) { + if (!(cM3d_IsZero(fVar1) != false)) { tevStr.TevColor.r = fVar1 * 20.0f; tevStr.TevColor.g = 0; } else if (param_1 != 0) { diff --git a/src/d/actor/d_a_npc_hoz.cpp b/src/d/actor/d_a_npc_hoz.cpp index ea8253323b..5a22b4a638 100644 --- a/src/d/actor/d_a_npc_hoz.cpp +++ b/src/d/actor/d_a_npc_hoz.cpp @@ -371,7 +371,7 @@ int daNpc_Hoz_c::CreateHeap() { int resIdx; int idx = 0; - idx = mTwilight == true ? TRUE : FALSE; + idx = mTwilight == TRUE ? TRUE : FALSE; resIdx = l_bmdData[idx][1]; bmdIdx = l_bmdData[idx][0]; diff --git a/src/d/actor/d_a_npc_kn_base.inc b/src/d/actor/d_a_npc_kn_base.inc index 79e8349c3b..8804e8bb0f 100644 --- a/src/d/actor/d_a_npc_kn_base.inc +++ b/src/d/actor/d_a_npc_kn_base.inc @@ -704,11 +704,11 @@ void daNpc_Kn_c::setFootPrtcl(cXyz* param_0, f32 param_1) { } field_0x9F4.setEffectTwo(&tevStr, ¤t.pos, 0, 0, NULL, - !mFootLOnGround && cross_l == true ? &foot_l_pos : NULL, - !mFootROnGround && cross_r == true ? &foot_r_pos : NULL, + !mFootLOnGround && cross_l == TRUE ? &foot_l_pos : NULL, + !mFootROnGround && cross_r == TRUE ? &foot_r_pos : NULL, &mCurAngle, param_0, fopAcM_GetRoomNo(this), 0.0f, speedF); - if (!mFootLOnGround && cross_l == true) { + if (!mFootLOnGround && cross_l == TRUE) { switch (foot_l_att) { case 3: break; @@ -718,7 +718,7 @@ void daNpc_Kn_c::setFootPrtcl(cXyz* param_0, f32 param_1) { } } - if (!mFootROnGround && cross_r == true) { + if (!mFootROnGround && cross_r == TRUE) { switch (foot_r_att) { case 3: break; diff --git a/src/d/actor/d_a_npc_kolin.cpp b/src/d/actor/d_a_npc_kolin.cpp index a7c1fe41a6..cbabebbd93 100644 --- a/src/d/actor/d_a_npc_kolin.cpp +++ b/src/d/actor/d_a_npc_kolin.cpp @@ -489,7 +489,7 @@ cPhs_Step daNpc_Kolin_c::create() { int daNpc_Kolin_c::CreateHeap() { int bmdIdx; - if (mTwilight == true) { + if (mTwilight == TRUE) { bmdIdx = 1; } else { bmdIdx = 0; diff --git a/src/d/actor/d_a_npc_maro.cpp b/src/d/actor/d_a_npc_maro.cpp index 2384a380aa..86c2bc6230 100644 --- a/src/d/actor/d_a_npc_maro.cpp +++ b/src/d/actor/d_a_npc_maro.cpp @@ -340,7 +340,7 @@ int daNpc_Maro_c::create() { int daNpc_Maro_c::CreateHeap() { J3DModelData* modelData = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? TRUE : FALSE; + int bmdIdx = mTwilight == TRUE ? TRUE : FALSE; int res_name_idx = l_bmdData[bmdIdx][1]; int my_bmd = l_bmdData[bmdIdx][0]; modelData = static_cast(dComIfG_getObjectRes(l_resNameList[res_name_idx], my_bmd)); diff --git a/src/d/actor/d_a_npc_pachi_maro.cpp b/src/d/actor/d_a_npc_pachi_maro.cpp index 6f29d62006..d97d1da018 100644 --- a/src/d/actor/d_a_npc_pachi_maro.cpp +++ b/src/d/actor/d_a_npc_pachi_maro.cpp @@ -617,7 +617,7 @@ int daNpc_Pachi_Maro_c::CreateHeap() { J3DModelData* modelData = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? MARO : NONE; + int bmdIdx = mTwilight == TRUE ? MARO : NONE; int arcIdx = l_bmdData[bmdIdx][1]; int idx = l_bmdData[bmdIdx][0]; modelData = static_cast(dComIfG_getObjectRes(l_resNameList[arcIdx], idx)); diff --git a/src/d/actor/d_a_npc_pachi_taro.cpp b/src/d/actor/d_a_npc_pachi_taro.cpp index 99d47bc5b5..2b934f7fcd 100644 --- a/src/d/actor/d_a_npc_pachi_taro.cpp +++ b/src/d/actor/d_a_npc_pachi_taro.cpp @@ -843,7 +843,7 @@ int daNpc_Pachi_Taro_c::CreateHeap() { J3DModelData* modelData = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? TARO0 : NONE; + int bmdIdx = mTwilight == TRUE ? TARO0 : NONE; int resNameIdx = l_bmdData[bmdIdx][1]; int resIdx = l_bmdData[bmdIdx][0]; modelData = static_cast(dComIfG_getObjectRes(l_resNameList[resNameIdx], resIdx)); diff --git a/src/d/actor/d_a_npc_raca.cpp b/src/d/actor/d_a_npc_raca.cpp index 4aa9ab47c1..110a7e57dc 100644 --- a/src/d/actor/d_a_npc_raca.cpp +++ b/src/d/actor/d_a_npc_raca.cpp @@ -289,7 +289,7 @@ cPhs_Step daNpc_Raca_c::create() { } int daNpc_Raca_c::CreateHeap() { - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; J3DModelData* modelData = (J3DModelData*)dComIfG_getObjectRes(l_resNameList[l_bmdData[bmdIdx][1]], l_bmdData[bmdIdx][0]); if (modelData == NULL) { return 0; diff --git a/src/d/actor/d_a_npc_saru.cpp b/src/d/actor/d_a_npc_saru.cpp index 671acb7e4d..827ec925c4 100644 --- a/src/d/actor/d_a_npc_saru.cpp +++ b/src/d/actor/d_a_npc_saru.cpp @@ -367,7 +367,7 @@ int daNpc_Saru_c::CreateHeap() { 2, 3, }; - int bmdIdx = mTwilight == true ? TRUE : FALSE; + int bmdIdx = mTwilight == TRUE ? TRUE : FALSE; J3DModelData* modelData = static_cast(dComIfG_getObjectRes(l_resNameList[l_bmdData[bmdIdx][1]], l_bmdData[bmdIdx][0])); if (modelData == NULL) { return 0; @@ -620,7 +620,7 @@ BOOL daNpc_Saru_c::evtCutProc() { void daNpc_Saru_c::action() { fopAc_ac_c* actor_p = NULL; - if (mTwilight == false) { + if (mTwilight == FALSE) { actor_p = hitChk(&field_0xe4c, -1); } @@ -743,7 +743,7 @@ void daNpc_Saru_c::drawOtherMdl() { Mtx mtx; J3DModel* model = mpMorf[0]->getModel(); for (int i = 0; i < 2; i++) { - if (mpRoseModels[i] != NULL && ((i == 0 && mTwilight == false) || (i == 1 && mTwilight != false))) { + if (mpRoseModels[i] != NULL && ((i == 0 && mTwilight == FALSE) || (i == 1 && mTwilight != false))) { g_env_light.setLightTevColorType_MAJI(mpRoseModels[i], &tevStr); mDoMtx_stack_c::copy(model->getAnmMtx(jointNo[i])); cMtx_copy(mDoMtx_stack_c::get(), mtx); @@ -780,7 +780,7 @@ int daNpc_Saru_c::setAction(int (daNpc_Saru_c::*action)(void*)) { } void daNpc_Saru_c::setSe() { - if (cM3d_IsZero(mpMorf[0]->getPlaySpeed()) <= 0) { + if (cM3d_IsZero(mpMorf[0]->getPlaySpeed()) == false) { if ((J3DAnmTransform*)dComIfG_getObjectRes(l_resNameList[l_motionAnmData[25].mBckArcIdx], l_motionAnmData[25].mBckFileIdx) == mpMorf[0]->getAnm()) { if (mpMorf[0]->checkFrame(0.0f)) { mSound.startCreatureVoice(Z2SE_KOSARU_V_WALK, -1); @@ -1088,7 +1088,7 @@ int daNpc_Saru_c::wait(void* param_1) { } } - if (mPlayerActorMngr.getActorP() != NULL && mTwilight == false) { + if (mPlayerActorMngr.getActorP() != NULL && mTwilight == FALSE) { mJntAnm.lookPlayer(0); if (!chkActorInSight(mPlayerActorMngr.getActorP(), mAttnFovY, mCurAngle.y)) { mJntAnm.lookNone(0); diff --git a/src/d/actor/d_a_npc_sola.cpp b/src/d/actor/d_a_npc_sola.cpp index 0bac7e4fb6..74f6900ef6 100644 --- a/src/d/actor/d_a_npc_sola.cpp +++ b/src/d/actor/d_a_npc_sola.cpp @@ -359,7 +359,7 @@ void daNpc_solA_c::setAttnPos() { void daNpc_solA_c::setCollision() { cXyz pos; if (!mHide) { - int prm = mTwilight == true ? 0x69 : 0x79; + int prm = mTwilight == TRUE ? 0x69 : 0x79; mCyl.SetCoSPrm(prm); pos = current.pos; diff --git a/src/d/actor/d_a_npc_toby.cpp b/src/d/actor/d_a_npc_toby.cpp index db423a1d13..88682cf935 100644 --- a/src/d/actor/d_a_npc_toby.cpp +++ b/src/d/actor/d_a_npc_toby.cpp @@ -350,7 +350,7 @@ int daNpc_Toby_c::CreateHeap() { J3DModelData* modelData = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? TRUE : FALSE; + int bmdIdx = mTwilight == TRUE ? TRUE : FALSE; int res_name_idx = l_bmdData[bmdIdx][1]; int my_bmd = l_bmdData[bmdIdx][0]; modelData = static_cast(dComIfG_getObjectRes(l_resNameList[res_name_idx], my_bmd)); @@ -1878,7 +1878,7 @@ int daNpc_Toby_c::wait(void*) { } } - if (mTwilight == false && mHide == 0 && daPy_py_c::checkNowWolf()) { + if (mTwilight == FALSE && mHide == 0 && daPy_py_c::checkNowWolf()) { cXyz att_pos = getAttnPos(daPy_getPlayerActorClass()); if (field_0x1000) { if (chkPointInArea(att_pos, attention_info.position, @@ -1918,7 +1918,7 @@ int daNpc_Toby_c::wait(void*) { mPlayerActorMngr.remove(); } - if (mPlayerActorMngr.getActorP() != NULL && mTwilight == false) { + if (mPlayerActorMngr.getActorP() != NULL && mTwilight == FALSE) { int reg_r28 = 1; mJntAnm.lookPlayer(0); if (chkActorInSight(mPlayerActorMngr.getActorP(), mAttnFovY, mCurAngle.y) == FALSE) { diff --git a/src/d/actor/d_a_npc_yamid.cpp b/src/d/actor/d_a_npc_yamid.cpp index c9e9e64280..bef3d826e6 100644 --- a/src/d/actor/d_a_npc_yamid.cpp +++ b/src/d/actor/d_a_npc_yamid.cpp @@ -259,7 +259,7 @@ cPhs_Step daNpc_yamiD_c::create() { int daNpc_yamiD_c::CreateHeap() { J3DModelData* mdlData_p = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; int res_name_idx = l_bmdData[bmdIdx][1]; int index = l_bmdData[bmdIdx][0]; diff --git a/src/d/actor/d_a_npc_yamis.cpp b/src/d/actor/d_a_npc_yamis.cpp index 0c418b1730..97e578e81a 100644 --- a/src/d/actor/d_a_npc_yamis.cpp +++ b/src/d/actor/d_a_npc_yamis.cpp @@ -196,7 +196,7 @@ cPhs_Step daNpc_yamiS_c::create() { int daNpc_yamiS_c::CreateHeap() { J3DModelData* mdlData_p = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; int res_name_idx = l_bmdData[bmdIdx][1]; int index = l_bmdData[bmdIdx][0]; diff --git a/src/d/actor/d_a_npc_yamit.cpp b/src/d/actor/d_a_npc_yamit.cpp index f5faefdf97..8af916ed0d 100644 --- a/src/d/actor/d_a_npc_yamit.cpp +++ b/src/d/actor/d_a_npc_yamit.cpp @@ -199,7 +199,7 @@ cPhs_Step daNpc_yamiT_c::create() { int daNpc_yamiT_c::CreateHeap() { J3DModelData* mdlData_p = NULL; J3DModel* model = NULL; - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; int res_name_idx = l_bmdData[bmdIdx][1]; int index = l_bmdData[bmdIdx][0]; diff --git a/src/d/actor/d_a_npc_zelR.cpp b/src/d/actor/d_a_npc_zelR.cpp index bd59d22cdf..ac82a43596 100644 --- a/src/d/actor/d_a_npc_zelR.cpp +++ b/src/d/actor/d_a_npc_zelR.cpp @@ -195,7 +195,7 @@ int daNpc_ZelR_c::create() { } int daNpc_ZelR_c::CreateHeap() { - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; J3DModelData* mdlData_p = (J3DModelData*)(dComIfG_getObjectRes( l_resNameList[l_bmdData[bmdIdx].arcIdx], l_bmdData[bmdIdx].fileIdx )); diff --git a/src/d/actor/d_a_npc_zelRo.cpp b/src/d/actor/d_a_npc_zelRo.cpp index 8eeabe0d67..85d8bbd28d 100644 --- a/src/d/actor/d_a_npc_zelRo.cpp +++ b/src/d/actor/d_a_npc_zelRo.cpp @@ -223,7 +223,7 @@ cPhs_Step daNpc_ZelRo_c::create() { } int daNpc_ZelRo_c::CreateHeap() { - int bmdIdx = mTwilight == true ? NONE : NONE; + int bmdIdx = mTwilight == TRUE ? NONE : NONE; J3DModelData* mdlData_p = (J3DModelData*)dComIfG_getObjectRes(l_resNameList[l_bmdData[bmdIdx][1]], l_bmdData[bmdIdx][0]); JUT_ASSERT(432, NULL != mdlData_p); @@ -521,7 +521,7 @@ void daNpc_ZelRo_c::setCollision() { cXyz pos; if (!mHide) { - if (mTwilight == true && !dComIfGp_event_runCheck()) { + if (mTwilight == TRUE && !dComIfGp_event_runCheck()) { mCyl.SetCoSPrm(0x69); } else { mCyl.SetCoSPrm(0x79); diff --git a/src/d/d_s_play.cpp b/src/d/d_s_play.cpp index 869f5499b1..b916590d08 100644 --- a/src/d/d_s_play.cpp +++ b/src/d/d_s_play.cpp @@ -1165,11 +1165,11 @@ static int phase_1(dScnPly_c* i_this) { } if ((u8)dKy_darkworld_stage_check(dComIfGp_getStartStageName(), - dComIfGp_getStartStageRoomNo()) == true) + dComIfGp_getStartStageRoomNo()) == TRUE) { dComIfGp_world_dark_set(1); } else if ((u8)dKy_darkworld_spot_check(dComIfGp_getStartStageName(), - dComIfGp_getStartStageRoomNo()) == true) + dComIfGp_getStartStageRoomNo()) == TRUE) { dComIfGp_world_dark_set(2); } else {