From ca1ece683b3eae1a9dcf4fe9ba971d2eb82b64ae Mon Sep 17 00:00:00 2001 From: TakaRikka <38417346+TakaRikka@users.noreply.github.com> Date: Fri, 12 Jul 2024 23:24:50 -0700 Subject: Lv5key / Iceblock done (#2177) * obj_lv5key * obj_iceblock done * remove asm --- include/SSystem/SComponent/c_bg_s_chk.h | 7 ++++--- include/SSystem/SComponent/c_lib.h | 6 +++--- 2 files changed, 7 insertions(+), 6 deletions(-) (limited to 'include/SSystem') diff --git a/include/SSystem/SComponent/c_bg_s_chk.h b/include/SSystem/SComponent/c_bg_s_chk.h index d56dd19c67..98d22fe790 100644 --- a/include/SSystem/SComponent/c_bg_s_chk.h +++ b/include/SSystem/SComponent/c_bg_s_chk.h @@ -2,6 +2,7 @@ #define C_BG_S_CHK_H #include "dolphin/mtx/vec.h" +#include "f_pc/f_pc_base.h" struct cBgD_Vtx_t : public Vec {}; @@ -16,7 +17,7 @@ class cBgS_Chk { public: /* 0x0 */ cBgS_PolyPassChk* mPolyPassChk; /* 0x4 */ cBgS_GrpPassChk* mGrpPassChk; - /* 0x8 */ u32 mActorPid; + /* 0x8 */ fpc_ProcID mActorPid; /* 0xC */ u8 unk_0x0C; /* 0x10 */ // __vtable__ @@ -25,8 +26,8 @@ public: void SetExtChk(cBgS_Chk&); bool ChkSameActorPid(unsigned int) const; - void SetActorPid(u32 pid) { mActorPid = pid; } - u32 GetActorPid() const { return mActorPid; } + void SetActorPid(fpc_ProcID pid) { mActorPid = pid; } + fpc_ProcID GetActorPid() const { return mActorPid; } void SetPolyPassChk(cBgS_PolyPassChk* p_chk) { mPolyPassChk = p_chk; } void SetGrpPassChk(cBgS_GrpPassChk* p_chk) { mGrpPassChk = p_chk; } cBgS_PolyPassChk* GetPolyPassChk() const { return mPolyPassChk; } diff --git a/include/SSystem/SComponent/c_lib.h b/include/SSystem/SComponent/c_lib.h index ae65e692fe..3d15cd8280 100644 --- a/include/SSystem/SComponent/c_lib.h +++ b/include/SSystem/SComponent/c_lib.h @@ -37,16 +37,16 @@ s32 cLib_distanceAngleS(s16 x, s16 y); template inline void cLib_offBit(T& value, T bit) { - value &= ~bit; + value = (T)(value & ~bit); } template inline void cLib_onBit(T& value, T bit) { - value |= bit; + value = (T)(value | bit); } template -inline T cLib_checkBit(T& value, T bit) { +inline T cLib_checkBit(T value, T bit) { return (T)(value & bit); } -- cgit v1.2.3