diff options
| author | TakaRikka <38417346+TakaRikka@users.noreply.github.com> | 2024-12-10 08:46:19 -0800 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-12-10 18:46:19 +0200 |
| commit | 8d73439554beb2b4870b86159aa2e676357792b7 (patch) | |
| tree | f146d56805cdbbf0ee01412b66d328396d2b0305 /src/d/d_bg_plc.cpp | |
| parent | 3fa6b50e6ab76f8d6fed3c92a70084db2f0e221e (diff) | |
tbox/camera/d_bg_w_kcol work and cleanup (#2262)
* some camera/tbox cleanup
* d_bg_w_kcol work
* make item name enum better
Diffstat (limited to 'src/d/d_bg_plc.cpp')
| -rw-r--r-- | src/d/d_bg_plc.cpp | 28 |
1 files changed, 13 insertions, 15 deletions
diff --git a/src/d/d_bg_plc.cpp b/src/d/d_bg_plc.cpp index ae69d34d34..eb8ebc8342 100644 --- a/src/d/d_bg_plc.cpp +++ b/src/d/d_bg_plc.cpp @@ -1,7 +1,3 @@ -// -// Translation Unit: d/d_bg_plc -// - #include "d/d_bg_plc.h" #include "JSystem/JUtility/JUTAssert.h" @@ -14,19 +10,20 @@ dBgPlc::dBgPlc() { dBgPlc::~dBgPlc() {} /* 800740BC-800740C4 -00001 0008+00 0/0 0/0 0/0 .text setBase__6dBgPlcFPv */ -void dBgPlc::setBase(void* p_base) { - m_base = (PLC*)p_base; +void dBgPlc::setBase(void* pbase) { + m_base = (sBgPlc*)pbase; } /* 800740C4-800740DC 06EA04 0018+00 0/0 1/1 0/0 .text getCode__6dBgPlcCFiPP5sBgPc */ -sBgPc* dBgPlc::getCode(int index, sBgPc** param_1) const { +sBgPc* dBgPlc::getCode(int index, sBgPc** ppcode) const { JUT_ASSERT(45, m_base != 0); JUT_ASSERT(46, m_base->m_code_size == ZELDA_CODE_SIZE); JUT_ASSERT(47, index >= 0 && index< m_base->m_num); - sBgPc* rv = m_base->field_0x8; - rv += index; - *param_1 = rv; - return rv; + sBgPc* code = m_base->m_code; + code += index; + + *ppcode = code; + return code; } /* 800740DC-800740F4 06EA1C 0018+00 0/0 1/1 0/0 .text getGrpCode__6dBgPlcCFi */ @@ -34,7 +31,8 @@ u32 dBgPlc::getGrpCode(int index) const { JUT_ASSERT(62, m_base != 0); JUT_ASSERT(63, m_base->m_code_size == ZELDA_CODE_SIZE); JUT_ASSERT(64, 0 <= index && index < m_base->m_num); - sBgPc* rv = m_base->field_0x8; - rv += index; - return rv->code4; -}
\ No newline at end of file + sBgPc* code = m_base->m_code; + code += index; + + return code->code4; +} |
