mirror of
https://github.com/zeldaret/tww.git
synced 2026-08-09 02:45:45 -04:00
More demo work, cleanup
This commit is contained in:
+16
-11
@@ -41,11 +41,13 @@ fpc_ProcID fpcBs_MakeOfId() {
|
||||
|
||||
/* 8003C904-8003C960 .text fpcBs_Execute__FP18base_process_class */
|
||||
BOOL fpcBs_Execute(base_process_class* i_proc) {
|
||||
BOOL result;
|
||||
layer_class* savedLayer = fpcLy_CurrentLayer();
|
||||
fpcLy_SetCurrentLayer(i_proc->mLyTg.mpLayer);
|
||||
result = fpcMtd_Execute(i_proc->mpPcMtd, i_proc);
|
||||
fpcLy_SetCurrentLayer(savedLayer);
|
||||
BOOL result = TRUE;
|
||||
if (result == TRUE) {
|
||||
layer_class* savedLayer = fpcLy_CurrentLayer();
|
||||
fpcLy_SetCurrentLayer(i_proc->mLyTg.mpLayer);
|
||||
result = fpcMtd_Execute(i_proc->mpPcMtd, i_proc);
|
||||
fpcLy_SetCurrentLayer(savedLayer);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@@ -69,13 +71,16 @@ BOOL fpcBs_IsDelete(base_process_class* i_proc) {
|
||||
|
||||
/* 8003C9FC-8003CA60 .text fpcBs_Delete__FP18base_process_class */
|
||||
BOOL fpcBs_Delete(base_process_class* i_proc) {
|
||||
BOOL deleteResult = fpcMtd_Delete(i_proc->mpPcMtd, i_proc);
|
||||
if (deleteResult == TRUE) {
|
||||
fpcBs_DeleteAppend(i_proc);
|
||||
i_proc->mBsType = 0;
|
||||
cMl::free(i_proc);
|
||||
BOOL result = TRUE;
|
||||
if (result == TRUE) {
|
||||
result = fpcMtd_Delete(i_proc->mpPcMtd, i_proc);
|
||||
if (result == TRUE) {
|
||||
fpcBs_DeleteAppend(i_proc);
|
||||
i_proc->mBsType = 0;
|
||||
cMl::free(i_proc);
|
||||
}
|
||||
}
|
||||
return deleteResult;
|
||||
return result;
|
||||
}
|
||||
|
||||
/* 8003CA60-8003CB5C .text fpcBs_Create__FsUiPv */
|
||||
|
||||
@@ -39,7 +39,8 @@ s32 fpcEx_ToLineQ(base_process_class* i_proc) {
|
||||
base_process_class* pLayerPcNode = &pLayer->mpPcNode->base;
|
||||
|
||||
if (pLayer->mLayerID == 0 || cTg_IsUse(&pLayerPcNode->mLnTg.base) == TRUE) {
|
||||
s32 ret = fpcLnTg_ToQueue(&i_proc->mLnTg, i_proc->mPi.mInfoCurr.mListID);
|
||||
u16 listID = i_proc->mPi.mInfoCurr.mListID;
|
||||
s32 ret = fpcLnTg_ToQueue(&i_proc->mLnTg, listID);
|
||||
if (ret == 0) {
|
||||
fpcLyTg_QueueTo(&i_proc->mLyTg);
|
||||
return 0;
|
||||
|
||||
@@ -33,7 +33,8 @@ s32 fpcPause_Enable(void* i_proc, u8 i_flag) {
|
||||
/* 800403AC-80040420 .text fpcPause_Disable__FPvUc */
|
||||
s32 fpcPause_Disable(void* i_proc, u8 i_flag) {
|
||||
base_process_class* pProc = (base_process_class*)i_proc;
|
||||
pProc->mPauseFlag &= (0xFF - i_flag) & 0xFF;
|
||||
u8 mask = 0xFF - i_flag;
|
||||
pProc->mPauseFlag &= mask;
|
||||
|
||||
if (fpcBs_Is_JustOfType(g_fpcNd_type, pProc->mSubType)) {
|
||||
process_node_class* pNode = (process_node_class*)pProc;
|
||||
|
||||
@@ -7,18 +7,14 @@
|
||||
|
||||
/* 80040050-80040068 .text fpcSch_JudgeForPName__FPvPv */
|
||||
void* fpcSch_JudgeForPName(void* i_proc, void* i_data) {
|
||||
s16 proc_name = *(s16*)i_data;
|
||||
|
||||
if (((base_process_class*)i_proc)->mProcName == proc_name)
|
||||
if (((base_process_class*)i_proc)->mProcName == *(s16*)i_data)
|
||||
return i_proc;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
/* 80040068-80040080 .text fpcSch_JudgeByID__FPvPv */
|
||||
void* fpcSch_JudgeByID(void* i_proc, void* i_data) {
|
||||
fpc_ProcID process_id = *(fpc_ProcID*)i_data;
|
||||
|
||||
if (((base_process_class*)i_proc)->mBsPcId == process_id)
|
||||
if (((base_process_class*)i_proc)->mBsPcId == *(fpc_ProcID*)i_data)
|
||||
return i_proc;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user