Skip to content

Commit

Permalink
Merge pull request #671 from DanTGL/cleanup
Browse files Browse the repository at this point in the history
Minor cleanup
  • Loading branch information
LagoLunatic authored Jul 18, 2024
2 parents 842aeab + df7ece7 commit 01ca395
Show file tree
Hide file tree
Showing 11 changed files with 4 additions and 24 deletions.
1 change: 0 additions & 1 deletion src/JSystem/J2DGraph/J2DPane.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,6 @@ void J2DPane::makeMatrix(f32 x, f32 y) {

/* 802D0800-802D08D8 .text setBasePosition__7J2DPaneF15J2DBasePosition */
void J2DPane::setBasePosition(J2DBasePosition pos) {
/* Nonmatching */
m2DBasePosition = pos;

if (pos % 3 == 0) {
Expand Down
1 change: 0 additions & 1 deletion src/JSystem/J2DGraph/J2DPrint.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,6 @@ void J2DPrint::printReturn(const char* param_1, f32 param_2, f32 param_3, J2DTex

/* 802CE888-802CEF9C .text parse__8J2DPrintFPCUciiPUsRQ28J2DPrint5TSizeUcb */
f32 J2DPrint::parse(const u8* param_1, int param_2, int param_3, u16* param_4, J2DPrint::TSize& param_5, u8 param_6, bool param_7) {
/* Nonmatching */
if (mFont == NULL) {
return 0.0f;
}
Expand Down
1 change: 0 additions & 1 deletion src/JSystem/J2DGraph/J2DWindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,6 @@ void J2DWindow::draw_private(const JGeometry::TBox2<f32>& frameBox, const JGeome

/* 802D1F5C-802D207C .text resize__9J2DWindowFff */
void J2DWindow::resize(f32 w, f32 h) {
/* Nonmatching - regalloc */
f32 oldW = getWidth();
f32 oldH = getHeight();
J2DPane::resize(w, h);
Expand Down
4 changes: 0 additions & 4 deletions src/JSystem/J3DGraphBase/J3DShapeMtx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,6 @@ void J3DShapeMtxMultiConcatView::loadNrmMtx(int mtxNo, u16 index, Mtx mtx) const
J3DFifoLoadNrmMtxImm3x3(mtx33, mtxNo * 3);
}
}
/* Nonmatching */
}

/* 802DC6F4-802DC7B8 .text load__20J3DShapeMtxBBoardImmCFv */
Expand Down Expand Up @@ -382,7 +381,6 @@ void J3DShapeMtxYBBoardImm::load() const {
J3DFifoLoadNrmMtxImm3x3(mtx33, 0);
}
}
/* Nonmatching */
}

/* 802DC9B8-802DCAEC .text load__28J3DShapeMtxYBBoardConcatViewCFv */
Expand Down Expand Up @@ -418,8 +416,6 @@ void J3DShapeMtxYBBoardConcatView::load() const {
J3DFifoLoadNrmMtxImm3x3(mtx33, 0);
}
}

/* Nonmatching */
}

