From be35d2141195c222444206b219d13b9c5c241e96 Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Mon, 2 Nov 2020 22:57:47 +1000 Subject: [PATCH] Decompile func0f0a212c --- src/game/game_097ba0.c | 19 ++++--------------- src/include/game/game_097ba0.h | 2 +- 2 files changed, 5 insertions(+), 16 deletions(-) diff --git a/src/game/game_097ba0.c b/src/game/game_097ba0.c index 842854dd6..86eeaac59 100644 --- a/src/game/game_097ba0.c +++ b/src/game/game_097ba0.c @@ -12597,21 +12597,10 @@ s32 func0f0a20fc(s32 handnum) return g_Vars.currentplayer->hands[handnum].unk063c; } -GLOBAL_ASM( -glabel func0f0a212c -/* f0a212c: 00047900 */ sll $t7,$a0,0x4 -/* f0a2130: 01e47823 */ subu $t7,$t7,$a0 -/* f0a2134: 000f7880 */ sll $t7,$t7,0x2 -/* f0a2138: 01e47821 */ addu $t7,$t7,$a0 -/* f0a213c: 3c0e800a */ lui $t6,%hi(g_Vars+0x284) -/* f0a2140: 8dcea244 */ lw $t6,%lo(g_Vars+0x284)($t6) -/* f0a2144: 000f78c0 */ sll $t7,$t7,0x3 -/* f0a2148: 01e47821 */ addu $t7,$t7,$a0 -/* f0a214c: 000f7880 */ sll $t7,$t7,0x2 -/* f0a2150: 01cfc021 */ addu $t8,$t6,$t7 -/* f0a2154: 03e00008 */ jr $ra -/* f0a2158: 8f020ce4 */ lw $v0,0xce4($t8) -); +s32 func0f0a212c(s32 handnum) +{ + return g_Vars.currentplayer->hands[handnum].unk0ce4; +} char *weaponGetName(s32 weaponnum) { diff --git a/src/include/game/game_097ba0.h b/src/include/game/game_097ba0.h index 5a970b80b..22f6e24d9 100644 --- a/src/include/game/game_097ba0.h +++ b/src/include/game/game_097ba0.h @@ -99,7 +99,7 @@ bool func0f0a1d14(u32 weaponnum); void func0f0a1df4(void); void currentPlayerEquipWeaponWrapper(bool arg0, s32 weaponnum); s32 func0f0a20fc(s32 handnum); -u32 func0f0a212c(void); +s32 func0f0a212c(s32 handnum); char *weaponGetName(s32 weaponnum); u16 weaponGetNameId(s32 weaponnum); char *weaponGetShortName(s32 arg0);