From 7cec9d8b5b662eeec351234d6f13f09500551885 Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Wed, 27 Oct 2021 23:33:59 +1000 Subject: [PATCH] Decompile debug0f11941cnb --- src/game/debug2.c | 21 ++++++--------------- src/include/lib/rmon.h | 2 ++ src/lib/rmon.c | 9 +++++---- 3 files changed, 13 insertions(+), 19 deletions(-) diff --git a/src/game/debug2.c b/src/game/debug2.c index f97470910..da7279395 100644 --- a/src/game/debug2.c +++ b/src/game/debug2.c @@ -2,6 +2,7 @@ #include "constants.h" #include "game/chr/chraction.h" #include "game/debug.h" +#include "lib/rmon.h" #include "lib/vi.h" #include "lib/vm.h" #include "bss.h" @@ -450,21 +451,11 @@ void debug0f1193f4nb(void) var80075d60 = var80075d64 = var800786f4nb = 2; } -GLOBAL_ASM( -glabel debug0f11941cnb -/* f11941c: 27bdffe8 */ addiu $sp,$sp,-24 -/* f119420: afbf0014 */ sw $ra,0x14($sp) -/* f119424: 3c048008 */ lui $a0,0x8008 -/* f119428: 248487f4 */ addiu $a0,$a0,-30732 -/* f11942c: 0c00c460 */ jal rmon0002fa30 -/* f119430: 24050002 */ addiu $a1,$zero,0x2 -/* f119434: 0c00c462 */ jal rmon0002fa38 -/* f119438: 240400fa */ addiu $a0,$zero,0xfa -/* f11943c: 8fbf0014 */ lw $ra,0x14($sp) -/* f119440: 27bd0018 */ addiu $sp,$sp,0x18 -/* f119444: 03e00008 */ jr $ra -/* f119448: 00000000 */ sll $zero,$zero,0x0 -); +void debug0f11941cnb(void) +{ + rmon0002fa30(&var800787f4nb, 2); + rmon0002fa38(250); +} GLOBAL_ASM( glabel debug0f11944cnb diff --git a/src/include/lib/rmon.h b/src/include/lib/rmon.h index 723d8beef..2f7c7ccb7 100644 --- a/src/include/lib/rmon.h +++ b/src/include/lib/rmon.h @@ -5,6 +5,8 @@ #include "types.h" void rmonproc(); +void rmon0002fa30(u32 *arg0, s32 arg1); +void rmon0002fa38(s32 arg0); bool rmonIsDisabled(void); void rmonPrint(const char *format, ...); diff --git a/src/lib/rmon.c b/src/lib/rmon.c index f34fd28b6..9082023ae 100644 --- a/src/lib/rmon.c +++ b/src/lib/rmon.c @@ -37,14 +37,15 @@ void rmon0002fa28(void) // empty } -void rmon0002fa30(void) +void rmon0002fa30(s32 *arg0, s32 arg1) { - // empty + if (arg0); + if (arg1); } -void rmon0002fa38(void) +void rmon0002fa38(u32 arg0) { - // empty + if (arg0); } void rmon0002fa40(void)