diff --git a/papermario/asm/nonmatchings/code_80850_len_3060/func_800E98D4.s b/papermario/asm/nonmatchings/code_80850_len_3060/func_800E98D4.s deleted file mode 100644 index eae2036036..0000000000 --- a/papermario/asm/nonmatchings/code_80850_len_3060/func_800E98D4.s +++ /dev/null @@ -1,13 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.include "include/macro.inc" - -glabel func_800E98D4 -/* 082D84 800E98D4 3C028011 */ lui $v0, 0x8011 -/* 082D88 800E98D8 2442EF58 */ addiu $v0, $v0, -0x10a8 -/* 082D8C 800E98DC 80430046 */ lb $v1, 0x46($v0) -/* 082D90 800E98E0 80420044 */ lb $v0, 0x44($v0) -/* 082D94 800E98E4 03E00008 */ jr $ra -/* 082D98 800E98E8 00621021 */ addu $v0, $v1, $v0 - diff --git a/papermario/asm/nonmatchings/code_80850_len_3060/func_800E9900.s b/papermario/asm/nonmatchings/code_80850_len_3060/func_800E9900.s deleted file mode 100644 index 49e5fc6328..0000000000 --- a/papermario/asm/nonmatchings/code_80850_len_3060/func_800E9900.s +++ /dev/null @@ -1,11 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.include "include/macro.inc" - -glabel func_800E9900 -/* 082DB0 800E9900 3C018011 */ lui $at, 0x8011 -/* 082DB4 800E9904 A020EF9E */ sb $zero, -0x1062($at) -/* 082DB8 800E9908 03E00008 */ jr $ra -/* 082DBC 800E990C 00000000 */ nop - diff --git a/papermario/asm/nonmatchings/code_80850_len_3060/is_status_menu_visible.s b/papermario/asm/nonmatchings/code_80850_len_3060/is_status_menu_visible.s deleted file mode 100644 index 00df735972..0000000000 --- a/papermario/asm/nonmatchings/code_80850_len_3060/is_status_menu_visible.s +++ /dev/null @@ -1,11 +0,0 @@ -.set noat # allow manual use of $at -.set noreorder # don't insert nops after branches - -.include "include/macro.inc" - -glabel is_status_menu_visible -/* 082DC0 800E9910 3C028011 */ lui $v0, 0x8011 -/* 082DC4 800E9914 8042EF92 */ lb $v0, -0x106e($v0) -/* 082DC8 800E9918 03E00008 */ jr $ra -/* 082DCC 800E991C 2C420001 */ sltiu $v0, $v0, 1 - diff --git a/papermario/include/common_structs.h b/papermario/include/common_structs.h index c14aee3018..848403a631 100644 --- a/papermario/include/common_structs.h +++ b/papermario/include/common_structs.h @@ -142,7 +142,7 @@ typedef struct { /* 0x3F */ char unk_3F; /* 0x40 */ s16 displayCoins; /* 0x42 */ s16 displayStarpoints; - /* 0x44 */ s8 igonreChanges; /* set != 0 to prevent automatic opening from HP/FP changes */ + /* 0x44 */ s8 ignoreChanges; /* set != 0 to prevent automatic opening from HP/FP changes */ /* 0x45 */ s8 unk_45; /* 0x46 */ s8 unk_46; /* 0x47 */ s8 disabled; /* set != 0 for menu to be disabled completely */ diff --git a/papermario/src/code_80850_len_3060.c b/papermario/src/code_80850_len_3060.c index 3e8823ed3a..df84edccfc 100644 --- a/papermario/src/code_80850_len_3060.c +++ b/papermario/src/code_80850_len_3060.c @@ -156,13 +156,23 @@ INCLUDE_ASM(code_80850_len_3060, func_800E9894); INCLUDE_ASM(code_80850_len_3060, func_800E98C4); -INCLUDE_ASM(code_80850_len_3060, func_800E98D4); +s32 func_800E98D4(void) { + ui_status* uiStatus = &gUIStatus; + + return uiStatus->unk_46 + uiStatus->ignoreChanges; +} + INCLUDE_ASM(code_80850_len_3060, func_800E98EC); -INCLUDE_ASM(code_80850_len_3060, func_800E9900); +void func_800E9900(void) { + gUIStatus.unk_46 = 0; +} -INCLUDE_ASM(code_80850_len_3060, is_status_menu_visible); + +s32 is_status_menu_visible(void) { + return !gUIStatus.hidden; +} void status_menu_start_blinking_hp(void) { game_status* gameStatus = (*gGameStatusPtr);