Faradise MM_MenuBox_NewLoad

This commit is contained in:
Niko 2023-04-10 14:00:00 -04:00
parent 02f6a45552
commit ef6741ac60
4 changed files with 27 additions and 42 deletions

View File

@ -0,0 +1,24 @@
#include <common.h>
void DECOMP_MM_MenuBox_NewLoad(struct MenuBox* mb)
{
short row;
// row number
row = mb->rowSelected;
if(row == -1)
mb->ptrPrevMenuBox_InHierarchy->state &= 0xffffffeb;
if((unsigned char)row > 1) return;
// if Load was chosen
*(int*)0x800b59e0 = row;
// MM_Title transitioning out
*(int*)0x800b5a1c = 2;
mb->state |= 4;
return;
}

View File

@ -1,40 +0,0 @@
#include <common.h>
void DECOMP_MM_MenuBox_NewLoad(struct MenuBox* mb)
{
short row;
// row number
row = mb->rowSelected;
// if you choose New
if (row == 0) {
*(int*)0x800b59e0 = 0;
}
// if not
else {
if (row < 1) {
if (row != -1) {
return;
}
mb->ptrPrevMenuBox_InHierarchy->state &= 0xffffffeb;
return;
}
// if you did not choose Load
if (row != 1) {
return;
}
// if Load was chosen
*(int*)0x800b59e0 = row;
}
// MM_Title transitioning out
*(int*)0x800b5a1c = 2;
mb->state |= 4;
return;
}

View File

@ -1,6 +1,6 @@
// 260+21+1+1+7+3+3+3+2+2+3+1+5+3+1+2+10+1 = 329 rewritten so far
// 257 for every 'common' and ','
// 260 for every 'common' and ','
// additions for every file that has multiple functions,
// 21 for cheats
// most other additions for 231
@ -25,7 +25,8 @@ common, 230, MM_MenuBox_2p3p4p, 0x0, General/230/230_MM_34_MenuBox_2p3p4p.c
common, 230, MM_ToggleRows_Difficulty, 0x0, General/230/230_MM_35_ToggleRows_Difficulty.c
common, 230, MM_MenuBox_Difficulty, 0x0, General/230/230_MM_36_MenuBox_Difficulty.c
common, 230, MM_MenuBox_SingleCup, 0x0, General/230/230_MM_37_MenuBox_SingleCup.c
common, 230, MM_Characters_boolIsInvalid, 0x0, General/230/230_MM_43_Characters_boolIsInvalid.c
common, 230, MM_MenuBox_NewLoad, 0x0, General/230/230_MM_38_MenuBox_NewLoad.c
common, 230, MM_Characters_boolIsInvalid, 0x0, General/230/230_MM_42_Characters_boolIsInvalid.c
// 231 (incomplete)
// skip first two