/* 802DCAEC-802DCB04 .text __ct__12J3DShapeDrawFPCUcUl */
Expand Down
2 changes: 0 additions & 2 deletions src/JSystem/JKernel/JKRAram.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,6 @@ JKRAramBlock* JKRAram::mainRamToAram(u8 *buf, u32 bufSize, u32 alignedSize, JKRE

/* 802B490C-802B49DC .text mainRamToAram__7JKRAramFPUcP12JKRAramBlockUl15JKRExpandSwitchUlP7JKRHeapi */
JKRAramBlock* JKRAram::mainRamToAram(u8 *buf, JKRAramBlock* block, u32 alignedSize, JKRExpandSwitch expandSwitch, u32 fileSize, JKRHeap* heap, int id) {
/* Nonmatching */
checkOkAddress(buf, 0, block, 0);
if (!block) {
return mainRamToAram(buf, u32(0), alignedSize, expandSwitch, fileSize, heap, id);
Expand Down Expand Up @@ -283,7 +282,6 @@ u8* JKRAram::aramToMainRam(u32 address, u8 *buf, u32 p3, JKRExpandSwitch expandS

/* 802B4C54-802B4D4C .text aramToMainRam__7JKRAramFP12JKRAramBlockPUcUlUl15JKRExpandSwitchUlP7JKRHeapiPUl */
u8* JKRAram::aramToMainRam(JKRAramBlock* block, u8 *buf, u32 p3, u32 p4, JKRExpandSwitch expandSwitch, u32 p6, JKRHeap* heap, int id, u32 *pSize) {
/* Nonmatching */
if (pSize) {
*pSize = 0;
}
Expand Down
4 changes: 0 additions & 4 deletions src/JSystem/JKernel/JKRStdHeap.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@

/* 802B0F34-802B0FE0 .text create__10JKRStdHeapFUlP7JKRHeapb */
JKRStdHeap* JKRStdHeap::create(u32 size, JKRHeap* parent, bool errorFlag) {
/* Nonmatching */
if (!parent) {
parent = sRootHeap;
}
Expand Down Expand Up @@ -74,7 +73,6 @@ void* JKRStdHeap::do_alloc(u32 size, int alignment) {
}
}
return ptr;
/* Nonmatching */
}

/* 802B11A4-802B1228 .text do_free__10JKRStdHeapFPv */
Expand All @@ -86,12 +84,10 @@ void JKRStdHeap::do_free(void* ptr) {
JUT_WARN(279, "free: memblock %x not in heap %x", ptr, this);
}
}
/* Nonmatching */
}

/* 802B1228-802B1278 .text do_freeAll__10JKRStdHeapFv */
void JKRStdHeap::do_freeAll() {
/* Nonmatching */
if (mHeapHandle == -1) {
return;
}
Expand Down
3 changes: 0 additions & 3 deletions src/JSystem/JUtility/JUTCacheFont.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -353,7 +353,6 @@ JUTCacheFont::TGlyphCacheInfo* JUTCacheFont::determineBlankPage() {

/* 802C0E80-802C0FE8 .text getGlyphFromAram__12JUTCacheFontFPQ212JUTCacheFont15TGlyphCacheInfoPQ212JUTCacheFont10TCachePagePiPi */
void JUTCacheFont::getGlyphFromAram(TGlyphCacheInfo* param_0, TCachePage* pCachePage, int* param_2, int* param_3) {
/* Nonmatching */
TGlyphCacheInfo* pGylphCacheInfo = pCachePage;
memcpy(pGylphCacheInfo, param_0, sizeof(TGlyphCacheInfo));
prepend(pGylphCacheInfo);
Expand All @@ -376,7 +375,6 @@ void JUTCacheFont::getGlyphFromAram(TGlyphCacheInfo* param_0, TCachePage* pCache

/* 802C0FE8-802C109C .text loadImage__12JUTCacheFontFi11_GXTexMapID */
void JUTCacheFont::loadImage(int param_0, GXTexMapID texMapId) {
/* Nonmatching */
TCachePage* cachePage = loadCache_char_subroutine(&param_0, false);
if (cachePage != NULL) {
mWidth = cachePage->field_0xc * (param_0 % int(cachePage->field_0x16));
Expand All @@ -391,7 +389,6 @@ void JUTCacheFont::loadImage(int param_0, GXTexMapID texMapId) {

/* 802C109C-802C11E4 .text loadCache_char_subroutine__12JUTCacheFontFPib */
JUTCacheFont::TCachePage* JUTCacheFont::loadCache_char_subroutine(int* param_0, bool param_1) {
/* Nonmatching */
TCachePage* rv = NULL;
for (TCachePage* pCachePage = (TCachePage*)field_0x9c; pCachePage != NULL;
pCachePage = (TCachePage*)pCachePage->mNext)
Expand Down
1 change: 0 additions & 1 deletion src/JSystem/JUtility/JUTGamePad.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ u32 JUTGamePad::sRumbleSupported;

/* 802C3980-802C3C14 .text read__10JUTGamePadFv */
u32 JUTGamePad::read() {
/* Nonmatching */
sRumbleSupported = PADRead(mPadStatus);

PADClamp(mPadStatus);
Expand Down
1 change: 0 additions & 1 deletion src/JSystem/JUtility/JUTGba.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,6 @@ BOOL JUTGba::resultGetStatus(int param_1, u8* param_2) {

/* 802CCA08-802CCC6C .text gbaThreadMain__6JUTGbaFPv */
void* JUTGba::gbaThreadMain(void* param_1) {
/* Nonmatching */
JUTGbaParam* param = (JUTGbaParam*)param_1;
{ JKRThread jkrThread(OSGetCurrentThread(), 0); }
JKRSetCurrentHeap(NULL);
Expand Down
4 changes: 1 addition & 3 deletions src/JSystem/JUtility/JUTVideo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,4 @@ void JUTVideo::setRenderMode(const GXRenderModeObj* pObj) {
}

/* 802C81D4-802C81D8 .text waitRetraceIfNeed__8JUTVideoFv */
void JUTVideo::waitRetraceIfNeed() {
/* Nonmatching */
}
void JUTVideo::waitRetraceIfNeed() {}
6 changes: 3 additions & 3 deletions src/d/actor/d_a_auction.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -823,7 +823,7 @@ void daAuction_c::eventMainKai() {
if (dComIfG_getTimerRestTimeMs() <= 0) {
m82B = 1;
} else {
if (g_mDoCPd_cpadInfo[0].mButtonTrig.b) {
if (CPad_CHECK_TRIG_B(0)) {
setMessage2(0x1CFC);
mDoAud_seStart(JA_SE_AUC_QUIT);
} else {
Expand All @@ -841,7 +841,7 @@ void daAuction_c::eventMainKai() {
m7C4[0] += 0.02f;
}

if (g_mDoCPd_cpadInfo[0].mButtonTrig.a) {
if (CPad_CHECK_TRIG_A(0)) {
m7C4[0] += l_npc_dat[0].field_0x00 + cM_rndF(l_npc_dat[0].field_0x04 - l_npc_dat[0].field_0x00);

mDoAud_seStart(JA_SE_AUC_BID_GAUGE, NULL, m7C4[0]);
Expand Down Expand Up @@ -989,7 +989,7 @@ void daAuction_c::eventMainUri() {

if (dComIfG_getTimerRestTimeMs() <= 0) {
m82B = 1;
} else if (m82E != 0 && g_mDoCPd_cpadInfo[0].mButtonTrig.a) {
} else if (m82E != 0 && CPad_CHECK_TRIG_A(0)) {
setMessage2(0x1D1A);
} else {
if (m806 != 0) {
Expand Down

0 comments on commit 01ca395

Please sign in to comment.