diff options
| author | LagoLunatic <LagoLunatic@users.noreply.github.com> | 2024-07-19 13:17:43 -0400 |
|---|---|---|
| committer | LagoLunatic <LagoLunatic@users.noreply.github.com> | 2024-07-19 13:17:43 -0400 |
| commit | 287bdab653c8ec4e10c31b6b2530dfd5ff7b9639 (patch) | |
| tree | d4e3870a294512cd0b0cda13fc3e9de776d66c31 /src | |
| parent | 66dfae2571265ed7b72c9a6cb74d804a50695f3e (diff) | |
Match daNpc_Bs1_c::CreateInit and cLib_minMaxLimit inline
Diffstat (limited to 'src')
| -rw-r--r-- | src/d/actor/d_a_bomb2.cpp | 6 | ||||
| -rw-r--r-- | src/d/actor/d_a_npc_bs1.cpp | 2 | ||||
| -rw-r--r-- | src/d/actor/d_a_obj_roten.cpp | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/d/actor/d_a_bomb2.cpp b/src/d/actor/d_a_bomb2.cpp index 023e0225..b6725ed9 100644 --- a/src/d/actor/d_a_bomb2.cpp +++ b/src/d/actor/d_a_bomb2.cpp @@ -1293,10 +1293,10 @@ namespace daBomb2 { }; if(fopAcM_GetModel(this) == 0) { - f32 frame = mBck0.getFrame(); - frame = mult[cLib_minMaxLimit<int>(mBck0.getEndFrame() - frame, 0, 9)] * 25.0f; + int framesLeft = mBck0.getEndFrame() - mBck0.getFrame(); + f32 scale = mult[cLib_minMaxLimit<int>(framesLeft, 0, 9)] * 25.0f; - dComIfGd_setSimpleShadow2(¤t.pos, mAcch.GetGroundH(), frame, mAcch.m_gnd, 0, 1.0f, dDlst_shadowControl_c::getSimpleTex()); + dComIfGd_setSimpleShadow2(¤t.pos, mAcch.GetGroundH(), scale, mAcch.m_gnd, 0, 1.0f, dDlst_shadowControl_c::getSimpleTex()); } } diff --git a/src/d/actor/d_a_npc_bs1.cpp b/src/d/actor/d_a_npc_bs1.cpp index 44cc9e30..7f83e054 100644 --- a/src/d/actor/d_a_npc_bs1.cpp +++ b/src/d/actor/d_a_npc_bs1.cpp @@ -1596,7 +1596,7 @@ BOOL daNpc_Bs1_c::CreateInit() { mShopIndex = 6; } - mShopIndex = cLib_minMaxLimit<int>(mShopIndex, 0, 7); + mShopIndex = cLib_minMaxLimit<s8>(mShopIndex, 0, 7); mShopCamAction.setCamDataIdx(mShopIndex); mShopItems.setItemDataIdx(mShopIndex); diff --git a/src/d/actor/d_a_obj_roten.cpp b/src/d/actor/d_a_obj_roten.cpp index ab3656b5..7a1f0c45 100644 --- a/src/d/actor/d_a_obj_roten.cpp +++ b/src/d/actor/d_a_obj_roten.cpp @@ -100,7 +100,7 @@ s32 daObj_Roten_c::_create() { fopAcM_SetupActor(this, daObj_Roten_c); mType = fopAcM_GetParam(this) >> 0x18; - mType = cLib_minMaxLimit<u8>((int)mType, 0, 2); // fakematch? debug says this is templated to u8 + mType = cLib_minMaxLimit<u8>(mType, 0, 2); if(Roten_create_check(mType)) { field_0x2D1 = 0; |
