Decompile pakMenuTextLocationName

This commit is contained in:
Ryan Dwyer 2020-03-21 11:14:31 +10:00
parent 69b74a99ab
commit 9ad31f7287
4 changed files with 10 additions and 31 deletions

View File

@ -88,7 +88,7 @@ struct menu_dialog menudialog_filesaved = {
// 1a4a4
struct menu_item menuitems_saveerror[] = {
{ MENUITEMTYPE_LABEL, 0, 0x00000010, (u32)&func0f108078, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, (u32)&pakMenuTextLocationName, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, L_OPTIONS(348), 0x00000000, NULL }, // "An error occurred while trying to save"
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000020, L_OPTIONS(349), 0x00000000, menuhandlerPakErrorTryAgain }, // "Try Again"
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000020, L_OPTIONS(350), 0x00000000, menuhandlerSaveElsewhere }, // "Save Elsewhere"
@ -108,7 +108,7 @@ struct menu_dialog menudialog_saveerror = {
// 1a534
struct menu_item menuitems_savelost[] = {
{ MENUITEMTYPE_LABEL, 0, 0x00000010, (u32)&func0f108078, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, (u32)&pakMenuTextLocationName, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, L_MPWEAPONS(251), 0x00000000, NULL }, // "The saved file has been erased due to corruption or damage."
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000020, L_OPTIONS(354), 0x00000000, menuhandlerAcknowledgePakFileLost }, // "Cancel"
{ MENUITEMTYPE_END, 0, 0x00000000, 0x00000000, 0x00000000, NULL },
@ -244,7 +244,7 @@ struct menu_dialog menudialog_selectlocation = {
// 1a890
struct menu_item menuitems_confirmdelete[] = {
{ MENUITEMTYPE_LABEL, 0, 0x00000030, (u32)&func0f1082b0, 0x00000000, menuhandler00108254 },
{ MENUITEMTYPE_LABEL, 0, 0x00000230, (u32)&func0f108078, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000230, (u32)&pakMenuTextLocationName, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, L_OPTIONS(380), 0x00000000, NULL }, // "Are you sure you want to delete this file?"
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000028, L_OPTIONS(381), 0x00000000, NULL }, // "Cancel"
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000020, L_OPTIONS(382), 0x00000000, menuhandlerPakConfirmDelete }, // "OK"
@ -264,7 +264,7 @@ struct menu_dialog menudialog_confirmdelete = {
// 1a920
struct menu_item menuitems_1a920[] = {
{ MENUITEMTYPE_LABEL, 0, 0x00000030, (u32)&func0f1082b0, 0x00000000, menuhandler00108254 },
{ MENUITEMTYPE_LABEL, 0, 0x00000230, (u32)&func0f108078, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000230, (u32)&pakMenuTextLocationName, 0x00000000, menuhandler00108014 },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, (u32)&func0f10a5e8, 0x00000000, NULL },
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000028, L_MPWEAPONS(161), 0x00000000, NULL }, // "Cancel"
{ MENUITEMTYPE_END, 0, 0x00000000, 0x00000000, 0x00000000, NULL },

View File

@ -10424,7 +10424,7 @@ struct menu_dialog menudialog_mpsavesetupname = {
// 2ad14
struct menu_item menuitems_mpsavesetup[] = {
{ MENUITEMTYPE_LABEL, 0, L_AME(16), L_MPWEAPONS(230), (u32)&mpMenuTextSetupName, NULL }, // "Name:"
{ MENUITEMTYPE_LABEL, 0, 0x00000230, (u32)&func0f108078, 0x00000000, NULL },
{ MENUITEMTYPE_LABEL, 0, 0x00000230, (u32)&pakMenuTextLocationName, 0x00000000, NULL },
{ MENUITEMTYPE_LABEL, 0, 0x00000010, L_MPMENU(184), 0x00000000, NULL }, // "Do you want to save over your original game file?"
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000000, L_MPMENU(185), 0x00000000, menuhandlerMpSaveSetupOverwrite }, // "Save Over Original"
{ MENUITEMTYPE_SELECTABLE, 0, 0x00000000, L_MPMENU(186), 0x00000000, menuhandlerMpSaveSetupCopy }, // "Save Copy"

View File

@ -112,31 +112,10 @@ s32 menuhandler00108014(u32 operation, struct menu_item *item, s32 *value)
return 0;
}
GLOBAL_ASM(
glabel func0f108078
/* f108078: 3c0e8007 */ lui $t6,%hi(g_MpPlayerNum)
/* f10807c: 8dce1448 */ lw $t6,%lo(g_MpPlayerNum)($t6)
/* f108080: 27bdffe8 */ addiu $sp,$sp,-24
/* f108084: afa40018 */ sw $a0,0x18($sp)
/* f108088: 000e78c0 */ sll $t7,$t6,0x3
/* f10808c: 01ee7823 */ subu $t7,$t7,$t6
/* f108090: 000f7880 */ sll $t7,$t7,0x2
/* f108094: 01ee7821 */ addu $t7,$t7,$t6
/* f108098: 000f78c0 */ sll $t7,$t7,0x3
/* f10809c: 01ee7823 */ subu $t7,$t7,$t6
/* f1080a0: 000f7900 */ sll $t7,$t7,0x4
/* f1080a4: 3c04800a */ lui $a0,%hi(g_MenuStack+0xe3c)
/* f1080a8: 008f2021 */ addu $a0,$a0,$t7
/* f1080ac: 9084ee3c */ lbu $a0,%lo(g_MenuStack+0xe3c)($a0)
/* f1080b0: afbf0014 */ sw $ra,0x14($sp)
/* f1080b4: 3098007f */ andi $t8,$a0,0x7f
/* f1080b8: 0fc41fec */ jal getSaveLocationName
/* f1080bc: 03002025 */ or $a0,$t8,$zero
/* f1080c0: 8fbf0014 */ lw $ra,0x14($sp)
/* f1080c4: 27bd0018 */ addiu $sp,$sp,0x18
/* f1080c8: 03e00008 */ jr $ra
/* f1080cc: 00000000 */ sll $zero,$zero,0x0
);
char *pakMenuTextLocationName(struct menu_item *item)
{
return getSaveLocationName(g_MenuStack[g_MpPlayerNum].unke3c_01);
}
GLOBAL_ASM(
glabel func0f1080d0

View File

@ -4,7 +4,7 @@
#include "types.h"
char *getSaveLocationName(s32 index);
u32 func0f108078(void);
char *pakMenuTextLocationName(struct menu_item *item);
u32 func0f1080d0(void);
u32 func0f1082b0(void);
void func0f108324(s32 arg0);