From 5d40470f89de581391e8bcfdadfe3767bb0bca0c Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Tue, 26 Oct 2021 17:15:43 +1000 Subject: [PATCH] ntsc-beta: Get ROM fully matching --- ld/pd.ld | 13 +- src/assets/ntsc-beta/files/list.c | 1 - src/assets/ntsc-beta/files/list.ld | 4 - src/game/bg.c | 2 +- src/game/bgbss.c | 6 + src/game/bondbike.c | 16 +- src/game/bondgrab.c | 670 +++- src/game/bondgun.c | 37 +- src/game/bondmove.c | 8 +- src/game/bondview.c | 176 + src/game/bondwalk.c | 389 ++- src/game/casing/reset.c | 45 + src/game/cheats.c | 48 + src/game/chr/chraction.c | 1265 ++++++- src/game/chr/chrai.c | 4 +- src/game/credits.c | 582 ++-- src/game/debug1.c | 6 +- src/game/debug2.c | 142 +- src/game/dlights.c | 326 ++ src/game/endscreen.c | 2 +- src/game/file.c | 44 +- src/game/filelist.c | 116 +- src/game/filemgr.c | 28 +- src/game/game_02cde0.c | 2 +- src/game/game_091e10.c | 2 +- src/game/game_092610.c | 8 +- src/game/game_0abe70.c | 245 ++ src/game/game_0b0fd0.c | 2 +- src/game/game_0b69d0.c | 376 ++ src/game/game_0f09f0.c | 3170 ++++++++++++++++- src/game/game_127910.c | 243 ++ src/game/game_190260.c | 1058 ++++++ src/game/game_19aa80.c | 2 + src/game/gamefile.c | 477 ++- src/game/hudmsg.c | 44 +- src/game/lv.c | 20 +- src/game/mainmenu.c | 321 +- src/game/menu/items.c | 659 +++- src/game/mplayer/ingame.c | 5 +- src/game/mplayer/mplayer.c | 380 +- src/game/mplayer/scenarios.c | 47 + src/game/mplayer/setup.c | 761 +++- src/game/music.c | 105 + src/game/objectives/objectives.c | 6 +- src/game/pak/pak.c | 89 +- src/game/prop.c | 3 + src/game/propobj.c | 5219 +++++++++++++++++++++++++++- src/game/savebuffer.c | 10 +- src/game/splat.c | 6 + src/game/title.c | 2 +- src/game/training/menus.c | 136 +- src/game/weather/weather.c | 15 +- src/include/bss.h | 2 +- src/include/constants.h | 2 - src/include/data.h | 4 +- src/include/types.h | 42 +- src/lib/base.c | 2 + src/lib/boot.c | 4 +- src/lib/crash.c | 60 +- src/lib/dma.c | 4 + src/lib/gvars.c | 4 + src/lib/joy.c | 49 +- src/lib/reset.c | 4 + src/lib/snd.c | 8 +- src/lib/ultra/io/pfsisplug.c | 3 +- src/lib/ultra/os/initialize.c | 13 +- src/lib/vi.c | 4 + src/romheader/romheader.s | 15 +- tools/extract | 2 +- tools/mkrom/mkrom.h | 6 + tools/mkrom/pack.c | 40 +- tools/mkrom/rom.c | 3 + 72 files changed, 16927 insertions(+), 687 deletions(-) diff --git a/ld/pd.ld b/ld/pd.ld index 08b454aa5..69a1ab818 100644 --- a/ld/pd.ld +++ b/ld/pd.ld @@ -84,7 +84,7 @@ #else #define ROMALLOCATION_LIB 0x02f800 #define ROMALLOCATION_DATA 0x012000 -#define ROMALLOCATION_GAME 0x112080 +#define ROMALLOCATION_GAME 0x105000 #endif OUTPUT_ARCH (mips) @@ -95,10 +95,14 @@ SECTIONS _gamecode = 0x4450; _jpndata1 = 0x17fc40; _jpndata2 = 0x18b340; -#else +#elif VERSION >= VERSION_NTSC_1_0 _gamecode = 0x4445; _jpndata1 = 0x194440; _jpndata2 = 0x19fb40; +#else + _gamecode = 0x4445; + _jpndata1 = 0x148c40; + _jpndata2 = 0x154340; #endif #if VERSION >= VERSION_PAL_FINAL @@ -184,7 +188,7 @@ SECTIONS BEGIN_SEG(preamble) { build/ROMID/preamble/preamble.o (.text); - . = ALIGN(0x30); + . = 0x50; } END_SEG(preamble) @@ -446,10 +450,7 @@ SECTIONS FONT(handelgothicmd) FONT(handelgothiclg) FONT(ocramd) - -#if VERSION >= VERSION_NTSC_1_0 FONT(ocralg) -#endif /*************************************************************************** * sfxctl diff --git a/src/assets/ntsc-beta/files/list.c b/src/assets/ntsc-beta/files/list.c index c932f9c69..deab4b095 100644 --- a/src/assets/ntsc-beta/files/list.c +++ b/src/assets/ntsc-beta/files/list.c @@ -2015,5 +2015,4 @@ char *filenames[] = { /*0x7da*/ "Ap29_15_joM", /*0x7db*/ "Ap16_03_joM", /*0x7dc*/ "Acarrbye02M", - /*0x7dd*/ "Asaucerexp1M", }; diff --git a/src/assets/ntsc-beta/files/list.ld b/src/assets/ntsc-beta/files/list.ld index 491a0b809..1bd62e64b 100644 --- a/src/assets/ntsc-beta/files/list.ld +++ b/src/assets/ntsc-beta/files/list.ld @@ -2021,7 +2021,3 @@ FILE(07d9, CheadphelpsZ, _file_CheadphelpsZ); FILE(07da, Ap29_15_joM, _file_Ap29_15_joM); FILE(07db, Ap16_03_joM, _file_Ap16_03_joM); FILE(07dc, Acarrbye02M, _file_Acarrbye02M); - -#if VERSION >= VERSION_NTSC_1_0 -FILE(07dd, Asaucerexp1M, _file_Asaucerexp1M); -#endif diff --git a/src/game/bg.c b/src/game/bg.c index 73cab2578..f893dfae3 100644 --- a/src/game/bg.c +++ b/src/game/bg.c @@ -109,12 +109,12 @@ s32 g_StageIndex = 1; u32 var8007fc04 = 0x00000000; u8 *var8007fc08 = NULL; s16 var8007fc0c = 0; -s16 var8007fc10 = 0; #if VERSION < VERSION_NTSC_1_0 u32 var80082474nb = 0; #endif +s16 var8007fc10 = 0; s32 var8007fc14 = 0; u32 var8007fc18 = 0x01000100; u32 var8007fc1c = 0x00000000; diff --git a/src/game/bgbss.c b/src/game/bgbss.c index 594e49a6d..b0c001d1c 100644 --- a/src/game/bgbss.c +++ b/src/game/bgbss.c @@ -6,6 +6,7 @@ u32 var800a6470; u32 var800a6474; u32 var800a6478; + u32 var800a647c; u32 var800a6480; u32 var800a6484; @@ -53,6 +54,11 @@ u32 var800a6528; u32 var800a652c; u32 var800a6530; u32 var800a6534; + +#if VERSION < VERSION_NTSC_1_0 +u8 var800aacb8nb[0x140]; +#endif + u32 var800a6538; u32 var800a653c; u32 var800a6540; diff --git a/src/game/bondbike.c b/src/game/bondbike.c index 887041f49..6148d08e3 100644 --- a/src/game/bondbike.c +++ b/src/game/bondbike.c @@ -1296,7 +1296,11 @@ s32 bbike0f0d3680(struct coord *arg0, struct coord *arg1, struct coord *arg2) s32 result = bbikeCalculateNewPositionWithPush(arg0, 0); if (!result) { +#if VERSION >= VERSION_NTSC_1_0 cd00024e4c(arg1, arg2, 659, "bondbike.c"); +#else + cd00024e4c(arg1, arg2, 656, "bondbike.c"); +#endif } return result; @@ -1320,7 +1324,11 @@ s32 bbike0f0d36d4(struct coord *arg0, struct coord *arg1, struct coord *arg2, st } if (someint == 0) { +#if VERSION >= VERSION_NTSC_1_0 cd00024e4c(arg3, arg4, 685, "bondbike.c"); +#else + cd00024e4c(arg3, arg4, 682, "bondbike.c"); +#endif if (arg3->f[0] != arg1->f[0] || arg3->f[1] != arg1->f[1] @@ -1551,7 +1559,9 @@ void bbikeTick(void) f32 sp1f4; struct coord sp1e8; Mtxf sp1a8; - u32 stack2; +#if VERSION >= VERSION_NTSC_1_0 + s32 j; +#endif Mtxf sp164; Mtxf sp124; Mtxf spe4; @@ -1667,8 +1677,8 @@ void bbikeTick(void) prop = g_Vars.currentplayer->prop; #if VERSION >= VERSION_NTSC_1_0 - for (i = 0; prop->rooms[i] != -1; i++) { - if (prop->rooms[i] == g_Vars.currentplayer->floorroom) { + for (j = 0; prop->rooms[j] != -1; j++) { + if (prop->rooms[j] == g_Vars.currentplayer->floorroom) { propDeregisterRooms(prop); g_Vars.currentplayer->prop->rooms[0] = g_Vars.currentplayer->floorroom; g_Vars.currentplayer->prop->rooms[1] = -1; diff --git a/src/game/bondgrab.c b/src/game/bondgrab.c index e79bb0eca..86e2e24c9 100644 --- a/src/game/bondgrab.c +++ b/src/game/bondgrab.c @@ -110,15 +110,17 @@ void bgrabInit(void) if (obj->flags3 & OBJFLAG3_GEOTYPE3) { withforce = cd000276c8(obj->geo3, g_Vars.currentplayer->prop->pos.x, - g_Vars.currentplayer->prop->pos.z, 45, 0, 0); + g_Vars.currentplayer->prop->pos.z, + VERSION >= VERSION_NTSC_1_0 ? 45 : 40, 0, 0); } else { withforce = cd000274e0(obj->geo2, g_Vars.currentplayer->prop->pos.x, - g_Vars.currentplayer->prop->pos.z, 45, 0, 0); + g_Vars.currentplayer->prop->pos.z, + VERSION >= VERSION_NTSC_1_0 ? 45 : 40, 0, 0); } if (withforce) { - g_Vars.currentplayer->grabbedforcez = 15; + g_Vars.currentplayer->grabbedforcez = VERSION >= VERSION_NTSC_1_0 ? 15 : 10; } } @@ -179,6 +181,7 @@ void bgrabExit(void) } } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel bgrab0f0ccbf0 .late_rodata @@ -482,6 +485,311 @@ glabel var7f1ad990 /* f0cd054: 03e00008 */ jr $ra /* f0cd058: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel bgrab0f0ccbf0 +.late_rodata +glabel var7f1ad990 +.word 0x3dcccccd +.text +/* f0ccbf0: 3c03800a */ lui $v1,%hi(g_Vars) +/* f0ccbf4: 24639fc0 */ addiu $v1,$v1,%lo(g_Vars) +/* f0ccbf8: 8c6e0034 */ lw $t6,0x34($v1) +/* f0ccbfc: 27bdff20 */ addiu $sp,$sp,-224 +/* f0ccc00: afbf001c */ sw $ra,0x1c($sp) +/* f0ccc04: afa400e0 */ sw $a0,0xe0($sp) +/* f0ccc08: afa500e4 */ sw $a1,0xe4($sp) +/* f0ccc0c: 19c0010f */ blez $t6,.L0f0cd04c +/* f0ccc10: afa600e8 */ sw $a2,0xe8($sp) +/* f0ccc14: 3c0f800a */ lui $t7,%hi(var8009de70) +/* f0ccc18: 8defde70 */ lw $t7,%lo(var8009de70)($t7) +/* f0ccc1c: 24010006 */ addiu $at,$zero,0x6 +/* f0ccc20: 27ae0074 */ addiu $t6,$sp,0x74 +/* f0ccc24: 91f80000 */ lbu $t8,0x0($t7) +/* f0ccc28: 3c0f8007 */ lui $t7,%hi(var80070e84) +/* f0ccc2c: 25ef0e84 */ addiu $t7,$t7,%lo(var80070e84) +/* f0ccc30: 1701004f */ bne $t8,$at,.L0f0ccd70 +/* f0ccc34: 27a5005c */ addiu $a1,$sp,0x5c +/* f0ccc38: 8c620284 */ lw $v0,0x284($v1) +/* f0ccc3c: c4840000 */ lwc1 $f4,0x0($a0) +/* f0ccc40: 3c077f1b */ lui $a3,%hi(var7f1ad940) +/* f0ccc44: 8c4800bc */ lw $t0,0xbc($v0) +/* f0ccc48: 24e7d940 */ addiu $a3,$a3,%lo(var7f1ad940) +/* f0ccc4c: 27a500a4 */ addiu $a1,$sp,0xa4 +/* f0ccc50: c5060008 */ lwc1 $f6,0x8($t0) +/* f0ccc54: 240600c9 */ addiu $a2,$zero,0xc8 +/* f0ccc58: 46062200 */ add.s $f8,$f4,$f6 +/* f0ccc5c: e7a80098 */ swc1 $f8,0x98($sp) +/* f0ccc60: 8c4900bc */ lw $t1,0xbc($v0) +/* f0ccc64: c52a000c */ lwc1 $f10,0xc($t1) +/* f0ccc68: e7aa009c */ swc1 $f10,0x9c($sp) +/* f0ccc6c: 8c4a00bc */ lw $t2,0xbc($v0) +/* f0ccc70: c4840008 */ lwc1 $f4,0x8($a0) +/* f0ccc74: 27a400b0 */ addiu $a0,$sp,0xb0 +/* f0ccc78: c5460010 */ lwc1 $f6,0x10($t2) +/* f0ccc7c: 46062200 */ add.s $f8,$f4,$f6 +/* f0ccc80: 0c009393 */ jal cd00024e4c +/* f0ccc84: e7a800a0 */ swc1 $f8,0xa0($sp) +/* f0ccc88: c7aa00ac */ lwc1 $f10,0xac($sp) +/* f0ccc8c: c7a400b8 */ lwc1 $f4,0xb8($sp) +/* f0ccc90: 44809000 */ mtc1 $zero,$f18 +/* f0ccc94: c7a600b0 */ lwc1 $f6,0xb0($sp) +/* f0ccc98: 46045001 */ sub.s $f0,$f10,$f4 +/* f0ccc9c: c7a800a4 */ lwc1 $f8,0xa4($sp) +/* f0ccca0: 27a400c8 */ addiu $a0,$sp,0xc8 +/* f0ccca4: 27a500cc */ addiu $a1,$sp,0xcc +/* f0ccca8: 46009032 */ c.eq.s $f18,$f0 +/* f0cccac: e7a000c8 */ swc1 $f0,0xc8($sp) +/* f0cccb0: 46083281 */ sub.s $f10,$f6,$f8 +/* f0cccb4: e7b200cc */ swc1 $f18,0xcc($sp) +/* f0cccb8: 45000005 */ bc1f .L0f0cccd0 +/* f0cccbc: e7aa00d0 */ swc1 $f10,0xd0($sp) +/* f0cccc0: 460a9032 */ c.eq.s $f18,$f10 +/* f0cccc4: 3c013f80 */ lui $at,0x3f80 +/* f0cccc8: 45030006 */ bc1tl .L0f0ccce4 +/* f0ccccc: 44812000 */ mtc1 $at,$f4 +.L0f0cccd0: +/* f0cccd0: 0c0011e4 */ jal guNormalize +/* f0cccd4: 27a600d0 */ addiu $a2,$sp,0xd0 +/* f0cccd8: 10000005 */ b .L0f0cccf0 +/* f0cccdc: 27ab00d4 */ addiu $t3,$sp,0xd4 +/* f0ccce0: 44812000 */ mtc1 $at,$f4 +.L0f0ccce4: +/* f0ccce4: 00000000 */ nop +/* f0ccce8: e7a400d0 */ swc1 $f4,0xd0($sp) +/* f0cccec: 27ab00d4 */ addiu $t3,$sp,0xd4 +.L0f0cccf0: +/* f0cccf0: afab0010 */ sw $t3,0x10($sp) +/* f0cccf4: 27a400b0 */ addiu $a0,$sp,0xb0 +/* f0cccf8: 27a500a4 */ addiu $a1,$sp,0xa4 +/* f0cccfc: 27a60098 */ addiu $a2,$sp,0x98 +/* f0ccd00: 0fc0b8f7 */ jal func0f02e3dc +/* f0ccd04: 27a700c8 */ addiu $a3,$sp,0xc8 +/* f0ccd08: 3c03800a */ lui $v1,%hi(g_Vars) +/* f0ccd0c: 24639fc0 */ addiu $v1,$v1,%lo(g_Vars) +/* f0ccd10: 8c620284 */ lw $v0,0x284($v1) +/* f0ccd14: c7a60098 */ lwc1 $f6,0x98($sp) +/* f0ccd18: c460004c */ lwc1 $f0,0x4c($v1) +/* f0ccd1c: 8c4c00bc */ lw $t4,0xbc($v0) +/* f0ccd20: 44809000 */ mtc1 $zero,$f18 +/* f0ccd24: 8fa400e8 */ lw $a0,0xe8($sp) +/* f0ccd28: c5880008 */ lwc1 $f8,0x8($t4) +/* f0ccd2c: e7b200c0 */ swc1 $f18,0xc0($sp) +/* f0ccd30: 27a500d4 */ addiu $a1,$sp,0xd4 +/* f0ccd34: 46083281 */ sub.s $f10,$f6,$f8 +/* f0ccd38: c7a600a0 */ lwc1 $f6,0xa0($sp) +/* f0ccd3c: 27a600c8 */ addiu $a2,$sp,0xc8 +/* f0ccd40: 27a700bc */ addiu $a3,$sp,0xbc +/* f0ccd44: 46005103 */ div.s $f4,$f10,$f0 +/* f0ccd48: e7a400bc */ swc1 $f4,0xbc($sp) +/* f0ccd4c: 8c4d00bc */ lw $t5,0xbc($v0) +/* f0ccd50: c5a80010 */ lwc1 $f8,0x10($t5) +/* f0ccd54: afa00010 */ sw $zero,0x10($sp) +/* f0ccd58: 46083281 */ sub.s $f10,$f6,$f8 +/* f0ccd5c: 46005103 */ div.s $f4,$f10,$f0 +/* f0ccd60: 0fc20ba1 */ jal func0f082e84 +/* f0ccd64: e7a400c4 */ swc1 $f4,0xc4($sp) +/* f0ccd68: 100000b9 */ b .L0f0cd050 +/* f0ccd6c: 8fbf001c */ lw $ra,0x1c($sp) +.L0f0ccd70: +/* f0ccd70: 8de10000 */ lw $at,0x0($t7) +/* f0ccd74: 8de90004 */ lw $t1,0x4($t7) +/* f0ccd78: 3c077f1b */ lui $a3,%hi(var7f1ad94c) +/* f0ccd7c: adc10000 */ sw $at,0x0($t6) +/* f0ccd80: 8de10008 */ lw $at,0x8($t7) +/* f0ccd84: 24e7d94c */ addiu $a3,$a3,%lo(var7f1ad94c) +/* f0ccd88: 27a40068 */ addiu $a0,$sp,0x68 +/* f0ccd8c: 240600e4 */ addiu $a2,$zero,0xe3 +/* f0ccd90: adc90004 */ sw $t1,0x4($t6) +/* f0ccd94: 0c009393 */ jal cd00024e4c +/* f0ccd98: adc10008 */ sw $at,0x8($t6) +/* f0ccd9c: 27a40050 */ addiu $a0,$sp,0x50 +/* f0ccda0: 0c0094d9 */ jal cd00025364 +/* f0ccda4: 27a50044 */ addiu $a1,$sp,0x44 +/* f0ccda8: 1040000e */ beqz $v0,.L0f0ccde4 +/* f0ccdac: 27a40068 */ addiu $a0,$sp,0x68 +/* f0ccdb0: c7a60044 */ lwc1 $f6,0x44($sp) +/* f0ccdb4: c7a80050 */ lwc1 $f8,0x50($sp) +/* f0ccdb8: c7a40048 */ lwc1 $f4,0x48($sp) +/* f0ccdbc: 46083281 */ sub.s $f10,$f6,$f8 +/* f0ccdc0: c7a60054 */ lwc1 $f6,0x54($sp) +/* f0ccdc4: 46062201 */ sub.s $f8,$f4,$f6 +/* f0ccdc8: e7aa0044 */ swc1 $f10,0x44($sp) +/* f0ccdcc: c7aa004c */ lwc1 $f10,0x4c($sp) +/* f0ccdd0: c7a40058 */ lwc1 $f4,0x58($sp) +/* f0ccdd4: e7a80048 */ swc1 $f8,0x48($sp) +/* f0ccdd8: 46045181 */ sub.s $f6,$f10,$f4 +/* f0ccddc: 10000019 */ b .L0f0cce44 +/* f0ccde0: e7a6004c */ swc1 $f6,0x4c($sp) +.L0f0ccde4: +/* f0ccde4: 3c02800a */ lui $v0,%hi(var8009de70) +/* f0ccde8: 8c42de70 */ lw $v0,%lo(var8009de70)($v0) +/* f0ccdec: 8fb900e8 */ lw $t9,0xe8($sp) +/* f0ccdf0: c4480008 */ lwc1 $f8,0x8($v0) +/* f0ccdf4: e7a80050 */ swc1 $f8,0x50($sp) +/* f0ccdf8: c44a000c */ lwc1 $f10,0xc($v0) +/* f0ccdfc: e7aa0054 */ swc1 $f10,0x54($sp) +/* f0cce00: c4440010 */ lwc1 $f4,0x10($v0) +/* f0cce04: e7a40058 */ swc1 $f4,0x58($sp) +/* f0cce08: 8f2a0014 */ lw $t2,0x14($t9) +/* f0cce0c: c4480008 */ lwc1 $f8,0x8($v0) +/* f0cce10: c5460008 */ lwc1 $f6,0x8($t2) +/* f0cce14: 46083281 */ sub.s $f10,$f6,$f8 +/* f0cce18: e7aa0044 */ swc1 $f10,0x44($sp) +/* f0cce1c: 8f2b0014 */ lw $t3,0x14($t9) +/* f0cce20: c446000c */ lwc1 $f6,0xc($v0) +/* f0cce24: c564000c */ lwc1 $f4,0xc($t3) +/* f0cce28: 46062201 */ sub.s $f8,$f4,$f6 +/* f0cce2c: e7a80048 */ swc1 $f8,0x48($sp) +/* f0cce30: 8f2c0014 */ lw $t4,0x14($t9) +/* f0cce34: c4440010 */ lwc1 $f4,0x10($v0) +/* f0cce38: c58a0010 */ lwc1 $f10,0x10($t4) +/* f0cce3c: 46045181 */ sub.s $f6,$f10,$f4 +/* f0cce40: e7a6004c */ swc1 $f6,0x4c($sp) +.L0f0cce44: +/* f0cce44: 27ad008c */ addiu $t5,$sp,0x8c +/* f0cce48: afad0010 */ sw $t5,0x10($sp) +/* f0cce4c: 27a5005c */ addiu $a1,$sp,0x5c +/* f0cce50: 27a60050 */ addiu $a2,$sp,0x50 +/* f0cce54: 0fc0b8f7 */ jal func0f02e3dc +/* f0cce58: 27a70044 */ addiu $a3,$sp,0x44 +/* f0cce5c: 8fa200e0 */ lw $v0,0xe0($sp) +/* f0cce60: 44809000 */ mtc1 $zero,$f18 +/* f0cce64: 27a40080 */ addiu $a0,$sp,0x80 +/* f0cce68: c4480000 */ lwc1 $f8,0x0($v0) +/* f0cce6c: e7b20084 */ swc1 $f18,0x84($sp) +/* f0cce70: 27a50084 */ addiu $a1,$sp,0x84 +/* f0cce74: e7a80080 */ swc1 $f8,0x80($sp) +/* f0cce78: c7a40080 */ lwc1 $f4,0x80($sp) +/* f0cce7c: c44a0008 */ lwc1 $f10,0x8($v0) +/* f0cce80: 46049032 */ c.eq.s $f18,$f4 +/* f0cce84: e7aa0088 */ swc1 $f10,0x88($sp) +/* f0cce88: c7a60088 */ lwc1 $f6,0x88($sp) +/* f0cce8c: 45000005 */ bc1f .L0f0ccea4 +/* f0cce90: 00000000 */ nop +/* f0cce94: 46069032 */ c.eq.s $f18,$f6 +/* f0cce98: 3c013f80 */ lui $at,0x3f80 +/* f0cce9c: 45030007 */ bc1tl .L0f0ccebc +/* f0ccea0: 44814000 */ mtc1 $at,$f8 +.L0f0ccea4: +/* f0ccea4: 0c0011e4 */ jal guNormalize +/* f0ccea8: 27a60088 */ addiu $a2,$sp,0x88 +/* f0cceac: 44809000 */ mtc1 $zero,$f18 +/* f0cceb0: 10000004 */ b .L0f0ccec4 +/* f0cceb4: 8fa200e0 */ lw $v0,0xe0($sp) +/* f0cceb8: 44814000 */ mtc1 $at,$f8 +.L0f0ccebc: +/* f0ccebc: 00000000 */ nop +/* f0ccec0: e7a80088 */ swc1 $f8,0x88($sp) +.L0f0ccec4: +/* f0ccec4: c4400000 */ lwc1 $f0,0x0($v0) +/* f0ccec8: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f0ccecc: 27a5008c */ addiu $a1,$sp,0x8c +/* f0cced0: 46009032 */ c.eq.s $f18,$f0 +/* f0cced4: 27a60080 */ addiu $a2,$sp,0x80 +/* f0cced8: 27a70074 */ addiu $a3,$sp,0x74 +/* f0ccedc: 45030007 */ bc1tl .L0f0ccefc +/* f0ccee0: c4400008 */ lwc1 $f0,0x8($v0) +/* f0ccee4: c424a00c */ lwc1 $f4,%lo(g_Vars+0x4c)($at) +/* f0ccee8: c7aa0074 */ lwc1 $f10,0x74($sp) +/* f0cceec: 46040183 */ div.s $f6,$f0,$f4 +/* f0ccef0: 46065200 */ add.s $f8,$f10,$f6 +/* f0ccef4: e7a80074 */ swc1 $f8,0x74($sp) +/* f0ccef8: c4400008 */ lwc1 $f0,0x8($v0) +.L0f0ccefc: +/* f0ccefc: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f0ccf00: 46009032 */ c.eq.s $f18,$f0 +/* f0ccf04: 00000000 */ nop +/* f0ccf08: 45030007 */ bc1tl .L0f0ccf28 +/* f0ccf0c: 8fa400e8 */ lw $a0,0xe8($sp) +/* f0ccf10: c42aa00c */ lwc1 $f10,%lo(g_Vars+0x4c)($at) +/* f0ccf14: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f0ccf18: 460a0183 */ div.s $f6,$f0,$f10 +/* f0ccf1c: 46062200 */ add.s $f8,$f4,$f6 +/* f0ccf20: e7a8007c */ swc1 $f8,0x7c($sp) +/* f0ccf24: 8fa400e8 */ lw $a0,0xe8($sp) +.L0f0ccf28: +/* f0ccf28: 0fc20ba1 */ jal func0f082e84 +/* f0ccf2c: afa00010 */ sw $zero,0x10($sp) +/* f0ccf30: 44809000 */ mtc1 $zero,$f18 +/* f0ccf34: c7aa00e4 */ lwc1 $f10,0xe4($sp) +/* f0ccf38: 3c08800a */ lui $t0,%hi(g_Vars+0x284) +/* f0ccf3c: 46125032 */ c.eq.s $f10,$f18 +/* f0ccf40: 00000000 */ nop +/* f0ccf44: 45030042 */ bc1tl .L0f0cd050 +/* f0ccf48: 8fbf001c */ lw $ra,0x1c($sp) +/* f0ccf4c: 8d08a244 */ lw $t0,%lo(g_Vars+0x284)($t0) +/* f0ccf50: c7a4008c */ lwc1 $f4,0x8c($sp) +/* f0ccf54: c7a80094 */ lwc1 $f8,0x94($sp) +/* f0ccf58: 8d0200bc */ lw $v0,0xbc($t0) +/* f0ccf5c: 3c0e8007 */ lui $t6,%hi(var80070e90) +/* f0ccf60: 25ce0e90 */ addiu $t6,$t6,%lo(var80070e90) +/* f0ccf64: c4460008 */ lwc1 $f6,0x8($v0) +/* f0ccf68: c44a0010 */ lwc1 $f10,0x10($v0) +/* f0ccf6c: 8dc10000 */ lw $at,0x0($t6) +/* f0ccf70: 46062081 */ sub.s $f2,$f4,$f6 +/* f0ccf74: 27b8002c */ addiu $t8,$sp,0x2c +/* f0ccf78: af010000 */ sw $at,0x0($t8) +/* f0ccf7c: 460a4381 */ sub.s $f14,$f8,$f10 +/* f0ccf80: 46021102 */ mul.s $f4,$f2,$f2 +/* f0ccf84: 8dc10008 */ lw $at,0x8($t6) +/* f0ccf88: 8dc90004 */ lw $t1,0x4($t6) +/* f0ccf8c: 460e7182 */ mul.s $f6,$f14,$f14 +/* f0ccf90: af010008 */ sw $at,0x8($t8) +/* f0ccf94: af090004 */ sw $t1,0x4($t8) +/* f0ccf98: e7ae003c */ swc1 $f14,0x3c($sp) +/* f0ccf9c: e7a20040 */ swc1 $f2,0x40($sp) +/* f0ccfa0: 0c012974 */ jal sqrtf +/* f0ccfa4: 46062300 */ add.s $f12,$f4,$f6 +/* f0ccfa8: 3c013f80 */ lui $at,0x3f80 +/* f0ccfac: 44814000 */ mtc1 $at,$f8 +/* f0ccfb0: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f0ccfb4: c424a00c */ lwc1 $f4,%lo(g_Vars+0x4c)($at) +/* f0ccfb8: 46004303 */ div.s $f12,$f8,$f0 +/* f0ccfbc: c7aa00e4 */ lwc1 $f10,0xe4($sp) +/* f0ccfc0: c7a20040 */ lwc1 $f2,0x40($sp) +/* f0ccfc4: c7ae003c */ lwc1 $f14,0x3c($sp) +/* f0ccfc8: 3c014220 */ lui $at,0x4220 +/* f0ccfcc: 44809000 */ mtc1 $zero,$f18 +/* f0ccfd0: 240a0001 */ addiu $t2,$zero,0x1 +/* f0ccfd4: afaa0010 */ sw $t2,0x10($sp) +/* f0ccfd8: 8fa400e8 */ lw $a0,0xe8($sp) +/* f0ccfdc: 27a5002c */ addiu $a1,$sp,0x2c +/* f0ccfe0: 24070001 */ addiu $a3,$zero,0x1 +/* f0ccfe4: 46045183 */ div.s $f6,$f10,$f4 +/* f0ccfe8: 44812000 */ mtc1 $at,$f4 +/* f0ccfec: 460c1082 */ mul.s $f2,$f2,$f12 +/* f0ccff0: 00000000 */ nop +/* f0ccff4: 460c7382 */ mul.s $f14,$f14,$f12 +/* f0ccff8: 46007207 */ neg.s $f8,$f14 +/* f0ccffc: e7a600e4 */ swc1 $f6,0xe4($sp) +/* f0cd000: 46064282 */ mul.s $f10,$f8,$f6 +/* f0cd004: 00000000 */ nop +/* f0cd008: 46045202 */ mul.s $f8,$f10,$f4 +/* f0cd00c: c7aa002c */ lwc1 $f10,0x2c($sp) +/* f0cd010: 46085100 */ add.s $f4,$f10,$f8 +/* f0cd014: 46061282 */ mul.s $f10,$f2,$f6 +/* f0cd018: 44814000 */ mtc1 $at,$f8 +/* f0cd01c: 3c017f1b */ lui $at,%hi(var7f1ad990) +/* f0cd020: e7a4002c */ swc1 $f4,0x2c($sp) +/* f0cd024: 46085102 */ mul.s $f4,$f10,$f8 +/* f0cd028: c7aa0034 */ lwc1 $f10,0x34($sp) +/* f0cd02c: 46045200 */ add.s $f8,$f10,$f4 +/* f0cd030: c42ad990 */ lwc1 $f10,%lo(var7f1ad990)($at) +/* f0cd034: 460a3102 */ mul.s $f4,$f6,$f10 +/* f0cd038: e7a80034 */ swc1 $f8,0x34($sp) +/* f0cd03c: 46049400 */ add.s $f16,$f18,$f4 +/* f0cd040: 44068000 */ mfc1 $a2,$f16 +/* f0cd044: 0fc20a87 */ jal func0f082a1c +/* f0cd048: 00000000 */ nop +.L0f0cd04c: +/* f0cd04c: 8fbf001c */ lw $ra,0x1c($sp) +.L0f0cd050: +/* f0cd050: 27bd00e0 */ addiu $sp,$sp,0xe0 +/* f0cd054: 03e00008 */ jr $ra +/* f0cd058: 00000000 */ nop +); +#endif bool bgrabTryMoveUpwards(f32 y) { @@ -2285,6 +2593,7 @@ bool bgrab0f0cdb04(f32 angle, bool arg2) return result; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel bgrab0f0cdb68 .late_rodata @@ -2532,6 +2841,255 @@ glabel var7f1ad9c8 /* f0cdee8: 03e00008 */ jr $ra /* f0cdeec: 27bd00b0 */ addiu $sp,$sp,0xb0 ); +#else +GLOBAL_ASM( +glabel bgrab0f0cdb68 +.late_rodata +glabel var7f1ad9c8 +.word 0x3f8147ae +.text +/* f0cdb68: 27bdff50 */ addiu $sp,$sp,-176 +/* f0cdb6c: 3c01bf80 */ lui $at,0xbf80 +/* f0cdb70: 44817000 */ mtc1 $at,$f14 +/* f0cdb74: afbf002c */ sw $ra,0x2c($sp) +/* f0cdb78: 3c077f1b */ lui $a3,%hi(var7f1ad958) +/* f0cdb7c: f7b80020 */ sdc1 $f24,0x20($sp) +/* f0cdb80: f7b60018 */ sdc1 $f22,0x18($sp) +/* f0cdb84: f7b40010 */ sdc1 $f20,0x10($sp) +/* f0cdb88: e7ac00b0 */ swc1 $f12,0xb0($sp) +/* f0cdb8c: 24e7d958 */ addiu $a3,$a3,%lo(var7f1ad958) +/* f0cdb90: 27a400a4 */ addiu $a0,$sp,0xa4 +/* f0cdb94: 27a50098 */ addiu $a1,$sp,0x98 +/* f0cdb98: 240602a6 */ addiu $a2,$zero,0x2a2 +/* f0cdb9c: 0c009393 */ jal cd00024e4c +/* f0cdba0: e7ae0060 */ swc1 $f14,0x60($sp) +/* f0cdba4: c7ac00a4 */ lwc1 $f12,0xa4($sp) +/* f0cdba8: c7a40098 */ lwc1 $f4,0x98($sp) +/* f0cdbac: 4480c000 */ mtc1 $zero,$f24 +/* f0cdbb0: c7b200ac */ lwc1 $f18,0xac($sp) +/* f0cdbb4: 460c2401 */ sub.s $f16,$f4,$f12 +/* f0cdbb8: c7a600a0 */ lwc1 $f6,0xa0($sp) +/* f0cdbbc: c7ae0060 */ lwc1 $f14,0x60($sp) +/* f0cdbc0: 46188032 */ c.eq.s $f16,$f24 +/* f0cdbc4: 46123001 */ sub.s $f0,$f6,$f18 +/* f0cdbc8: 45000008 */ bc1f .L0f0cdbec +/* f0cdbcc: 46000086 */ mov.s $f2,$f0 +/* f0cdbd0: 46180032 */ c.eq.s $f0,$f24 +/* f0cdbd4: 3c013f80 */ lui $at,0x3f80 +/* f0cdbd8: 45000004 */ bc1f .L0f0cdbec +/* f0cdbdc: 00000000 */ nop +/* f0cdbe0: 44811000 */ mtc1 $at,$f2 +/* f0cdbe4: 10000012 */ b .L0f0cdc30 +/* f0cdbe8: 00000000 */ nop +.L0f0cdbec: +/* f0cdbec: 46108202 */ mul.s $f8,$f16,$f16 +/* f0cdbf0: e7a20078 */ swc1 $f2,0x78($sp) +/* f0cdbf4: e7ae0060 */ swc1 $f14,0x60($sp) +/* f0cdbf8: 46021282 */ mul.s $f10,$f2,$f2 +/* f0cdbfc: e7b0007c */ swc1 $f16,0x7c($sp) +/* f0cdc00: 0c012974 */ jal sqrtf +/* f0cdc04: 460a4300 */ add.s $f12,$f8,$f10 +/* f0cdc08: 3c013f80 */ lui $at,0x3f80 +/* f0cdc0c: 44812000 */ mtc1 $at,$f4 +/* f0cdc10: c7b0007c */ lwc1 $f16,0x7c($sp) +/* f0cdc14: c7a20078 */ lwc1 $f2,0x78($sp) +/* f0cdc18: 46002303 */ div.s $f12,$f4,$f0 +/* f0cdc1c: c7ae0060 */ lwc1 $f14,0x60($sp) +/* f0cdc20: 460c8402 */ mul.s $f16,$f16,$f12 +/* f0cdc24: 00000000 */ nop +/* f0cdc28: 460c1082 */ mul.s $f2,$f2,$f12 +/* f0cdc2c: 00000000 */ nop +.L0f0cdc30: +/* f0cdc30: 3c0e800a */ lui $t6,%hi(g_Vars+0x284) +/* f0cdc34: 8dcea244 */ lw $t6,%lo(g_Vars+0x284)($t6) +/* f0cdc38: c7a800ac */ lwc1 $f8,0xac($sp) +/* f0cdc3c: 46008007 */ neg.s $f0,$f16 +/* f0cdc40: 8dc200bc */ lw $v0,0xbc($t6) +/* f0cdc44: 46001506 */ mov.s $f20,$f2 +/* f0cdc48: 46000586 */ mov.s $f22,$f0 +/* f0cdc4c: c4460010 */ lwc1 $f6,0x10($v0) +/* f0cdc50: 3c0f8006 */ lui $t7,%hi(var8005f034) +/* f0cdc54: 27a4008c */ addiu $a0,$sp,0x8c +/* f0cdc58: 46083281 */ sub.s $f10,$f6,$f8 +/* f0cdc5c: c4460008 */ lwc1 $f6,0x8($v0) +/* f0cdc60: 27a50080 */ addiu $a1,$sp,0x80 +/* f0cdc64: 46005102 */ mul.s $f4,$f10,$f0 +/* f0cdc68: c7aa00a4 */ lwc1 $f10,0xa4($sp) +/* f0cdc6c: 460a3181 */ sub.s $f6,$f6,$f10 +/* f0cdc70: 46061182 */ mul.s $f6,$f2,$f6 +/* f0cdc74: 46062100 */ add.s $f4,$f4,$f6 +/* f0cdc78: 4618203c */ c.lt.s $f4,$f24 +/* f0cdc7c: 00000000 */ nop +/* f0cdc80: 45000003 */ bc1f .L0f0cdc90 +/* f0cdc84: 00000000 */ nop +/* f0cdc88: 46001507 */ neg.s $f20,$f2 +/* f0cdc8c: 46000587 */ neg.s $f22,$f0 +.L0f0cdc90: +/* f0cdc90: 8deff034 */ lw $t7,%lo(var8005f034)($t7) +/* f0cdc94: c7ac00a4 */ lwc1 $f12,0xa4($sp) +/* f0cdc98: c7b200ac */ lwc1 $f18,0xac($sp) +/* f0cdc9c: 11e00020 */ beqz $t7,.L0f0cdd20 +/* f0cdca0: 00000000 */ nop +/* f0cdca4: 3c04800a */ lui $a0,%hi(var8009a918+0x1) +/* f0cdca8: 9084a919 */ lbu $a0,%lo(var8009a918+0x1)($a0) +/* f0cdcac: 3c18800a */ lui $t8,%hi(var8009a918) +/* f0cdcb0: 2702a918 */ addiu $v0,$t8,%lo(var8009a918) +/* f0cdcb4: 18800061 */ blez $a0,.L0f0cde3c +/* f0cdcb8: 0004c8c0 */ sll $t9,$a0,0x3 +/* f0cdcbc: 03221821 */ addu $v1,$t9,$v0 +/* f0cdcc0: c4460010 */ lwc1 $f6,0x10($v0) +.L0f0cdcc4: +/* f0cdcc4: c448000c */ lwc1 $f8,0xc($v0) +/* f0cdcc8: 24420008 */ addiu $v0,$v0,0x8 +/* f0cdccc: 46123101 */ sub.s $f4,$f6,$f18 +/* f0cdcd0: 0043082b */ sltu $at,$v0,$v1 +/* f0cdcd4: 460c4181 */ sub.s $f6,$f8,$f12 +/* f0cdcd8: 46162282 */ mul.s $f10,$f4,$f22 +/* f0cdcdc: 00000000 */ nop +/* f0cdce0: 46143102 */ mul.s $f4,$f6,$f20 +/* f0cdce4: 46045000 */ add.s $f0,$f10,$f4 +/* f0cdce8: 4618003c */ c.lt.s $f0,$f24 +/* f0cdcec: 00000000 */ nop +/* f0cdcf0: 45000007 */ bc1f .L0f0cdd10 +/* f0cdcf4: 00000000 */ nop +/* f0cdcf8: 46000007 */ neg.s $f0,$f0 +/* f0cdcfc: 4600703c */ c.lt.s $f14,$f0 +/* f0cdd00: 00000000 */ nop +/* f0cdd04: 45000002 */ bc1f .L0f0cdd10 +/* f0cdd08: 00000000 */ nop +/* f0cdd0c: 46000386 */ mov.s $f14,$f0 +.L0f0cdd10: +/* f0cdd10: 5420ffec */ bnezl $at,.L0f0cdcc4 +/* f0cdd14: c4460010 */ lwc1 $f6,0x10($v0) +/* f0cdd18: 10000049 */ b .L0f0cde40 +/* f0cdd1c: c7ac00b0 */ lwc1 $f12,0xb0($sp) +.L0f0cdd20: +/* f0cdd20: 0c0094d9 */ jal cd00025364 +/* f0cdd24: e7ae0060 */ swc1 $f14,0x60($sp) +/* f0cdd28: 1040001c */ beqz $v0,.L0f0cdd9c +/* f0cdd2c: c7ae0060 */ lwc1 $f14,0x60($sp) +/* f0cdd30: c7b200ac */ lwc1 $f18,0xac($sp) +/* f0cdd34: c7a80094 */ lwc1 $f8,0x94($sp) +/* f0cdd38: c7ac00a4 */ lwc1 $f12,0xa4($sp) +/* f0cdd3c: c7a4008c */ lwc1 $f4,0x8c($sp) +/* f0cdd40: 46124181 */ sub.s $f6,$f8,$f18 +/* f0cdd44: 460c2201 */ sub.s $f8,$f4,$f12 +/* f0cdd48: 46163282 */ mul.s $f10,$f6,$f22 +/* f0cdd4c: c7a40088 */ lwc1 $f4,0x88($sp) +/* f0cdd50: 46144182 */ mul.s $f6,$f8,$f20 +/* f0cdd54: 46122201 */ sub.s $f8,$f4,$f18 +/* f0cdd58: 46065000 */ add.s $f0,$f10,$f6 +/* f0cdd5c: c7a60080 */ lwc1 $f6,0x80($sp) +/* f0cdd60: 46164282 */ mul.s $f10,$f8,$f22 +/* f0cdd64: 460c3101 */ sub.s $f4,$f6,$f12 +/* f0cdd68: 46142202 */ mul.s $f8,$f4,$f20 +/* f0cdd6c: 46085400 */ add.s $f16,$f10,$f8 +/* f0cdd70: 4600803c */ c.lt.s $f16,$f0 +/* f0cdd74: 00000000 */ nop +/* f0cdd78: 45020003 */ bc1fl .L0f0cdd88 +/* f0cdd7c: 4618003c */ c.lt.s $f0,$f24 +/* f0cdd80: 46008006 */ mov.s $f0,$f16 +/* f0cdd84: 4618003c */ c.lt.s $f0,$f24 +.L0f0cdd88: +/* f0cdd88: 00000000 */ nop +/* f0cdd8c: 4502002c */ bc1fl .L0f0cde40 +/* f0cdd90: c7ac00b0 */ lwc1 $f12,0xb0($sp) +/* f0cdd94: 10000029 */ b .L0f0cde3c +/* f0cdd98: 46000387 */ neg.s $f14,$f0 +.L0f0cdd9c: +/* f0cdd9c: 3c088007 */ lui $t0,%hi(var80070e80) +/* f0cdda0: 8d080e80 */ lw $t0,%lo(var80070e80)($t0) +/* f0cdda4: 3c09800a */ lui $t1,%hi(g_Vars+0x284) +/* f0cdda8: 51000025 */ beqzl $t0,.L0f0cde40 +/* f0cddac: c7ac00b0 */ lwc1 $f12,0xb0($sp) +/* f0cddb0: 8d29a244 */ lw $t1,%lo(g_Vars+0x284)($t1) +/* f0cddb4: 24010001 */ addiu $at,$zero,0x1 +/* f0cddb8: 8d241b5c */ lw $a0,0x1b5c($t1) +/* f0cddbc: 908a0000 */ lbu $t2,0x0($a0) +/* f0cddc0: 5541001f */ bnel $t2,$at,.L0f0cde40 +/* f0cddc4: c7ac00b0 */ lwc1 $f12,0xb0($sp) +/* f0cddc8: 8c8b0004 */ lw $t3,0x4($a0) +/* f0cddcc: 27a5004c */ addiu $a1,$sp,0x4c +/* f0cddd0: 27a60048 */ addiu $a2,$sp,0x48 +/* f0cddd4: 8d6c0010 */ lw $t4,0x10($t3) +/* f0cddd8: 27a70044 */ addiu $a3,$sp,0x44 +/* f0cdddc: 000c6980 */ sll $t5,$t4,0x6 +/* f0cdde0: 05a30017 */ bgezl $t5,.L0f0cde40 +/* f0cdde4: c7ac00b0 */ lwc1 $f12,0xb0($sp) +/* f0cdde8: 0fc21d5b */ jal propObjGetBbox +/* f0cddec: e7ae0060 */ swc1 $f14,0x60($sp) +/* f0cddf0: 3c02800a */ lui $v0,%hi(var8009de78) +/* f0cddf4: 2442de78 */ addiu $v0,$v0,%lo(var8009de78) +/* f0cddf8: c7b200ac */ lwc1 $f18,0xac($sp) +/* f0cddfc: c4460008 */ lwc1 $f6,0x8($v0) +/* f0cde00: c7ac00a4 */ lwc1 $f12,0xa4($sp) +/* f0cde04: c4480000 */ lwc1 $f8,0x0($v0) +/* f0cde08: 46123101 */ sub.s $f4,$f6,$f18 +/* f0cde0c: c7ae0060 */ lwc1 $f14,0x60($sp) +/* f0cde10: 460c4181 */ sub.s $f6,$f8,$f12 +/* f0cde14: 46162282 */ mul.s $f10,$f4,$f22 +/* f0cde18: c7a8004c */ lwc1 $f8,0x4c($sp) +/* f0cde1c: 46143102 */ mul.s $f4,$f6,$f20 +/* f0cde20: 46045000 */ add.s $f0,$f10,$f4 +/* f0cde24: 46080001 */ sub.s $f0,$f0,$f8 +/* f0cde28: 4618003c */ c.lt.s $f0,$f24 +/* f0cde2c: 00000000 */ nop +/* f0cde30: 45020003 */ bc1fl .L0f0cde40 +/* f0cde34: c7ac00b0 */ lwc1 $f12,0xb0($sp) +/* f0cde38: 46000387 */ neg.s $f14,$f0 +.L0f0cde3c: +/* f0cde3c: c7ac00b0 */ lwc1 $f12,0xb0($sp) +.L0f0cde40: +/* f0cde40: 0c0068f7 */ jal sinf +/* f0cde44: e7ae0060 */ swc1 $f14,0x60($sp) +/* f0cde48: 3c0143c8 */ lui $at,0x43c8 +/* f0cde4c: 44813000 */ mtc1 $at,$f6 +/* f0cde50: c7ae0060 */ lwc1 $f14,0x60($sp) +/* f0cde54: 00001025 */ or $v0,$zero,$zero +/* f0cde58: 46060302 */ mul.s $f12,$f0,$f6 +/* f0cde5c: 4618603c */ c.lt.s $f12,$f24 +/* f0cde60: 46006086 */ mov.s $f2,$f12 +/* f0cde64: 45020003 */ bc1fl .L0f0cde74 +/* f0cde68: 460e103c */ c.lt.s $f2,$f14 +/* f0cde6c: 46006087 */ neg.s $f2,$f12 +/* f0cde70: 460e103c */ c.lt.s $f2,$f14 +.L0f0cde74: +/* f0cde74: 00000000 */ nop +/* f0cde78: 45020003 */ bc1fl .L0f0cde88 +/* f0cde7c: 460ec03e */ c.le.s $f24,$f14 +/* f0cde80: 46001386 */ mov.s $f14,$f2 +/* f0cde84: 460ec03e */ c.le.s $f24,$f14 +.L0f0cde88: +/* f0cde88: 00000000 */ nop +/* f0cde8c: 45000012 */ bc1f .L0f0cded8 +/* f0cde90: 00000000 */ nop +/* f0cde94: 46147282 */ mul.s $f10,$f14,$f20 +/* f0cde98: 3c017f1b */ lui $at,%hi(var7f1ad9c8) +/* f0cde9c: c420d9c8 */ lwc1 $f0,%lo(var7f1ad9c8)($at) +/* f0cdea0: e7b80058 */ swc1 $f24,0x58($sp) +/* f0cdea4: 27a40054 */ addiu $a0,$sp,0x54 +/* f0cdea8: 46005102 */ mul.s $f4,$f10,$f0 +/* f0cdeac: 00000000 */ nop +/* f0cdeb0: 46167202 */ mul.s $f8,$f14,$f22 +/* f0cdeb4: e7a40054 */ swc1 $f4,0x54($sp) +/* f0cdeb8: 46004182 */ mul.s $f6,$f8,$f0 +/* f0cdebc: 0fc3382f */ jal bgrab0f0ce0bc +/* f0cdec0: e7a6005c */ swc1 $f6,0x5c($sp) +/* f0cdec4: c7ac00b0 */ lwc1 $f12,0xb0($sp) +/* f0cdec8: 0fc336c1 */ jal bgrab0f0cdb04 +/* f0cdecc: 24050001 */ addiu $a1,$zero,0x1 +/* f0cded0: 10000002 */ b .L0f0cdedc +/* f0cded4: 8fbf002c */ lw $ra,0x2c($sp) +.L0f0cded8: +/* f0cded8: 8fbf002c */ lw $ra,0x2c($sp) +.L0f0cdedc: +/* f0cdedc: d7b40010 */ ldc1 $f20,0x10($sp) +/* f0cdee0: d7b60018 */ ldc1 $f22,0x18($sp) +/* f0cdee4: d7b80020 */ ldc1 $f24,0x20($sp) +/* f0cdee8: 03e00008 */ jr $ra +/* f0cdeec: 27bd00b0 */ addiu $sp,$sp,0xb0 +); +#endif void bgrab0f0cdef0(void) { @@ -2549,7 +3107,11 @@ bool bgrab0f0cdf64(struct coord *delta, struct coord *arg1, struct coord *arg2) bool result = bgrabCalculateNewPositiontWithPush(delta, 0, true); if (!result) { - cd00024e4c(arg1, arg2, 0x32f, "bondgrab.c"); +#if VERSION >= VERSION_NTSC_1_0 + cd00024e4c(arg1, arg2, 815, "bondgrab.c"); +#else + cd00024e4c(arg1, arg2, 811, "bondgrab.c"); +#endif } return result; @@ -3614,10 +4176,6 @@ glabel var7f1ada2c void bgrabTick(void) { - s32 i; - struct defaultobj *obj; - struct hov *hov; - bgrabUpdatePrevPos(); bgrab0f0cdef0(); bmoveUpdateVerta(); @@ -3626,57 +4184,63 @@ void bgrabTick(void) bgrabUpdateVertical(); #if VERSION >= VERSION_NTSC_1_0 - for (i = 0; g_Vars.currentplayer->prop->rooms[i] != -1; i++) { - if (g_Vars.currentplayer->prop->rooms[i] == g_Vars.currentplayer->floorroom) { - propDeregisterRooms(g_Vars.currentplayer->prop); - g_Vars.currentplayer->prop->rooms[0] = g_Vars.currentplayer->floorroom; - g_Vars.currentplayer->prop->rooms[1] = -1; - break; + { + s32 i; + + for (i = 0; g_Vars.currentplayer->prop->rooms[i] != -1; i++) { + if (g_Vars.currentplayer->prop->rooms[i] == g_Vars.currentplayer->floorroom) { + propDeregisterRooms(g_Vars.currentplayer->prop); + g_Vars.currentplayer->prop->rooms[0] = g_Vars.currentplayer->floorroom; + g_Vars.currentplayer->prop->rooms[1] = -1; + break; + } } } #endif - obj = g_Vars.currentplayer->grabbedprop->obj; - hov = NULL; + { + struct defaultobj *obj = g_Vars.currentplayer->grabbedprop->obj; + struct hov *hov = NULL; - if (obj->type == OBJTYPE_HOVERPROP) { - struct hoverpropobj *hoverprop = (struct hoverpropobj *)g_Vars.currentplayer->grabbedprop->obj; - hov = &hoverprop->hov; - } else if (obj->type == OBJTYPE_HOVERBIKE) { - struct hoverbikeobj *hoverbike = (struct hoverbikeobj *)g_Vars.currentplayer->grabbedprop->obj; - hov = &hoverbike->hov; - } - - if (hov) { - func0f0714b8(obj, hov); - } - - bmove0f0cb8c4(g_Vars.currentplayer); - objectiveCheckRoomEntered(g_Vars.currentplayer->prop->rooms[0]); - bmove0f0cc19c(&g_Vars.currentplayer->prop->pos); - currentPlayerUpdatePerimInfo(); - doorsCheckAutomatic(); - - if (g_Vars.currentplayer->grabbedprop) { - // Determine if the grabbed prop should be force released - f32 ydiff = g_Vars.currentplayer->grabbedprop->pos.y - - objGetHov04(g_Vars.currentplayer->grabbedprop->obj) - - g_Vars.currentplayer->vv_manground; - - struct prop *grabbedprop = g_Vars.currentplayer->grabbedprop; - - propSetCollisionsEnabled(g_Vars.currentplayer->prop, false); - propSetCollisionsEnabled(grabbedprop, false); - - if (g_Vars.currentplayer->vv_ground <= -30000 - || ydiff < -100 || ydiff > 100 - || g_Vars.currentplayer->vv_ground < g_Vars.currentplayer->vv_manground - 50 - || !cdHasLineOfSight(&g_Vars.currentplayer->prop->pos, g_Vars.currentplayer->prop->rooms, - &g_Vars.currentplayer->grabbedprop->pos, g_Vars.currentplayer->grabbedprop->rooms, CDTYPE_ALL, 12)) { - bmoveSetMode(MOVEMODE_WALK); + if (obj->type == OBJTYPE_HOVERPROP) { + struct hoverpropobj *hoverprop = (struct hoverpropobj *)g_Vars.currentplayer->grabbedprop->obj; + hov = &hoverprop->hov; + } else if (obj->type == OBJTYPE_HOVERBIKE) { + struct hoverbikeobj *hoverbike = (struct hoverbikeobj *)g_Vars.currentplayer->grabbedprop->obj; + hov = &hoverbike->hov; } - propSetCollisionsEnabled(g_Vars.currentplayer->prop, true); - propSetCollisionsEnabled(grabbedprop, true); + if (hov) { + func0f0714b8(obj, hov); + } + + bmove0f0cb8c4(g_Vars.currentplayer); + objectiveCheckRoomEntered(g_Vars.currentplayer->prop->rooms[0]); + bmove0f0cc19c(&g_Vars.currentplayer->prop->pos); + currentPlayerUpdatePerimInfo(); + doorsCheckAutomatic(); + + if (g_Vars.currentplayer->grabbedprop) { + // Determine if the grabbed prop should be force released + f32 ydiff = g_Vars.currentplayer->grabbedprop->pos.y + - objGetHov04(g_Vars.currentplayer->grabbedprop->obj) + - g_Vars.currentplayer->vv_manground; + + struct prop *grabbedprop = g_Vars.currentplayer->grabbedprop; + + propSetCollisionsEnabled(g_Vars.currentplayer->prop, false); + propSetCollisionsEnabled(grabbedprop, false); + + if (g_Vars.currentplayer->vv_ground <= -30000 + || ydiff < -100 || ydiff > 100 + || g_Vars.currentplayer->vv_ground < g_Vars.currentplayer->vv_manground - 50 + || !cdHasLineOfSight(&g_Vars.currentplayer->prop->pos, g_Vars.currentplayer->prop->rooms, + &g_Vars.currentplayer->grabbedprop->pos, g_Vars.currentplayer->grabbedprop->rooms, CDTYPE_ALL, 12)) { + bmoveSetMode(MOVEMODE_WALK); + } + + propSetCollisionsEnabled(g_Vars.currentplayer->prop, true); + propSetCollisionsEnabled(grabbedprop, true); + } } } diff --git a/src/game/bondgun.c b/src/game/bondgun.c index 57e3712d1..ff357d92e 100644 --- a/src/game/bondgun.c +++ b/src/game/bondgun.c @@ -51,6 +51,7 @@ #include "data.h" #include "types.h" +#if VERSION >= VERSION_NTSC_1_0 u32 var8009d0d0[2]; s32 var8009d0d8; u32 var8009d0dc; @@ -86,6 +87,40 @@ s32 var8009d148; u32 var8009d14c; struct fireslot g_Fireslots[NUM_FIRESLOTS]; +#else +u32 var8009d0dc; +u32 var800a1800nb; +u32 var8009d0f0; +u32 var8009d0f4; +u32 var8009d0f8; +u32 var8009d0fc; +u32 var8009d100; +u32 var8009d104; +u32 var8009d108; +u32 var8009d10c; +u32 var8009d110; +u32 var8009d114; +u32 var8009d118; +u32 var8009d11c; +u32 var8009d120; +u32 var8009d124; +u32 var8009d128; +u32 var8009d12c; +u32 var8009d130; +u32 var8009d134; +u32 var8009d138; +u32 var8009d13c; +u32 var8009d140; +u32 var8009d144; +s32 var8009d148; +u32 var8009d14c; + +u32 var8009d0d0[2]; +s32 var8009d0d8; +struct audiohandle *g_BgunAudioHandles[4]; +struct fireslot g_Fireslots[NUM_FIRESLOTS]; +u32 fill2[1]; +#endif u32 var80070090 = 0x96969600; u32 var80070094 = 0x96969600; @@ -5308,7 +5343,7 @@ glabel var7f1ac31c /* f09a150: 5720001a */ bnezl $t9,.L0f09a1bc /* f09a154: 8e0e001c */ lw $t6,0x1c($s0) /* f09a158: 8da90000 */ lw $t1,0x0($t5) -/* f09a15c: 2d210058 */ sltiu $at,$t1,0x58 +/* f09a15c: 2d210058 */ sltiu $at,$t1,0x57 /* f09a160: 10200006 */ beqz $at,.L0f09a17c /* f09a164: 00094880 */ sll $t1,$t1,0x2 /* f09a168: 3c017f1b */ lui $at,%hi(var7f1ac1bc) diff --git a/src/game/bondmove.c b/src/game/bondmove.c index 19866b247..79f56a19a 100644 --- a/src/game/bondmove.c +++ b/src/game/bondmove.c @@ -2044,15 +2044,13 @@ void bmove0f0cc19c(struct coord *arg) g_Vars.currentplayer->bond2.unk10.y = (g_Vars.currentplayer->bond2.unk10.y - g_Vars.currentplayer->vv_manground) * mult; -#if VERSION >= VERSION_NTSC_1_0 - g_Vars.currentplayer->bond2.unk10.y += g_Vars.currentplayer->vv_manground; -#else +#if VERSION < VERSION_NTSC_1_0 if (g_Vars.currentplayer->bond2.unk10.y < 30) { g_Vars.currentplayer->bond2.unk10.y = 30; } - - g_Vars.currentplayer->bond2.unk10.y += g_Vars.currentplayer->vv_ground; #endif + + g_Vars.currentplayer->bond2.unk10.y += g_Vars.currentplayer->vv_manground; } #if VERSION >= VERSION_NTSC_1_0 diff --git a/src/game/bondview.c b/src/game/bondview.c index efa6bc332..b5bcc03d3 100644 --- a/src/game/bondview.c +++ b/src/game/bondview.c @@ -19,7 +19,11 @@ #include "types.h" #include "gbiex.h" +#if VERSION >= VERSION_NTSC_1_0 char var800a41c0[990]; +#else +char var800a41c0[1438]; +#endif s32 var8007f840 = 0x00000000; u8 var8007f844 = 0; @@ -14748,6 +14752,7 @@ void func0f1572f8(void) // empty } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel bviewRenderNvLens /* f1472fc: 27bdffa0 */ addiu $sp,$sp,-96 @@ -14917,6 +14922,177 @@ glabel bviewRenderNvLens /* f147568: 03e00008 */ jr $ra /* f14756c: 27bd0060 */ addiu $sp,$sp,0x60 ); +#else +GLOBAL_ASM( +glabel bviewRenderNvLens +/* f141b90: 27bdffa0 */ addiu $sp,$sp,-96 +/* f141b94: afbf0054 */ sw $ra,0x54($sp) +/* f141b98: afb10034 */ sw $s1,0x34($sp) +/* f141b9c: 00808825 */ or $s1,$a0,$zero +/* f141ba0: afbe0050 */ sw $s8,0x50($sp) +/* f141ba4: afb7004c */ sw $s7,0x4c($sp) +/* f141ba8: afb60048 */ sw $s6,0x48($sp) +/* f141bac: afb50044 */ sw $s5,0x44($sp) +/* f141bb0: afb40040 */ sw $s4,0x40($sp) +/* f141bb4: afb3003c */ sw $s3,0x3c($sp) +/* f141bb8: afb20038 */ sw $s2,0x38($sp) +/* f141bbc: afb00030 */ sw $s0,0x30($sp) +/* f141bc0: 0c002b27 */ jal viGetBackBuffer +/* f141bc4: f7b40028 */ sdc1 $f20,0x28($sp) +/* f141bc8: 0c002f9b */ jal viGetViewHeight +/* f141bcc: afa2005c */ sw $v0,0x5c($sp) +/* f141bd0: 0c002f97 */ jal viGetViewWidth +/* f141bd4: 00408025 */ or $s0,$v0,$zero +/* f141bd8: 0c002fb9 */ jal viGetViewTop +/* f141bdc: 0040b025 */ or $s6,$v0,$zero +/* f141be0: 0c002fb5 */ jal viGetViewLeft +/* f141be4: 00409825 */ or $s3,$v0,$zero +/* f141be8: 3c038008 */ lui $v1,0x8008 +/* f141bec: 246320a0 */ addiu $v1,$v1,0x20a0 +/* f141bf0: 8c6e0000 */ lw $t6,0x0($v1) +/* f141bf4: 0270a021 */ addu $s4,$s3,$s0 +/* f141bf8: 0040b825 */ or $s7,$v0,$zero +/* f141bfc: 25cf0001 */ addiu $t7,$t6,0x1 +/* f141c00: 29e10002 */ slti $at,$t7,0x2 +/* f141c04: 0280f025 */ or $s8,$s4,$zero +/* f141c08: 14200003 */ bnez $at,.NB0f141c18 +/* f141c0c: ac6f0000 */ sw $t7,0x0($v1) +/* f141c10: 1000006f */ beqz $zero,.NB0f141dd0 +/* f141c14: 02201025 */ or $v0,$s1,$zero +.NB0f141c18: +/* f141c18: 3c04800b */ lui $a0,0x800b +/* f141c1c: 3c057f1b */ lui $a1,0x7f1b +/* f141c20: 24a503a0 */ addiu $a1,$a1,0x3a0 +/* f141c24: 0c004e60 */ jal strcpy +/* f141c28: 24848780 */ addiu $a0,$a0,-30848 +/* f141c2c: 241900bc */ addiu $t9,$zero,0xbc +/* f141c30: 3c01800a */ lui $at,0x800a +/* f141c34: a039122c */ sb $t9,0x122c($at) +/* f141c38: 3c01800a */ lui $at,0x800a +/* f141c3c: 240800be */ addiu $t0,$zero,0xbe +/* f141c40: a028122f */ sb $t0,0x122f($at) +/* f141c44: 3c01800a */ lui $at,0x800a +/* f141c48: 240900de */ addiu $t1,$zero,0xde +/* f141c4c: a0291230 */ sb $t1,0x1230($at) +/* f141c50: 3c01800a */ lui $at,0x800a +/* f141c54: 240a0050 */ addiu $t2,$zero,0x50 +/* f141c58: a02a122d */ sb $t2,0x122d($at) +/* f141c5c: 3c10800a */ lui $s0,0x800a +/* f141c60: 3c01800a */ lui $at,0x800a +/* f141c64: 240b00c0 */ addiu $t3,$zero,0xc0 +/* f141c68: 2610e6c0 */ addiu $s0,$s0,-6464 +/* f141c6c: a02b122e */ sb $t3,0x122e($at) +/* f141c70: 8e0c0284 */ lw $t4,0x284($s0) +/* f141c74: 8d8d00bc */ lw $t5,0xbc($t4) +/* f141c78: 0fc00270 */ jal func0f0009c0 +/* f141c7c: 85a40028 */ lh $a0,0x28($t5) +/* f141c80: 28410081 */ slti $at,$v0,0x81 +/* f141c84: 14200004 */ bnez $at,.NB0f141c98 +/* f141c88: 00402025 */ or $a0,$v0,$zero +/* f141c8c: 00402825 */ or $a1,$v0,$zero +/* f141c90: 0fc487dd */ jal func0f127334 +/* f141c94: 00403025 */ or $a2,$v0,$zero +.NB0f141c98: +/* f141c98: 8e0e0288 */ lw $t6,0x288($s0) +/* f141c9c: 3c19800a */ lui $t9,0x800a +/* f141ca0: 02202025 */ or $a0,$s1,$zero +/* f141ca4: 8dcf0070 */ lw $t7,0x70($t6) +/* f141ca8: 3c0500ff */ lui $a1,0xff +/* f141cac: 000fc0c0 */ sll $t8,$t7,0x3 +/* f141cb0: 030fc023 */ subu $t8,$t8,$t7 +/* f141cb4: 0018c0c0 */ sll $t8,$t8,0x3 +/* f141cb8: 030fc023 */ subu $t8,$t8,$t7 +/* f141cbc: 0018c100 */ sll $t8,$t8,0x4 +/* f141cc0: 030fc023 */ subu $t8,$t8,$t7 +/* f141cc4: 0018c080 */ sll $t8,$t8,0x2 +/* f141cc8: 0338c821 */ addu $t9,$t9,$t8 +/* f141ccc: 8f392c48 */ lw $t9,0x2c48($t9) +/* f141cd0: 57200005 */ bnezl $t9,.NB0f141ce8 +/* f141cd4: 02201025 */ or $v0,$s1,$zero +/* f141cd8: 0fc4f3ca */ jal bviewRenderMotionBlur +/* f141cdc: 24060060 */ addiu $a2,$zero,0x60 +/* f141ce0: 00408825 */ or $s1,$v0,$zero +/* f141ce4: 02201025 */ or $v0,$s1,$zero +.NB0f141ce8: +/* f141ce8: 3c08e700 */ lui $t0,0xe700 +/* f141cec: ac480000 */ sw $t0,0x0($v0) +/* f141cf0: ac400004 */ sw $zero,0x4($v0) +/* f141cf4: 26240008 */ addiu $a0,$s1,0x8 +/* f141cf8: 2405ffff */ addiu $a1,$zero,-1 +/* f141cfc: 0fc4f2e8 */ jal bviewPrepareStaticRgba16 +/* f141d00: 240600ff */ addiu $a2,$zero,0xff +/* f141d04: 3c128008 */ lui $s2,0x8008 +/* f141d08: 265220d8 */ addiu $s2,$s2,0x20d8 +/* f141d0c: 92490000 */ lbu $t1,0x0($s2) +/* f141d10: 0274082a */ slt $at,$s3,$s4 +/* f141d14: 00408825 */ or $s1,$v0,$zero +/* f141d18: 252a0001 */ addiu $t2,$t1,0x1 +/* f141d1c: a24a0000 */ sb $t2,0x0($s2) +/* f141d20: 1020002a */ beqz $at,.NB0f141dcc +/* f141d24: 02608025 */ or $s0,$s3,$zero +/* f141d28: 3c013f80 */ lui $at,0x3f80 +/* f141d2c: 4481a000 */ mtc1 $at,$f20 +/* f141d30: 3c15fb00 */ lui $s5,0xfb00 +/* f141d34: 2414000c */ addiu $s4,$zero,0xc +/* f141d38: 241300ff */ addiu $s3,$zero,0xff +.NB0f141d3c: +/* f141d3c: 924c0000 */ lbu $t4,0x0($s2) +/* f141d40: 320b0001 */ andi $t3,$s0,0x1 +/* f141d44: 24030094 */ addiu $v1,$zero,0x94 +/* f141d48: 318d0001 */ andi $t5,$t4,0x1 +/* f141d4c: 116d000e */ beq $t3,$t5,.NB0f141d88 +/* f141d50: 00000000 */ sll $zero,$zero,0x0 +/* f141d54: 0c004d84 */ jal random +/* f141d58: 00000000 */ sll $zero,$zero,0x0 +/* f141d5c: 0054001b */ divu $zero,$v0,$s4 +/* f141d60: 00007810 */ mfhi $t7 +/* f141d64: 31f800ff */ andi $t8,$t7,0xff +/* f141d68: 02781823 */ subu $v1,$s3,$t8 +/* f141d6c: 307900ff */ andi $t9,$v1,0xff +/* f141d70: 16800002 */ bnez $s4,.NB0f141d7c +/* f141d74: 00000000 */ sll $zero,$zero,0x0 +/* f141d78: 0007000d */ break 0x7 +.NB0f141d7c: +/* f141d7c: 03201825 */ or $v1,$t9,$zero +/* f141d80: 10000002 */ beqz $zero,.NB0f141d8c +/* f141d84: 02201025 */ or $v0,$s1,$zero +.NB0f141d88: +/* f141d88: 02201025 */ or $v0,$s1,$zero +.NB0f141d8c: +/* f141d8c: 00034400 */ sll $t0,$v1,0x10 +/* f141d90: 250900ff */ addiu $t1,$t0,0xff +/* f141d94: ac490004 */ sw $t1,0x4($v0) +/* f141d98: ac550000 */ sw $s5,0x0($v0) +/* f141d9c: 26240008 */ addiu $a0,$s1,0x8 +/* f141da0: afb6001c */ sw $s6,0x1c($sp) +/* f141da4: afb70018 */ sw $s7,0x18($sp) +/* f141da8: e7b40014 */ swc1 $f20,0x14($sp) +/* f141dac: afb00010 */ sw $s0,0x10($sp) +/* f141db0: 8fa5005c */ lw $a1,0x5c($sp) +/* f141db4: 02003025 */ or $a2,$s0,$zero +/* f141db8: 0fc4f168 */ jal bviewRenderLensRect +/* f141dbc: 24070005 */ addiu $a3,$zero,0x5 +/* f141dc0: 26100001 */ addiu $s0,$s0,0x1 +/* f141dc4: 161effdd */ bne $s0,$s8,.NB0f141d3c +/* f141dc8: 00408825 */ or $s1,$v0,$zero +.NB0f141dcc: +/* f141dcc: 02201025 */ or $v0,$s1,$zero +.NB0f141dd0: +/* f141dd0: 8fbf0054 */ lw $ra,0x54($sp) +/* f141dd4: d7b40028 */ ldc1 $f20,0x28($sp) +/* f141dd8: 8fb00030 */ lw $s0,0x30($sp) +/* f141ddc: 8fb10034 */ lw $s1,0x34($sp) +/* f141de0: 8fb20038 */ lw $s2,0x38($sp) +/* f141de4: 8fb3003c */ lw $s3,0x3c($sp) +/* f141de8: 8fb40040 */ lw $s4,0x40($sp) +/* f141dec: 8fb50044 */ lw $s5,0x44($sp) +/* f141df0: 8fb60048 */ lw $s6,0x48($sp) +/* f141df4: 8fb7004c */ lw $s7,0x4c($sp) +/* f141df8: 8fbe0050 */ lw $s8,0x50($sp) +/* f141dfc: 03e00008 */ jr $ra +/* f141e00: 27bd0060 */ addiu $sp,$sp,0x60 +); +#endif // Mismatch because var8009caec and friends needs to be moved into this file, // and regalloc near random(). diff --git a/src/game/bondwalk.c b/src/game/bondwalk.c index de6242c14..615a21dda 100644 --- a/src/game/bondwalk.c +++ b/src/game/bondwalk.c @@ -344,7 +344,11 @@ void bwalk0f0c3b38(struct coord *reltarget, struct defaultobj *obj) abstarget.y = g_Vars.currentplayer->prop->pos.y; abstarget.z = reltarget->z + g_Vars.currentplayer->prop->pos.z; +#if VERSION >= VERSION_NTSC_1_0 cd00024e4c(&globalthinga, &globalthingb, 223, "bondwalk.c"); +#else + cd00024e4c(&globalthinga, &globalthingb, 221, "bondwalk.c"); +#endif vector.x = globalthingb.z - globalthinga.z; vector.y = 0; @@ -1193,7 +1197,7 @@ glabel bwalkCalculateNewPositionWithPush /* f0c475c: 03e00008 */ jr $ra /* f0c4760: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel bwalkCalculateNewPositionWithPush /* f0c4250: 27bdff58 */ addiu $sp,$sp,-168 @@ -1536,6 +1540,349 @@ glabel bwalkCalculateNewPositionWithPush /* f0c475c: 03e00008 */ jr $ra /* f0c4760: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel bwalkCalculateNewPositionWithPush +/* f0c4250: 27bdff58 */ addiu $sp,$sp,-168 +/* f0c4254: 8fae00b8 */ lw $t6,0xb8($sp) +/* f0c4258: afbf0024 */ sw $ra,0x24($sp) +/* f0c425c: afa400a8 */ sw $a0,0xa8($sp) +/* f0c4260: afa500ac */ sw $a1,0xac($sp) +/* f0c4264: afa600b0 */ sw $a2,0xb0($sp) +/* f0c4268: afa700b4 */ sw $a3,0xb4($sp) +/* f0c426c: 0fc30f85 */ jal bwalkCalculateNewPosition +/* f0c4270: afae0010 */ sw $t6,0x10($sp) +/* f0c4274: 24010001 */ addiu $at,$zero,0x1 +/* f0c4278: 10410135 */ beq $v0,$at,.L0f0c4750 +/* f0c427c: afa200a4 */ sw $v0,0xa4($sp) +/* f0c4280: 0c0093ac */ jal cdGetObstacle +/* f0c4284: 00000000 */ nop +/* f0c4288: 10400131 */ beqz $v0,.L0f0c4750 +/* f0c428c: afa200a0 */ sw $v0,0xa0($sp) +/* f0c4290: 3c08800a */ lui $t0,%hi(g_Vars) +/* f0c4294: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f0c4298: 8d0f0034 */ lw $t7,0x34($t0) +/* f0c429c: 59e0012d */ blezl $t7,.L0f0c4754 +/* f0c42a0: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c42a4: 90430000 */ lbu $v1,0x0($v0) +/* f0c42a8: 24010002 */ addiu $at,$zero,0x2 +/* f0c42ac: 54610046 */ bnel $v1,$at,.L0f0c43c8 +/* f0c42b0: 24010003 */ addiu $at,$zero,0x3 +/* f0c42b4: 8c430004 */ lw $v1,0x4($v0) +/* f0c42b8: 94780070 */ lhu $t8,0x70($v1) +/* f0c42bc: 33190400 */ andi $t9,$t8,0x400 +/* f0c42c0: 53200124 */ beqzl $t9,.L0f0c4754 +/* f0c42c4: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c42c8: 8d090284 */ lw $t1,0x284($t0) +/* f0c42cc: 27a40084 */ addiu $a0,$sp,0x84 +/* f0c42d0: 27a50078 */ addiu $a1,$sp,0x78 +/* f0c42d4: 8d2a00d8 */ lw $t2,0xd8($t1) +/* f0c42d8: 240601d1 */ addiu $a2,$zero,0x1cc +/* f0c42dc: 3c077f1b */ lui $a3,%hi(var7f1ad75c) +/* f0c42e0: 5540011c */ bnezl $t2,.L0f0c4754 +/* f0c42e4: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c42e8: 0c009393 */ jal cd00024e4c +/* f0c42ec: 24e7d75c */ addiu $a3,$a3,%lo(var7f1ad75c) +/* f0c42f0: c7a40080 */ lwc1 $f4,0x80($sp) +/* f0c42f4: c7a6008c */ lwc1 $f6,0x8c($sp) +/* f0c42f8: 44801000 */ mtc1 $zero,$f2 +/* f0c42fc: c7a80084 */ lwc1 $f8,0x84($sp) +/* f0c4300: 46062001 */ sub.s $f0,$f4,$f6 +/* f0c4304: c7aa0078 */ lwc1 $f10,0x78($sp) +/* f0c4308: 3c08800a */ lui $t0,%hi(g_Vars) +/* f0c430c: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f0c4310: 46001032 */ c.eq.s $f2,$f0 +/* f0c4314: e7a00090 */ swc1 $f0,0x90($sp) +/* f0c4318: 460a4101 */ sub.s $f4,$f8,$f10 +/* f0c431c: 27a40090 */ addiu $a0,$sp,0x90 +/* f0c4320: e7a20094 */ swc1 $f2,0x94($sp) +/* f0c4324: 45000004 */ bc1f .L0f0c4338 +/* f0c4328: e7a40098 */ swc1 $f4,0x98($sp) +/* f0c432c: 46041032 */ c.eq.s $f2,$f4 +/* f0c4330: 3c013f80 */ lui $at,0x3f80 +/* f0c4334: 45010006 */ bc1t .L0f0c4350 +.L0f0c4338: +/* f0c4338: 27a50094 */ addiu $a1,$sp,0x94 +/* f0c433c: 0c0011e4 */ jal guNormalize +/* f0c4340: 27a60098 */ addiu $a2,$sp,0x98 +/* f0c4344: 3c08800a */ lui $t0,%hi(g_Vars) +/* f0c4348: 10000004 */ b .L0f0c435c +/* f0c434c: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +.L0f0c4350: +/* f0c4350: 44813000 */ mtc1 $at,$f6 +/* f0c4354: 00000000 */ nop +/* f0c4358: e7a60098 */ swc1 $f6,0x98($sp) +.L0f0c435c: +/* f0c435c: 8d0b0284 */ lw $t3,0x284($t0) +/* f0c4360: 3c053ecc */ lui $a1,0x3ecc +/* f0c4364: 34a5cccd */ ori $a1,$a1,0xcccd +/* f0c4368: 8d6200bc */ lw $v0,0xbc($t3) +/* f0c436c: 27a60090 */ addiu $a2,$sp,0x90 +/* f0c4370: 00003825 */ or $a3,$zero,$zero +/* f0c4374: 8c440004 */ lw $a0,0x4($v0) +/* f0c4378: 0fc0d05f */ jal chrDamageByLaser +/* f0c437c: afa20010 */ sw $v0,0x10($sp) +/* f0c4380: 3c01bf80 */ lui $at,0xbf80 +/* f0c4384: 44814000 */ mtc1 $at,$f8 +/* f0c4388: 3c048009 */ lui $a0,%hi(var80095200) +/* f0c438c: 240cffff */ addiu $t4,$zero,-1 +/* f0c4390: 240dffff */ addiu $t5,$zero,-1 +/* f0c4394: 240effff */ addiu $t6,$zero,-1 +/* f0c4398: afae001c */ sw $t6,0x1c($sp) +/* f0c439c: afad0018 */ sw $t5,0x18($sp) +/* f0c43a0: afac0010 */ sw $t4,0x10($sp) +/* f0c43a4: 8c845200 */ lw $a0,%lo(var80095200)($a0) +/* f0c43a8: 240500f2 */ addiu $a1,$zero,0xf2 +/* f0c43ac: 00003025 */ or $a2,$zero,$zero +/* f0c43b0: 2407ffff */ addiu $a3,$zero,-1 +/* f0c43b4: 0c004241 */ jal sndStart +/* f0c43b8: e7a80014 */ swc1 $f8,0x14($sp) +/* f0c43bc: 100000e5 */ b .L0f0c4754 +/* f0c43c0: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c43c4: 24010003 */ addiu $at,$zero,0x3 +.L0f0c43c8: +/* f0c43c8: 5461008b */ bnel $v1,$at,.L0f0c45f8 +/* f0c43cc: 24010006 */ addiu $at,$zero,0x6 +/* f0c43d0: 8d180318 */ lw $t8,0x318($t0) +/* f0c43d4: 8c4f0004 */ lw $t7,0x4($v0) +/* f0c43d8: 00001825 */ or $v1,$zero,$zero +/* f0c43dc: 1300000c */ beqz $t8,.L0f0c4410 +/* f0c43e0: afaf0074 */ sw $t7,0x74($sp) +/* f0c43e4: 8d190284 */ lw $t9,0x284($t0) +/* f0c43e8: 01e02825 */ or $a1,$t7,$zero +/* f0c43ec: 24060001 */ addiu $a2,$zero,0x1 +/* f0c43f0: 8f2900bc */ lw $t1,0xbc($t9) +/* f0c43f4: 8d240004 */ lw $a0,0x4($t1) +/* f0c43f8: 0fc12aa3 */ jal chrCompareTeams +/* f0c43fc: afa00044 */ sw $zero,0x44($sp) +/* f0c4400: 10400014 */ beqz $v0,.L0f0c4454 +/* f0c4404: 8fa30044 */ lw $v1,0x44($sp) +/* f0c4408: 10000012 */ b .L0f0c4454 +/* f0c440c: 24030001 */ addiu $v1,$zero,0x1 +.L0f0c4410: +/* f0c4410: 8faa0074 */ lw $t2,0x74($sp) +/* f0c4414: 8d4b0018 */ lw $t3,0x18($t2) +/* f0c4418: 000b61c0 */ sll $t4,$t3,0x7 +/* f0c441c: 0581000d */ bgez $t4,.L0f0c4454 +/* f0c4420: 00000000 */ nop +/* f0c4424: 8d0d029c */ lw $t5,0x29c($t0) +/* f0c4428: 05a2000a */ bltzl $t5,.L0f0c4454 +/* f0c442c: 24030001 */ addiu $v1,$zero,0x1 +/* f0c4430: 8d0e02a8 */ lw $t6,0x2a8($t0) +/* f0c4434: 8d0f0284 */ lw $t7,0x284($t0) +/* f0c4438: 55cf0006 */ bnel $t6,$t7,.L0f0c4454 +/* f0c443c: 24030001 */ addiu $v1,$zero,0x1 +/* f0c4440: 8d580014 */ lw $t8,0x14($t2) +/* f0c4444: 0018c840 */ sll $t9,$t8,0x1 +/* f0c4448: 07200002 */ bltz $t9,.L0f0c4454 +/* f0c444c: 00000000 */ nop +/* f0c4450: 24030001 */ addiu $v1,$zero,0x1 +.L0f0c4454: +/* f0c4454: 106000be */ beqz $v1,.L0f0c4750 +/* f0c4458: 8fa200a8 */ lw $v0,0xa8($sp) +/* f0c445c: c4400008 */ lwc1 $f0,0x8($v0) +/* f0c4460: c4420000 */ lwc1 $f2,0x0($v0) +/* f0c4464: 46000282 */ mul.s $f10,$f0,$f0 +/* f0c4468: 00000000 */ nop +/* f0c446c: 46021102 */ mul.s $f4,$f2,$f2 +/* f0c4470: 0c012974 */ jal sqrtf +/* f0c4474: 46045300 */ add.s $f12,$f10,$f4 +/* f0c4478: 3c08800a */ lui $t0,%hi(g_Vars) +/* f0c447c: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f0c4480: c5060044 */ lwc1 $f6,0x44($t0) +/* f0c4484: 8d090284 */ lw $t1,0x284($t0) +/* f0c4488: 8fa300a0 */ lw $v1,0xa0($sp) +/* f0c448c: 46060203 */ div.s $f8,$f0,$f6 +/* f0c4490: 44801000 */ mtc1 $zero,$f2 +/* f0c4494: e7a80054 */ swc1 $f8,0x54($sp) +/* f0c4498: 8d2200bc */ lw $v0,0xbc($t1) +/* f0c449c: c46a0008 */ lwc1 $f10,0x8($v1) +/* f0c44a0: c4660010 */ lwc1 $f6,0x10($v1) +/* f0c44a4: c4440008 */ lwc1 $f4,0x8($v0) +/* f0c44a8: c4480010 */ lwc1 $f8,0x10($v0) +/* f0c44ac: 46045381 */ sub.s $f14,$f10,$f4 +/* f0c44b0: 46083401 */ sub.s $f16,$f6,$f8 +/* f0c44b4: 46027032 */ c.eq.s $f14,$f2 +/* f0c44b8: 00000000 */ nop +/* f0c44bc: 45000005 */ bc1f .L0f0c44d4 +/* f0c44c0: 00000000 */ nop +/* f0c44c4: 46028032 */ c.eq.s $f16,$f2 +/* f0c44c8: 00000000 */ nop +/* f0c44cc: 450300a1 */ bc1tl .L0f0c4754 +/* f0c44d0: 8fbf0024 */ lw $ra,0x24($sp) +.L0f0c44d4: +/* f0c44d4: 460e7282 */ mul.s $f10,$f14,$f14 +/* f0c44d8: e7ae0050 */ swc1 $f14,0x50($sp) +/* f0c44dc: e7b0004c */ swc1 $f16,0x4c($sp) +/* f0c44e0: 46108102 */ mul.s $f4,$f16,$f16 +/* f0c44e4: 0c012974 */ jal sqrtf +/* f0c44e8: 46045300 */ add.s $f12,$f10,$f4 +/* f0c44ec: 44801000 */ mtc1 $zero,$f2 +/* f0c44f0: 3c08800a */ lui $t0,%hi(g_Vars) +/* f0c44f4: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f0c44f8: 4600103c */ c.lt.s $f2,$f0 +/* f0c44fc: c7ae0050 */ lwc1 $f14,0x50($sp) +/* f0c4500: c7b0004c */ lwc1 $f16,0x4c($sp) +/* f0c4504: c7a60054 */ lwc1 $f6,0x54($sp) +/* f0c4508: 45020092 */ bc1fl .L0f0c4754 +/* f0c450c: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c4510: 46003303 */ div.s $f12,$f6,$f0 +/* f0c4514: 3c013f00 */ lui $at,0x3f00 +/* f0c4518: 44819000 */ mtc1 $at,$f18 +/* f0c451c: 8fa40074 */ lw $a0,0x74($sp) +/* f0c4520: 8fa200a0 */ lw $v0,0xa0($sp) +/* f0c4524: 27a50068 */ addiu $a1,$sp,0x68 +/* f0c4528: 27a60058 */ addiu $a2,$sp,0x58 +/* f0c452c: 00003825 */ or $a3,$zero,$zero +/* f0c4530: 460c7382 */ mul.s $f14,$f14,$f12 +/* f0c4534: 00000000 */ nop +/* f0c4538: 460c8402 */ mul.s $f16,$f16,$f12 +/* f0c453c: 00000000 */ nop +/* f0c4540: 460e9082 */ mul.s $f2,$f18,$f14 +/* f0c4544: 00000000 */ nop +/* f0c4548: 46109202 */ mul.s $f8,$f18,$f16 +/* f0c454c: e4820304 */ swc1 $f2,0x304($a0) +/* f0c4550: e4880308 */ swc1 $f8,0x308($a0) +/* f0c4554: c5000044 */ lwc1 $f0,0x44($t0) +/* f0c4558: c4440008 */ lwc1 $f4,0x8($v0) +/* f0c455c: 46001282 */ mul.s $f10,$f2,$f0 +/* f0c4560: 46045180 */ add.s $f6,$f10,$f4 +/* f0c4564: e7a60068 */ swc1 $f6,0x68($sp) +/* f0c4568: c448000c */ lwc1 $f8,0xc($v0) +/* f0c456c: e7a8006c */ swc1 $f8,0x6c($sp) +/* f0c4570: c48a0308 */ lwc1 $f10,0x308($a0) +/* f0c4574: c4460010 */ lwc1 $f6,0x10($v0) +/* f0c4578: 46005102 */ mul.s $f4,$f10,$f0 +/* f0c457c: 46062200 */ add.s $f8,$f4,$f6 +/* f0c4580: 0fc079fd */ jal chrCalculatePushPos +/* f0c4584: e7a80070 */ swc1 $f8,0x70($sp) +/* f0c4588: 8fa400a0 */ lw $a0,0xa0($sp) +/* f0c458c: c7aa0068 */ lwc1 $f10,0x68($sp) +/* f0c4590: e48a0008 */ swc1 $f10,0x8($a0) +/* f0c4594: c7a4006c */ lwc1 $f4,0x6c($sp) +/* f0c4598: e484000c */ swc1 $f4,0xc($a0) +/* f0c459c: c7a60070 */ lwc1 $f6,0x70($sp) +/* f0c45a0: 0fc19711 */ jal propDeregisterRooms +/* f0c45a4: e4860010 */ swc1 $f6,0x10($a0) +/* f0c45a8: 8fa500a0 */ lw $a1,0xa0($sp) +/* f0c45ac: 27a40058 */ addiu $a0,$sp,0x58 +/* f0c45b0: 0fc195e9 */ jal roomsCopy +/* f0c45b4: 24a50028 */ addiu $a1,$a1,0x28 +/* f0c45b8: 0fc0882b */ jal func0f0220ac +/* f0c45bc: 8fa40074 */ lw $a0,0x74($sp) +/* f0c45c0: 8fab0074 */ lw $t3,0x74($sp) +/* f0c45c4: 27a50068 */ addiu $a1,$sp,0x68 +/* f0c45c8: 0c006b4d */ jal modelSetRootPosition +/* f0c45cc: 8d640020 */ lw $a0,0x20($t3) +/* f0c45d0: 8fac00b8 */ lw $t4,0xb8($sp) +/* f0c45d4: 8fa400a8 */ lw $a0,0xa8($sp) +/* f0c45d8: 8fa500ac */ lw $a1,0xac($sp) +/* f0c45dc: 8fa600b0 */ lw $a2,0xb0($sp) +/* f0c45e0: 8fa700b4 */ lw $a3,0xb4($sp) +/* f0c45e4: 0fc30f85 */ jal bwalkCalculateNewPosition +/* f0c45e8: afac0010 */ sw $t4,0x10($sp) +/* f0c45ec: 10000058 */ b .L0f0c4750 +/* f0c45f0: afa200a4 */ sw $v0,0xa4($sp) +/* f0c45f4: 24010006 */ addiu $at,$zero,0x6 +.L0f0c45f8: +/* f0c45f8: 10610055 */ beq $v1,$at,.L0f0c4750 +/* f0c45fc: 24010001 */ addiu $at,$zero,0x1 +/* f0c4600: 54610054 */ bnel $v1,$at,.L0f0c4754 +/* f0c4604: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c4608: 8c460004 */ lw $a2,0x4($v0) +/* f0c460c: 8cc30040 */ lw $v1,0x40($a2) +/* f0c4610: 00036940 */ sll $t5,$v1,0x5 +/* f0c4614: 05a0004e */ bltz $t5,.L0f0c4750 +/* f0c4618: 00037100 */ sll $t6,$v1,0x4 +/* f0c461c: 05c2004d */ bltzl $t6,.L0f0c4754 +/* f0c4620: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c4624: 8d030284 */ lw $v1,0x284($t0) +/* f0c4628: 8c6f1af0 */ lw $t7,0x1af0($v1) +/* f0c462c: 55e00008 */ bnezl $t7,.L0f0c4650 +/* f0c4630: 8cd80010 */ lw $t8,0x10($a2) +/* f0c4634: 90ca0003 */ lbu $t2,0x3($a2) +/* f0c4638: 2401002d */ addiu $at,$zero,0x2d +/* f0c463c: 55410004 */ bnel $t2,$at,.L0f0c4650 +/* f0c4640: 8cd80010 */ lw $t8,0x10($a2) +/* f0c4644: 10000042 */ b .L0f0c4750 +/* f0c4648: ac621aec */ sw $v0,0x1aec($v1) +/* f0c464c: 8cd80010 */ lw $t8,0x10($a2) +.L0f0c4650: +/* f0c4650: 33190001 */ andi $t9,$t8,0x1 +/* f0c4654: 5320003f */ beqzl $t9,.L0f0c4754 +/* f0c4658: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c465c: ac600178 */ sw $zero,0x178($v1) +/* f0c4660: 8cc90040 */ lw $t1,0x40($a2) +/* f0c4664: 24020001 */ addiu $v0,$zero,0x1 +/* f0c4668: 8fa400a8 */ lw $a0,0xa8($sp) +/* f0c466c: 312b0080 */ andi $t3,$t1,0x80 +/* f0c4670: 11600007 */ beqz $t3,.L0f0c4690 +/* f0c4674: 00c02825 */ or $a1,$a2,$zero +/* f0c4678: 8ccc0048 */ lw $t4,0x48($a2) +/* f0c467c: 8d8d0000 */ lw $t5,0x0($t4) +/* f0c4680: 31ae1000 */ andi $t6,$t5,0x1000 +/* f0c4684: 11c00002 */ beqz $t6,.L0f0c4690 +/* f0c4688: 00000000 */ nop +/* f0c468c: 00001025 */ or $v0,$zero,$zero +.L0f0c4690: +/* f0c4690: 50400030 */ beqzl $v0,.L0f0c4754 +/* f0c4694: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c4698: 0fc30ece */ jal bwalk0f0c3b38 +/* f0c469c: afa60040 */ sw $a2,0x40($sp) +/* f0c46a0: 8fa60040 */ lw $a2,0x40($sp) +/* f0c46a4: 8ccf0040 */ lw $t7,0x40($a2) +/* f0c46a8: 31ea0080 */ andi $t2,$t7,0x80 +/* f0c46ac: 51400029 */ beqzl $t2,.L0f0c4754 +/* f0c46b0: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c46b4: 8cd80048 */ lw $t8,0x48($a2) +/* f0c46b8: 00c02025 */ or $a0,$a2,$zero +/* f0c46bc: 27a50034 */ addiu $a1,$sp,0x34 +/* f0c46c0: 8f190000 */ lw $t9,0x0($t8) +/* f0c46c4: 33290800 */ andi $t1,$t9,0x800 +/* f0c46c8: 51200022 */ beqzl $t1,.L0f0c4754 +/* f0c46cc: 8fbf0024 */ lw $ra,0x24($sp) +/* f0c46d0: afa00034 */ sw $zero,0x34($sp) +/* f0c46d4: 0fc1cf1b */ jal func0f073c6c +/* f0c46d8: afa60040 */ sw $a2,0x40($sp) +/* f0c46dc: 8fa60040 */ lw $a2,0x40($sp) +/* f0c46e0: 8ccb0040 */ lw $t3,0x40($a2) +/* f0c46e4: 316c0080 */ andi $t4,$t3,0x80 +/* f0c46e8: 11800010 */ beqz $t4,.L0f0c472c +/* f0c46ec: 00000000 */ nop +/* f0c46f0: 8cc30048 */ lw $v1,0x48($a2) +/* f0c46f4: 8c6d0000 */ lw $t5,0x0($v1) +/* f0c46f8: 35ae1000 */ ori $t6,$t5,0x1000 +/* f0c46fc: 10400006 */ beqz $v0,.L0f0c4718 +/* f0c4700: ac6e0000 */ sw $t6,0x0($v1) +/* f0c4704: 8cc30048 */ lw $v1,0x48($a2) +/* f0c4708: 8c6f0000 */ lw $t7,0x0($v1) +/* f0c470c: 35ea2000 */ ori $t2,$t7,0x2000 +/* f0c4710: 10000006 */ b .L0f0c472c +/* f0c4714: ac6a0000 */ sw $t2,0x0($v1) +.L0f0c4718: +/* f0c4718: 8cc30048 */ lw $v1,0x48($a2) +/* f0c471c: 2401dfff */ addiu $at,$zero,-8193 +/* f0c4720: 8c780000 */ lw $t8,0x0($v1) +/* f0c4724: 0301c824 */ and $t9,$t8,$at +/* f0c4728: ac790000 */ sw $t9,0x0($v1) +.L0f0c472c: +/* f0c472c: 10400008 */ beqz $v0,.L0f0c4750 +/* f0c4730: 8fa400a8 */ lw $a0,0xa8($sp) +/* f0c4734: 8fa900b8 */ lw $t1,0xb8($sp) +/* f0c4738: 8fa500ac */ lw $a1,0xac($sp) +/* f0c473c: 8fa600b0 */ lw $a2,0xb0($sp) +/* f0c4740: 8fa700b4 */ lw $a3,0xb4($sp) +/* f0c4744: 0fc30f85 */ jal bwalkCalculateNewPosition +/* f0c4748: afa90010 */ sw $t1,0x10($sp) +/* f0c474c: afa200a4 */ sw $v0,0xa4($sp) +.L0f0c4750: +/* f0c4750: 8fbf0024 */ lw $ra,0x24($sp) +.L0f0c4754: +/* f0c4754: 8fa200a4 */ lw $v0,0xa4($sp) +/* f0c4758: 27bd00a8 */ addiu $sp,$sp,0xa8 +/* f0c475c: 03e00008 */ jr $ra +/* f0c4760: 00000000 */ nop +); #endif // Mismatch: The below loads 0.5f twice in the chr push code while goal reuses it. @@ -1686,7 +2033,11 @@ s32 bwalk0f0c4764(struct coord *delta, struct coord *arg1, struct coord *arg2, s s32 result = bwalkCalculateNewPositionWithPush(delta, 0, true, 0, types); if (result == CDRESULT_COLLISION) { - cd00024e4c(arg1, arg2, 0x25f, "bondwalk.c"); +#if VERSION >= VERSION_NTSC_1_0 + cd00024e4c(arg1, arg2, 607, "bondwalk.c"); +#else + cd00024e4c(arg1, arg2, 602, "bondwalk.c"); +#endif } return result; @@ -1710,7 +2061,11 @@ s32 bwalk0f0c47d0(struct coord *a, struct coord *b, struct coord *c, } if (result == CDRESULT_COLLISION) { - cd00024e4c(d, e, 0x27b, "bondwalk.c"); +#if VERSION >= VERSION_NTSC_1_0 + cd00024e4c(d, e, 635, "bondwalk.c"); +#else + cd00024e4c(d, e, 630, "bondwalk.c"); +#endif if (b->x != d->x || b->y != d->y @@ -6984,9 +7339,6 @@ u32 var80070e70 = 0x00000000; void bwalkTick(void) { - s32 i; - struct coord sStack16; - bwalkUpdatePrevPos(); bwalkUpdateTheta(); bmoveUpdateVerta(); @@ -6994,12 +7346,16 @@ void bwalkTick(void) bwalkUpdateVertical(); #if VERSION >= VERSION_NTSC_1_0 - for (i = 0; g_Vars.currentplayer->prop->rooms[i] != -1; i++) { - if (g_Vars.currentplayer->floorroom == g_Vars.currentplayer->prop->rooms[i]) { - propDeregisterRooms(g_Vars.currentplayer->prop); - g_Vars.currentplayer->prop->rooms[0] = g_Vars.currentplayer->floorroom; - g_Vars.currentplayer->prop->rooms[1] = -1; - break; + { + s32 i; + + for (i = 0; g_Vars.currentplayer->prop->rooms[i] != -1; i++) { + if (g_Vars.currentplayer->floorroom == g_Vars.currentplayer->prop->rooms[i]) { + propDeregisterRooms(g_Vars.currentplayer->prop); + g_Vars.currentplayer->prop->rooms[0] = g_Vars.currentplayer->floorroom; + g_Vars.currentplayer->prop->rooms[1] = -1; + break; + } } } #endif @@ -7008,16 +7364,17 @@ void bwalkTick(void) objectiveCheckRoomEntered(g_Vars.currentplayer->prop->rooms[0]); if (g_Vars.currentplayer->walkinitmove) { - sStack16.x = (g_Vars.currentplayer->walkinitstart.x - g_Vars.currentplayer->walkinitpos.x) + struct coord coord; + coord.x = (g_Vars.currentplayer->walkinitstart.x - g_Vars.currentplayer->walkinitpos.x) * (1.0f - g_Vars.currentplayer->walkinitt2) + g_Vars.currentplayer->prop->pos.x; - sStack16.y = (g_Vars.currentplayer->walkinitstart.y - g_Vars.currentplayer->prop->pos.y) + coord.y = (g_Vars.currentplayer->walkinitstart.y - g_Vars.currentplayer->prop->pos.y) * (1.0f - g_Vars.currentplayer->walkinitt2) + g_Vars.currentplayer->prop->pos.y; - sStack16.z = (g_Vars.currentplayer->walkinitstart.z - g_Vars.currentplayer->walkinitpos.z) + coord.z = (g_Vars.currentplayer->walkinitstart.z - g_Vars.currentplayer->walkinitpos.z) * (1.0f - g_Vars.currentplayer->walkinitt2) + g_Vars.currentplayer->prop->pos.z; - bmove0f0cc19c(&sStack16); + bmove0f0cc19c(&coord); } else { bmove0f0cc19c(&g_Vars.currentplayer->prop->pos); } diff --git a/src/game/casing/reset.c b/src/game/casing/reset.c index 0d76cff60..8f96fa6c5 100644 --- a/src/game/casing/reset.c +++ b/src/game/casing/reset.c @@ -4,6 +4,7 @@ #include "data.h" #include "types.h" +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel casingsReset /* f010b20: 3c04800a */ lui $a0,%hi(var8009d0d0) @@ -46,6 +47,50 @@ glabel casingsReset /* f010ba8: 03e00008 */ jr $ra /* f010bac: ac4002b4 */ sw $zero,0x2b4($v0) ); +#else +GLOBAL_ASM( +glabel casingsReset +/* f010860: 3c04800a */ lui $a0,0x800a +/* f010864: 24841868 */ addiu $a0,$a0,0x1868 +/* f010868: ac800000 */ sw $zero,0x0($a0) +/* f01086c: ac800004 */ sw $zero,0x4($a0) +/* f010870: 3c01800a */ lui $at,0x800a +/* f010874: 3c03800a */ lui $v1,0x800a +/* f010878: 3c02800a */ lui $v0,0x800a +/* f01087c: ac201870 */ sw $zero,0x1870($at) +/* f010880: 24421888 */ addiu $v0,$v0,0x1888 +/* f010884: 24631878 */ addiu $v1,$v1,0x1878 +.NB0f010888: +/* f010888: 24630004 */ addiu $v1,$v1,0x4 +/* f01088c: 1462fffe */ bne $v1,$v0,.NB0f010888 +/* f010890: ac60fffc */ sw $zero,-0x4($v1) +/* f010894: 3c02800a */ lui $v0,0x800a +/* f010898: 3c03800a */ lui $v1,0x800a +/* f01089c: 24422240 */ addiu $v0,$v0,0x2240 +/* f0108a0: 24631cf0 */ addiu $v1,$v1,0x1cf0 +.NB0f0108a4: +/* f0108a4: 24630044 */ addiu $v1,$v1,0x44 +/* f0108a8: 0062082b */ sltu $at,$v1,$v0 +/* f0108ac: 1420fffd */ bnez $at,.NB0f0108a4 +/* f0108b0: ac60fffc */ sw $zero,-0x4($v1) +/* f0108b4: 3c018007 */ lui $at,0x8007 +/* f0108b8: 3c03800a */ lui $v1,0x800a +/* f0108bc: 3c04800a */ lui $a0,0x800a +/* f0108c0: ac202be4 */ sw $zero,0x2be4($at) +/* f0108c4: 24841ce8 */ addiu $a0,$a0,0x1ce8 +/* f0108c8: 24631888 */ addiu $v1,$v1,0x1888 +/* f0108cc: 2402ffff */ addiu $v0,$zero,-1 +.NB0f0108d0: +/* f0108d0: 24630038 */ addiu $v1,$v1,0x38 +/* f0108d4: 1464fffe */ bne $v1,$a0,.NB0f0108d0 +/* f0108d8: ac62ffc8 */ sw $v0,-0x38($v1) +/* f0108dc: 3c02800a */ lui $v0,0x800a +/* f0108e0: 2442e6c0 */ addiu $v0,$v0,-6464 +/* f0108e4: ac4002b0 */ sw $zero,0x2b0($v0) +/* f0108e8: 03e00008 */ jr $ra +/* f0108ec: ac4002b4 */ sw $zero,0x2b4($v0) +); +#endif // Mismatch: Two instructions are swapped //void casingsReset(void) diff --git a/src/game/cheats.c b/src/game/cheats.c index a16c64d92..18e4d00e4 100644 --- a/src/game/cheats.c +++ b/src/game/cheats.c @@ -859,17 +859,30 @@ char *cheatGetMarquee(struct menuitem *arg0) if (g_Menus[g_MpPlayerNum].curframe->dialog == &g_CheatsBuddiesMenuDialog && g_Menus[g_MpPlayerNum].curframe->focuseditem == &g_CheatsBuddiesMenuItems[0]) { // Velvet +#if VERSION >= VERSION_NTSC_1_0 sprintf(g_CheatMarqueeString, "%s: %s", langGet(L_MPWEAPONS_143), langGet(L_MPWEAPONS_117)); // "Buddy Available", "Velvet Dark" return g_CheatMarqueeString; +#else + sprintf(g_StringPointer, "%s: %s", langGet(L_MPWEAPONS_143), langGet(L_MPWEAPONS_117)); // "Buddy Available", "Velvet Dark" + return g_StringPointer; +#endif } if (cheatIsUnlocked(cheat_id)) { // Show cheat name +#if VERSION >= VERSION_NTSC_1_0 sprintf(g_CheatMarqueeString, "%s: %s\n", g_Menus[g_MpPlayerNum].curframe->dialog == &g_CheatsBuddiesMenuDialog ? langGet(L_MPWEAPONS_143) : langGet(L_MPWEAPONS_136), // "Buddy Available", "Cheat available" langGet(g_Cheats[cheat_id].nametextid) ); return g_CheatMarqueeString; +#else + sprintf(g_StringPointer, "%s: %s\n", + g_Menus[g_MpPlayerNum].curframe->dialog == &g_CheatsBuddiesMenuDialog ? langGet(L_MPWEAPONS_143) : langGet(L_MPWEAPONS_136), // "Buddy Available", "Cheat available" + langGet(g_Cheats[cheat_id].nametextid) + ); + return g_StringPointer; +#endif } // Locked @@ -883,6 +896,7 @@ char *cheatGetMarquee(struct menuitem *arg0) *ptr = '\0'; if (g_Cheats[cheat_id].flags & CHEATFLAG_COMPLETION) { +#if VERSION >= VERSION_NTSC_1_0 sprintf(g_CheatMarqueeString, "%s %s: %s %s %s", langGet(L_MPWEAPONS_137), // "Complete" langGet(g_StageNames[g_Cheats[cheat_id].stage_index].name1), @@ -890,6 +904,15 @@ char *cheatGetMarquee(struct menuitem *arg0) langGet(L_MPWEAPONS_138), // "for cheat:" &cheatname ); +#else + sprintf(g_StringPointer, "%s %s: %s %s %s", + langGet(L_MPWEAPONS_137), // "Complete" + langGet(g_StageNames[g_Cheats[cheat_id].stage_index].name1), + langGet(g_StageNames[g_Cheats[cheat_id].stage_index].name2), + langGet(L_MPWEAPONS_138), // "for cheat:" + &cheatname + ); +#endif } else { // Timed strcpy(difficultyname, langGet(L_OPTIONS_251 + g_Cheats[cheat_id].difficulty)); @@ -901,6 +924,7 @@ char *cheatGetMarquee(struct menuitem *arg0) *ptr = '\0'; +#if VERSION >= VERSION_NTSC_1_0 sprintf(g_CheatMarqueeString, "%s %s: %s %s %s %s %d:%02d %s %s", langGet(L_MPWEAPONS_137), // "Complete" langGet(g_StageNames[g_Cheats[cheat_id].stage_index].name1), @@ -913,8 +937,23 @@ char *cheatGetMarquee(struct menuitem *arg0) langGet(L_MPWEAPONS_138), // "for cheat:" &cheatname ); +#else + sprintf(g_StringPointer, "%s %s: %s %s %s %s %d:%02d %s %s", + langGet(L_MPWEAPONS_137), // "Complete" + langGet(g_StageNames[g_Cheats[cheat_id].stage_index].name1), + langGet(g_StageNames[g_Cheats[cheat_id].stage_index].name2), + langGet(L_MPWEAPONS_139), // "on" + &difficultyname, + langGet(L_MPWEAPONS_140), // "in under" + g_Cheats[cheat_id].time / 60, + g_Cheats[cheat_id].time % 60, + langGet(L_MPWEAPONS_138), // "for cheat:" + &cheatname + ); +#endif } +#if VERSION >= VERSION_NTSC_1_0 if (g_Cheats[cheat_id].flags & CHEATFLAG_TRANSFERPAK) { strcat(g_CheatMarqueeString, langGet(L_MPWEAPONS_141)); // " or insert Game Boy ..." } @@ -922,6 +961,15 @@ char *cheatGetMarquee(struct menuitem *arg0) strcat(g_CheatMarqueeString, "\n"); return g_CheatMarqueeString; +#else + if (g_Cheats[cheat_id].flags & CHEATFLAG_TRANSFERPAK) { + strcat(g_StringPointer, langGet(L_MPWEAPONS_141)); // " or insert Game Boy ..." + } + + strcat(g_StringPointer, "\n"); + + return g_StringPointer; +#endif } // No cheat selected diff --git a/src/game/chr/chraction.c b/src/game/chr/chraction.c index ebef85c9c..7c53de10a 100644 --- a/src/game/chr/chraction.c +++ b/src/game/chr/chraction.c @@ -1589,8 +1589,10 @@ void func0f02e4f8(struct coord *arg0, struct coord *arg1, struct coord *dst) #if VERSION >= VERSION_PAL_FINAL cd00024e4c(&sp2c, &sp20, 2298, "chr/chraction.c"); -#else +#elif VERSION >= VERSION_NTSC_1_0 cd00024e4c(&sp2c, &sp20, 2298, "chraction.c"); +#else + cd00024e4c(&sp2c, &sp20, 2338, "chraction.c"); #endif func0f02e3dc(&sp2c, &sp20, arg0, arg1, dst); @@ -1621,8 +1623,10 @@ f32 func0f02e550(struct prop *prop, f32 arg1, f32 arg2, u32 arg3, f32 ymax, f32 } else { #if VERSION >= VERSION_PAL_FINAL cdGetPos(&sp3c, 2377, "chr/chraction.c"); -#else +#elif VERSION >= VERSION_NTSC_1_0 cdGetPos(&sp3c, 2377, "chraction.c"); +#else + cdGetPos(&sp3c, 2417, "chraction.c"); #endif xdiff = sp3c.x - prop->pos.x; @@ -7874,8 +7878,10 @@ bool chrTryRunFromTarget(struct chrdata *chr) ymax - prop->pos.y, ymin - prop->pos.y)) { #if VERSION >= VERSION_PAL_FINAL cdGetPos(&dst, 8793, "chr/chraction.c"); -#else +#elif VERSION >= VERSION_NTSC_1_0 cdGetPos(&dst, 8788, "chraction.c"); +#else + cdGetPos(&dst, 8782, "chraction.c"); #endif } @@ -8069,6 +8075,7 @@ s32 chrConsiderGrenadeThrow(struct chrdata *chr, u32 attackflags, u32 entityid) u32 checksum = 0; s32 *i = (s32 *)&bgInit; s32 *end = (s32 *)&bgBuildTables; + u32 stackpadding[1]; while (i < end) { checksum += *i; @@ -8110,7 +8117,6 @@ s32 chrConsiderGrenadeThrow(struct chrdata *chr, u32 attackflags, u32 entityid) // Grenade not equipped, and using a single weapon if (!done && (leftprop == NULL || rightprop == NULL)) { - u32 stackpadding[1]; struct prop *prop; u32 flags = 0; u32 stackpadding2[2]; @@ -8254,7 +8260,11 @@ bool chrTryPunch(struct chrdata *chr, u8 reverse) } else if (race == RACE_SKEDAR) { anims = g_SkedarPunchAnims; chrhitradius = 200; +#if VERSION >= VERSION_NTSC_1_0 playerhitradius = 200; +#else + playerhitradius = 350; +#endif startframe = 20; if (reverse) { @@ -17186,7 +17196,7 @@ void robotAttack(struct chrdata *chr) chr->act_robotattack.dir[0].x = 0.0f; chr->act_robotattack.dir[0].y = 0.0f; chr->act_robotattack.dir[0].z = 0.0f; - chr->act_robotattack.guntype[0] = 90; + chr->act_robotattack.guntype[0] = WEAPON_WATCHLASER; chr->act_robotattack.firing[0] = false; chr->unk348[1]->beam->age = -1; @@ -17197,7 +17207,7 @@ void robotAttack(struct chrdata *chr) chr->unk348[1]->unk10 = 0.2f; chr->unk348[1]->unk14 = 0.0f; - chr->act_robotattack.guntype[1] = 90; + chr->act_robotattack.guntype[1] = WEAPON_WATCHLASER; chr->act_robotattack.firing[1] = false; chr->act_robotattack.finished = false; chr->act_robotattack.numshots[0] = numshots; @@ -18963,7 +18973,7 @@ glabel var7f1a9244 /* f0451a0: 03e00008 */ jr $ra /* f0451a4: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f044c38 .late_rodata @@ -19338,6 +19348,381 @@ glabel var7f1a9244 /* f0451a0: 03e00008 */ jr $ra /* f0451a4: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f044c38 +.late_rodata +glabel var7f1a9238 +.word 0x3f733333 +glabel var7f1a923c +.word 0x3f733333 +glabel var7f1a9240 +.word 0x3f99999a +glabel var7f1a9244 +.word 0x3f99999a +.text +/* f044c38: 27bdff20 */ addiu $sp,$sp,-224 +/* f044c3c: afbf002c */ sw $ra,0x2c($sp) +/* f044c40: afb00028 */ sw $s0,0x28($sp) +/* f044c44: afa400e0 */ sw $a0,0xe0($sp) +/* f044c48: afa600e8 */ sw $a2,0xe8($sp) +/* f044c4c: afa700ec */ sw $a3,0xec($sp) +/* f044c50: afa000bc */ sw $zero,0xbc($sp) +/* f044c54: afa000b8 */ sw $zero,0xb8($sp) +/* f044c58: afa00084 */ sw $zero,0x84($sp) +/* f044c5c: 8c84001c */ lw $a0,0x1c($a0) +/* f044c60: 00a08025 */ or $s0,$a1,$zero +/* f044c64: 27a50078 */ addiu $a1,$sp,0x78 +/* f044c68: 27a7007c */ addiu $a3,$sp,0x7c +/* f044c6c: 27a60080 */ addiu $a2,$sp,0x80 +/* f044c70: 0fc0a277 */ jal propChrGetBbox +/* f044c74: afa4003c */ sw $a0,0x3c($sp) +/* f044c78: 8fa200ec */ lw $v0,0xec($sp) +/* f044c7c: c6060000 */ lwc1 $f6,0x0($s0) +/* f044c80: 44800000 */ mtc1 $zero,$f0 +/* f044c84: c4440000 */ lwc1 $f4,0x0($v0) +/* f044c88: e7a000d8 */ swc1 $f0,0xd8($sp) +/* f044c8c: 46062201 */ sub.s $f8,$f4,$f6 +/* f044c90: e7a800d4 */ swc1 $f8,0xd4($sp) +/* f044c94: c7a800d4 */ lwc1 $f8,0xd4($sp) +/* f044c98: c6040008 */ lwc1 $f4,0x8($s0) +/* f044c9c: c44a0008 */ lwc1 $f10,0x8($v0) +/* f044ca0: 46080032 */ c.eq.s $f0,$f8 +/* f044ca4: 46045181 */ sub.s $f6,$f10,$f4 +/* f044ca8: 45000008 */ bc1f .L0f044ccc +/* f044cac: e7a600dc */ swc1 $f6,0xdc($sp) +/* f044cb0: c7b200dc */ lwc1 $f18,0xdc($sp) +/* f044cb4: 46120032 */ c.eq.s $f0,$f18 +/* f044cb8: 00000000 */ nop +/* f044cbc: 45020004 */ bc1fl .L0f044cd0 +/* f044cc0: c7b200dc */ lwc1 $f18,0xdc($sp) +/* f044cc4: 10000133 */ b .L0f045194 +/* f044cc8: 24020001 */ addiu $v0,$zero,0x1 +.L0f044ccc: +/* f044ccc: c7b200dc */ lwc1 $f18,0xdc($sp) +.L0f044cd0: +/* f044cd0: c7b000d4 */ lwc1 $f16,0xd4($sp) +/* f044cd4: 46129282 */ mul.s $f10,$f18,$f18 +/* f044cd8: 00000000 */ nop +/* f044cdc: 46108102 */ mul.s $f4,$f16,$f16 +/* f044ce0: 0c012974 */ jal sqrtf +/* f044ce4: 46045300 */ add.s $f12,$f10,$f4 +/* f044ce8: 3c013f80 */ lui $at,0x3f80 +/* f044cec: 44813000 */ mtc1 $at,$f6 +/* f044cf0: c7b000d4 */ lwc1 $f16,0xd4($sp) +/* f044cf4: c7b200dc */ lwc1 $f18,0xdc($sp) +/* f044cf8: 46003083 */ div.s $f2,$f6,$f0 +/* f044cfc: c7a800fc */ lwc1 $f8,0xfc($sp) +/* f044d00: 3c017f1b */ lui $at,%hi(var7f1a9238) +/* f044d04: c42a9238 */ lwc1 $f10,%lo(var7f1a9238)($at) +/* f044d08: 3c017f1b */ lui $at,%hi(var7f1a923c) +/* f044d0c: c426923c */ lwc1 $f6,%lo(var7f1a923c)($at) +/* f044d10: 3c017f1b */ lui $at,%hi(var7f1a9240) +/* f044d14: 8fa400e0 */ lw $a0,0xe0($sp) +/* f044d18: 00002825 */ or $a1,$zero,$zero +/* f044d1c: 46028402 */ mul.s $f16,$f16,$f2 +/* f044d20: 00000000 */ nop +/* f044d24: 46029482 */ mul.s $f18,$f18,$f2 +/* f044d28: 00000000 */ nop +/* f044d2c: 46088302 */ mul.s $f12,$f16,$f8 +/* f044d30: e7b000d4 */ swc1 $f16,0xd4($sp) +/* f044d34: e7b200dc */ swc1 $f18,0xdc($sp) +/* f044d38: 460a6102 */ mul.s $f4,$f12,$f10 +/* f044d3c: 00000000 */ nop +/* f044d40: 46089382 */ mul.s $f14,$f18,$f8 +/* f044d44: e7a400d0 */ swc1 $f4,0xd0($sp) +/* f044d48: c4249240 */ lwc1 $f4,%lo(var7f1a9240)($at) +/* f044d4c: 3c017f1b */ lui $at,%hi(var7f1a9244) +/* f044d50: 46067282 */ mul.s $f10,$f14,$f6 +/* f044d54: c4269244 */ lwc1 $f6,%lo(var7f1a9244)($at) +/* f044d58: 46046202 */ mul.s $f8,$f12,$f4 +/* f044d5c: e7aa00cc */ swc1 $f10,0xcc($sp) +/* f044d60: 46067282 */ mul.s $f10,$f14,$f6 +/* f044d64: e7a800c8 */ swc1 $f8,0xc8($sp) +/* f044d68: 0fc079ef */ jal chrSetOrUnsetHiddenFlag00000100 +/* f044d6c: e7aa00c4 */ swc1 $f10,0xc4($sp) +/* f044d70: c6040000 */ lwc1 $f4,0x0($s0) +/* f044d74: c7a800cc */ lwc1 $f8,0xcc($sp) +/* f044d78: 8fa200ec */ lw $v0,0xec($sp) +/* f044d7c: c7a200f8 */ lwc1 $f2,0xf8($sp) +/* f044d80: 46082180 */ add.s $f6,$f4,$f8 +/* f044d84: c7a800d0 */ lwc1 $f8,0xd0($sp) +/* f044d88: 8faf0100 */ lw $t7,0x100($sp) +/* f044d8c: 8fb9003c */ lw $t9,0x3c($sp) +/* f044d90: e7a6006c */ swc1 $f6,0x6c($sp) +/* f044d94: c60a0004 */ lwc1 $f10,0x4($s0) +/* f044d98: 24180001 */ addiu $t8,$zero,0x1 +/* f044d9c: 02002025 */ or $a0,$s0,$zero +/* f044da0: e7aa0070 */ swc1 $f10,0x70($sp) +/* f044da4: c6040008 */ lwc1 $f4,0x8($s0) +/* f044da8: 8fa500e8 */ lw $a1,0xe8($sp) +/* f044dac: 27a6006c */ addiu $a2,$sp,0x6c +/* f044db0: 46082181 */ sub.s $f6,$f4,$f8 +/* f044db4: c7a400c4 */ lwc1 $f4,0xc4($sp) +/* f044db8: 27a70050 */ addiu $a3,$sp,0x50 +/* f044dbc: e7a60074 */ swc1 $f6,0x74($sp) +/* f044dc0: c44a0000 */ lwc1 $f10,0x0($v0) +/* f044dc4: c7a600d4 */ lwc1 $f6,0xd4($sp) +/* f044dc8: 46045200 */ add.s $f8,$f10,$f4 +/* f044dcc: 46023282 */ mul.s $f10,$f6,$f2 +/* f044dd0: 46085100 */ add.s $f4,$f10,$f8 +/* f044dd4: c7a800c8 */ lwc1 $f8,0xc8($sp) +/* f044dd8: e7a40060 */ swc1 $f4,0x60($sp) +/* f044ddc: c4460004 */ lwc1 $f6,0x4($v0) +/* f044de0: e7a60064 */ swc1 $f6,0x64($sp) +/* f044de4: c44a0008 */ lwc1 $f10,0x8($v0) +/* f044de8: c7a600dc */ lwc1 $f6,0xdc($sp) +/* f044dec: afb80014 */ sw $t8,0x14($sp) +/* f044df0: 46085101 */ sub.s $f4,$f10,$f8 +/* f044df4: 46023282 */ mul.s $f10,$f6,$f2 +/* f044df8: afaf0010 */ sw $t7,0x10($sp) +/* f044dfc: c7a60080 */ lwc1 $f6,0x80($sp) +/* f044e00: 46045200 */ add.s $f8,$f10,$f4 +/* f044e04: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f044e08: e7a80068 */ swc1 $f8,0x68($sp) +/* f044e0c: c720000c */ lwc1 $f0,0xc($t9) +/* f044e10: 46003281 */ sub.s $f10,$f6,$f0 +/* f044e14: 46002201 */ sub.s $f8,$f4,$f0 +/* f044e18: e7aa0018 */ swc1 $f10,0x18($sp) +/* f044e1c: 0c00b694 */ jal cd0002da50 +/* f044e20: e7a8001c */ swc1 $f8,0x1c($sp) +/* f044e24: 10400010 */ beqz $v0,.L0f044e68 +/* f044e28: 24080001 */ addiu $t0,$zero,0x1 +/* f044e2c: 8fa9003c */ lw $t1,0x3c($sp) +/* f044e30: afa80010 */ sw $t0,0x10($sp) +/* f044e34: c7a60080 */ lwc1 $f6,0x80($sp) +/* f044e38: c520000c */ lwc1 $f0,0xc($t1) +/* f044e3c: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f044e40: 27a4006c */ addiu $a0,$sp,0x6c +/* f044e44: 46003281 */ sub.s $f10,$f6,$f0 +/* f044e48: 27a50050 */ addiu $a1,$sp,0x50 +/* f044e4c: 27a60060 */ addiu $a2,$sp,0x60 +/* f044e50: 46002201 */ sub.s $f8,$f4,$f0 +/* f044e54: e7aa0014 */ swc1 $f10,0x14($sp) +/* f044e58: 8fa70100 */ lw $a3,0x100($sp) +/* f044e5c: 0c00b5f0 */ jal cd0002d7c0 +/* f044e60: e7a80018 */ swc1 $f8,0x18($sp) +/* f044e64: 1440000c */ bnez $v0,.L0f044e98 +.L0f044e68: +/* f044e68: 240a0001 */ addiu $t2,$zero,0x1 +/* f044e6c: 3c077f1b */ lui $a3,%hi(var7f1a8ba0) +/* f044e70: afaa00bc */ sw $t2,0xbc($sp) +/* f044e74: 24e78ba0 */ addiu $a3,$a3,%lo(var7f1a8ba0) +/* f044e78: 27a400ac */ addiu $a0,$sp,0xac +/* f044e7c: 27a500a0 */ addiu $a1,$sp,0xa0 +/* f044e80: 0c009393 */ jal cd00024e4c +/* f044e84: 24063741 */ addiu $a2,$zero,0x374e +/* f044e88: 27a400ac */ addiu $a0,$sp,0xac +/* f044e8c: 27a500a0 */ addiu $a1,$sp,0xa0 +/* f044e90: 0fc112da */ jal func0f044b68 +/* f044e94: 27a600d4 */ addiu $a2,$sp,0xd4 +.L0f044e98: +/* f044e98: c6060000 */ lwc1 $f6,0x0($s0) +/* f044e9c: c7aa00cc */ lwc1 $f10,0xcc($sp) +/* f044ea0: 8fa200ec */ lw $v0,0xec($sp) +/* f044ea4: c7a200f8 */ lwc1 $f2,0xf8($sp) +/* f044ea8: 460a3101 */ sub.s $f4,$f6,$f10 +/* f044eac: c7aa00d0 */ lwc1 $f10,0xd0($sp) +/* f044eb0: 8fab0100 */ lw $t3,0x100($sp) +/* f044eb4: 8fad003c */ lw $t5,0x3c($sp) +/* f044eb8: e7a4006c */ swc1 $f4,0x6c($sp) +/* f044ebc: c6080004 */ lwc1 $f8,0x4($s0) +/* f044ec0: 240c0001 */ addiu $t4,$zero,0x1 +/* f044ec4: 02002025 */ or $a0,$s0,$zero +/* f044ec8: e7a80070 */ swc1 $f8,0x70($sp) +/* f044ecc: c6060008 */ lwc1 $f6,0x8($s0) +/* f044ed0: 8fa500e8 */ lw $a1,0xe8($sp) +/* f044ed4: 27a6006c */ addiu $a2,$sp,0x6c +/* f044ed8: 460a3100 */ add.s $f4,$f6,$f10 +/* f044edc: c7a600c4 */ lwc1 $f6,0xc4($sp) +/* f044ee0: 27a70050 */ addiu $a3,$sp,0x50 +/* f044ee4: e7a40074 */ swc1 $f4,0x74($sp) +/* f044ee8: c4480000 */ lwc1 $f8,0x0($v0) +/* f044eec: c7a400d4 */ lwc1 $f4,0xd4($sp) +/* f044ef0: 46064281 */ sub.s $f10,$f8,$f6 +/* f044ef4: 46022202 */ mul.s $f8,$f4,$f2 +/* f044ef8: 460a4180 */ add.s $f6,$f8,$f10 +/* f044efc: c7aa00c8 */ lwc1 $f10,0xc8($sp) +/* f044f00: e7a60060 */ swc1 $f6,0x60($sp) +/* f044f04: c4440004 */ lwc1 $f4,0x4($v0) +/* f044f08: e7a40064 */ swc1 $f4,0x64($sp) +/* f044f0c: c4480008 */ lwc1 $f8,0x8($v0) +/* f044f10: c7a400dc */ lwc1 $f4,0xdc($sp) +/* f044f14: afac0014 */ sw $t4,0x14($sp) +/* f044f18: 460a4180 */ add.s $f6,$f8,$f10 +/* f044f1c: 46022202 */ mul.s $f8,$f4,$f2 +/* f044f20: afab0010 */ sw $t3,0x10($sp) +/* f044f24: c7a40080 */ lwc1 $f4,0x80($sp) +/* f044f28: 46064280 */ add.s $f10,$f8,$f6 +/* f044f2c: c7a6007c */ lwc1 $f6,0x7c($sp) +/* f044f30: e7aa0068 */ swc1 $f10,0x68($sp) +/* f044f34: c5a0000c */ lwc1 $f0,0xc($t5) +/* f044f38: 46002201 */ sub.s $f8,$f4,$f0 +/* f044f3c: 46003281 */ sub.s $f10,$f6,$f0 +/* f044f40: e7a80018 */ swc1 $f8,0x18($sp) +/* f044f44: 0c00b694 */ jal cd0002da50 +/* f044f48: e7aa001c */ swc1 $f10,0x1c($sp) +/* f044f4c: 10400010 */ beqz $v0,.L0f044f90 +/* f044f50: 240e0001 */ addiu $t6,$zero,0x1 +/* f044f54: 8faf003c */ lw $t7,0x3c($sp) +/* f044f58: afae0010 */ sw $t6,0x10($sp) +/* f044f5c: c7a40080 */ lwc1 $f4,0x80($sp) +/* f044f60: c5e0000c */ lwc1 $f0,0xc($t7) +/* f044f64: c7a6007c */ lwc1 $f6,0x7c($sp) +/* f044f68: 27a4006c */ addiu $a0,$sp,0x6c +/* f044f6c: 46002201 */ sub.s $f8,$f4,$f0 +/* f044f70: 8fa500e8 */ lw $a1,0xe8($sp) +/* f044f74: 27a60060 */ addiu $a2,$sp,0x60 +/* f044f78: 46003281 */ sub.s $f10,$f6,$f0 +/* f044f7c: e7a80014 */ swc1 $f8,0x14($sp) +/* f044f80: 8fa70100 */ lw $a3,0x100($sp) +/* f044f84: 0c00b5f0 */ jal cd0002d7c0 +/* f044f88: e7aa0018 */ swc1 $f10,0x18($sp) +/* f044f8c: 1440000c */ bnez $v0,.L0f044fc0 +.L0f044f90: +/* f044f90: 24180001 */ addiu $t8,$zero,0x1 +/* f044f94: 3c077f1b */ lui $a3,%hi(var7f1a8bac) +/* f044f98: afb800b8 */ sw $t8,0xb8($sp) +/* f044f9c: 24e78bac */ addiu $a3,$a3,%lo(var7f1a8bac) +/* f044fa0: 27a40094 */ addiu $a0,$sp,0x94 +/* f044fa4: 27a50088 */ addiu $a1,$sp,0x88 +/* f044fa8: 0c009393 */ jal cd00024e4c +/* f044fac: 24063750 */ addiu $a2,$zero,0x375d +/* f044fb0: 27a40094 */ addiu $a0,$sp,0x94 +/* f044fb4: 27a50088 */ addiu $a1,$sp,0x88 +/* f044fb8: 0fc112da */ jal func0f044b68 +/* f044fbc: 27a600d4 */ addiu $a2,$sp,0xd4 +.L0f044fc0: +/* f044fc0: 8fb900bc */ lw $t9,0xbc($sp) +/* f044fc4: 8fa800b8 */ lw $t0,0xb8($sp) +/* f044fc8: 8fa900bc */ lw $t1,0xbc($sp) +/* f044fcc: 13200019 */ beqz $t9,.L0f045034 +/* f044fd0: 00000000 */ nop +/* f044fd4: 11000017 */ beqz $t0,.L0f045034 +/* f044fd8: 27a400ac */ addiu $a0,$sp,0xac +/* f044fdc: 27a50094 */ addiu $a1,$sp,0x94 +/* f044fe0: 0fc112da */ jal func0f044b68 +/* f044fe4: 27a600d4 */ addiu $a2,$sp,0xd4 +/* f044fe8: 27a400a0 */ addiu $a0,$sp,0xa0 +/* f044fec: 27a50088 */ addiu $a1,$sp,0x88 +/* f044ff0: 0fc112da */ jal func0f044b68 +/* f044ff4: 27a600d4 */ addiu $a2,$sp,0xd4 +/* f044ff8: 8fa400f0 */ lw $a0,0xf0($sp) +/* f044ffc: c7a400ac */ lwc1 $f4,0xac($sp) +/* f045000: 8fa500f4 */ lw $a1,0xf4($sp) +/* f045004: e4840000 */ swc1 $f4,0x0($a0) +/* f045008: c7a800b0 */ lwc1 $f8,0xb0($sp) +/* f04500c: e4880004 */ swc1 $f8,0x4($a0) +/* f045010: c7a600b4 */ lwc1 $f6,0xb4($sp) +/* f045014: e4860008 */ swc1 $f6,0x8($a0) +/* f045018: c7aa0088 */ lwc1 $f10,0x88($sp) +/* f04501c: e4aa0000 */ swc1 $f10,0x0($a1) +/* f045020: c7a4008c */ lwc1 $f4,0x8c($sp) +/* f045024: e4a40004 */ swc1 $f4,0x4($a1) +/* f045028: c7a80090 */ lwc1 $f8,0x90($sp) +/* f04502c: 10000055 */ b .L0f045184 +/* f045030: e4a80008 */ swc1 $f8,0x8($a1) +.L0f045034: +/* f045034: 11200010 */ beqz $t1,.L0f045078 +/* f045038: 8faa00b8 */ lw $t2,0xb8($sp) +/* f04503c: 8fa400f0 */ lw $a0,0xf0($sp) +/* f045040: c7a600ac */ lwc1 $f6,0xac($sp) +/* f045044: 8fa500f4 */ lw $a1,0xf4($sp) +/* f045048: e4860000 */ swc1 $f6,0x0($a0) +/* f04504c: c7aa00b0 */ lwc1 $f10,0xb0($sp) +/* f045050: e48a0004 */ swc1 $f10,0x4($a0) +/* f045054: c7a400b4 */ lwc1 $f4,0xb4($sp) +/* f045058: e4840008 */ swc1 $f4,0x8($a0) +/* f04505c: c7a800a0 */ lwc1 $f8,0xa0($sp) +/* f045060: e4a80000 */ swc1 $f8,0x0($a1) +/* f045064: c7a600a4 */ lwc1 $f6,0xa4($sp) +/* f045068: e4a60004 */ swc1 $f6,0x4($a1) +/* f04506c: c7aa00a8 */ lwc1 $f10,0xa8($sp) +/* f045070: 10000044 */ b .L0f045184 +/* f045074: e4aa0008 */ swc1 $f10,0x8($a1) +.L0f045078: +/* f045078: 11400010 */ beqz $t2,.L0f0450bc +/* f04507c: 8fab0100 */ lw $t3,0x100($sp) +/* f045080: 8fa400f0 */ lw $a0,0xf0($sp) +/* f045084: c7a40094 */ lwc1 $f4,0x94($sp) +/* f045088: 8fa500f4 */ lw $a1,0xf4($sp) +/* f04508c: e4840000 */ swc1 $f4,0x0($a0) +/* f045090: c7a80098 */ lwc1 $f8,0x98($sp) +/* f045094: e4880004 */ swc1 $f8,0x4($a0) +/* f045098: c7a6009c */ lwc1 $f6,0x9c($sp) +/* f04509c: e4860008 */ swc1 $f6,0x8($a0) +/* f0450a0: c7aa0088 */ lwc1 $f10,0x88($sp) +/* f0450a4: e4aa0000 */ swc1 $f10,0x0($a1) +/* f0450a8: c7a4008c */ lwc1 $f4,0x8c($sp) +/* f0450ac: e4a40004 */ swc1 $f4,0x4($a1) +/* f0450b0: c7a80090 */ lwc1 $f8,0x90($sp) +/* f0450b4: 10000033 */ b .L0f045184 +/* f0450b8: e4a80008 */ swc1 $f8,0x8($a1) +.L0f0450bc: +/* f0450bc: 8fad003c */ lw $t5,0x3c($sp) +/* f0450c0: 240c0001 */ addiu $t4,$zero,0x1 +/* f0450c4: afac0014 */ sw $t4,0x14($sp) +/* f0450c8: afab0010 */ sw $t3,0x10($sp) +/* f0450cc: c5a0000c */ lwc1 $f0,0xc($t5) +/* f0450d0: c7a60080 */ lwc1 $f6,0x80($sp) +/* f0450d4: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f0450d8: 02002025 */ or $a0,$s0,$zero +/* f0450dc: 46003281 */ sub.s $f10,$f6,$f0 +/* f0450e0: 8fa500e8 */ lw $a1,0xe8($sp) +/* f0450e4: 8fa600ec */ lw $a2,0xec($sp) +/* f0450e8: 46002201 */ sub.s $f8,$f4,$f0 +/* f0450ec: e7aa0018 */ swc1 $f10,0x18($sp) +/* f0450f0: 27a70040 */ addiu $a3,$sp,0x40 +/* f0450f4: 0c00b694 */ jal cd0002da50 +/* f0450f8: e7a8001c */ swc1 $f8,0x1c($sp) +/* f0450fc: 10400017 */ beqz $v0,.L0f04515c +/* f045100: 8fae0104 */ lw $t6,0x104($sp) +/* f045104: 11c00012 */ beqz $t6,.L0f045150 +/* f045108: 8faf0100 */ lw $t7,0x100($sp) +/* f04510c: 8fb9003c */ lw $t9,0x3c($sp) +/* f045110: 24180001 */ addiu $t8,$zero,0x1 +/* f045114: afb80014 */ sw $t8,0x14($sp) +/* f045118: afaf0010 */ sw $t7,0x10($sp) +/* f04511c: c720000c */ lwc1 $f0,0xc($t9) +/* f045120: c7a60080 */ lwc1 $f6,0x80($sp) +/* f045124: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f045128: 02002025 */ or $a0,$s0,$zero +/* f04512c: 46003281 */ sub.s $f10,$f6,$f0 +/* f045130: 8fa500ec */ lw $a1,0xec($sp) +/* f045134: 8fa600fc */ lw $a2,0xfc($sp) +/* f045138: 46002201 */ sub.s $f8,$f4,$f0 +/* f04513c: e7aa0018 */ swc1 $f10,0x18($sp) +/* f045140: 27a70040 */ addiu $a3,$sp,0x40 +/* f045144: 0c00a9bf */ jal cd0002a6fc +/* f045148: e7a8001c */ swc1 $f8,0x1c($sp) +/* f04514c: 10400003 */ beqz $v0,.L0f04515c +.L0f045150: +/* f045150: 24080001 */ addiu $t0,$zero,0x1 +/* f045154: 1000000b */ b .L0f045184 +/* f045158: afa80084 */ sw $t0,0x84($sp) +.L0f04515c: +/* f04515c: 3c077f1b */ lui $a3,%hi(var7f1a8bb8) +/* f045160: 8fa400f0 */ lw $a0,0xf0($sp) +/* f045164: 8fa500f4 */ lw $a1,0xf4($sp) +/* f045168: 24e78bb8 */ addiu $a3,$a3,%lo(var7f1a8bb8) +/* f04516c: 0c009393 */ jal cd00024e4c +/* f045170: 24063796 */ addiu $a2,$zero,0x37a3 +/* f045174: 8fa400f0 */ lw $a0,0xf0($sp) +/* f045178: 8fa500f4 */ lw $a1,0xf4($sp) +/* f04517c: 0fc112da */ jal func0f044b68 +/* f045180: 27a600d4 */ addiu $a2,$sp,0xd4 +.L0f045184: +/* f045184: 8fa400e0 */ lw $a0,0xe0($sp) +/* f045188: 0fc079ef */ jal chrSetOrUnsetHiddenFlag00000100 +/* f04518c: 24050001 */ addiu $a1,$zero,0x1 +/* f045190: 8fa20084 */ lw $v0,0x84($sp) +.L0f045194: +/* f045194: 8fbf002c */ lw $ra,0x2c($sp) +/* f045198: 8fb00028 */ lw $s0,0x28($sp) +/* f04519c: 27bd00e0 */ addiu $sp,$sp,0xe0 +/* f0451a0: 03e00008 */ jr $ra +/* f0451a4: 00000000 */ nop +); #endif #if VERSION >= VERSION_PAL_FINAL @@ -19734,7 +20119,7 @@ glabel var7f1a9254 /* f045758: 03e00008 */ jr $ra /* f04575c: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0451a8 .late_rodata @@ -20128,6 +20513,400 @@ glabel var7f1a9254 /* f045758: 03e00008 */ jr $ra /* f04575c: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f0451a8 +.late_rodata +glabel var7f1a9248 +.word 0x3f733333 +glabel var7f1a924c +.word 0x3f733333 +glabel var7f1a9250 +.word 0x3f99999a +glabel var7f1a9254 +.word 0x3f99999a +.text +/* f0451a8: 27bdff18 */ addiu $sp,$sp,-232 +/* f0451ac: afbf002c */ sw $ra,0x2c($sp) +/* f0451b0: afb00028 */ sw $s0,0x28($sp) +/* f0451b4: afa400e8 */ sw $a0,0xe8($sp) +/* f0451b8: afa600f0 */ sw $a2,0xf0($sp) +/* f0451bc: afa700f4 */ sw $a3,0xf4($sp) +/* f0451c0: afa000c4 */ sw $zero,0xc4($sp) +/* f0451c4: afa000c0 */ sw $zero,0xc0($sp) +/* f0451c8: afa0008c */ sw $zero,0x8c($sp) +/* f0451cc: 8c84001c */ lw $a0,0x1c($a0) +/* f0451d0: 00a08025 */ or $s0,$a1,$zero +/* f0451d4: 27a50078 */ addiu $a1,$sp,0x78 +/* f0451d8: 27a7007c */ addiu $a3,$sp,0x7c +/* f0451dc: 27a60080 */ addiu $a2,$sp,0x80 +/* f0451e0: 0fc0a277 */ jal propChrGetBbox +/* f0451e4: afa4003c */ sw $a0,0x3c($sp) +/* f0451e8: 8fa200f4 */ lw $v0,0xf4($sp) +/* f0451ec: c6060000 */ lwc1 $f6,0x0($s0) +/* f0451f0: 44800000 */ mtc1 $zero,$f0 +/* f0451f4: c4440000 */ lwc1 $f4,0x0($v0) +/* f0451f8: e7a000e0 */ swc1 $f0,0xe0($sp) +/* f0451fc: 46062201 */ sub.s $f8,$f4,$f6 +/* f045200: e7a800dc */ swc1 $f8,0xdc($sp) +/* f045204: c7a800dc */ lwc1 $f8,0xdc($sp) +/* f045208: c6040008 */ lwc1 $f4,0x8($s0) +/* f04520c: c44a0008 */ lwc1 $f10,0x8($v0) +/* f045210: 46080032 */ c.eq.s $f0,$f8 +/* f045214: 46045181 */ sub.s $f6,$f10,$f4 +/* f045218: 45000008 */ bc1f .L0f04523c +/* f04521c: e7a600e4 */ swc1 $f6,0xe4($sp) +/* f045220: c7b200e4 */ lwc1 $f18,0xe4($sp) +/* f045224: 46120032 */ c.eq.s $f0,$f18 +/* f045228: 00000000 */ nop +/* f04522c: 45020004 */ bc1fl .L0f045240 +/* f045230: c7b200e4 */ lwc1 $f18,0xe4($sp) +/* f045234: 10000145 */ b .L0f04574c +/* f045238: 24020001 */ addiu $v0,$zero,0x1 +.L0f04523c: +/* f04523c: c7b200e4 */ lwc1 $f18,0xe4($sp) +.L0f045240: +/* f045240: c7b000dc */ lwc1 $f16,0xdc($sp) +/* f045244: 46129282 */ mul.s $f10,$f18,$f18 +/* f045248: 00000000 */ nop +/* f04524c: 46108102 */ mul.s $f4,$f16,$f16 +/* f045250: 0c012974 */ jal sqrtf +/* f045254: 46045300 */ add.s $f12,$f10,$f4 +/* f045258: 3c013f80 */ lui $at,0x3f80 +/* f04525c: 44813000 */ mtc1 $at,$f6 +/* f045260: c7b000dc */ lwc1 $f16,0xdc($sp) +/* f045264: c7b200e4 */ lwc1 $f18,0xe4($sp) +/* f045268: 46003083 */ div.s $f2,$f6,$f0 +/* f04526c: c7a80104 */ lwc1 $f8,0x104($sp) +/* f045270: 3c017f1b */ lui $at,%hi(var7f1a9248) +/* f045274: c42a9248 */ lwc1 $f10,%lo(var7f1a9248)($at) +/* f045278: 3c017f1b */ lui $at,%hi(var7f1a924c) +/* f04527c: c426924c */ lwc1 $f6,%lo(var7f1a924c)($at) +/* f045280: 3c017f1b */ lui $at,%hi(var7f1a9250) +/* f045284: 8fa400e8 */ lw $a0,0xe8($sp) +/* f045288: 00002825 */ or $a1,$zero,$zero +/* f04528c: 46028402 */ mul.s $f16,$f16,$f2 +/* f045290: 00000000 */ nop +/* f045294: 46029482 */ mul.s $f18,$f18,$f2 +/* f045298: 00000000 */ nop +/* f04529c: 46088302 */ mul.s $f12,$f16,$f8 +/* f0452a0: e7b000dc */ swc1 $f16,0xdc($sp) +/* f0452a4: e7b200e4 */ swc1 $f18,0xe4($sp) +/* f0452a8: 460a6102 */ mul.s $f4,$f12,$f10 +/* f0452ac: 00000000 */ nop +/* f0452b0: 46089382 */ mul.s $f14,$f18,$f8 +/* f0452b4: e7a400d8 */ swc1 $f4,0xd8($sp) +/* f0452b8: c4249250 */ lwc1 $f4,%lo(var7f1a9250)($at) +/* f0452bc: 3c017f1b */ lui $at,%hi(var7f1a9254) +/* f0452c0: 46067282 */ mul.s $f10,$f14,$f6 +/* f0452c4: c4269254 */ lwc1 $f6,%lo(var7f1a9254)($at) +/* f0452c8: 46046202 */ mul.s $f8,$f12,$f4 +/* f0452cc: e7aa00d4 */ swc1 $f10,0xd4($sp) +/* f0452d0: 46067282 */ mul.s $f10,$f14,$f6 +/* f0452d4: e7a800d0 */ swc1 $f8,0xd0($sp) +/* f0452d8: 0fc079ef */ jal chrSetOrUnsetHiddenFlag00000100 +/* f0452dc: e7aa00cc */ swc1 $f10,0xcc($sp) +/* f0452e0: c6040000 */ lwc1 $f4,0x0($s0) +/* f0452e4: c7a800d4 */ lwc1 $f8,0xd4($sp) +/* f0452e8: 8fa200f4 */ lw $v0,0xf4($sp) +/* f0452ec: c7a20100 */ lwc1 $f2,0x100($sp) +/* f0452f0: 46082180 */ add.s $f6,$f4,$f8 +/* f0452f4: c7a800d8 */ lwc1 $f8,0xd8($sp) +/* f0452f8: 8faf0108 */ lw $t7,0x108($sp) +/* f0452fc: 8fb9003c */ lw $t9,0x3c($sp) +/* f045300: e7a6006c */ swc1 $f6,0x6c($sp) +/* f045304: c60a0004 */ lwc1 $f10,0x4($s0) +/* f045308: 24180001 */ addiu $t8,$zero,0x1 +/* f04530c: 02002025 */ or $a0,$s0,$zero +/* f045310: e7aa0070 */ swc1 $f10,0x70($sp) +/* f045314: c6040008 */ lwc1 $f4,0x8($s0) +/* f045318: 8fa500f0 */ lw $a1,0xf0($sp) +/* f04531c: 27a6006c */ addiu $a2,$sp,0x6c +/* f045320: 46082181 */ sub.s $f6,$f4,$f8 +/* f045324: c7a400cc */ lwc1 $f4,0xcc($sp) +/* f045328: 27a70050 */ addiu $a3,$sp,0x50 +/* f04532c: e7a60074 */ swc1 $f6,0x74($sp) +/* f045330: c44a0000 */ lwc1 $f10,0x0($v0) +/* f045334: c7a600dc */ lwc1 $f6,0xdc($sp) +/* f045338: 46045200 */ add.s $f8,$f10,$f4 +/* f04533c: 46023282 */ mul.s $f10,$f6,$f2 +/* f045340: 46085100 */ add.s $f4,$f10,$f8 +/* f045344: c7a800d0 */ lwc1 $f8,0xd0($sp) +/* f045348: e7a40060 */ swc1 $f4,0x60($sp) +/* f04534c: c4460004 */ lwc1 $f6,0x4($v0) +/* f045350: e7a60064 */ swc1 $f6,0x64($sp) +/* f045354: c44a0008 */ lwc1 $f10,0x8($v0) +/* f045358: c7a600e4 */ lwc1 $f6,0xe4($sp) +/* f04535c: afb80014 */ sw $t8,0x14($sp) +/* f045360: 46085101 */ sub.s $f4,$f10,$f8 +/* f045364: 46023282 */ mul.s $f10,$f6,$f2 +/* f045368: afaf0010 */ sw $t7,0x10($sp) +/* f04536c: c7a60080 */ lwc1 $f6,0x80($sp) +/* f045370: 46045200 */ add.s $f8,$f10,$f4 +/* f045374: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f045378: e7a80068 */ swc1 $f8,0x68($sp) +/* f04537c: c720000c */ lwc1 $f0,0xc($t9) +/* f045380: 46003281 */ sub.s $f10,$f6,$f0 +/* f045384: 46002201 */ sub.s $f8,$f4,$f0 +/* f045388: e7aa0018 */ swc1 $f10,0x18($sp) +/* f04538c: 0c00b694 */ jal cd0002da50 +/* f045390: e7a8001c */ swc1 $f8,0x1c($sp) +/* f045394: 10400010 */ beqz $v0,.L0f0453d8 +/* f045398: 24080001 */ addiu $t0,$zero,0x1 +/* f04539c: 8fa9003c */ lw $t1,0x3c($sp) +/* f0453a0: afa80010 */ sw $t0,0x10($sp) +/* f0453a4: c7a60080 */ lwc1 $f6,0x80($sp) +/* f0453a8: c520000c */ lwc1 $f0,0xc($t1) +/* f0453ac: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f0453b0: 27a4006c */ addiu $a0,$sp,0x6c +/* f0453b4: 46003281 */ sub.s $f10,$f6,$f0 +/* f0453b8: 27a50050 */ addiu $a1,$sp,0x50 +/* f0453bc: 27a60060 */ addiu $a2,$sp,0x60 +/* f0453c0: 46002201 */ sub.s $f8,$f4,$f0 +/* f0453c4: e7aa0014 */ swc1 $f10,0x14($sp) +/* f0453c8: 8fa70108 */ lw $a3,0x108($sp) +/* f0453cc: 0c00b5f0 */ jal cd0002d7c0 +/* f0453d0: e7a80018 */ swc1 $f8,0x18($sp) +/* f0453d4: 1440000f */ bnez $v0,.L0f045414 +.L0f0453d8: +/* f0453d8: 240a0001 */ addiu $t2,$zero,0x1 +/* f0453dc: 3c077f1b */ lui $a3,%hi(var7f1a8bc4) +/* f0453e0: afaa00c4 */ sw $t2,0xc4($sp) +/* f0453e4: 24e78bc4 */ addiu $a3,$a3,%lo(var7f1a8bc4) +/* f0453e8: 27a400b4 */ addiu $a0,$sp,0xb4 +/* f0453ec: 27a500a8 */ addiu $a1,$sp,0xa8 +/* f0453f0: 0c009393 */ jal cd00024e4c +/* f0453f4: 240637e6 */ addiu $a2,$zero,0x37f3 +/* f0453f8: 27a400b4 */ addiu $a0,$sp,0xb4 +/* f0453fc: 27a500a8 */ addiu $a1,$sp,0xa8 +/* f045400: 0fc112da */ jal func0f044b68 +/* f045404: 27a600dc */ addiu $a2,$sp,0xdc +/* f045408: 0c009390 */ jal cd00024e40 +/* f04540c: 00000000 */ nop +/* f045410: e7a00088 */ swc1 $f0,0x88($sp) +.L0f045414: +/* f045414: c6060000 */ lwc1 $f6,0x0($s0) +/* f045418: c7aa00d4 */ lwc1 $f10,0xd4($sp) +/* f04541c: 8fa200f4 */ lw $v0,0xf4($sp) +/* f045420: c7a20100 */ lwc1 $f2,0x100($sp) +/* f045424: 460a3101 */ sub.s $f4,$f6,$f10 +/* f045428: c7aa00d8 */ lwc1 $f10,0xd8($sp) +/* f04542c: 8fab0108 */ lw $t3,0x108($sp) +/* f045430: 8fad003c */ lw $t5,0x3c($sp) +/* f045434: e7a4006c */ swc1 $f4,0x6c($sp) +/* f045438: c6080004 */ lwc1 $f8,0x4($s0) +/* f04543c: 240c0001 */ addiu $t4,$zero,0x1 +/* f045440: 02002025 */ or $a0,$s0,$zero +/* f045444: e7a80070 */ swc1 $f8,0x70($sp) +/* f045448: c6060008 */ lwc1 $f6,0x8($s0) +/* f04544c: 8fa500f0 */ lw $a1,0xf0($sp) +/* f045450: 27a6006c */ addiu $a2,$sp,0x6c +/* f045454: 460a3100 */ add.s $f4,$f6,$f10 +/* f045458: c7a600cc */ lwc1 $f6,0xcc($sp) +/* f04545c: 27a70050 */ addiu $a3,$sp,0x50 +/* f045460: e7a40074 */ swc1 $f4,0x74($sp) +/* f045464: c4480000 */ lwc1 $f8,0x0($v0) +/* f045468: c7a400dc */ lwc1 $f4,0xdc($sp) +/* f04546c: 46064281 */ sub.s $f10,$f8,$f6 +/* f045470: 46022202 */ mul.s $f8,$f4,$f2 +/* f045474: 460a4180 */ add.s $f6,$f8,$f10 +/* f045478: c7aa00d0 */ lwc1 $f10,0xd0($sp) +/* f04547c: e7a60060 */ swc1 $f6,0x60($sp) +/* f045480: c4440004 */ lwc1 $f4,0x4($v0) +/* f045484: e7a40064 */ swc1 $f4,0x64($sp) +/* f045488: c4480008 */ lwc1 $f8,0x8($v0) +/* f04548c: c7a400e4 */ lwc1 $f4,0xe4($sp) +/* f045490: afac0014 */ sw $t4,0x14($sp) +/* f045494: 460a4180 */ add.s $f6,$f8,$f10 +/* f045498: 46022202 */ mul.s $f8,$f4,$f2 +/* f04549c: afab0010 */ sw $t3,0x10($sp) +/* f0454a0: c7a40080 */ lwc1 $f4,0x80($sp) +/* f0454a4: 46064280 */ add.s $f10,$f8,$f6 +/* f0454a8: c7a6007c */ lwc1 $f6,0x7c($sp) +/* f0454ac: e7aa0068 */ swc1 $f10,0x68($sp) +/* f0454b0: c5a0000c */ lwc1 $f0,0xc($t5) +/* f0454b4: 46002201 */ sub.s $f8,$f4,$f0 +/* f0454b8: 46003281 */ sub.s $f10,$f6,$f0 +/* f0454bc: e7a80018 */ swc1 $f8,0x18($sp) +/* f0454c0: 0c00b694 */ jal cd0002da50 +/* f0454c4: e7aa001c */ swc1 $f10,0x1c($sp) +/* f0454c8: 10400010 */ beqz $v0,.L0f04550c +/* f0454cc: 240e0001 */ addiu $t6,$zero,0x1 +/* f0454d0: 8faf003c */ lw $t7,0x3c($sp) +/* f0454d4: afae0010 */ sw $t6,0x10($sp) +/* f0454d8: c7a40080 */ lwc1 $f4,0x80($sp) +/* f0454dc: c5e0000c */ lwc1 $f0,0xc($t7) +/* f0454e0: c7a6007c */ lwc1 $f6,0x7c($sp) +/* f0454e4: 27a4006c */ addiu $a0,$sp,0x6c +/* f0454e8: 46002201 */ sub.s $f8,$f4,$f0 +/* f0454ec: 8fa500f0 */ lw $a1,0xf0($sp) +/* f0454f0: 27a60060 */ addiu $a2,$sp,0x60 +/* f0454f4: 46003281 */ sub.s $f10,$f6,$f0 +/* f0454f8: e7a80014 */ swc1 $f8,0x14($sp) +/* f0454fc: 8fa70108 */ lw $a3,0x108($sp) +/* f045500: 0c00b5f0 */ jal cd0002d7c0 +/* f045504: e7aa0018 */ swc1 $f10,0x18($sp) +/* f045508: 1440000f */ bnez $v0,.L0f045548 +.L0f04550c: +/* f04550c: 24180001 */ addiu $t8,$zero,0x1 +/* f045510: 3c077f1b */ lui $a3,%hi(var7f1a8bd0) +/* f045514: afb800c0 */ sw $t8,0xc0($sp) +/* f045518: 24e78bd0 */ addiu $a3,$a3,%lo(var7f1a8bd0) +/* f04551c: 27a4009c */ addiu $a0,$sp,0x9c +/* f045520: 27a50090 */ addiu $a1,$sp,0x90 +/* f045524: 0c009393 */ jal cd00024e4c +/* f045528: 240637f5 */ addiu $a2,$zero,0x3802 +/* f04552c: 27a4009c */ addiu $a0,$sp,0x9c +/* f045530: 27a50090 */ addiu $a1,$sp,0x90 +/* f045534: 0fc112da */ jal func0f044b68 +/* f045538: 27a600dc */ addiu $a2,$sp,0xdc +/* f04553c: 0c009390 */ jal cd00024e40 +/* f045540: 00000000 */ nop +/* f045544: e7a00084 */ swc1 $f0,0x84($sp) +.L0f045548: +/* f045548: 8fb900c4 */ lw $t9,0xc4($sp) +/* f04554c: 8fa800c0 */ lw $t0,0xc0($sp) +/* f045550: 8fa900c4 */ lw $t1,0xc4($sp) +/* f045554: 13200025 */ beqz $t9,.L0f0455ec +/* f045558: 00000000 */ nop +/* f04555c: 11000023 */ beqz $t0,.L0f0455ec +/* f045560: c7a40088 */ lwc1 $f4,0x88($sp) +/* f045564: c7a80084 */ lwc1 $f8,0x84($sp) +/* f045568: c7a600b4 */ lwc1 $f6,0xb4($sp) +/* f04556c: 8fa400f8 */ lw $a0,0xf8($sp) +/* f045570: 4608203c */ c.lt.s $f4,$f8 +/* f045574: c7a4009c */ lwc1 $f4,0x9c($sp) +/* f045578: 45020010 */ bc1fl .L0f0455bc +/* f04557c: 8fa500fc */ lw $a1,0xfc($sp) +/* f045580: 8fa400f8 */ lw $a0,0xf8($sp) +/* f045584: 8fa500fc */ lw $a1,0xfc($sp) +/* f045588: e4860000 */ swc1 $f6,0x0($a0) +/* f04558c: c7aa00b8 */ lwc1 $f10,0xb8($sp) +/* f045590: e48a0004 */ swc1 $f10,0x4($a0) +/* f045594: c7a400bc */ lwc1 $f4,0xbc($sp) +/* f045598: e4840008 */ swc1 $f4,0x8($a0) +/* f04559c: c7a800a8 */ lwc1 $f8,0xa8($sp) +/* f0455a0: e4a80000 */ swc1 $f8,0x0($a1) +/* f0455a4: c7a600ac */ lwc1 $f6,0xac($sp) +/* f0455a8: e4a60004 */ swc1 $f6,0x4($a1) +/* f0455ac: c7aa00b0 */ lwc1 $f10,0xb0($sp) +/* f0455b0: 10000062 */ b .L0f04573c +/* f0455b4: e4aa0008 */ swc1 $f10,0x8($a1) +/* f0455b8: 8fa500fc */ lw $a1,0xfc($sp) +.L0f0455bc: +/* f0455bc: e4840000 */ swc1 $f4,0x0($a0) +/* f0455c0: c7a800a0 */ lwc1 $f8,0xa0($sp) +/* f0455c4: e4880004 */ swc1 $f8,0x4($a0) +/* f0455c8: c7a600a4 */ lwc1 $f6,0xa4($sp) +/* f0455cc: e4860008 */ swc1 $f6,0x8($a0) +/* f0455d0: c7aa0090 */ lwc1 $f10,0x90($sp) +/* f0455d4: e4aa0000 */ swc1 $f10,0x0($a1) +/* f0455d8: c7a40094 */ lwc1 $f4,0x94($sp) +/* f0455dc: e4a40004 */ swc1 $f4,0x4($a1) +/* f0455e0: c7a80098 */ lwc1 $f8,0x98($sp) +/* f0455e4: 10000055 */ b .L0f04573c +/* f0455e8: e4a80008 */ swc1 $f8,0x8($a1) +.L0f0455ec: +/* f0455ec: 11200010 */ beqz $t1,.L0f045630 +/* f0455f0: 8faa00c0 */ lw $t2,0xc0($sp) +/* f0455f4: 8fa400f8 */ lw $a0,0xf8($sp) +/* f0455f8: c7a600b4 */ lwc1 $f6,0xb4($sp) +/* f0455fc: 8fa500fc */ lw $a1,0xfc($sp) +/* f045600: e4860000 */ swc1 $f6,0x0($a0) +/* f045604: c7aa00b8 */ lwc1 $f10,0xb8($sp) +/* f045608: e48a0004 */ swc1 $f10,0x4($a0) +/* f04560c: c7a400bc */ lwc1 $f4,0xbc($sp) +/* f045610: e4840008 */ swc1 $f4,0x8($a0) +/* f045614: c7a800a8 */ lwc1 $f8,0xa8($sp) +/* f045618: e4a80000 */ swc1 $f8,0x0($a1) +/* f04561c: c7a600ac */ lwc1 $f6,0xac($sp) +/* f045620: e4a60004 */ swc1 $f6,0x4($a1) +/* f045624: c7aa00b0 */ lwc1 $f10,0xb0($sp) +/* f045628: 10000044 */ b .L0f04573c +/* f04562c: e4aa0008 */ swc1 $f10,0x8($a1) +.L0f045630: +/* f045630: 11400010 */ beqz $t2,.L0f045674 +/* f045634: 8fab0108 */ lw $t3,0x108($sp) +/* f045638: 8fa400f8 */ lw $a0,0xf8($sp) +/* f04563c: c7a4009c */ lwc1 $f4,0x9c($sp) +/* f045640: 8fa500fc */ lw $a1,0xfc($sp) +/* f045644: e4840000 */ swc1 $f4,0x0($a0) +/* f045648: c7a800a0 */ lwc1 $f8,0xa0($sp) +/* f04564c: e4880004 */ swc1 $f8,0x4($a0) +/* f045650: c7a600a4 */ lwc1 $f6,0xa4($sp) +/* f045654: e4860008 */ swc1 $f6,0x8($a0) +/* f045658: c7aa0090 */ lwc1 $f10,0x90($sp) +/* f04565c: e4aa0000 */ swc1 $f10,0x0($a1) +/* f045660: c7a40094 */ lwc1 $f4,0x94($sp) +/* f045664: e4a40004 */ swc1 $f4,0x4($a1) +/* f045668: c7a80098 */ lwc1 $f8,0x98($sp) +/* f04566c: 10000033 */ b .L0f04573c +/* f045670: e4a80008 */ swc1 $f8,0x8($a1) +.L0f045674: +/* f045674: 8fad003c */ lw $t5,0x3c($sp) +/* f045678: 240c0001 */ addiu $t4,$zero,0x1 +/* f04567c: afac0014 */ sw $t4,0x14($sp) +/* f045680: afab0010 */ sw $t3,0x10($sp) +/* f045684: c5a0000c */ lwc1 $f0,0xc($t5) +/* f045688: c7a60080 */ lwc1 $f6,0x80($sp) +/* f04568c: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f045690: 02002025 */ or $a0,$s0,$zero +/* f045694: 46003281 */ sub.s $f10,$f6,$f0 +/* f045698: 8fa500f0 */ lw $a1,0xf0($sp) +/* f04569c: 8fa600f4 */ lw $a2,0xf4($sp) +/* f0456a0: 46002201 */ sub.s $f8,$f4,$f0 +/* f0456a4: e7aa0018 */ swc1 $f10,0x18($sp) +/* f0456a8: 27a70040 */ addiu $a3,$sp,0x40 +/* f0456ac: 0c00b694 */ jal cd0002da50 +/* f0456b0: e7a8001c */ swc1 $f8,0x1c($sp) +/* f0456b4: 10400017 */ beqz $v0,.L0f045714 +/* f0456b8: 8fae010c */ lw $t6,0x10c($sp) +/* f0456bc: 11c00012 */ beqz $t6,.L0f045708 +/* f0456c0: 8faf0108 */ lw $t7,0x108($sp) +/* f0456c4: 8fb9003c */ lw $t9,0x3c($sp) +/* f0456c8: 24180001 */ addiu $t8,$zero,0x1 +/* f0456cc: afb80014 */ sw $t8,0x14($sp) +/* f0456d0: afaf0010 */ sw $t7,0x10($sp) +/* f0456d4: c720000c */ lwc1 $f0,0xc($t9) +/* f0456d8: c7a60080 */ lwc1 $f6,0x80($sp) +/* f0456dc: c7a4007c */ lwc1 $f4,0x7c($sp) +/* f0456e0: 02002025 */ or $a0,$s0,$zero +/* f0456e4: 46003281 */ sub.s $f10,$f6,$f0 +/* f0456e8: 8fa500f4 */ lw $a1,0xf4($sp) +/* f0456ec: 8fa60104 */ lw $a2,0x104($sp) +/* f0456f0: 46002201 */ sub.s $f8,$f4,$f0 +/* f0456f4: e7aa0018 */ swc1 $f10,0x18($sp) +/* f0456f8: 27a70040 */ addiu $a3,$sp,0x40 +/* f0456fc: 0c00a9bf */ jal cd0002a6fc +/* f045700: e7a8001c */ swc1 $f8,0x1c($sp) +/* f045704: 10400003 */ beqz $v0,.L0f045714 +.L0f045708: +/* f045708: 24080001 */ addiu $t0,$zero,0x1 +/* f04570c: 1000000b */ b .L0f04573c +/* f045710: afa8008c */ sw $t0,0x8c($sp) +.L0f045714: +/* f045714: 3c077f1b */ lui $a3,%hi(var7f1a8bdc) +/* f045718: 8fa400f8 */ lw $a0,0xf8($sp) +/* f04571c: 8fa500fc */ lw $a1,0xfc($sp) +/* f045720: 24e78bdc */ addiu $a3,$a3,%lo(var7f1a8bdc) +/* f045724: 0c009393 */ jal cd00024e4c +/* f045728: 2406383b */ addiu $a2,$zero,0x3848 +/* f04572c: 8fa400f8 */ lw $a0,0xf8($sp) +/* f045730: 8fa500fc */ lw $a1,0xfc($sp) +/* f045734: 0fc112da */ jal func0f044b68 +/* f045738: 27a600dc */ addiu $a2,$sp,0xdc +.L0f04573c: +/* f04573c: 8fa400e8 */ lw $a0,0xe8($sp) +/* f045740: 0fc079ef */ jal chrSetOrUnsetHiddenFlag00000100 +/* f045744: 24050001 */ addiu $a1,$zero,0x1 +/* f045748: 8fa2008c */ lw $v0,0x8c($sp) +.L0f04574c: +/* f04574c: 8fbf002c */ lw $ra,0x2c($sp) +/* f045750: 8fb00028 */ lw $s0,0x28($sp) +/* f045754: 27bd00e8 */ addiu $sp,$sp,0xe8 +/* f045758: 03e00008 */ jr $ra +/* f04575c: 00000000 */ nop +); #endif GLOBAL_ASM( @@ -21643,15 +22422,19 @@ void chrTickGoPos(struct chrdata *chr) chrGoPosInitMagic(chr, &chr->act_gopos.waydata, &curwppos, &prop->pos); } - if (var80062cbc >= 9 #if VERSION >= VERSION_NTSC_1_0 + if (var80062cbc >= 9 && (chr->hidden & CHRHFLAG_00400000) - && (chr->flags & CHRFLAG0_CAN_GO_TO_PLACES) == 0 -#endif - ) { + && (chr->flags & CHRFLAG0_CAN_GO_TO_PLACES) == 0) { chrStop(chr); return; } +#else + if (var80062cbc >= 10) { + chrStop(chr); + return; + } +#endif // If goposforce is set then decrease it on each tick. If it's reached -1 // then stop the chr. I guess goposforce is not only used to warp past @@ -22231,9 +23014,11 @@ void chrTick(struct chrdata *chr) } } - chr->hidden &= ~CHRHFLAG_IS_HEARING_TARGET; #if VERSION >= VERSION_NTSC_1_0 + chr->hidden &= ~CHRHFLAG_IS_HEARING_TARGET; chr->hidden2 &= ~CHRH2FLAG_0040; +#else + chr->hidden &= ~(CHRHFLAG_IS_HEARING_TARGET | CHRHFLAG_00000200); #endif if (pass) { @@ -24153,18 +24938,18 @@ f32 chrGetLateralDistanceToCoord(struct chrdata *chr, struct coord *pos) return sqrtf(xdiff * xdiff + zdiff * zdiff); } +#if VERSION >= VERSION_NTSC_1_0 f32 chrGetLateralDistanceToPad(struct chrdata *chr, s32 pad_id) { struct prop *prop = chr->prop; f32 xdiff, zdiff; struct pad pad; + f32 distance = 0; + pad_id = chrResolvePadId(chr, pad_id); -#if VERSION >= VERSION_NTSC_1_0 - if (pad_id >= 0) -#endif - { + if (pad_id >= 0) { padUnpack(pad_id, PADFIELD_POS, &pad); xdiff = pad.pos.x - prop->pos.x; zdiff = pad.pos.z - prop->pos.z; @@ -24173,6 +24958,36 @@ f32 chrGetLateralDistanceToPad(struct chrdata *chr, s32 pad_id) return distance; } +#else +GLOBAL_ASM( +glabel chrGetLateralDistanceToPad +/* f048910: 27bdff88 */ addiu $sp,$sp,-120 +/* f048914: afbf0014 */ sw $ra,0x14($sp) +/* f048918: 8c8e001c */ lw $t6,0x1c($a0) +/* f04891c: 0fc1228f */ jal chrResolvePadId +/* f048920: afae0074 */ sw $t6,0x74($sp) +/* f048924: 00402025 */ or $a0,$v0,$zero +/* f048928: 24050002 */ addiu $a1,$zero,0x2 +/* f04892c: 0fc43fc4 */ jal padUnpack +/* f048930: 27a60018 */ addiu $a2,$sp,0x18 +/* f048934: 8fa20074 */ lw $v0,0x74($sp) +/* f048938: c7a40018 */ lwc1 $f4,0x18($sp) +/* f04893c: c7a80020 */ lwc1 $f8,0x20($sp) +/* f048940: c4460008 */ lwc1 $f6,0x8($v0) +/* f048944: c44a0010 */ lwc1 $f10,0x10($v0) +/* f048948: 46062001 */ sub.s $f0,$f4,$f6 +/* f04894c: 460a4081 */ sub.s $f2,$f8,$f10 +/* f048950: 46000402 */ mul.s $f16,$f0,$f0 +/* f048954: 00000000 */ sll $zero,$zero,0x0 +/* f048958: 46021482 */ mul.s $f18,$f2,$f2 +/* f04895c: 0c012e84 */ jal sqrtf +/* f048960: 46128300 */ add.s $f12,$f16,$f18 +/* f048964: 8fbf0014 */ lw $ra,0x14($sp) +/* f048968: 27bd0078 */ addiu $sp,$sp,0x78 +/* f04896c: 03e00008 */ jr $ra +/* f048970: 00000000 */ sll $zero,$zero,0x0 +); +#endif f32 chrGetSquaredDistanceToCoord(struct chrdata *chr, struct coord *pos) { @@ -25207,6 +26022,7 @@ bool chrAdjustPosForSpawn(f32 width, struct coord *pos, s16 *rooms, f32 angle, b * triggered, but the function will not attempt to spawn the chr until the next * time it's called. */ +#if VERSION >= VERSION_NTSC_1_0 struct prop *chrSpawnAtCoord(s32 bodynum, s32 headnum, struct coord *pos, s16 *rooms, f32 angle, u8 *ailist, u32 spawnflags) { struct prop *prop; @@ -25305,6 +26121,172 @@ struct prop *chrSpawnAtCoord(s32 bodynum, s32 headnum, struct coord *pos, s16 *r return NULL; } +#else +GLOBAL_ASM( +glabel chrSpawnAtCoord +/* f04a594: 27bdff98 */ addiu $sp,$sp,-104 +/* f04a598: afbf001c */ sw $ra,0x1c($sp) +/* f04a59c: afa40068 */ sw $a0,0x68($sp) +/* f04a5a0: afa5006c */ sw $a1,0x6c($sp) +/* f04a5a4: afa60070 */ sw $a2,0x70($sp) +/* f04a5a8: 0fc0801f */ jal getNumFreeChrSlots +/* f04a5ac: afa70074 */ sw $a3,0x74($sp) +/* f04a5b0: 28410002 */ slti $at,$v0,0x2 +/* f04a5b4: 14200049 */ bnez $at,.NB0f04a6dc +/* f04a5b8: 8fa30070 */ lw $v1,0x70($sp) +/* f04a5bc: 8fae006c */ lw $t6,0x6c($sp) +/* f04a5c0: 05c30006 */ bgezl $t6,.NB0f04a5dc +/* f04a5c4: c4640000 */ lwc1 $f4,0x0($v1) +/* f04a5c8: 0fc0b36d */ jal bodyChooseHead +/* f04a5cc: 8fa40068 */ lw $a0,0x68($sp) +/* f04a5d0: 8fa30070 */ lw $v1,0x70($sp) +/* f04a5d4: afa2006c */ sw $v0,0x6c($sp) +/* f04a5d8: c4640000 */ lwc1 $f4,0x0($v1) +.NB0f04a5dc: +/* f04a5dc: 8fa40074 */ lw $a0,0x74($sp) +/* f04a5e0: 27a50048 */ addiu $a1,$sp,0x48 +/* f04a5e4: e7a40058 */ swc1 $f4,0x58($sp) +/* f04a5e8: c4660004 */ lwc1 $f6,0x4($v1) +/* f04a5ec: e7a6005c */ swc1 $f6,0x5c($sp) +/* f04a5f0: c4680008 */ lwc1 $f8,0x8($v1) +/* f04a5f4: 0fc19283 */ jal roomsCopy +/* f04a5f8: e7a80060 */ swc1 $f8,0x60($sp) +/* f04a5fc: 8faf0080 */ lw $t7,0x80($sp) +/* f04a600: 3c0141a0 */ lui $at,0x41a0 +/* f04a604: 44816000 */ mtc1 $at,$f12 +/* f04a608: 31f80010 */ andi $t8,$t7,0x10 +/* f04a60c: 0018c82b */ sltu $t9,$zero,$t8 +/* f04a610: afb90010 */ sw $t9,0x10($sp) +/* f04a614: 27a50058 */ addiu $a1,$sp,0x58 +/* f04a618: 27a60048 */ addiu $a2,$sp,0x48 +/* f04a61c: 8fa70078 */ lw $a3,0x78($sp) +/* f04a620: 0fc128dd */ jal chrAdjustPosForSpawn +/* f04a624: afa00014 */ sw $zero,0x14($sp) +/* f04a628: 1040002c */ beqz $v0,.NB0f04a6dc +/* f04a62c: 8fa40068 */ lw $a0,0x68($sp) +/* f04a630: 8fa5006c */ lw $a1,0x6c($sp) +/* f04a634: 0fc0b343 */ jal modelAllocateChr +/* f04a638: 8fa60080 */ lw $a2,0x80($sp) +/* f04a63c: 10400027 */ beqz $v0,.NB0f04a6dc +/* f04a640: 00402025 */ or $a0,$v0,$zero +/* f04a644: 8fab007c */ lw $t3,0x7c($sp) +/* f04a648: 27a50058 */ addiu $a1,$sp,0x58 +/* f04a64c: 27a60048 */ addiu $a2,$sp,0x48 +/* f04a650: 8fa70078 */ lw $a3,0x78($sp) +/* f04a654: afa20040 */ sw $v0,0x40($sp) +/* f04a658: 0fc08202 */ jal propAllocateChr +/* f04a65c: afab0010 */ sw $t3,0x10($sp) +/* f04a660: 1040001c */ beqz $v0,.NB0f04a6d4 +/* f04a664: 8fa40040 */ lw $a0,0x40($sp) +/* f04a668: 00402025 */ or $a0,$v0,$zero +/* f04a66c: 0fc17dfe */ jal propActivateThisFrame +/* f04a670: afa20064 */ sw $v0,0x64($sp) +/* f04a674: 0fc17d6c */ jal propEnable +/* f04a678: 8fa40064 */ lw $a0,0x64($sp) +/* f04a67c: 8fac0064 */ lw $t4,0x64($sp) +/* f04a680: 8fad006c */ lw $t5,0x6c($sp) +/* f04a684: 8d830004 */ lw $v1,0x4($t4) +/* f04a688: a06d0006 */ sb $t5,0x6($v1) +/* f04a68c: 8fae0068 */ lw $t6,0x68($sp) +/* f04a690: a46e0010 */ sh $t6,0x10($v1) +/* f04a694: 84640010 */ lh $a0,0x10($v1) +/* f04a698: 0fc0b1e0 */ jal bodyGetRace +/* f04a69c: afa3003c */ sw $v1,0x3c($sp) +/* f04a6a0: 8fa3003c */ lw $v1,0x3c($sp) +/* f04a6a4: a06202fe */ sb $v0,0x2fe($v1) +/* f04a6a8: ac600114 */ sw $zero,0x114($v1) +/* f04a6ac: ac600118 */ sw $zero,0x118($v1) +/* f04a6b0: 8faf0080 */ lw $t7,0x80($sp) +/* f04a6b4: 31f82000 */ andi $t8,$t7,0x2000 +/* f04a6b8: 13000004 */ beqz $t8,.NB0f04a6cc +/* f04a6bc: 00000000 */ sll $zero,$zero,0x0 +/* f04a6c0: 906b032e */ lbu $t3,0x32e($v1) +/* f04a6c4: 356c0010 */ ori $t4,$t3,0x10 +/* f04a6c8: a06c032e */ sb $t4,0x32e($v1) +.NB0f04a6cc: +/* f04a6cc: 10000042 */ beqz $zero,.NB0f04a7d8 +/* f04a6d0: 8fa20064 */ lw $v0,0x64($sp) +.NB0f04a6d4: +/* f04a6d4: 0fc2c38b */ jal modelFree +/* f04a6d8: 00000000 */ sll $zero,$zero,0x0 +.NB0f04a6dc: +/* f04a6dc: 0fc0801f */ jal getNumFreeChrSlots +/* f04a6e0: 00000000 */ sll $zero,$zero,0x0 +/* f04a6e4: 28410004 */ slti $at,$v0,0x4 +/* f04a6e8: 5020003b */ beqzl $at,.NB0f04a7d8 +/* f04a6ec: 00001025 */ or $v0,$zero,$zero +/* f04a6f0: 0c004d84 */ jal random +/* f04a6f4: afa00034 */ sw $zero,0x34($sp) +/* f04a6f8: 3c0a8006 */ lui $t2,0x8006 +/* f04a6fc: 8d4a4e9c */ lw $t2,0x4e9c($t2) +/* f04a700: 3c058006 */ lui $a1,0x8006 +/* f04a704: 8fa60034 */ lw $a2,0x34($sp) +/* f04a708: 004a001b */ divu $zero,$v0,$t2 +/* f04a70c: 00004810 */ mfhi $t1 +/* f04a710: 01202025 */ or $a0,$t1,$zero +/* f04a714: 8ca54e98 */ lw $a1,0x4e98($a1) +/* f04a718: 24080005 */ addiu $t0,$zero,0x5 +/* f04a71c: 24070368 */ addiu $a3,$zero,0x368 +/* f04a720: 15400002 */ bnez $t2,.NB0f04a72c +/* f04a724: 00000000 */ sll $zero,$zero,0x0 +/* f04a728: 0007000d */ break 0x7 +.NB0f04a72c: +/* f04a72c: 00870019 */ multu $a0,$a3 +/* f04a730: 248b0001 */ addiu $t3,$a0,0x1 +/* f04a734: 00001812 */ mflo $v1 +/* f04a738: 00a31021 */ addu $v0,$a1,$v1 +/* f04a73c: 844d0000 */ lh $t5,0x0($v0) +/* f04a740: 05a00013 */ bltz $t5,.NB0f04a790 +/* f04a744: 00000000 */ sll $zero,$zero,0x0 +/* f04a748: 8c4e0020 */ lw $t6,0x20($v0) +/* f04a74c: 11c00010 */ beqz $t6,.NB0f04a790 +/* f04a750: 00000000 */ sll $zero,$zero,0x0 +/* f04a754: 8c4f001c */ lw $t7,0x1c($v0) +/* f04a758: 11e0000d */ beqz $t7,.NB0f04a790 +/* f04a75c: 00000000 */ sll $zero,$zero,0x0 +/* f04a760: 80580007 */ lb $t8,0x7($v0) +/* f04a764: 1518000a */ bne $t0,$t8,.NB0f04a790 +/* f04a768: 00000000 */ sll $zero,$zero,0x0 +/* f04a76c: 8c590034 */ lw $t9,0x34($v0) +/* f04a770: 2b210078 */ slti $at,$t9,0x78 +/* f04a774: 14200003 */ bnez $at,.NB0f04a784 +/* f04a778: 00000000 */ sll $zero,$zero,0x0 +/* f04a77c: 10000011 */ beqz $zero,.NB0f04a7c4 +/* f04a780: 00653021 */ addu $a2,$v1,$a1 +.NB0f04a784: +/* f04a784: 14c00002 */ bnez $a2,.NB0f04a790 +/* f04a788: 00000000 */ sll $zero,$zero,0x0 +/* f04a78c: 00653021 */ addu $a2,$v1,$a1 +.NB0f04a790: +/* f04a790: 016a001a */ div $zero,$t3,$t2 +/* f04a794: 00002010 */ mfhi $a0 +/* f04a798: 15400002 */ bnez $t2,.NB0f04a7a4 +/* f04a79c: 00000000 */ sll $zero,$zero,0x0 +/* f04a7a0: 0007000d */ break 0x7 +.NB0f04a7a4: +/* f04a7a4: 2401ffff */ addiu $at,$zero,-1 +/* f04a7a8: 15410004 */ bne $t2,$at,.NB0f04a7bc +/* f04a7ac: 3c018000 */ lui $at,0x8000 +/* f04a7b0: 15610002 */ bne $t3,$at,.NB0f04a7bc +/* f04a7b4: 00000000 */ sll $zero,$zero,0x0 +/* f04a7b8: 0006000d */ break 0x6 +.NB0f04a7bc: +/* f04a7bc: 1489ffdb */ bne $a0,$t1,.NB0f04a72c +/* f04a7c0: 00000000 */ sll $zero,$zero,0x0 +.NB0f04a7c4: +/* f04a7c4: 10c00003 */ beqz $a2,.NB0f04a7d4 +/* f04a7c8: 24020001 */ addiu $v0,$zero,0x1 +/* f04a7cc: acc20030 */ sw $v0,0x30($a2) +/* f04a7d0: acc2002c */ sw $v0,0x2c($a2) +.NB0f04a7d4: +/* f04a7d4: 00001025 */ or $v0,$zero,$zero +.NB0f04a7d8: +/* f04a7d8: 8fbf001c */ lw $ra,0x1c($sp) +/* f04a7dc: 27bd0068 */ addiu $sp,$sp,0x68 +/* f04a7e0: 03e00008 */ jr $ra +/* f04a7e4: 00000000 */ sll $zero,$zero,0x0 +); +#endif struct prop *chrSpawnAtPad(struct chrdata *basechr, s32 body, s32 head, s32 pad_id, u8 *ailist, u32 spawnflags) { @@ -26337,8 +27319,10 @@ bool chrRunFromPos(struct chrdata *chr, u32 speed, f32 rundist, struct coord *fr if (cdTestAToB4(&chr->prop->pos, chr->prop->rooms, &delta, CDTYPE_ALL, 4) == CDRESULT_COLLISION) { #if VERSION >= VERSION_PAL_FINAL cdGetPos(&delta, 18555, "chr/chraction.c"); -#else +#elif VERSION >= VERSION_NTSC_1_0 cdGetPos(&delta, 18547, "chraction.c"); +#else + cdGetPos(&delta, 18277, "chraction.c"); #endif } @@ -26677,7 +27661,7 @@ glabel var7f1a942c /* f04cbfc: 03e00008 */ jr $ra /* f04cc00: 24020001 */ addiu $v0,$zero,0x1 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f04c874 .late_rodata @@ -26920,6 +27904,249 @@ glabel var7f1a942c /* f04cbfc: 03e00008 */ jr $ra /* f04cc00: 24020001 */ addiu $v0,$zero,0x1 ); +#else +GLOBAL_ASM( +glabel func0f04c874 +.late_rodata +glabel var7f1a942c +.word 0x3c8ef461 +.text +/* f04c874: 27bdff18 */ addiu $sp,$sp,-232 +/* f04c878: afbf007c */ sw $ra,0x7c($sp) +/* f04c87c: afb40068 */ sw $s4,0x68($sp) +/* f04c880: afb30064 */ sw $s3,0x64($sp) +/* f04c884: afb20060 */ sw $s2,0x60($sp) +/* f04c888: afb00058 */ sw $s0,0x58($sp) +/* f04c88c: 00c08025 */ or $s0,$a2,$zero +/* f04c890: 00a09025 */ or $s2,$a1,$zero +/* f04c894: 00809825 */ or $s3,$a0,$zero +/* f04c898: 30f400ff */ andi $s4,$a3,0xff +/* f04c89c: afbe0078 */ sw $s8,0x78($sp) +/* f04c8a0: afb70074 */ sw $s7,0x74($sp) +/* f04c8a4: afb60070 */ sw $s6,0x70($sp) +/* f04c8a8: afb5006c */ sw $s5,0x6c($sp) +/* f04c8ac: afb1005c */ sw $s1,0x5c($sp) +/* f04c8b0: f7be0050 */ sdc1 $f30,0x50($sp) +/* f04c8b4: f7bc0048 */ sdc1 $f28,0x48($sp) +/* f04c8b8: f7ba0040 */ sdc1 $f26,0x40($sp) +/* f04c8bc: f7b80038 */ sdc1 $f24,0x38($sp) +/* f04c8c0: f7b60030 */ sdc1 $f22,0x30($sp) +/* f04c8c4: f7b40028 */ sdc1 $f20,0x28($sp) +/* f04c8c8: 0fc0a221 */ jal chrGetTargetProp +/* f04c8cc: afa700f4 */ sw $a3,0xf4($sp) +/* f04c8d0: 4480d000 */ mtc1 $zero,$f26 +/* f04c8d4: 00408825 */ or $s1,$v0,$zero +/* f04c8d8: 0fc131e1 */ jal func0f04c784 +/* f04c8dc: 02602025 */ or $a0,$s3,$zero +/* f04c8e0: 8e6e001c */ lw $t6,0x1c($s3) +/* f04c8e4: 3c0143b4 */ lui $at,0x43b4 +/* f04c8e8: 4481f000 */ mtc1 $at,$f30 +/* f04c8ec: c5c40008 */ lwc1 $f4,0x8($t6) +/* f04c8f0: 3c014334 */ lui $at,0x4334 +/* f04c8f4: 4481e000 */ mtc1 $at,$f28 +/* f04c8f8: e7a400c8 */ swc1 $f4,0xc8($sp) +/* f04c8fc: 8e6f001c */ lw $t7,0x1c($s3) +/* f04c900: 46000606 */ mov.s $f24,$f0 +/* f04c904: 27be00c8 */ addiu $s8,$sp,0xc8 +/* f04c908: c5e6000c */ lwc1 $f6,0xc($t7) +/* f04c90c: 27b7009c */ addiu $s7,$sp,0x9c +/* f04c910: 27b600a0 */ addiu $s6,$sp,0xa0 +/* f04c914: e7a600cc */ swc1 $f6,0xcc($sp) +/* f04c918: 8e78001c */ lw $t8,0x1c($s3) +/* f04c91c: 27b50098 */ addiu $s5,$sp,0x98 +/* f04c920: c7080010 */ lwc1 $f8,0x10($t8) +/* f04c924: e7a800d0 */ swc1 $f8,0xd0($sp) +/* f04c928: 44925000 */ mtc1 $s2,$f10 +.L0f04c92c: +/* f04c92c: 3c014f80 */ lui $at,0x4f80 +/* f04c930: 06410004 */ bgez $s2,.L0f04c944 +/* f04c934: 46805020 */ cvt.s.w $f0,$f10 +/* f04c938: 44818000 */ mtc1 $at,$f16 +/* f04c93c: 00000000 */ nop +/* f04c940: 46100000 */ add.s $f0,$f0,$f16 +.L0f04c944: +/* f04c944: 4600e03c */ c.lt.s $f28,$f0 +/* f04c948: 46000506 */ mov.s $f20,$f0 +/* f04c94c: 3c017f1b */ lui $at,%hi(var7f1a942c) +/* f04c950: 45020003 */ bc1fl .L0f04c960 +/* f04c954: 4618a501 */ sub.s $f20,$f20,$f24 +/* f04c958: 461e0501 */ sub.s $f20,$f0,$f30 +/* f04c95c: 4618a501 */ sub.s $f20,$f20,$f24 +.L0f04c960: +/* f04c960: c432942c */ lwc1 $f18,%lo(var7f1a942c)($at) +/* f04c964: 4612a502 */ mul.s $f20,$f20,$f18 +/* f04c968: 0c0068f4 */ jal cosf +/* f04c96c: 4600a306 */ mov.s $f12,$f20 +/* f04c970: 46000586 */ mov.s $f22,$f0 +/* f04c974: 0c0068f7 */ jal sinf +/* f04c978: 4600a306 */ mov.s $f12,$f20 +/* f04c97c: c62e0008 */ lwc1 $f14,0x8($s1) +/* f04c980: c7a400c8 */ lwc1 $f4,0xc8($sp) +/* f04c984: c7a600d0 */ lwc1 $f6,0xd0($sp) +/* f04c988: c6280010 */ lwc1 $f8,0x10($s1) +/* f04c98c: 460e2081 */ sub.s $f2,$f4,$f14 +/* f04c990: 02a02825 */ or $a1,$s5,$zero +/* f04c994: 02c03025 */ or $a2,$s6,$zero +/* f04c998: 46083301 */ sub.s $f12,$f6,$f8 +/* f04c99c: 46161282 */ mul.s $f10,$f2,$f22 +/* f04c9a0: 02e03825 */ or $a3,$s7,$zero +/* f04c9a4: 46006402 */ mul.s $f16,$f12,$f0 +/* f04c9a8: 46105481 */ sub.s $f18,$f10,$f16 +/* f04c9ac: 46001202 */ mul.s $f8,$f2,$f0 +/* f04c9b0: 00000000 */ nop +/* f04c9b4: 46166282 */ mul.s $f10,$f12,$f22 +/* f04c9b8: 46127100 */ add.s $f4,$f14,$f18 +/* f04c9bc: e6040000 */ swc1 $f4,0x0($s0) +/* f04c9c0: c7a600cc */ lwc1 $f6,0xcc($sp) +/* f04c9c4: 460a4400 */ add.s $f16,$f8,$f10 +/* f04c9c8: e6060004 */ swc1 $f6,0x4($s0) +/* f04c9cc: c6320010 */ lwc1 $f18,0x10($s1) +/* f04c9d0: 46109100 */ add.s $f4,$f18,$f16 +/* f04c9d4: e6040008 */ swc1 $f4,0x8($s0) +/* f04c9d8: 0fc0a277 */ jal propChrGetBbox +/* f04c9dc: 8e64001c */ lw $a0,0x1c($s3) +/* f04c9e0: c7a800cc */ lwc1 $f8,0xcc($sp) +/* f04c9e4: c7a600a0 */ lwc1 $f6,0xa0($sp) +/* f04c9e8: c7b2009c */ lwc1 $f18,0x9c($sp) +/* f04c9ec: 8e65001c */ lw $a1,0x1c($s3) +/* f04c9f0: 46083281 */ sub.s $f10,$f6,$f8 +/* f04c9f4: 24190001 */ addiu $t9,$zero,0x1 +/* f04c9f8: afb90010 */ sw $t9,0x10($sp) +/* f04c9fc: 46089401 */ sub.s $f16,$f18,$f8 +/* f04ca00: e7aa0014 */ swc1 $f10,0x14($sp) +/* f04ca04: 03c02025 */ or $a0,$s8,$zero +/* f04ca08: 02003025 */ or $a2,$s0,$zero +/* f04ca0c: e7b00018 */ swc1 $f16,0x18($sp) +/* f04ca10: 24070023 */ addiu $a3,$zero,0x23 +/* f04ca14: 0c00b5f0 */ jal cd0002d7c0 +/* f04ca18: 24a50028 */ addiu $a1,$a1,0x28 +/* f04ca1c: 1440002a */ bnez $v0,.L0f04cac8 +/* f04ca20: 02002025 */ or $a0,$s0,$zero +/* f04ca24: 3c067f1b */ lui $a2,%hi(var7f1a8ce4) +/* f04ca28: 24c68ce4 */ addiu $a2,$a2,%lo(var7f1a8ce4) +/* f04ca2c: 0c0093af */ jal cdGetPos +/* f04ca30: 240548fe */ addiu $a1,$zero,0x47f0 +/* f04ca34: c6040000 */ lwc1 $f4,0x0($s0) +/* f04ca38: c7a600c8 */ lwc1 $f6,0xc8($sp) +/* f04ca3c: c60a0008 */ lwc1 $f10,0x8($s0) +/* f04ca40: c7b200d0 */ lwc1 $f18,0xd0($sp) +/* f04ca44: 46062501 */ sub.s $f20,$f4,$f6 +/* f04ca48: 46125581 */ sub.s $f22,$f10,$f18 +/* f04ca4c: 4614a202 */ mul.s $f8,$f20,$f20 +/* f04ca50: 00000000 */ nop +/* f04ca54: 4616b402 */ mul.s $f16,$f22,$f22 +/* f04ca58: 0c012974 */ jal sqrtf +/* f04ca5c: 46104300 */ add.s $f12,$f8,$f16 +/* f04ca60: 3c014248 */ lui $at,0x4248 +/* f04ca64: 44812000 */ mtc1 $at,$f4 +/* f04ca68: 44805000 */ mtc1 $zero,$f10 +/* f04ca6c: c7b200c8 */ lwc1 $f18,0xc8($sp) +/* f04ca70: 46040181 */ sub.s $f6,$f0,$f4 +/* f04ca74: c7a400c8 */ lwc1 $f4,0xc8($sp) +/* f04ca78: 46003083 */ div.s $f2,$f6,$f0 +/* f04ca7c: 460a103c */ c.lt.s $f2,$f10 +/* f04ca80: 00000000 */ nop +/* f04ca84: 45000007 */ bc1f .L0f04caa4 +/* f04ca88: 00000000 */ nop +/* f04ca8c: e6120000 */ swc1 $f18,0x0($s0) +/* f04ca90: c7a800cc */ lwc1 $f8,0xcc($sp) +/* f04ca94: e6080004 */ swc1 $f8,0x4($s0) +/* f04ca98: c7b000d0 */ lwc1 $f16,0xd0($sp) +/* f04ca9c: 1000000a */ b .L0f04cac8 +/* f04caa0: e6100008 */ swc1 $f16,0x8($s0) +.L0f04caa4: +/* f04caa4: 4602a502 */ mul.s $f20,$f20,$f2 +/* f04caa8: 46142180 */ add.s $f6,$f4,$f20 +/* f04caac: 4602b582 */ mul.s $f22,$f22,$f2 +/* f04cab0: e6060000 */ swc1 $f6,0x0($s0) +/* f04cab4: c7aa00cc */ lwc1 $f10,0xcc($sp) +/* f04cab8: e60a0004 */ swc1 $f10,0x4($s0) +/* f04cabc: c7b200d0 */ lwc1 $f18,0xd0($sp) +/* f04cac0: 46169200 */ add.s $f8,$f18,$f22 +/* f04cac4: e6080008 */ swc1 $f8,0x8($s0) +.L0f04cac8: +/* f04cac8: 12800019 */ beqz $s4,.L0f04cb30 +/* f04cacc: 00001025 */ or $v0,$zero,$zero +/* f04cad0: c6000000 */ lwc1 $f0,0x0($s0) +/* f04cad4: c7b000c8 */ lwc1 $f16,0xc8($sp) +/* f04cad8: c7a400cc */ lwc1 $f4,0xcc($sp) +/* f04cadc: c6060004 */ lwc1 $f6,0x4($s0) +/* f04cae0: 46008081 */ sub.s $f2,$f16,$f0 +/* f04cae4: c7aa00d0 */ lwc1 $f10,0xd0($sp) +/* f04cae8: c6120008 */ lwc1 $f18,0x8($s0) +/* f04caec: 46062381 */ sub.s $f14,$f4,$f6 +/* f04caf0: 46021202 */ mul.s $f8,$f2,$f2 +/* f04caf4: e7a000a8 */ swc1 $f0,0xa8($sp) +/* f04caf8: 46125301 */ sub.s $f12,$f10,$f18 +/* f04cafc: 460e7402 */ mul.s $f16,$f14,$f14 +/* f04cb00: c60a0004 */ lwc1 $f10,0x4($s0) +/* f04cb04: 24080168 */ addiu $t0,$zero,0x168 +/* f04cb08: 460c6182 */ mul.s $f6,$f12,$f12 +/* f04cb0c: e7aa00ac */ swc1 $f10,0xac($sp) +/* f04cb10: c6120008 */ lwc1 $f18,0x8($s0) +/* f04cb14: 01129023 */ subu $s2,$t0,$s2 +/* f04cb18: 24020001 */ addiu $v0,$zero,0x1 +/* f04cb1c: 46104100 */ add.s $f4,$f8,$f16 +/* f04cb20: 0000a025 */ or $s4,$zero,$zero +/* f04cb24: e7b200b0 */ swc1 $f18,0xb0($sp) +/* f04cb28: 10000001 */ b .L0f04cb30 +/* f04cb2c: 46062680 */ add.s $f26,$f4,$f6 +.L0f04cb30: +/* f04cb30: 5440ff7e */ bnezl $v0,.L0f04c92c +/* f04cb34: 44925000 */ mtc1 $s2,$f10 +/* f04cb38: 44804000 */ mtc1 $zero,$f8 +/* f04cb3c: c7b000c8 */ lwc1 $f16,0xc8($sp) +/* f04cb40: 02602025 */ or $a0,$s3,$zero +/* f04cb44: 4608d032 */ c.eq.s $f26,$f8 +/* f04cb48: 02002825 */ or $a1,$s0,$zero +/* f04cb4c: 45010018 */ bc1t .L0f04cbb0 +/* f04cb50: 00000000 */ nop +/* f04cb54: c6040000 */ lwc1 $f4,0x0($s0) +/* f04cb58: c7a600cc */ lwc1 $f6,0xcc($sp) +/* f04cb5c: c60a0004 */ lwc1 $f10,0x4($s0) +/* f04cb60: 46048081 */ sub.s $f2,$f16,$f4 +/* f04cb64: c7b200d0 */ lwc1 $f18,0xd0($sp) +/* f04cb68: c6080008 */ lwc1 $f8,0x8($s0) +/* f04cb6c: 460a3381 */ sub.s $f14,$f6,$f10 +/* f04cb70: 46021402 */ mul.s $f16,$f2,$f2 +/* f04cb74: 46089301 */ sub.s $f12,$f18,$f8 +/* f04cb78: 460e7102 */ mul.s $f4,$f14,$f14 +/* f04cb7c: c7a800a8 */ lwc1 $f8,0xa8($sp) +/* f04cb80: 460c6282 */ mul.s $f10,$f12,$f12 +/* f04cb84: 46048180 */ add.s $f6,$f16,$f4 +/* f04cb88: 460a3480 */ add.s $f18,$f6,$f10 +/* f04cb8c: 461a903c */ c.lt.s $f18,$f26 +/* f04cb90: 00000000 */ nop +/* f04cb94: 45000006 */ bc1f .L0f04cbb0 +/* f04cb98: 00000000 */ nop +/* f04cb9c: e6080000 */ swc1 $f8,0x0($s0) +/* f04cba0: c7b000ac */ lwc1 $f16,0xac($sp) +/* f04cba4: e6100004 */ swc1 $f16,0x4($s0) +/* f04cba8: c7a400b0 */ lwc1 $f4,0xb0($sp) +/* f04cbac: e6040008 */ swc1 $f4,0x8($s0) +.L0f04cbb0: +/* f04cbb0: 0fc0eaf4 */ jal func0f03abd0 +/* f04cbb4: 93a600fb */ lbu $a2,0xfb($sp) +/* f04cbb8: 8fbf007c */ lw $ra,0x7c($sp) +/* f04cbbc: d7b40028 */ ldc1 $f20,0x28($sp) +/* f04cbc0: d7b60030 */ ldc1 $f22,0x30($sp) +/* f04cbc4: d7b80038 */ ldc1 $f24,0x38($sp) +/* f04cbc8: d7ba0040 */ ldc1 $f26,0x40($sp) +/* f04cbcc: d7bc0048 */ ldc1 $f28,0x48($sp) +/* f04cbd0: d7be0050 */ ldc1 $f30,0x50($sp) +/* f04cbd4: 8fb00058 */ lw $s0,0x58($sp) +/* f04cbd8: 8fb1005c */ lw $s1,0x5c($sp) +/* f04cbdc: 8fb20060 */ lw $s2,0x60($sp) +/* f04cbe0: 8fb30064 */ lw $s3,0x64($sp) +/* f04cbe4: 8fb40068 */ lw $s4,0x68($sp) +/* f04cbe8: 8fb5006c */ lw $s5,0x6c($sp) +/* f04cbec: 8fb60070 */ lw $s6,0x70($sp) +/* f04cbf0: 8fb70074 */ lw $s7,0x74($sp) +/* f04cbf4: 8fbe0078 */ lw $s8,0x78($sp) +/* f04cbf8: 27bd00e8 */ addiu $sp,$sp,0xe8 +/* f04cbfc: 03e00008 */ jr $ra +/* f04cc00: 24020001 */ addiu $v0,$zero,0x1 +); #endif // Mismatch: Probably due to variable reuse. diff --git a/src/game/chr/chrai.c b/src/game/chr/chrai.c index 61124bd3a..4c2a6c75f 100644 --- a/src/game/chr/chrai.c +++ b/src/game/chr/chrai.c @@ -778,7 +778,7 @@ void chraiExecute(void *entity, s32 proptype) u8 *cmd = g_Vars.aioffset + g_Vars.ailist; s32 type = (cmd[0] << 8) + cmd[1]; - if (type >= 0 && type <= 0x1e0) { + if (type >= 0 && type < ARRAYCOUNT(g_CommandPointers)) { if (g_CommandPointers[type]()) { break; } @@ -807,7 +807,7 @@ u32 chraiGetCommandLength(u8 *ailist, u32 aioffset) return (prop - aioffset) + 1; } - if (type >= 0 && type < NUM_AICOMMANDS) { + if (type >= 0 && type < ARRAYCOUNT(g_CommandLengths)) { return g_CommandLengths[type]; } diff --git a/src/game/credits.c b/src/game/credits.c index f166c5b6a..367b57407 100644 --- a/src/game/credits.c +++ b/src/game/credits.c @@ -5679,297 +5679,297 @@ glabel var7f1b5944 glabel var7f1b5948 .word 0x3fbbc6a8 .text -/* 7f135b64: 27bdff58 */ addiu $sp,$sp,-168 -/* 7f135b68: afbf001c */ sw $ra,0x1c($sp) -/* 7f135b6c: afb00018 */ sw $s0,0x18($sp) -/* 7f135b70: 0fc588b6 */ jal gfxAllocateMatrix -/* 7f135b74: 00808025 */ or $s0,$a0,$zero -/* 7f135b78: afa20064 */ sw $v0,0x64($sp) -/* 7f135b7c: 0fc53637 */ jal func0f1531dc -/* 7f135b80: 00002025 */ or $a0,$zero,$zero -/* 7f135b84: 240e0001 */ addiu $t6,$zero,0x1 -/* 7f135b88: 3c018008 */ lui $at,0x8008 -/* 7f135b8c: ac2e2320 */ sw $t6,0x2320($at) -/* 7f135b90: 0c002d00 */ jal vi0000b280 -/* 7f135b94: 02002025 */ or $a0,$s0,$zero -/* 7f135b98: 0c002cd4 */ jal vi0000b1d0 -/* 7f135b9c: 00402025 */ or $a0,$v0,$zero -/* 7f135ba0: 00402025 */ or $a0,$v0,$zero -/* 7f135ba4: 0fc4cc11 */ jal creditsClearFramebuffer -/* 7f135ba8: 240500ff */ addiu $a1,$zero,0xff -/* 7f135bac: 3c0fed00 */ lui $t7,0xed00 -/* 7f135bb0: 35ef0078 */ ori $t7,$t7,0x78 -/* 7f135bb4: afa20048 */ sw $v0,0x48($sp) -/* 7f135bb8: ac4f0000 */ sw $t7,0x0($v0) -/* 7f135bbc: 0c002f77 */ jal viGetWidth -/* 7f135bc0: 24500008 */ addiu $s0,$v0,0x8 -/* 7f135bc4: 0c002f7b */ jal viGetHeight -/* 7f135bc8: a7a20036 */ sh $v0,0x36($sp) -/* 7f135bcc: 2458ffe2 */ addiu $t8,$v0,-30 -/* 7f135bd0: 44982000 */ mtc1 $t8,$f4 -/* 7f135bd4: 87aa0036 */ lh $t2,0x36($sp) -/* 7f135bd8: 3c014080 */ lui $at,0x4080 -/* 7f135bdc: 468021a0 */ cvt.s.w $f6,$f4 -/* 7f135be0: 448a8000 */ mtc1 $t2,$f16 -/* 7f135be4: 44810000 */ mtc1 $at,$f0 -/* 7f135be8: 8fb80048 */ lw $t8,0x48($sp) -/* 7f135bec: 468084a0 */ cvt.s.w $f18,$f16 -/* 7f135bf0: 46003202 */ mul.s $f8,$f6,$f0 -/* 7f135bf4: 00000000 */ sll $zero,$zero,0x0 -/* 7f135bf8: 46009102 */ mul.s $f4,$f18,$f0 -/* 7f135bfc: 4600428d */ trunc.w.s $f10,$f8 -/* 7f135c00: 4600218d */ trunc.w.s $f6,$f4 -/* 7f135c04: 44085000 */ mfc1 $t0,$f10 -/* 7f135c08: 440c3000 */ mfc1 $t4,$f6 -/* 7f135c0c: 31090fff */ andi $t1,$t0,0xfff -/* 7f135c10: 318d0fff */ andi $t5,$t4,0xfff -/* 7f135c14: 000d7300 */ sll $t6,$t5,0xc -/* 7f135c18: 012e7825 */ or $t7,$t1,$t6 -/* 7f135c1c: 0fc4d645 */ jal creditsTick -/* 7f135c20: af0f0004 */ sw $t7,0x4($t8) -/* 7f135c24: 3c07800b */ lui $a3,0x800b -/* 7f135c28: 24e78730 */ addiu $a3,$a3,-30928 -/* 7f135c2c: 8ce30000 */ lw $v1,0x0($a3) -/* 7f135c30: 906441f4 */ lbu $a0,0x41f4($v1) -/* 7f135c34: 14800007 */ bnez $a0,.NB7f135c54 -/* 7f135c38: 00000000 */ sll $zero,$zero,0x0 -/* 7f135c3c: 8c624204 */ lw $v0,0x4204($v1) -/* 7f135c40: 2c41003c */ sltiu $at,$v0,0x3c -/* 7f135c44: 14200003 */ bnez $at,.NB7f135c54 -/* 7f135c48: 2c4104b1 */ sltiu $at,$v0,0x4b1 -/* 7f135c4c: 142000bd */ bnez $at,.NB7f135f44 -/* 7f135c50: 00000000 */ sll $zero,$zero,0x0 -.NB7f135c54: -/* 7f135c54: 14800066 */ bnez $a0,.NB7f135df0 -/* 7f135c58: 00000000 */ sll $zero,$zero,0x0 -/* 7f135c5c: 8c794204 */ lw $t9,0x4204($v1) -/* 7f135c60: 3c058008 */ lui $a1,0x8008 -/* 7f135c64: 24a51990 */ addiu $a1,$a1,0x1990 -/* 7f135c68: 2f2104b1 */ sltiu $at,$t9,0x4b1 -/* 7f135c6c: 14200060 */ bnez $at,.NB7f135df0 -/* 7f135c70: 00000000 */ sll $zero,$zero,0x0 -/* 7f135c74: 8ca80000 */ lw $t0,0x0($a1) -/* 7f135c78: 240a0001 */ addiu $t2,$zero,0x1 -/* 7f135c7c: 24642ef0 */ addiu $a0,$v1,0x2ef0 -/* 7f135c80: 15000007 */ bnez $t0,.NB7f135ca0 -/* 7f135c84: 3c018008 */ lui $at,0x8008 -/* 7f135c88: acaa0000 */ sw $t2,0x0($a1) -/* 7f135c8c: 0fc3c0ba */ jal func0f0f37a4 -/* 7f135c90: ac201f30 */ sw $zero,0x1f30($at) -/* 7f135c94: 3c07800b */ lui $a3,0x800b -/* 7f135c98: 24e78730 */ addiu $a3,$a3,-30928 -/* 7f135c9c: 8ce30000 */ lw $v1,0x0($a3) -.NB7f135ca0: -/* 7f135ca0: 3c028008 */ lui $v0,0x8008 -/* 7f135ca4: 3c0b800a */ lui $t3,0x800a -/* 7f135ca8: 8c421f30 */ lw $v0,0x1f30($v0) -/* 7f135cac: 8d6be700 */ lw $t3,-0x1900($t3) -/* 7f135cb0: 44800000 */ mtc1 $zero,$f0 -/* 7f135cb4: 004b1021 */ addu $v0,$v0,$t3 -/* 7f135cb8: 2c413841 */ sltiu $at,$v0,0x3841 -/* 7f135cbc: 54200003 */ bnezl $at,.NB7f135ccc -/* 7f135cc0: e460343c */ swc1 $f0,0x343c($v1) -/* 7f135cc4: 00001025 */ or $v0,$zero,$zero -/* 7f135cc8: e460343c */ swc1 $f0,0x343c($v1) -.NB7f135ccc: -/* 7f135ccc: 8cec0000 */ lw $t4,0x0($a3) -/* 7f135cd0: 3c017f1b */ lui $at,0x7f1b -/* 7f135cd4: 44829000 */ mtc1 $v0,$f18 -/* 7f135cd8: e5803414 */ swc1 $f0,0x3414($t4) -/* 7f135cdc: 8ced0000 */ lw $t5,0x0($a3) -/* 7f135ce0: c428fe74 */ lwc1 $f8,-0x18c($at) -/* 7f135ce4: 3c014f80 */ lui $at,0x4f80 -/* 7f135ce8: 46809120 */ cvt.s.w $f4,$f18 -/* 7f135cec: e5a83438 */ swc1 $f8,0x3438($t5) -/* 7f135cf0: 8ce30000 */ lw $v1,0x0($a3) -/* 7f135cf4: c46a3438 */ lwc1 $f10,0x3438($v1) -/* 7f135cf8: e46a3410 */ swc1 $f10,0x3410($v1) -/* 7f135cfc: 8ce90000 */ lw $t1,0x0($a3) -/* 7f135d00: e5203440 */ swc1 $f0,0x3440($t1) -/* 7f135d04: 8ce30000 */ lw $v1,0x0($a3) -/* 7f135d08: c4703440 */ lwc1 $f16,0x3440($v1) -/* 7f135d0c: 04410004 */ bgez $v0,.NB7f135d20 -/* 7f135d10: e4703418 */ swc1 $f16,0x3418($v1) -/* 7f135d14: 44813000 */ mtc1 $at,$f6 -/* 7f135d18: 00000000 */ sll $zero,$zero,0x0 -/* 7f135d1c: 46062100 */ add.s $f4,$f4,$f6 -.NB7f135d20: -/* 7f135d20: 3c014661 */ lui $at,0x4661 -/* 7f135d24: 44814000 */ mtc1 $at,$f8 -/* 7f135d28: 3c017f1b */ lui $at,0x7f1b -/* 7f135d2c: c430fe78 */ lwc1 $f16,-0x188($at) -/* 7f135d30: 46082283 */ div.s $f10,$f4,$f8 -/* 7f135d34: 3c017f1b */ lui $at,0x7f1b -/* 7f135d38: c426fe7c */ lwc1 $f6,-0x184($at) -/* 7f135d3c: 8cee0000 */ lw $t6,0x0($a3) -/* 7f135d40: 3c017f1b */ lui $at,0x7f1b -/* 7f135d44: 240804b0 */ addiu $t0,$zero,0x4b0 -/* 7f135d48: 02002025 */ or $a0,$s0,$zero -/* 7f135d4c: 24060004 */ addiu $a2,$zero,0x4 -/* 7f135d50: 46105482 */ mul.s $f18,$f10,$f16 -/* 7f135d54: 46123101 */ sub.s $f4,$f6,$f18 -/* 7f135d58: e5c43428 */ swc1 $f4,0x3428($t6) -/* 7f135d5c: 8cef0000 */ lw $t7,0x0($a3) -/* 7f135d60: c428fe80 */ lwc1 $f8,-0x180($at) -/* 7f135d64: 3c017f1b */ lui $at,0x7f1b -/* 7f135d68: e5e8342c */ swc1 $f8,0x342c($t7) -/* 7f135d6c: 8cf80000 */ lw $t8,0x0($a3) -/* 7f135d70: c42afe84 */ lwc1 $f10,-0x17c($at) -/* 7f135d74: 3c017f1b */ lui $at,0x7f1b -/* 7f135d78: e70a3430 */ swc1 $f10,0x3430($t8) -/* 7f135d7c: 8cf90000 */ lw $t9,0x0($a3) -/* 7f135d80: c430fe88 */ lwc1 $f16,-0x178($at) -/* 7f135d84: 3c018008 */ lui $at,0x8008 -/* 7f135d88: e7303434 */ swc1 $f16,0x3434($t9) -/* 7f135d8c: 8cea0000 */ lw $t2,0x0($a3) -/* 7f135d90: ad482efc */ sw $t0,0x2efc($t2) -/* 7f135d94: 8ce30000 */ lw $v1,0x0($a3) -/* 7f135d98: 906c34a1 */ lbu $t4,0x34a1($v1) -/* 7f135d9c: 358d0002 */ ori $t5,$t4,0x2 -/* 7f135da0: a06d34a1 */ sb $t5,0x34a1($v1) -/* 7f135da4: 8ce90000 */ lw $t1,0x0($a3) -/* 7f135da8: ad2034a4 */ sw $zero,0x34a4($t1) -/* 7f135dac: 8ce50000 */ lw $a1,0x0($a3) -/* 7f135db0: ac221f30 */ sw $v0,0x1f30($at) -/* 7f135db4: 0fc3c0fd */ jal func0f0f38b0 -/* 7f135db8: 24a52ef0 */ addiu $a1,$a1,0x2ef0 -/* 7f135dbc: 3c0e0102 */ lui $t6,0x102 -/* 7f135dc0: 35ce0040 */ ori $t6,$t6,0x40 -/* 7f135dc4: afa20040 */ sw $v0,0x40($sp) -/* 7f135dc8: ac4e0000 */ sw $t6,0x0($v0) -/* 7f135dcc: 8fa40064 */ lw $a0,0x64($sp) -/* 7f135dd0: 0c013100 */ jal osVirtualToPhysical -/* 7f135dd4: 24500008 */ addiu $s0,$v0,0x8 -/* 7f135dd8: 8faf0040 */ lw $t7,0x40($sp) -/* 7f135ddc: 02002025 */ or $a0,$s0,$zero -/* 7f135de0: 240500d8 */ addiu $a1,$zero,0xd8 -/* 7f135de4: 0fc4cc11 */ jal creditsClearFramebuffer -/* 7f135de8: ade20004 */ sw $v0,0x4($t7) -/* 7f135dec: 00408025 */ or $s0,$v0,$zero -.NB7f135df0: -/* 7f135df0: 0c005a28 */ jal mtx000159b0 -/* 7f135df4: 27a40068 */ addiu $a0,$sp,0x68 -/* 7f135df8: 27a40068 */ addiu $a0,$sp,0x68 -/* 7f135dfc: 0c005bd1 */ jal mtx00016054 -/* 7f135e00: 8fa50064 */ lw $a1,0x64($sp) -/* 7f135e04: 0fc2cb5e */ jal currentPlayerSetMatrix1740 -/* 7f135e08: 27a40068 */ addiu $a0,$sp,0x68 -/* 7f135e0c: 3c180102 */ lui $t8,0x102 -/* 7f135e10: 37180040 */ ori $t8,$t8,0x40 -/* 7f135e14: 02001825 */ or $v1,$s0,$zero -/* 7f135e18: ac780000 */ sw $t8,0x0($v1) -/* 7f135e1c: afa3003c */ sw $v1,0x3c($sp) -/* 7f135e20: 8fa40064 */ lw $a0,0x64($sp) -/* 7f135e24: 0c013100 */ jal osVirtualToPhysical -/* 7f135e28: 26100008 */ addiu $s0,$s0,0x8 -/* 7f135e2c: 8fa3003c */ lw $v1,0x3c($sp) -/* 7f135e30: 3c01c47a */ lui $at,0xc47a -/* 7f135e34: 44810000 */ mtc1 $at,$f0 -/* 7f135e38: ac620004 */ sw $v0,0x4($v1) -/* 7f135e3c: 3c01c2c8 */ lui $at,0xc2c8 -/* 7f135e40: 44803000 */ mtc1 $zero,$f6 -/* 7f135e44: 44809000 */ mtc1 $zero,$f18 -/* 7f135e48: 44812000 */ mtc1 $at,$f4 -/* 7f135e4c: 02002025 */ or $a0,$s0,$zero -/* 7f135e50: e7a00058 */ swc1 $f0,0x58($sp) -/* 7f135e54: e7a0005c */ swc1 $f0,0x5c($sp) -/* 7f135e58: e7a00060 */ swc1 $f0,0x60($sp) -/* 7f135e5c: e7a6004c */ swc1 $f6,0x4c($sp) -/* 7f135e60: e7b20050 */ swc1 $f18,0x50($sp) -/* 7f135e64: 0fc4caad */ jal creditsRenderBackground -/* 7f135e68: e7a40054 */ swc1 $f4,0x54($sp) -/* 7f135e6c: 0fc4cf66 */ jal creditsRenderSprites -/* 7f135e70: 00402025 */ or $a0,$v0,$zero -/* 7f135e74: 3c07800b */ lui $a3,0x800b -/* 7f135e78: 24e78730 */ addiu $a3,$a3,-30928 -/* 7f135e7c: 8ce30000 */ lw $v1,0x0($a3) -/* 7f135e80: 00408025 */ or $s0,$v0,$zero -/* 7f135e84: 906441f4 */ lbu $a0,0x41f4($v1) -/* 7f135e88: 10800009 */ beqz $a0,.NB7f135eb0 -/* 7f135e8c: 00000000 */ sll $zero,$zero,0x0 -/* 7f135e90: 0fc347cf */ jal func0f0d479c -/* 7f135e94: 00402025 */ or $a0,$v0,$zero -/* 7f135e98: 0fc4d3bd */ jal func0f13a3ec -/* 7f135e9c: 00402025 */ or $a0,$v0,$zero -/* 7f135ea0: 3c03800b */ lui $v1,0x800b -/* 7f135ea4: 8c638730 */ lw $v1,-0x78d0($v1) -/* 7f135ea8: 00408025 */ or $s0,$v0,$zero -/* 7f135eac: 906441f4 */ lbu $a0,0x41f4($v1) -.NB7f135eb0: -/* 7f135eb0: 14800024 */ bnez $a0,.NB7f135f44 -/* 7f135eb4: 00000000 */ sll $zero,$zero,0x0 -/* 7f135eb8: 8c624204 */ lw $v0,0x4204($v1) -/* 7f135ebc: 00002825 */ or $a1,$zero,$zero -/* 7f135ec0: 240300ff */ addiu $v1,$zero,0xff -/* 7f135ec4: 2c41003c */ sltiu $at,$v0,0x3c -/* 7f135ec8: 5020000b */ beqzl $at,.NB7f135ef8 -/* 7f135ecc: 2c4104b1 */ sltiu $at,$v0,0x4b1 -/* 7f135ed0: 00430019 */ multu $v0,$v1 -/* 7f135ed4: 2401003c */ addiu $at,$zero,0x3c -/* 7f135ed8: 00002812 */ mflo $a1 -/* 7f135edc: 00000000 */ sll $zero,$zero,0x0 -/* 7f135ee0: 00000000 */ sll $zero,$zero,0x0 -/* 7f135ee4: 00a1001b */ divu $zero,$a1,$at -/* 7f135ee8: 00002812 */ mflo $a1 -/* 7f135eec: 00000000 */ sll $zero,$zero,0x0 -/* 7f135ef0: 00000000 */ sll $zero,$zero,0x0 -/* 7f135ef4: 2c4104b1 */ sltiu $at,$v0,0x4b1 -.NB7f135ef8: -/* 7f135ef8: 1420000d */ bnez $at,.NB7f135f30 -/* 7f135efc: 240300ff */ addiu $v1,$zero,0xff -/* 7f135f00: 2c4104ec */ sltiu $at,$v0,0x4ec -/* 7f135f04: 1020000a */ beqz $at,.NB7f135f30 -/* 7f135f08: 2448fb50 */ addiu $t0,$v0,-1200 -/* 7f135f0c: 01030019 */ multu $t0,$v1 -/* 7f135f10: 2401003c */ addiu $at,$zero,0x3c -/* 7f135f14: 00005012 */ mflo $t2 -/* 7f135f18: 00000000 */ sll $zero,$zero,0x0 -/* 7f135f1c: 00000000 */ sll $zero,$zero,0x0 -/* 7f135f20: 0141001b */ divu $zero,$t2,$at -/* 7f135f24: 00005812 */ mflo $t3 -/* 7f135f28: 006b2823 */ subu $a1,$v1,$t3 -/* 7f135f2c: 00000000 */ sll $zero,$zero,0x0 -.NB7f135f30: -/* 7f135f30: 10a00004 */ beqz $a1,.NB7f135f44 -/* 7f135f34: 00000000 */ sll $zero,$zero,0x0 -/* 7f135f38: 0fc4cc11 */ jal creditsClearFramebuffer -/* 7f135f3c: 02002025 */ or $a0,$s0,$zero -/* 7f135f40: 00408025 */ or $s0,$v0,$zero -.NB7f135f44: -/* 7f135f44: 3c0c8008 */ lui $t4,0x8008 -/* 7f135f48: 8d8c1998 */ lw $t4,0x1998($t4) -/* 7f135f4c: 00002025 */ or $a0,$zero,$zero -/* 7f135f50: 51800018 */ beqzl $t4,.NB7f135fb4 -/* 7f135f54: 8fbf001c */ lw $ra,0x1c($sp) -/* 7f135f58: 0c005790 */ jal joyGetButtons -/* 7f135f5c: 3405ffff */ dli $a1,0xffff -/* 7f135f60: 10400013 */ beqz $v0,.NB7f135fb0 -/* 7f135f64: 240d0026 */ addiu $t5,$zero,0x26 -/* 7f135f68: 3c018006 */ lui $at,0x8006 -/* 7f135f6c: ac2d49f4 */ sw $t5,0x49f4($at) -/* 7f135f70: 0fc06821 */ jal setNumPlayers -/* 7f135f74: 24040001 */ addiu $a0,$zero,0x1 -/* 7f135f78: 3c048006 */ lui $a0,0x8006 -/* 7f135f7c: 0c003c56 */ jal mainChangeToStage -/* 7f135f80: 8c8449f4 */ lw $a0,0x49f4($a0) -/* 7f135f84: 3c01800a */ lui $at,0x800a -/* 7f135f88: ac20e954 */ sw $zero,-0x16ac($at) -/* 7f135f8c: 2402ffff */ addiu $v0,$zero,-1 -/* 7f135f90: 3c01800a */ lui $at,0x800a -/* 7f135f94: ac22e958 */ sw $v0,-0x16a8($at) -/* 7f135f98: 3c01800a */ lui $at,0x800a -/* 7f135f9c: ac22e95c */ sw $v0,-0x16a4($at) -/* 7f135fa0: 0fc59ed6 */ jal lvSetDifficulty -/* 7f135fa4: 00002025 */ or $a0,$zero,$zero -/* 7f135fa8: 0c00281a */ jal viBlack -/* 7f135fac: 24040001 */ addiu $a0,$zero,0x1 -.NB7f135fb0: -/* 7f135fb0: 8fbf001c */ lw $ra,0x1c($sp) -.NB7f135fb4: -/* 7f135fb4: 02001025 */ or $v0,$s0,$zero -/* 7f135fb8: 8fb00018 */ lw $s0,0x18($sp) -/* 7f135fbc: 03e00008 */ jr $ra -/* 7f135fc0: 27bd00a8 */ addiu $sp,$sp,0xa8 +/* f135b64: 27bdff58 */ addiu $sp,$sp,-168 +/* f135b68: afbf001c */ sw $ra,0x1c($sp) +/* f135b6c: afb00018 */ sw $s0,0x18($sp) +/* f135b70: 0fc588b6 */ jal gfxAllocateMatrix +/* f135b74: 00808025 */ or $s0,$a0,$zero +/* f135b78: afa20064 */ sw $v0,0x64($sp) +/* f135b7c: 0fc53637 */ jal func0f1531dc +/* f135b80: 00002025 */ or $a0,$zero,$zero +/* f135b84: 240e0001 */ addiu $t6,$zero,0x1 +/* f135b88: 3c018008 */ lui $at,0x8008 +/* f135b8c: ac2e2320 */ sw $t6,0x2320($at) +/* f135b90: 0c002d00 */ jal vi0000b280 +/* f135b94: 02002025 */ or $a0,$s0,$zero +/* f135b98: 0c002cd4 */ jal vi0000b1d0 +/* f135b9c: 00402025 */ or $a0,$v0,$zero +/* f135ba0: 00402025 */ or $a0,$v0,$zero +/* f135ba4: 0fc4cc11 */ jal creditsClearFramebuffer +/* f135ba8: 240500ff */ addiu $a1,$zero,0xff +/* f135bac: 3c0fed00 */ lui $t7,0xed00 +/* f135bb0: 35ef0078 */ ori $t7,$t7,0x78 +/* f135bb4: afa20048 */ sw $v0,0x48($sp) +/* f135bb8: ac4f0000 */ sw $t7,0x0($v0) +/* f135bbc: 0c002f77 */ jal viGetWidth +/* f135bc0: 24500008 */ addiu $s0,$v0,0x8 +/* f135bc4: 0c002f7b */ jal viGetHeight +/* f135bc8: a7a20036 */ sh $v0,0x36($sp) +/* f135bcc: 2458ffe2 */ addiu $t8,$v0,-30 +/* f135bd0: 44982000 */ mtc1 $t8,$f4 +/* f135bd4: 87aa0036 */ lh $t2,0x36($sp) +/* f135bd8: 3c014080 */ lui $at,0x4080 +/* f135bdc: 468021a0 */ cvt.s.w $f6,$f4 +/* f135be0: 448a8000 */ mtc1 $t2,$f16 +/* f135be4: 44810000 */ mtc1 $at,$f0 +/* f135be8: 8fb80048 */ lw $t8,0x48($sp) +/* f135bec: 468084a0 */ cvt.s.w $f18,$f16 +/* f135bf0: 46003202 */ mul.s $f8,$f6,$f0 +/* f135bf4: 00000000 */ sll $zero,$zero,0x0 +/* f135bf8: 46009102 */ mul.s $f4,$f18,$f0 +/* f135bfc: 4600428d */ trunc.w.s $f10,$f8 +/* f135c00: 4600218d */ trunc.w.s $f6,$f4 +/* f135c04: 44085000 */ mfc1 $t0,$f10 +/* f135c08: 440c3000 */ mfc1 $t4,$f6 +/* f135c0c: 31090fff */ andi $t1,$t0,0xfff +/* f135c10: 318d0fff */ andi $t5,$t4,0xfff +/* f135c14: 000d7300 */ sll $t6,$t5,0xc +/* f135c18: 012e7825 */ or $t7,$t1,$t6 +/* f135c1c: 0fc4d645 */ jal creditsTick +/* f135c20: af0f0004 */ sw $t7,0x4($t8) +/* f135c24: 3c07800b */ lui $a3,0x800b +/* f135c28: 24e78730 */ addiu $a3,$a3,-30928 +/* f135c2c: 8ce30000 */ lw $v1,0x0($a3) +/* f135c30: 906441f4 */ lbu $a0,0x41f4($v1) +/* f135c34: 14800007 */ bnez $a0,.NB0f135c54 +/* f135c38: 00000000 */ sll $zero,$zero,0x0 +/* f135c3c: 8c624204 */ lw $v0,0x4204($v1) +/* f135c40: 2c41003c */ sltiu $at,$v0,0x3c +/* f135c44: 14200003 */ bnez $at,.NB0f135c54 +/* f135c48: 2c4104b1 */ sltiu $at,$v0,0x4b1 +/* f135c4c: 142000bd */ bnez $at,.NB0f135f44 +/* f135c50: 00000000 */ sll $zero,$zero,0x0 +.NB0f135c54: +/* f135c54: 14800066 */ bnez $a0,.NB0f135df0 +/* f135c58: 00000000 */ sll $zero,$zero,0x0 +/* f135c5c: 8c794204 */ lw $t9,0x4204($v1) +/* f135c60: 3c058008 */ lui $a1,0x8008 +/* f135c64: 24a51990 */ addiu $a1,$a1,0x1990 +/* f135c68: 2f2104b1 */ sltiu $at,$t9,0x4b1 +/* f135c6c: 14200060 */ bnez $at,.NB0f135df0 +/* f135c70: 00000000 */ sll $zero,$zero,0x0 +/* f135c74: 8ca80000 */ lw $t0,0x0($a1) +/* f135c78: 240a0001 */ addiu $t2,$zero,0x1 +/* f135c7c: 24642ef0 */ addiu $a0,$v1,0x2ef0 +/* f135c80: 15000007 */ bnez $t0,.NB0f135ca0 +/* f135c84: 3c018008 */ lui $at,0x8008 +/* f135c88: acaa0000 */ sw $t2,0x0($a1) +/* f135c8c: 0fc3c0ba */ jal func0f0f37a4 +/* f135c90: ac201f30 */ sw $zero,0x1f30($at) +/* f135c94: 3c07800b */ lui $a3,0x800b +/* f135c98: 24e78730 */ addiu $a3,$a3,-30928 +/* f135c9c: 8ce30000 */ lw $v1,0x0($a3) +.NB0f135ca0: +/* f135ca0: 3c028008 */ lui $v0,0x8008 +/* f135ca4: 3c0b800a */ lui $t3,0x800a +/* f135ca8: 8c421f30 */ lw $v0,0x1f30($v0) +/* f135cac: 8d6be700 */ lw $t3,-0x1900($t3) +/* f135cb0: 44800000 */ mtc1 $zero,$f0 +/* f135cb4: 004b1021 */ addu $v0,$v0,$t3 +/* f135cb8: 2c413841 */ sltiu $at,$v0,0x3841 +/* f135cbc: 54200003 */ bnezl $at,.NB0f135ccc +/* f135cc0: e460343c */ swc1 $f0,0x343c($v1) +/* f135cc4: 00001025 */ or $v0,$zero,$zero +/* f135cc8: e460343c */ swc1 $f0,0x343c($v1) +.NB0f135ccc: +/* f135ccc: 8cec0000 */ lw $t4,0x0($a3) +/* f135cd0: 3c017f1b */ lui $at,0x7f1b +/* f135cd4: 44829000 */ mtc1 $v0,$f18 +/* f135cd8: e5803414 */ swc1 $f0,0x3414($t4) +/* f135cdc: 8ced0000 */ lw $t5,0x0($a3) +/* f135ce0: c428fe74 */ lwc1 $f8,-0x18c($at) +/* f135ce4: 3c014f80 */ lui $at,0x4f80 +/* f135ce8: 46809120 */ cvt.s.w $f4,$f18 +/* f135cec: e5a83438 */ swc1 $f8,0x3438($t5) +/* f135cf0: 8ce30000 */ lw $v1,0x0($a3) +/* f135cf4: c46a3438 */ lwc1 $f10,0x3438($v1) +/* f135cf8: e46a3410 */ swc1 $f10,0x3410($v1) +/* f135cfc: 8ce90000 */ lw $t1,0x0($a3) +/* f135d00: e5203440 */ swc1 $f0,0x3440($t1) +/* f135d04: 8ce30000 */ lw $v1,0x0($a3) +/* f135d08: c4703440 */ lwc1 $f16,0x3440($v1) +/* f135d0c: 04410004 */ bgez $v0,.NB0f135d20 +/* f135d10: e4703418 */ swc1 $f16,0x3418($v1) +/* f135d14: 44813000 */ mtc1 $at,$f6 +/* f135d18: 00000000 */ sll $zero,$zero,0x0 +/* f135d1c: 46062100 */ add.s $f4,$f4,$f6 +.NB0f135d20: +/* f135d20: 3c014661 */ lui $at,0x4661 +/* f135d24: 44814000 */ mtc1 $at,$f8 +/* f135d28: 3c017f1b */ lui $at,0x7f1b +/* f135d2c: c430fe78 */ lwc1 $f16,-0x188($at) +/* f135d30: 46082283 */ div.s $f10,$f4,$f8 +/* f135d34: 3c017f1b */ lui $at,0x7f1b +/* f135d38: c426fe7c */ lwc1 $f6,-0x184($at) +/* f135d3c: 8cee0000 */ lw $t6,0x0($a3) +/* f135d40: 3c017f1b */ lui $at,0x7f1b +/* f135d44: 240804b0 */ addiu $t0,$zero,0x4b0 +/* f135d48: 02002025 */ or $a0,$s0,$zero +/* f135d4c: 24060004 */ addiu $a2,$zero,0x4 +/* f135d50: 46105482 */ mul.s $f18,$f10,$f16 +/* f135d54: 46123101 */ sub.s $f4,$f6,$f18 +/* f135d58: e5c43428 */ swc1 $f4,0x3428($t6) +/* f135d5c: 8cef0000 */ lw $t7,0x0($a3) +/* f135d60: c428fe80 */ lwc1 $f8,-0x180($at) +/* f135d64: 3c017f1b */ lui $at,0x7f1b +/* f135d68: e5e8342c */ swc1 $f8,0x342c($t7) +/* f135d6c: 8cf80000 */ lw $t8,0x0($a3) +/* f135d70: c42afe84 */ lwc1 $f10,-0x17c($at) +/* f135d74: 3c017f1b */ lui $at,0x7f1b +/* f135d78: e70a3430 */ swc1 $f10,0x3430($t8) +/* f135d7c: 8cf90000 */ lw $t9,0x0($a3) +/* f135d80: c430fe88 */ lwc1 $f16,-0x178($at) +/* f135d84: 3c018008 */ lui $at,0x8008 +/* f135d88: e7303434 */ swc1 $f16,0x3434($t9) +/* f135d8c: 8cea0000 */ lw $t2,0x0($a3) +/* f135d90: ad482efc */ sw $t0,0x2efc($t2) +/* f135d94: 8ce30000 */ lw $v1,0x0($a3) +/* f135d98: 906c34a1 */ lbu $t4,0x34a1($v1) +/* f135d9c: 358d0002 */ ori $t5,$t4,0x2 +/* f135da0: a06d34a1 */ sb $t5,0x34a1($v1) +/* f135da4: 8ce90000 */ lw $t1,0x0($a3) +/* f135da8: ad2034a4 */ sw $zero,0x34a4($t1) +/* f135dac: 8ce50000 */ lw $a1,0x0($a3) +/* f135db0: ac221f30 */ sw $v0,0x1f30($at) +/* f135db4: 0fc3c0fd */ jal func0f0f38b0 +/* f135db8: 24a52ef0 */ addiu $a1,$a1,0x2ef0 +/* f135dbc: 3c0e0102 */ lui $t6,0x102 +/* f135dc0: 35ce0040 */ ori $t6,$t6,0x40 +/* f135dc4: afa20040 */ sw $v0,0x40($sp) +/* f135dc8: ac4e0000 */ sw $t6,0x0($v0) +/* f135dcc: 8fa40064 */ lw $a0,0x64($sp) +/* f135dd0: 0c013100 */ jal osVirtualToPhysical +/* f135dd4: 24500008 */ addiu $s0,$v0,0x8 +/* f135dd8: 8faf0040 */ lw $t7,0x40($sp) +/* f135ddc: 02002025 */ or $a0,$s0,$zero +/* f135de0: 240500d8 */ addiu $a1,$zero,0xd8 +/* f135de4: 0fc4cc11 */ jal creditsClearFramebuffer +/* f135de8: ade20004 */ sw $v0,0x4($t7) +/* f135dec: 00408025 */ or $s0,$v0,$zero +.NB0f135df0: +/* f135df0: 0c005a28 */ jal mtx000159b0 +/* f135df4: 27a40068 */ addiu $a0,$sp,0x68 +/* f135df8: 27a40068 */ addiu $a0,$sp,0x68 +/* f135dfc: 0c005bd1 */ jal mtx00016054 +/* f135e00: 8fa50064 */ lw $a1,0x64($sp) +/* f135e04: 0fc2cb5e */ jal currentPlayerSetMatrix1740 +/* f135e08: 27a40068 */ addiu $a0,$sp,0x68 +/* f135e0c: 3c180102 */ lui $t8,0x102 +/* f135e10: 37180040 */ ori $t8,$t8,0x40 +/* f135e14: 02001825 */ or $v1,$s0,$zero +/* f135e18: ac780000 */ sw $t8,0x0($v1) +/* f135e1c: afa3003c */ sw $v1,0x3c($sp) +/* f135e20: 8fa40064 */ lw $a0,0x64($sp) +/* f135e24: 0c013100 */ jal osVirtualToPhysical +/* f135e28: 26100008 */ addiu $s0,$s0,0x8 +/* f135e2c: 8fa3003c */ lw $v1,0x3c($sp) +/* f135e30: 3c01c47a */ lui $at,0xc47a +/* f135e34: 44810000 */ mtc1 $at,$f0 +/* f135e38: ac620004 */ sw $v0,0x4($v1) +/* f135e3c: 3c01c2c8 */ lui $at,0xc2c8 +/* f135e40: 44803000 */ mtc1 $zero,$f6 +/* f135e44: 44809000 */ mtc1 $zero,$f18 +/* f135e48: 44812000 */ mtc1 $at,$f4 +/* f135e4c: 02002025 */ or $a0,$s0,$zero +/* f135e50: e7a00058 */ swc1 $f0,0x58($sp) +/* f135e54: e7a0005c */ swc1 $f0,0x5c($sp) +/* f135e58: e7a00060 */ swc1 $f0,0x60($sp) +/* f135e5c: e7a6004c */ swc1 $f6,0x4c($sp) +/* f135e60: e7b20050 */ swc1 $f18,0x50($sp) +/* f135e64: 0fc4caad */ jal creditsRenderBackground +/* f135e68: e7a40054 */ swc1 $f4,0x54($sp) +/* f135e6c: 0fc4cf66 */ jal creditsRenderSprites +/* f135e70: 00402025 */ or $a0,$v0,$zero +/* f135e74: 3c07800b */ lui $a3,0x800b +/* f135e78: 24e78730 */ addiu $a3,$a3,-30928 +/* f135e7c: 8ce30000 */ lw $v1,0x0($a3) +/* f135e80: 00408025 */ or $s0,$v0,$zero +/* f135e84: 906441f4 */ lbu $a0,0x41f4($v1) +/* f135e88: 10800009 */ beqz $a0,.NB0f135eb0 +/* f135e8c: 00000000 */ sll $zero,$zero,0x0 +/* f135e90: 0fc347cf */ jal func0f0d479c +/* f135e94: 00402025 */ or $a0,$v0,$zero +/* f135e98: 0fc4d3bd */ jal func0f13a3ec +/* f135e9c: 00402025 */ or $a0,$v0,$zero +/* f135ea0: 3c03800b */ lui $v1,0x800b +/* f135ea4: 8c638730 */ lw $v1,-0x78d0($v1) +/* f135ea8: 00408025 */ or $s0,$v0,$zero +/* f135eac: 906441f4 */ lbu $a0,0x41f4($v1) +.NB0f135eb0: +/* f135eb0: 14800024 */ bnez $a0,.NB0f135f44 +/* f135eb4: 00000000 */ sll $zero,$zero,0x0 +/* f135eb8: 8c624204 */ lw $v0,0x4204($v1) +/* f135ebc: 00002825 */ or $a1,$zero,$zero +/* f135ec0: 240300ff */ addiu $v1,$zero,0xff +/* f135ec4: 2c41003c */ sltiu $at,$v0,0x3c +/* f135ec8: 5020000b */ beqzl $at,.NB0f135ef8 +/* f135ecc: 2c4104b1 */ sltiu $at,$v0,0x4b1 +/* f135ed0: 00430019 */ multu $v0,$v1 +/* f135ed4: 2401003c */ addiu $at,$zero,0x3c +/* f135ed8: 00002812 */ mflo $a1 +/* f135edc: 00000000 */ sll $zero,$zero,0x0 +/* f135ee0: 00000000 */ sll $zero,$zero,0x0 +/* f135ee4: 00a1001b */ divu $zero,$a1,$at +/* f135ee8: 00002812 */ mflo $a1 +/* f135eec: 00000000 */ sll $zero,$zero,0x0 +/* f135ef0: 00000000 */ sll $zero,$zero,0x0 +/* f135ef4: 2c4104b1 */ sltiu $at,$v0,0x4b1 +.NB0f135ef8: +/* f135ef8: 1420000d */ bnez $at,.NB0f135f30 +/* f135efc: 240300ff */ addiu $v1,$zero,0xff +/* f135f00: 2c4104ec */ sltiu $at,$v0,0x4ec +/* f135f04: 1020000a */ beqz $at,.NB0f135f30 +/* f135f08: 2448fb50 */ addiu $t0,$v0,-1200 +/* f135f0c: 01030019 */ multu $t0,$v1 +/* f135f10: 2401003c */ addiu $at,$zero,0x3c +/* f135f14: 00005012 */ mflo $t2 +/* f135f18: 00000000 */ sll $zero,$zero,0x0 +/* f135f1c: 00000000 */ sll $zero,$zero,0x0 +/* f135f20: 0141001b */ divu $zero,$t2,$at +/* f135f24: 00005812 */ mflo $t3 +/* f135f28: 006b2823 */ subu $a1,$v1,$t3 +/* f135f2c: 00000000 */ sll $zero,$zero,0x0 +.NB0f135f30: +/* f135f30: 10a00004 */ beqz $a1,.NB0f135f44 +/* f135f34: 00000000 */ sll $zero,$zero,0x0 +/* f135f38: 0fc4cc11 */ jal creditsClearFramebuffer +/* f135f3c: 02002025 */ or $a0,$s0,$zero +/* f135f40: 00408025 */ or $s0,$v0,$zero +.NB0f135f44: +/* f135f44: 3c0c8008 */ lui $t4,0x8008 +/* f135f48: 8d8c1998 */ lw $t4,0x1998($t4) +/* f135f4c: 00002025 */ or $a0,$zero,$zero +/* f135f50: 51800018 */ beqzl $t4,.NB0f135fb4 +/* f135f54: 8fbf001c */ lw $ra,0x1c($sp) +/* f135f58: 0c005790 */ jal joyGetButtons +/* f135f5c: 3405ffff */ dli $a1,0xffff +/* f135f60: 10400013 */ beqz $v0,.NB0f135fb0 +/* f135f64: 240d0026 */ addiu $t5,$zero,0x26 +/* f135f68: 3c018006 */ lui $at,0x8006 +/* f135f6c: ac2d49f4 */ sw $t5,0x49f4($at) +/* f135f70: 0fc06821 */ jal setNumPlayers +/* f135f74: 24040001 */ addiu $a0,$zero,0x1 +/* f135f78: 3c048006 */ lui $a0,0x8006 +/* f135f7c: 0c003c56 */ jal mainChangeToStage +/* f135f80: 8c8449f4 */ lw $a0,0x49f4($a0) +/* f135f84: 3c01800a */ lui $at,0x800a +/* f135f88: ac20e954 */ sw $zero,-0x16ac($at) +/* f135f8c: 2402ffff */ addiu $v0,$zero,-1 +/* f135f90: 3c01800a */ lui $at,0x800a +/* f135f94: ac22e958 */ sw $v0,-0x16a8($at) +/* f135f98: 3c01800a */ lui $at,0x800a +/* f135f9c: ac22e95c */ sw $v0,-0x16a4($at) +/* f135fa0: 0fc59ed6 */ jal lvSetDifficulty +/* f135fa4: 00002025 */ or $a0,$zero,$zero +/* f135fa8: 0c00281a */ jal viBlack +/* f135fac: 24040001 */ addiu $a0,$zero,0x1 +.NB0f135fb0: +/* f135fb0: 8fbf001c */ lw $ra,0x1c($sp) +.NB0f135fb4: +/* f135fb4: 02001025 */ or $v0,$s0,$zero +/* f135fb8: 8fb00018 */ lw $s0,0x18($sp) +/* f135fbc: 03e00008 */ jr $ra +/* f135fc0: 27bd00a8 */ addiu $sp,$sp,0xa8 ); #endif diff --git a/src/game/debug1.c b/src/game/debug1.c index e70021b4c..9d19088b9 100644 --- a/src/game/debug1.c +++ b/src/game/debug1.c @@ -5,9 +5,9 @@ #include "data.h" #include "types.h" -s32 var80075d60 = 0x00000000; -u32 var80075d64 = 0x00000000; -u32 var80075d68 = 0x00000000; +s32 var80078120nb = 0x00000000; +u32 var80078124nb = 0x00000000; +u32 var80078128nb = 0x00000000; u32 var8007812cnb = 0x00000000; u32 var80078130nb = 0x00000000; diff --git a/src/game/debug2.c b/src/game/debug2.c index ddb1b9829..7ecf53945 100644 --- a/src/game/debug2.c +++ b/src/game/debug2.c @@ -5,7 +5,7 @@ #include "data.h" #include "types.h" -s32 var800769d0nb[] = { +s32 var80078150nb[] = { 15, 30, 45, @@ -17,7 +17,7 @@ s32 var800769d0nb[] = { -1, }; -u32 var800769f4nb[] = { +u32 var80078174nb[] = { 8, 2, 8, 3, 8, 4, @@ -254,11 +254,11 @@ char *g_DebugMenuLabels[] = { "-", }; -s32 var80076f04nb[] = { +s32 var80078684nb[] = { 0, -1, }; -u32 var80076f0cnb[] = { +u32 var8007868cnb[] = { 8, 2, 8, 3, 8, 4, @@ -271,35 +271,111 @@ u32 var80076f0cnb[] = { 8, 11, }; -u32 var80076f5cnb[] = { - 0x00000000, 0x00000000, 0x00000000, 0x00000002, - 0x00000002, 0x00000002, 0x00000002, 0x00000000, - 0x00000001, 0x00000001, 0x00000001, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000001, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000001, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x80500000, 0x00040000, - 0x7f000000, 0x7f100000, 0x80600000, 0x00040000, - 0x70000000, 0x70100000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0xbf800000, 0x00000000, - 0x3f800000, 0x00000000, 0x00000000, 0x3f800000, - 0x00000000, 0x00000000, 0x3f800000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x00000000, - 0x00000000, 0x00000000, 0x00000000, 0x3f800000, - 0x00000000, -}; +u32 var800786dcnb = 0x00000000; +u32 var800786e0nb = 0x00000000; +u32 var800786e4nb = 0x00000000; +s32 var80075d60 = 2; +u32 var80075d64 = 2; +u32 var80075d68 = 2; +u32 var800786f4nb = 0x00000002; +u32 var800786f8nb = 0x00000000; +u32 var800786fcnb = 0x00000001; +u32 var80078700nb = 0x00000001; +u32 var80078704nb = 0x00000001; +u32 var80078708nb = 0x00000000; +u32 var8007870cnb = 0x00000000; +u32 var80078710nb = 0x00000000; +u32 var80078714nb = 0x00000000; +u32 var80078718nb = 0x00000000; +u32 var8007871cnb = 0x00000000; +u32 var80078720nb = 0x00000000; +u32 var80078724nb = 0x00000000; +u32 var80078728nb = 0x00000000; +u32 var8007872cnb = 0x00000000; +u32 var80078730nb = 0x00000000; +u32 var80078734nb = 0x00000000; +u32 var80078738nb = 0x00000000; +u32 var8007873cnb = 0x00000000; +u32 var80078740nb = 0x00000000; +u32 var80078744nb = 0x00000000; +u32 var80078748nb = 0x00000000; +u32 var8007874cnb = 0x00000000; +u32 var80078750nb = 0x00000000; +u32 var80078754nb = 0x00000000; +u32 var80078758nb = 0x00000000; +u32 var8007875cnb = 0x00000000; +u32 var80078760nb = 0x00000000; +u32 var80078764nb = 0x00000000; +u32 var80078768nb = 0x00000000; +u32 var8007876cnb = 0x00000000; +u32 var80078770nb = 0x00000000; +u32 var80078774nb = 0x00000000; +u32 var80078778nb = 0x00000000; +u32 var8007877cnb = 0x00000000; +u32 var80078780nb = 0x00000000; +u32 var80078784nb = 0x00000000; +u32 var80078788nb = 0x00000000; +u32 var8007878cnb = 0x00000000; +u32 var80078790nb = 0x00000000; +u32 var80078794nb = 0x00000001; +u32 var80078798nb = 0x00000000; +u32 var8007879cnb = 0x00000000; +u32 var800787a0nb = 0x00000000; +u32 var800787a4nb = 0x00000000; +u32 var800787a8nb = 0x00000000; +u32 var800787acnb = 0x00000000; +u32 var800787b0nb = 0x00000000; +u32 var800787b4nb = 0x00000000; +u32 var800787b8nb = 0x00000000; +u32 var800787bcnb = 0x00000000; +u32 var800787c0nb = 0x00000000; +u32 var800787c4nb = 0x00000001; +u32 var800787c8nb = 0x00000000; +u32 var800787ccnb = 0x00000000; +u32 var800787d0nb = 0x00000000; +u32 var800787d4nb = 0x00000000; +u32 var800787d8nb = 0x00000000; +u32 var800787dcnb = 0x00000000; +u32 var800787e0nb = 0x00000000; +u32 var800787e4nb = 0x00000000; +u32 var800787e8nb = 0x00000000; +u32 var800787ecnb = 0x00000000; +u32 var800787f0nb = 0x00000000; +u32 var800787f4nb = 0x80500000; +u32 var800787f8nb = 0x00040000; +u32 var800787fcnb = 0x7f000000; +u32 var80078800nb = 0x7f100000; +u32 var80078804nb = 0x80600000; +u32 var80078808nb = 0x00040000; +u32 var8007880cnb = 0x70000000; +u32 var80078810nb = 0x70100000; +u32 var80078814nb = 0x00000000; +u32 var80078818nb = 0x00000000; +u32 var8007881cnb = 0x00000000; +u32 var80078820nb = 0x00000000; +u32 var80078824nb = 0x00000000; +u32 var80078828nb = 0x00000000; +u32 var8007882cnb = 0x00000000; +u32 var80078830nb = 0x00000000; +u32 var80078834nb = 0xbf800000; +u32 var80078838nb = 0x00000000; +u32 var8007883cnb = 0x3f800000; +u32 var80078840nb = 0x00000000; +u32 var80078844nb = 0x00000000; +u32 var80078848nb = 0x3f800000; +u32 var8007884cnb = 0x00000000; +u32 var80078850nb = 0x00000000; +u32 var80078854nb = 0x3f800000; +u32 var80078858nb = 0x00000000; +u32 var8007885cnb = 0x00000000; +u32 var80078860nb = 0x00000000; +u32 var80078864nb = 0x00000000; +u32 var80078868nb = 0x00000000; +u32 var8007886cnb = 0x00000000; +u32 var80078870nb = 0x00000000; +u32 var80078874nb = 0x00000000; +u32 var80078878nb = 0x3f800000; +u32 var8007887cnb = 0x00000000; const char var7f1af378nb[] = "main"; const char var7f1af380nb[] = "scene %d"; diff --git a/src/game/dlights.c b/src/game/dlights.c index c70bcf175..092038dd4 100644 --- a/src/game/dlights.c +++ b/src/game/dlights.c @@ -1142,7 +1142,12 @@ void roomSetLightsFaulty(s32 roomnum, s32 chance) } } +#if VERSION >= VERSION_NTSC_1_0 g_Rooms[roomnum].unk4c = 50; +#else + g_Rooms[roomnum].unk4c = 15; +#endif + g_Rooms[roomnum].flags |= ROOMFLAG_DIRTY; } @@ -2240,6 +2245,7 @@ void roomSetLighting(s32 roomnum, s32 operation, u8 arg2, u8 arg3, u8 arg4) } } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f002ef8 /* f002ef8: 0004c0c0 */ sll $t8,$a0,0x3 @@ -2558,6 +2564,326 @@ glabel func0f002ef8 /* f0033a8: 03e00008 */ jr $ra /* f0033ac: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f002ef8 +/* f002ef8: 0004c0c0 */ sll $t8,$a0,0x3 +/* f002efc: 0304c021 */ addu $t8,$t8,$a0 +/* f002f00: 3c0e800a */ lui $t6,%hi(g_Rooms) +/* f002f04: 8dce4928 */ lw $t6,%lo(g_Rooms)($t6) +/* f002f08: 27bdff28 */ addiu $sp,$sp,-216 +/* f002f0c: 0018c080 */ sll $t8,$t8,0x2 +/* f002f10: 0304c023 */ subu $t8,$t8,$a0 +/* f002f14: 0018c080 */ sll $t8,$t8,0x2 +/* f002f18: afbf0044 */ sw $ra,0x44($sp) +/* f002f1c: afa400d8 */ sw $a0,0xd8($sp) +/* f002f20: afa500dc */ sw $a1,0xdc($sp) +/* f002f24: 01d8c821 */ addu $t9,$t6,$t8 +/* f002f28: 972a000a */ lhu $t2,0xa($t9) +/* f002f2c: 3c0f800a */ lui $t7,%hi(g_BgLightsFileData) +/* f002f30: 8def4cd8 */ lw $t7,%lo(g_BgLightsFileData)($t7) +/* f002f34: 01456021 */ addu $t4,$t2,$a1 +/* f002f38: 000c6900 */ sll $t5,$t4,0x4 +/* f002f3c: 01ac6821 */ addu $t5,$t5,$t4 +/* f002f40: 000d6840 */ sll $t5,$t5,0x1 +/* f002f44: 01af1821 */ addu $v1,$t5,$t7 +/* f002f48: 80780005 */ lb $t8,0x5($v1) +/* f002f4c: 07020004 */ bltzl $t8,.L0f002f60 +/* f002f50: 94790004 */ lhu $t9,0x4($v1) +/* f002f54: 10000112 */ b .L0f0033a0 +/* f002f58: 00001025 */ or $v0,$zero,$zero +/* f002f5c: 94790004 */ lhu $t9,0x4($v1) +.L0f002f60: +/* f002f60: 00195ec0 */ sll $t3,$t9,0x1b +/* f002f64: 05610102 */ bgez $t3,.L0f003370 +/* f002f68: 00000000 */ nop +/* f002f6c: 0c004b70 */ jal random +/* f002f70: afa300d4 */ sw $v1,0xd4($sp) +/* f002f74: 304c0007 */ andi $t4,$v0,0x7 +/* f002f78: 15800005 */ bnez $t4,.L0f002f90 +/* f002f7c: 8fa300d4 */ lw $v1,0xd4($sp) +/* f002f80: 906d0005 */ lbu $t5,0x5($v1) +/* f002f84: 31afffef */ andi $t7,$t5,0xffef +/* f002f88: 10000104 */ b .L0f00339c +/* f002f8c: a06f0005 */ sb $t7,0x5($v1) +.L0f002f90: +/* f002f90: 0c004b70 */ jal random +/* f002f94: afa300d4 */ sw $v1,0xd4($sp) +/* f002f98: 304e0001 */ andi $t6,$v0,0x1 +/* f002f9c: 15c000ff */ bnez $t6,.L0f00339c +/* f002fa0: 8fa300d4 */ lw $v1,0xd4($sp) +/* f002fa4: 0c004b70 */ jal random +/* f002fa8: afa300d4 */ sw $v1,0xd4($sp) +/* f002fac: 44822000 */ mtc1 $v0,$f4 +/* f002fb0: 04410005 */ bgez $v0,.L0f002fc8 +/* f002fb4: 468021a0 */ cvt.s.w $f6,$f4 +/* f002fb8: 3c014f80 */ lui $at,0x4f80 +/* f002fbc: 44814000 */ mtc1 $at,$f8 +/* f002fc0: 00000000 */ nop +/* f002fc4: 46083180 */ add.s $f6,$f6,$f8 +.L0f002fc8: +/* f002fc8: 3c012f80 */ lui $at,0x2f80 +/* f002fcc: 44815000 */ mtc1 $at,$f10 +/* f002fd0: 3c013f80 */ lui $at,0x3f80 +/* f002fd4: 44814000 */ mtc1 $at,$f8 +/* f002fd8: 460a3002 */ mul.s $f0,$f6,$f10 +/* f002fdc: 46000100 */ add.s $f4,$f0,$f0 +/* f002fe0: 46082301 */ sub.s $f12,$f4,$f8 +/* f002fe4: 0c004b70 */ jal random +/* f002fe8: e7ac0070 */ swc1 $f12,0x70($sp) +/* f002fec: 44823000 */ mtc1 $v0,$f6 +/* f002ff0: 8fa300d4 */ lw $v1,0xd4($sp) +/* f002ff4: c7ac0070 */ lwc1 $f12,0x70($sp) +/* f002ff8: 04410005 */ bgez $v0,.L0f003010 +/* f002ffc: 468032a0 */ cvt.s.w $f10,$f6 +/* f003000: 3c014f80 */ lui $at,0x4f80 +/* f003004: 44812000 */ mtc1 $at,$f4 +/* f003008: 00000000 */ nop +/* f00300c: 46045280 */ add.s $f10,$f10,$f4 +.L0f003010: +/* f003010: 3c012f80 */ lui $at,0x2f80 +/* f003014: 44814000 */ mtc1 $at,$f8 +/* f003018: 3c013f80 */ lui $at,0x3f80 +/* f00301c: 44812000 */ mtc1 $at,$f4 +/* f003020: 46085002 */ mul.s $f0,$f10,$f8 +/* f003024: 2409ffff */ addiu $t1,$zero,-1 +/* f003028: 3c077f1a */ lui $a3,%hi(var7f1a7bb4) +/* f00302c: 24e77bb4 */ addiu $a3,$a3,%lo(var7f1a7bb4) +/* f003030: 2406060a */ addiu $a2,$zero,0x622 +/* f003034: 46000180 */ add.s $f6,$f0,$f0 +/* f003038: 46043081 */ sub.s $f2,$f6,$f4 +/* f00303c: e7a2006c */ swc1 $f2,0x6c($sp) +/* f003040: 8468000a */ lh $t0,0xa($v1) +/* f003044: 84780010 */ lh $t8,0x10($v1) +/* f003048: 846f0016 */ lh $t7,0x16($v1) +/* f00304c: 846a0012 */ lh $t2,0x12($v1) +/* f003050: 0308c823 */ subu $t9,$t8,$t0 +/* f003054: 44995000 */ mtc1 $t9,$f10 +/* f003058: 01e87023 */ subu $t6,$t7,$t0 +/* f00305c: 448e2000 */ mtc1 $t6,$f4 +/* f003060: 468053a0 */ cvt.s.w $f14,$f10 +/* f003064: 8464000c */ lh $a0,0xc($v1) +/* f003068: 846c0014 */ lh $t4,0x14($v1) +/* f00306c: 8465000e */ lh $a1,0xe($v1) +/* f003070: 01445823 */ subu $t3,$t2,$a0 +/* f003074: 468022a0 */ cvt.s.w $f10,$f4 +/* f003078: 448b4000 */ mtc1 $t3,$f8 +/* f00307c: 01856823 */ subu $t5,$t4,$a1 +/* f003080: 448d3000 */ mtc1 $t5,$f6 +/* f003084: 460e6382 */ mul.s $f14,$f12,$f14 +/* f003088: e7aa00bc */ swc1 $f10,0xbc($sp) +/* f00308c: 84780018 */ lh $t8,0x18($v1) +/* f003090: 46804420 */ cvt.s.w $f16,$f8 +/* f003094: 0304c823 */ subu $t9,$t8,$a0 +/* f003098: 44994000 */ mtc1 $t9,$f8 +/* f00309c: 27a40098 */ addiu $a0,$sp,0x98 +/* f0030a0: 468034a0 */ cvt.s.w $f18,$f6 +/* f0030a4: 46106402 */ mul.s $f16,$f12,$f16 +/* f0030a8: 00000000 */ nop +/* f0030ac: 46126482 */ mul.s $f18,$f12,$f18 +/* f0030b0: c7ac006c */ lwc1 $f12,0x6c($sp) +/* f0030b4: 468041a0 */ cvt.s.w $f6,$f8 +/* f0030b8: e7a600c0 */ swc1 $f6,0xc0($sp) +/* f0030bc: 846a001a */ lh $t2,0x1a($v1) +/* f0030c0: 01455823 */ subu $t3,$t2,$a1 +/* f0030c4: 448b2000 */ mtc1 $t3,$f4 +/* f0030c8: 27a500a4 */ addiu $a1,$sp,0xa4 +/* f0030cc: 46802220 */ cvt.s.w $f8,$f4 +/* f0030d0: 460a1102 */ mul.s $f4,$f2,$f10 +/* f0030d4: 44885000 */ mtc1 $t0,$f10 +/* f0030d8: 46066002 */ mul.s $f0,$f12,$f6 +/* f0030dc: e7a800c4 */ swc1 $f8,0xc4($sp) +/* f0030e0: 46086082 */ mul.s $f2,$f12,$f8 +/* f0030e4: e7a400bc */ swc1 $f4,0xbc($sp) +/* f0030e8: c7a800bc */ lwc1 $f8,0xbc($sp) +/* f0030ec: 46805120 */ cvt.s.w $f4,$f10 +/* f0030f0: 460e2180 */ add.s $f6,$f4,$f14 +/* f0030f4: 46083280 */ add.s $f10,$f6,$f8 +/* f0030f8: e7aa0098 */ swc1 $f10,0x98($sp) +/* f0030fc: 846c000a */ lh $t4,0xa($v1) +/* f003100: 448c2000 */ mtc1 $t4,$f4 +/* f003104: 00000000 */ nop +/* f003108: 468021a0 */ cvt.s.w $f6,$f4 +/* f00310c: 46103200 */ add.s $f8,$f6,$f16 +/* f003110: 46004280 */ add.s $f10,$f8,$f0 +/* f003114: e7aa009c */ swc1 $f10,0x9c($sp) +/* f003118: 846d000a */ lh $t5,0xa($v1) +/* f00311c: 448d2000 */ mtc1 $t5,$f4 +/* f003120: 00000000 */ nop +/* f003124: 468021a0 */ cvt.s.w $f6,$f4 +/* f003128: 46123200 */ add.s $f8,$f6,$f18 +/* f00312c: 46024280 */ add.s $f10,$f8,$f2 +/* f003130: e7aa00a0 */ swc1 $f10,0xa0($sp) +/* f003134: 806f0007 */ lb $t7,0x7($v1) +/* f003138: 448f2000 */ mtc1 $t7,$f4 +/* f00313c: 00000000 */ nop +/* f003140: 468021a0 */ cvt.s.w $f6,$f4 +/* f003144: e7a6008c */ swc1 $f6,0x8c($sp) +/* f003148: 806e0008 */ lb $t6,0x8($v1) +/* f00314c: 448e4000 */ mtc1 $t6,$f8 +/* f003150: 00000000 */ nop +/* f003154: 468042a0 */ cvt.s.w $f10,$f8 +/* f003158: c7a8008c */ lwc1 $f8,0x8c($sp) +/* f00315c: e7aa0090 */ swc1 $f10,0x90($sp) +/* f003160: 80780009 */ lb $t8,0x9($v1) +/* f003164: 46004287 */ neg.s $f10,$f8 +/* f003168: afa90068 */ sw $t1,0x68($sp) +/* f00316c: 44982000 */ mtc1 $t8,$f4 +/* f003170: e7aa0080 */ swc1 $f10,0x80($sp) +/* f003174: 468021a0 */ cvt.s.w $f6,$f4 +/* f003178: c7a40090 */ lwc1 $f4,0x90($sp) +/* f00317c: e7a60094 */ swc1 $f6,0x94($sp) +/* f003180: c7a80094 */ lwc1 $f8,0x94($sp) +/* f003184: 46002187 */ neg.s $f6,$f4 +/* f003188: 46004287 */ neg.s $f10,$f8 +/* f00318c: e7a60084 */ swc1 $f6,0x84($sp) +/* f003190: 0fc5dc59 */ jal func0f177164 +/* f003194: e7aa0088 */ swc1 $f10,0x88($sp) +/* f003198: c7b200a4 */ lwc1 $f18,0xa4($sp) +/* f00319c: c7b00080 */ lwc1 $f16,0x80($sp) +/* f0031a0: c7ae00a8 */ lwc1 $f14,0xa8($sp) +/* f0031a4: c7ac0084 */ lwc1 $f12,0x84($sp) +/* f0031a8: 46109400 */ add.s $f16,$f18,$f16 +/* f0031ac: c7b200ac */ lwc1 $f18,0xac($sp) +/* f0031b0: c7aa0088 */ lwc1 $f10,0x88($sp) +/* f0031b4: 460c7300 */ add.s $f12,$f14,$f12 +/* f0031b8: 27a400a4 */ addiu $a0,$sp,0xa4 +/* f0031bc: 3c077f1a */ lui $a3,%hi(var7f1a7bc0) +/* f0031c0: 460a9280 */ add.s $f10,$f18,$f10 +/* f0031c4: e7b000a4 */ swc1 $f16,0xa4($sp) +/* f0031c8: e7ac00a8 */ swc1 $f12,0xa8($sp) +/* f0031cc: 00802825 */ or $a1,$a0,$zero +/* f0031d0: e7aa00ac */ swc1 $f10,0xac($sp) +/* f0031d4: 2406060c */ addiu $a2,$zero,0x624 +/* f0031d8: 0fc5dc59 */ jal func0f177164 +/* f0031dc: 24e77bc0 */ addiu $a3,$a3,%lo(var7f1a7bc0) +/* f0031e0: 8fa400d8 */ lw $a0,0xd8($sp) +/* f0031e4: 0004c880 */ sll $t9,$a0,0x2 +/* f0031e8: 0324c821 */ addu $t9,$t9,$a0 +/* f0031ec: 0019c880 */ sll $t9,$t9,0x2 +/* f0031f0: 0c004b70 */ jal random +/* f0031f4: afb90058 */ sw $t9,0x58($sp) +/* f0031f8: 30430003 */ andi $v1,$v0,0x3 +/* f0031fc: 1060000a */ beqz $v1,.L0f003228 +/* f003200: 8fa90068 */ lw $t1,0x68($sp) +/* f003204: 24010001 */ addiu $at,$zero,0x1 +/* f003208: 10610009 */ beq $v1,$at,.L0f003230 +/* f00320c: 24010002 */ addiu $at,$zero,0x2 +/* f003210: 10610009 */ beq $v1,$at,.L0f003238 +/* f003214: 24010003 */ addiu $at,$zero,0x3 +/* f003218: 5061000a */ beql $v1,$at,.L0f003244 +/* f00321c: 24090014 */ addiu $t1,$zero,0x14 +/* f003220: 10000009 */ b .L0f003248 +/* f003224: 8fa400d8 */ lw $a0,0xd8($sp) +.L0f003228: +/* f003228: 10000006 */ b .L0f003244 +/* f00322c: 24090011 */ addiu $t1,$zero,0x11 +.L0f003230: +/* f003230: 10000004 */ b .L0f003244 +/* f003234: 24090012 */ addiu $t1,$zero,0x12 +.L0f003238: +/* f003238: 10000002 */ b .L0f003244 +/* f00323c: 24090013 */ addiu $t1,$zero,0x13 +/* f003240: 24090014 */ addiu $t1,$zero,0x14 +.L0f003244: +/* f003244: 8fa400d8 */ lw $a0,0xd8($sp) +.L0f003248: +/* f003248: 8fa500dc */ lw $a1,0xdc($sp) +/* f00324c: 27a60074 */ addiu $a2,$sp,0x74 +/* f003250: 0fc0037f */ jal lightGetBboxCentre +/* f003254: afa90068 */ sw $t1,0x68($sp) +/* f003258: 3c0b800a */ lui $t3,%hi(g_BgRooms) +/* f00325c: 8d6b4cc4 */ lw $t3,%lo(g_BgRooms)($t3) +/* f003260: 8fac0058 */ lw $t4,0x58($sp) +/* f003264: c7a60074 */ lwc1 $f6,0x74($sp) +/* f003268: c7a40078 */ lwc1 $f4,0x78($sp) +/* f00326c: 016c1821 */ addu $v1,$t3,$t4 +/* f003270: c4680004 */ lwc1 $f8,0x4($v1) +/* f003274: 8fa90068 */ lw $t1,0x68($sp) +/* f003278: 27ad008c */ addiu $t5,$sp,0x8c +/* f00327c: 46083280 */ add.s $f10,$f6,$f8 +/* f003280: 8fa400d8 */ lw $a0,0xd8($sp) +/* f003284: 00002825 */ or $a1,$zero,$zero +/* f003288: 27a60074 */ addiu $a2,$sp,0x74 +/* f00328c: e7aa0074 */ swc1 $f10,0x74($sp) +/* f003290: c4660008 */ lwc1 $f6,0x8($v1) +/* f003294: c7aa007c */ lwc1 $f10,0x7c($sp) +/* f003298: 27a700a4 */ addiu $a3,$sp,0xa4 +/* f00329c: 46062200 */ add.s $f8,$f4,$f6 +/* f0032a0: e7a80078 */ swc1 $f8,0x78($sp) +/* f0032a4: c464000c */ lwc1 $f4,0xc($v1) +/* f0032a8: afad0010 */ sw $t5,0x10($sp) +/* f0032ac: afa90014 */ sw $t1,0x14($sp) +/* f0032b0: 46045180 */ add.s $f6,$f10,$f4 +/* f0032b4: 0fc4be7c */ jal sparksCreate +/* f0032b8: e7a6007c */ swc1 $f6,0x7c($sp) +/* f0032bc: 0c004b70 */ jal random +/* f0032c0: 00000000 */ nop +/* f0032c4: 304f0003 */ andi $t7,$v0,0x3 +/* f0032c8: 15e00008 */ bnez $t7,.L0f0032ec +/* f0032cc: 8fae00d8 */ lw $t6,0xd8($sp) +/* f0032d0: 2418ffff */ addiu $t8,$zero,-1 +/* f0032d4: a7ae0064 */ sh $t6,0x64($sp) +/* f0032d8: a7b80066 */ sh $t8,0x66($sp) +/* f0032dc: 27a40074 */ addiu $a0,$sp,0x74 +/* f0032e0: 27a50064 */ addiu $a1,$sp,0x64 +/* f0032e4: 0fc4ba08 */ jal smokeCreateSimple +/* f0032e8: 24060007 */ addiu $a2,$zero,0x7 +.L0f0032ec: +/* f0032ec: 8fa400d8 */ lw $a0,0xd8($sp) +/* f0032f0: 24050040 */ addiu $a1,$zero,0x40 +/* f0032f4: 0fc010e3 */ jal roomAdjustLighting +/* f0032f8: 24060050 */ addiu $a2,$zero,0x50 +/* f0032fc: 0fc25480 */ jal func0f095200 +/* f003300: 00000000 */ nop +/* f003304: 3c01bf80 */ lui $at,0xbf80 +/* f003308: 44810000 */ mtc1 $at,$f0 +/* f00330c: 8faf00d8 */ lw $t7,0xd8($sp) +/* f003310: 00023400 */ sll $a2,$v0,0x10 +/* f003314: 0006cc03 */ sra $t9,$a2,0x10 +/* f003318: 240affff */ addiu $t2,$zero,-1 +/* f00331c: 240b0400 */ addiu $t3,$zero,0x400 +/* f003320: 240c0010 */ addiu $t4,$zero,0x10 +/* f003324: 27ad0074 */ addiu $t5,$sp,0x74 +/* f003328: afad0020 */ sw $t5,0x20($sp) +/* f00332c: afac001c */ sw $t4,0x1c($sp) +/* f003330: afab0014 */ sw $t3,0x14($sp) +/* f003334: afaa0010 */ sw $t2,0x10($sp) +/* f003338: 03203025 */ or $a2,$t9,$zero +/* f00333c: 00002025 */ or $a0,$zero,$zero +/* f003340: 00002825 */ or $a1,$zero,$zero +/* f003344: 2407ffff */ addiu $a3,$zero,-1 +/* f003348: afa00018 */ sw $zero,0x18($sp) +/* f00334c: afa00028 */ sw $zero,0x28($sp) +/* f003350: afaf002c */ sw $t7,0x2c($sp) +/* f003354: e7a00024 */ swc1 $f0,0x24($sp) +/* f003358: e7a00030 */ swc1 $f0,0x30($sp) +/* f00335c: e7a00034 */ swc1 $f0,0x34($sp) +/* f003360: 0fc24e7e */ jal func0f0939f8 +/* f003364: e7a00038 */ swc1 $f0,0x38($sp) +/* f003368: 1000000d */ b .L0f0033a0 +/* f00336c: 24020001 */ addiu $v0,$zero,0x1 +.L0f003370: +/* f003370: 0c004b70 */ jal random +/* f003374: afa300d4 */ sw $v1,0xd4($sp) +/* f003378: 24010050 */ addiu $at,$zero,0x50 +/* f00337c: 0041001b */ divu $zero,$v0,$at +/* f003380: 00007010 */ mfhi $t6 +/* f003384: 8fa300d4 */ lw $v1,0xd4($sp) +/* f003388: 55c00005 */ bnezl $t6,.L0f0033a0 +/* f00338c: 00001025 */ or $v0,$zero,$zero +/* f003390: 90790005 */ lbu $t9,0x5($v1) +/* f003394: 372a0010 */ ori $t2,$t9,0x10 +/* f003398: a06a0005 */ sb $t2,0x5($v1) +.L0f00339c: +/* f00339c: 00001025 */ or $v0,$zero,$zero +.L0f0033a0: +/* f0033a0: 8fbf0044 */ lw $ra,0x44($sp) +/* f0033a4: 27bd00d8 */ addiu $sp,$sp,0xd8 +/* f0033a8: 03e00008 */ jr $ra +/* f0033ac: 00000000 */ nop +); +#endif void lightingTick(void) { diff --git a/src/game/endscreen.c b/src/game/endscreen.c index 8cc96adf2..ec2254320 100644 --- a/src/game/endscreen.c +++ b/src/game/endscreen.c @@ -921,7 +921,7 @@ s32 menudialogSolo2PEndscreenFailed(s32 operation, struct menudialog *dialog, un struct menuinputs *inputs = data->dialog2.inputs; if (inputs->select || inputs->back || inputs->start) { - g_Menus[g_MpPlayerNum].endscreen.unke1c = 6; + g_Menus[g_MpPlayerNum].endscreen.unke1c = VERSION >= VERSION_NTSC_1_0 ? 6 : 3; } if (g_Menus[g_MpPlayerNum].endscreen.unke1c) { diff --git a/src/game/file.c b/src/game/file.c index 693453468..36668bf7e 100644 --- a/src/game/file.c +++ b/src/game/file.c @@ -2035,7 +2035,10 @@ const char var7f1b1dd8nb[] = "ob.c"; #endif struct fileinfo g_FileInfo[NUM_FILES]; + +#if VERSION >= VERSION_NTSC_1_0 u32 var800aa570; +#endif void *filetable[] = { /*0x0000*/ NULL, @@ -4198,6 +4201,7 @@ glabel func0f166eb4 ); #endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f166f74 /* f166f74: 27bdffd0 */ addiu $sp,$sp,-48 @@ -4233,6 +4237,43 @@ glabel func0f166f74 /* f166fe8: 03e00008 */ jr $ra /* f166fec: 27bd0030 */ addiu $sp,$sp,0x30 ); +#else +GLOBAL_ASM( +glabel func0f166f74 +/* f166f74: 27bdffd0 */ addiu $sp,$sp,-48 +/* f166f78: afb20020 */ sw $s2,0x20($sp) +/* f166f7c: afb1001c */ sw $s1,0x1c($sp) +/* f166f80: afb40028 */ sw $s4,0x28($sp) +/* f166f84: afb00018 */ sw $s0,0x18($sp) +/* f166f88: 3c11800a */ lui $s1,%hi(g_FileInfo) +/* f166f8c: 3c128008 */ lui $s2,%hi(filetable) +/* f166f90: afbf002c */ sw $ra,0x2c($sp) +/* f166f94: afb30024 */ sw $s3,0x24($sp) +/* f166f98: 26522060 */ addiu $s2,$s2,%lo(filetable) +/* f166f9c: 26316680 */ addiu $s1,$s1,%lo(g_FileInfo) +/* f166fa0: 24100001 */ addiu $s0,$zero,0x1 +/* f166fa4: 241407de */ addiu $s4,$zero,0x7dd +/* f166fa8: 001070c0 */ sll $t6,$s0,0x3 +.L0f166fac: +/* f166fac: 022e1021 */ addu $v0,$s1,$t6 +/* f166fb0: 00107880 */ sll $t7,$s0,0x2 +/* f166fb4: ac400000 */ sw $zero,0x0($v0) +/* f166fb8: ac400004 */ sw $zero,0x4($v0) +/* f166fbc: 0fc59b95 */ jal fileGetRomSizeByTableAddress +/* f166fc0: 024f2021 */ addu $a0,$s2,$t7 +/* f166fc4: 26100001 */ addiu $s0,$s0,0x1 +/* f166fc8: 5614fff8 */ bnel $s0,$s4,.L0f166fac +/* f166fcc: 001070c0 */ sll $t6,$s0,0x3 +/* f166fd0: 8fbf002c */ lw $ra,0x2c($sp) +/* f166fd4: 8fb00018 */ lw $s0,0x18($sp) +/* f166fd8: 8fb1001c */ lw $s1,0x1c($sp) +/* f166fdc: 8fb20020 */ lw $s2,0x20($sp) +/* f166fe0: 8fb30024 */ lw $s3,0x24($sp) +/* f166fe4: 8fb40028 */ lw $s4,0x28($sp) +/* f166fe8: 03e00008 */ jr $ra +/* f166fec: 27bd0030 */ addiu $sp,$sp,0x30 +); +#endif //void func0f166f74(void) //{ @@ -4617,7 +4658,8 @@ void func0f1672f0(u8 arg0) { s32 i; - for (i = 1; i < 2014; i++) { + // Minus 1 because the last entry in the file table is just a marker + for (i = 1; i < ARRAYCOUNT(filetable) - 1; i++) { if (arg0 == 4) { g_FileInfo[i].size = 0; } diff --git a/src/game/filelist.c b/src/game/filelist.c index 8df32c966..d62c1de7f 100644 --- a/src/game/filelist.c +++ b/src/game/filelist.c @@ -112,16 +112,15 @@ void filelistsTick(void) var80075bf4 = true; } - i = 0; - updateall = false; - - for (; i < 5; i++) { #if VERSION >= VERSION_NTSC_1_0 + for (i = 0, updateall = false; i < 5; i++) { if (pak0f1167d8(i) && var800a2330[i] != pakGetUnk264(i)) { updateall = true; var800a2330[i] = pakGetUnk264(i); } + } #else + for (i = 0, updateall = false; i < 5; i++) { s32 tmp = pakGetUnk264(i); pak0f11698c(i); @@ -134,8 +133,8 @@ void filelistsTick(void) updateall = true; var800a2330[i] = tmp; } -#endif } +#endif for (i = 0; i < 4; i++) { if (g_FileLists[i] != NULL) { @@ -273,6 +272,7 @@ void filelistUpdate(struct filelist *list) } } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel pheadAllocateTextures /* f111260: 000470c0 */ sll $t6,$a0,0x3 @@ -377,6 +377,112 @@ glabel pheadAllocateTextures /* f1113d8: 03e00008 */ jr $ra /* f1113dc: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel pheadAllocateTextures +/* f10b6bc: 000470c0 */ sll $t6,$a0,0x3 +/* f10b6c0: 01c47023 */ subu $t6,$t6,$a0 +/* f10b6c4: 000e70c0 */ sll $t6,$t6,0x3 +/* f10b6c8: 01c47023 */ subu $t6,$t6,$a0 +/* f10b6cc: 000e7100 */ sll $t6,$t6,0x4 +/* f10b6d0: 27bdffe0 */ addiu $sp,$sp,-32 +/* f10b6d4: 01c47023 */ subu $t6,$t6,$a0 +/* f10b6d8: 3c0f800a */ lui $t7,0x800a +/* f10b6dc: afb00018 */ sw $s0,0x18($sp) +/* f10b6e0: 25ef27c0 */ addiu $t7,$t7,0x27c0 +/* f10b6e4: 000e7080 */ sll $t6,$t6,0x2 +/* f10b6e8: 01cf8021 */ addu $s0,$t6,$t7 +/* f10b6ec: 8e030db4 */ lw $v1,0xdb4($s0) +/* f10b6f0: afbf001c */ sw $ra,0x1c($sp) +/* f10b6f4: 14600017 */ bnez $v1,.NB0f10b754 +/* f10b6f8: 00000000 */ sll $zero,$zero,0x0 +/* f10b6fc: 54a00011 */ bnezl $a1,.NB0f10b744 +/* f10b700: 92090d9c */ lbu $t1,0xd9c($s0) +/* f10b704: 92190d9c */ lbu $t9,0xd9c($s0) +/* f10b708: 24040890 */ addiu $a0,$zero,0x890 +/* f10b70c: 37280040 */ ori $t0,$t9,0x40 +/* f10b710: 0fc5c691 */ jal align16 +/* f10b714: a2080d9c */ sb $t0,0xd9c($s0) +/* f10b718: 00402025 */ or $a0,$v0,$zero +/* f10b71c: 0fc5636f */ jal func0f15e5b8 +/* f10b720: 24050001 */ addiu $a1,$zero,0x1 +/* f10b724: 0fc5c691 */ jal align16 +/* f10b728: 24040890 */ addiu $a0,$zero,0x890 +/* f10b72c: 0c004cc9 */ jal func00012ab0 +/* f10b730: 00402025 */ or $a0,$v0,$zero +/* f10b734: ae020db4 */ sw $v0,0xdb4($s0) +/* f10b738: 10000006 */ beqz $zero,.NB0f10b754 +/* f10b73c: 00401825 */ or $v1,$v0,$zero +/* f10b740: 92090d9c */ lbu $t1,0xd9c($s0) +.NB0f10b744: +/* f10b744: ae050db4 */ sw $a1,0xdb4($s0) +/* f10b748: 00a01825 */ or $v1,$a1,$zero +/* f10b74c: 312affbf */ andi $t2,$t1,0xffbf +/* f10b750: a20a0d9c */ sb $t2,0xd9c($s0) +.NB0f10b754: +/* f10b754: 14600006 */ bnez $v1,.NB0f10b770 +/* f10b758: 3c047f1b */ lui $a0,0x7f1b +/* f10b75c: 3c057f1b */ lui $a1,0x7f1b +/* f10b760: 24a5d6d4 */ addiu $a1,$a1,-10540 +/* f10b764: 2484d6c8 */ addiu $a0,$a0,-10552 +/* f10b768: 0c003068 */ jal faultAssert +/* f10b76c: 240601c2 */ addiu $a2,$zero,0x1c2 +.NB0f10b770: +/* f10b770: 00001025 */ or $v0,$zero,$zero +/* f10b774: 24030080 */ addiu $v1,$zero,0x80 +.NB0f10b778: +/* f10b778: 8e0b0db4 */ lw $t3,0xdb4($s0) +/* f10b77c: 01626021 */ addu $t4,$t3,$v0 +/* f10b780: ad800800 */ sw $zero,0x800($t4) +/* f10b784: 8e0d0db4 */ lw $t5,0xdb4($s0) +/* f10b788: 01a27021 */ addu $t6,$t5,$v0 +/* f10b78c: 24420008 */ addiu $v0,$v0,0x8 +/* f10b790: 1443fff9 */ bne $v0,$v1,.NB0f10b778 +/* f10b794: a5c00804 */ sh $zero,0x804($t6) +/* f10b798: 8e0f0db4 */ lw $t7,0xdb4($s0) +/* f10b79c: 24020010 */ addiu $v0,$zero,0x10 +/* f10b7a0: 24090004 */ addiu $t1,$zero,0x4 +/* f10b7a4: ade00880 */ sw $zero,0x880($t7) +/* f10b7a8: 8e180db4 */ lw $t8,0xdb4($s0) +/* f10b7ac: 240d0001 */ addiu $t5,$zero,0x1 +/* f10b7b0: 00001825 */ or $v1,$zero,$zero +/* f10b7b4: a3020888 */ sb $v0,0x888($t8) +/* f10b7b8: 8e190db4 */ lw $t9,0xdb4($s0) +/* f10b7bc: 24050010 */ addiu $a1,$zero,0x10 +/* f10b7c0: 24040080 */ addiu $a0,$zero,0x80 +/* f10b7c4: a3220889 */ sb $v0,0x889($t9) +/* f10b7c8: 8e080db4 */ lw $t0,0xdb4($s0) +/* f10b7cc: a100088a */ sb $zero,0x88a($t0) +/* f10b7d0: 8e0a0db4 */ lw $t2,0xdb4($s0) +/* f10b7d4: a149088b */ sb $t1,0x88b($t2) +/* f10b7d8: 8e0b0db4 */ lw $t3,0xdb4($s0) +/* f10b7dc: a160088c */ sb $zero,0x88c($t3) +/* f10b7e0: 8e0c0db4 */ lw $t4,0xdb4($s0) +/* f10b7e4: a180088d */ sb $zero,0x88d($t4) +/* f10b7e8: 8e0e0db4 */ lw $t6,0xdb4($s0) +/* f10b7ec: a1cd088e */ sb $t5,0x88e($t6) +/* f10b7f0: 8e0f0db4 */ lw $t7,0xdb4($s0) +/* f10b7f4: a1e0088f */ sb $zero,0x88f($t7) +/* f10b7f8: 00001025 */ or $v0,$zero,$zero +.NB0f10b7fc: +/* f10b7fc: 8e190db4 */ lw $t9,0xdb4($s0) +/* f10b800: 000341c0 */ sll $t0,$v1,0x7 +/* f10b804: 0040c025 */ or $t8,$v0,$zero +/* f10b808: 03284821 */ addu $t1,$t9,$t0 +/* f10b80c: 01225021 */ addu $t2,$t1,$v0 +/* f10b810: 24420001 */ addiu $v0,$v0,0x1 +/* f10b814: 1444fff9 */ bne $v0,$a0,.NB0f10b7fc +/* f10b818: a1580000 */ sb $t8,0x0($t2) +/* f10b81c: 24630001 */ addiu $v1,$v1,0x1 +/* f10b820: 5465fff6 */ bnel $v1,$a1,.NB0f10b7fc +/* f10b824: 00001025 */ or $v0,$zero,$zero +/* f10b828: 8fbf001c */ lw $ra,0x1c($sp) +/* f10b82c: 8fb00018 */ lw $s0,0x18($sp) +/* f10b830: 27bd0020 */ addiu $sp,$sp,0x20 +/* f10b834: 03e00008 */ jr $ra +/* f10b838: 00000000 */ sll $zero,$zero,0x0 +); +#endif const char var7f1b3a08[] = "tc != NULL"; const char var7f1b3a14[] = "gamefile.c"; diff --git a/src/game/filemgr.c b/src/game/filemgr.c index 7211a4e5a..43ad378db 100644 --- a/src/game/filemgr.c +++ b/src/game/filemgr.c @@ -32,14 +32,12 @@ struct fileguid g_GameFileGuid; struct menudialog g_FilemgrCopyMenuDialog; struct menudialog g_FilemgrConfirmDeleteMenuDialog; struct menudialog g_FilemgrDeleteMenuDialog; -struct menudialog g_FilemgrDuplicateNameMenuDialog; struct menudialog g_FilemgrEnterNameMenuDialog; struct menudialog g_FilemgrErrorMenuDialog; struct menudialog g_FilemgrFileInUseMenuDialog; struct menudialog g_FilemgrFileLostMenuDialog; struct menudialog g_FilemgrFileSavedMenuDialog; struct menudialog g_FilemgrFileSelectMenuDialog; -struct menudialog g_FilemgrRenameMenuDialog; struct menudialog g_FilemgrSaveElsewhereMenuDialog; struct menudialog g_FilemgrSaveErrorMenuDialog; struct menudialog g_FilemgrSelectLocationMenuDialog; @@ -48,6 +46,11 @@ struct menudialog g_PakGameNotesMenuDialog; struct menudialog g_PakNotOriginalMenuDialog; struct pakdata *g_EditingPak; +#if VERSION >= VERSION_NTSC_1_0 +struct menudialog g_FilemgrDuplicateNameMenuDialog; +struct menudialog g_FilemgrRenameMenuDialog; +#endif + #if VERSION >= VERSION_PAL_FINAL s32 func0f1088d0pf(s32 operation, struct menuitem *item, union handlerdata *data); @@ -213,7 +216,11 @@ void filemgrSetDevice1BySerial(s32 deviceserial) if (device >= 0) { g_Menus[g_MpPlayerNum].fm.device1 = device; } else { +#if VERSION >= VERSION_NTSC_1_0 g_Menus[g_MpPlayerNum].fm.device1 = SAVEDEVICE_INVALID; +#else + g_Menus[g_MpPlayerNum].fm.device1 = 0x7f; +#endif } } @@ -706,8 +713,7 @@ void filemgrRetrySave(s32 context) #if VERSION >= VERSION_NTSC_1_0 filemgrEraseCorruptFile(); #else - // Argument is wrong/mismatching - func0f0f3704(&g_FilemgrSaveErrorMenuDialog); + func0f0f3704(&g_FilemgrFileLostMenuDialog); #endif } } @@ -1101,13 +1107,11 @@ bool filemgrSaveOrLoad(struct fileguid *guid, s32 fileop, u32 playernum) if (FILEOP_IS_SAVE(g_Menus[g_MpPlayerNum].fm.fileop)) { menuPushDialog(&g_FilemgrSaveErrorMenuDialog); } else { + // File couldn't be loaded #if VERSION >= VERSION_NTSC_1_0 - // File couldn't be loaded - delete it filemgrEraseCorruptFile(); #else - // ntsc-beta shows an error instead - // Note: This argument is wrong/mismatching - menuPushDialog(&g_FilemgrSaveErrorMenuDialog); + menuPushDialog(&g_FilemgrFileLostMenuDialog); #endif } @@ -2255,11 +2259,19 @@ s32 pakGameNoteListMenuHandler(s32 operation, struct menuitem *item, union handl Gfx *gdl; struct menuitemrenderdata *renderdata; OSPfsState *note; +#if VERSION >= VERSION_NTSC_1_0 char tmpname[40]; char tmpext[12]; char generalbuffer[60]; char extbuffer[60]; char pagesbuffer[60]; +#else + char tmpname[20]; + char tmpext[8]; + char generalbuffer[28]; + char extbuffer[28]; + char pagesbuffer[28]; +#endif s32 textwidth; s32 textheight; diff --git a/src/game/game_02cde0.c b/src/game/game_02cde0.c index 291847e58..bce502ffe 100644 --- a/src/game/game_02cde0.c +++ b/src/game/game_02cde0.c @@ -880,13 +880,13 @@ struct prop *propAllocateEyespy(struct pad *pad, s16 room) s32 inlift; struct prop *lift; f32 ground; - u32 stack[2]; rooms[0] = room; rooms[1] = -1; #if PIRACYCHECKS { + u32 stack[2]; u32 checksum = 0; s32 *ptr = (s32 *)&lvInit; s32 *end = (s32 *)&lvConfigureFade; diff --git a/src/game/game_091e10.c b/src/game/game_091e10.c index 2995e5631..cab64466b 100644 --- a/src/game/game_091e10.c +++ b/src/game/game_091e10.c @@ -16,7 +16,7 @@ u8 *g_GeCreditsData; u32 setupGetCommandLength(u32 *cmd) { #if VERSION < VERSION_NTSC_1_0 - static u32 crash1; + static u32 crash1 = 0; mainOverrideVariable("crash1", &crash1); #endif diff --git a/src/game/game_092610.c b/src/game/game_092610.c index ae726c5ff..22161e6a4 100644 --- a/src/game/game_092610.c +++ b/src/game/game_092610.c @@ -60,7 +60,11 @@ const char var7f1ab680[] = "AISOUND: Channel %d -> Setting params : Vol=%d, Pad= const char var7f1ab6e8[] = "AISOUND : This channel has a marker -> Shall start and use ID = %d(%x)\n"; struct audiochannel *g_AudioChannels = NULL; + +#if VERSION >= VERSION_NTSC_1_0 u32 g_AudioPrevUuid = 0x00000000; +#endif + s8 var8006ae18 = 0; s8 var8006ae1c = 0; s8 var8006ae20 = 0; @@ -72,10 +76,6 @@ u32 var8006ae34 = 0x00000000; u32 var8006ae38 = 0x00000000; bool g_PropsndPrintChannels = false; -#if VERSION < VERSION_NTSC_1_0 -u32 nbdata[3] = {0}; -#endif - u32 var8006ae40 = 0x00000000; u32 var8006ae44 = 0x00000000; u32 var8006ae48 = 0x00000001; diff --git a/src/game/game_0abe70.c b/src/game/game_0abe70.c index 1bffbd0aa..0c8be1ac1 100644 --- a/src/game/game_0abe70.c +++ b/src/game/game_0abe70.c @@ -139,6 +139,7 @@ void beamCreate(struct beam *beam, s32 weaponnum, struct coord *from, struct coo } } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0ac138 .late_rodata @@ -381,6 +382,250 @@ glabel var7f1acc48 /* f0ac4b0: 03e00008 */ jr $ra /* f0ac4b4: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f0ac138 +.late_rodata +glabel var7f1acc48 +.word 0x3db2b17a +.text +/* f0a9e98: 3c0e800a */ lui $t6,0x800a +/* f0a9e9c: 8dcee944 */ lw $t6,-0x16bc($t6) +/* f0a9ea0: 27bdff88 */ addiu $sp,$sp,-120 +/* f0a9ea4: afbf0014 */ sw $ra,0x14($sp) +/* f0a9ea8: afa40078 */ sw $a0,0x78($sp) +/* f0a9eac: 0fc2cd16 */ jal currentPlayerGetMatrix1740 +/* f0a9eb0: afae0074 */ sw $t6,0x74($sp) +/* f0a9eb4: 8fa40078 */ lw $a0,0x78($sp) +/* f0a9eb8: 8faf0074 */ lw $t7,0x74($sp) +/* f0a9ebc: c4460008 */ lwc1 $f6,0x8($v0) +/* f0a9ec0: 00042900 */ sll $a1,$a0,0x4 +/* f0a9ec4: 00a42823 */ subu $a1,$a1,$a0 +/* f0a9ec8: 00052880 */ sll $a1,$a1,0x2 +/* f0a9ecc: 00a42821 */ addu $a1,$a1,$a0 +/* f0a9ed0: 000528c0 */ sll $a1,$a1,0x3 +/* f0a9ed4: 00a42821 */ addu $a1,$a1,$a0 +/* f0a9ed8: 00052880 */ sll $a1,$a1,0x2 +/* f0a9edc: 01e51821 */ addu $v1,$t7,$a1 +/* f0a9ee0: c4640b94 */ lwc1 $f4,0xb94($v1) +/* f0a9ee4: c46a0b98 */ lwc1 $f10,0xb98($v1) +/* f0a9ee8: c4500018 */ lwc1 $f16,0x18($v0) +/* f0a9eec: 46062202 */ mul.s $f8,$f4,$f6 +/* f0a9ef0: c4660b9c */ lwc1 $f6,0xb9c($v1) +/* f0a9ef4: 24630638 */ addiu $v1,$v1,0x638 +/* f0a9ef8: 46105482 */ mul.s $f18,$f10,$f16 +/* f0a9efc: c44a0028 */ lwc1 $f10,0x28($v0) +/* f0a9f00: 460a3402 */ mul.s $f16,$f6,$f10 +/* f0a9f04: c4660380 */ lwc1 $f6,0x380($v1) +/* f0a9f08: 46124100 */ add.s $f4,$f8,$f18 +/* f0a9f0c: c4520038 */ lwc1 $f18,0x38($v0) +/* f0a9f10: 46102200 */ add.s $f8,$f4,$f16 +/* f0a9f14: 46089000 */ add.s $f0,$f18,$f8 +/* f0a9f18: 46000007 */ neg.s $f0,$f0 +/* f0a9f1c: 4606003c */ c.lt.s $f0,$f6 +/* f0a9f20: 00000000 */ sll $zero,$zero,0x0 +/* f0a9f24: 450300b9 */ bc1tl .NB0f0aa20c +/* f0a9f28: 8fbf0014 */ lw $ra,0x14($sp) +/* f0a9f2c: afa30028 */ sw $v1,0x28($sp) +/* f0a9f30: 0fc27dd7 */ jal bgunGetWeaponNum +/* f0a9f34: afa5002c */ sw $a1,0x2c($sp) +/* f0a9f38: 8fa30028 */ lw $v1,0x28($sp) +/* f0a9f3c: 2401001d */ addiu $at,$zero,0x1d +/* f0a9f40: 00402825 */ or $a1,$v0,$zero +/* f0a9f44: 90780000 */ lbu $t8,0x0($v1) +/* f0a9f48: 246401dc */ addiu $a0,$v1,0x1dc +/* f0a9f4c: 24660374 */ addiu $a2,$v1,0x374 +/* f0a9f50: 17010006 */ bne $t8,$at,.NB0f0a9f6c +/* f0a9f54: 2467055c */ addiu $a3,$v1,0x55c +/* f0a9f58: 90790003 */ lbu $t9,0x3($v1) +/* f0a9f5c: 24010001 */ addiu $at,$zero,0x1 +/* f0a9f60: 57210003 */ bnel $t9,$at,.NB0f0a9f70 +/* f0a9f64: afa30028 */ sw $v1,0x28($sp) +/* f0a9f68: 2405fffe */ addiu $a1,$zero,-2 +.NB0f0a9f6c: +/* f0a9f6c: afa30028 */ sw $v1,0x28($sp) +.NB0f0a9f70: +/* f0a9f70: afa40024 */ sw $a0,0x24($sp) +/* f0a9f74: afa50060 */ sw $a1,0x60($sp) +/* f0a9f78: 0fc2a6f4 */ jal beamCreate +/* f0a9f7c: afa70018 */ sw $a3,0x18($sp) +/* f0a9f80: 8fa40024 */ lw $a0,0x24($sp) +/* f0a9f84: 3c08800a */ lui $t0,0x800a +/* f0a9f88: 24010006 */ addiu $at,$zero,0x6 +/* f0a9f8c: 80890001 */ lb $t1,0x1($a0) +/* f0a9f90: 2508e6c0 */ addiu $t0,$t0,-6464 +/* f0a9f94: 8fa30028 */ lw $v1,0x28($sp) +/* f0a9f98: 1521000a */ bne $t1,$at,.NB0f0a9fc4 +/* f0a9f9c: 8faa0074 */ lw $t2,0x74($sp) +/* f0a9fa0: 8fab002c */ lw $t3,0x2c($sp) +/* f0a9fa4: 240ffffd */ addiu $t7,$zero,-3 +/* f0a9fa8: 014b6021 */ addu $t4,$t2,$t3 +/* f0a9fac: c58a0874 */ lwc1 $f10,0x874($t4) +/* f0a9fb0: 4600510d */ trunc.w.s $f4,$f10 +/* f0a9fb4: 440e2000 */ mfc1 $t6,$f4 +/* f0a9fb8: 00000000 */ sll $zero,$zero,0x0 +/* f0a9fbc: 01eec023 */ subu $t8,$t7,$t6 +/* f0a9fc0: a0980001 */ sb $t8,0x1($a0) +.NB0f0a9fc4: +/* f0a9fc4: 8fb90074 */ lw $t9,0x74($sp) +/* f0a9fc8: 8f2900bc */ lw $t1,0xbc($t9) +/* f0a9fcc: 8d270004 */ lw $a3,0x4($t1) +/* f0a9fd0: 50e0008e */ beqzl $a3,.NB0f0aa20c +/* f0a9fd4: 8fbf0014 */ lw $ra,0x14($sp) +/* f0a9fd8: 8d0a006c */ lw $t2,0x6c($t0) +/* f0a9fdc: 00003025 */ or $a2,$zero,$zero +/* f0a9fe0: 00002025 */ or $a0,$zero,$zero +/* f0a9fe4: 11400003 */ beqz $t2,.NB0f0a9ff4 +/* f0a9fe8: 00002825 */ or $a1,$zero,$zero +/* f0a9fec: 10000001 */ beqz $zero,.NB0f0a9ff4 +/* f0a9ff0: 24060001 */ addiu $a2,$zero,0x1 +.NB0f0a9ff4: +/* f0a9ff4: 8d0b0068 */ lw $t3,0x68($t0) +/* f0a9ff8: 8fb90078 */ lw $t9,0x78($sp) +/* f0a9ffc: 00001025 */ or $v0,$zero,$zero +/* f0aa000: 11600003 */ beqz $t3,.NB0f0aa010 +/* f0aa004: 00f94821 */ addu $t1,$a3,$t9 +/* f0aa008: 10000001 */ beqz $zero,.NB0f0aa010 +/* f0aa00c: 24040001 */ addiu $a0,$zero,0x1 +.NB0f0aa010: +/* f0aa010: 8d0c0064 */ lw $t4,0x64($t0) +/* f0aa014: 11800003 */ beqz $t4,.NB0f0aa024 +/* f0aa018: 00000000 */ sll $zero,$zero,0x0 +/* f0aa01c: 10000001 */ beqz $zero,.NB0f0aa024 +/* f0aa020: 24050001 */ addiu $a1,$zero,0x1 +.NB0f0aa024: +/* f0aa024: 8d0d0070 */ lw $t5,0x70($t0) +/* f0aa028: 11a00003 */ beqz $t5,.NB0f0aa038 +/* f0aa02c: 00000000 */ sll $zero,$zero,0x0 +/* f0aa030: 10000001 */ beqz $zero,.NB0f0aa038 +/* f0aa034: 24020001 */ addiu $v0,$zero,0x1 +.NB0f0aa038: +/* f0aa038: 00457821 */ addu $t7,$v0,$a1 +/* f0aa03c: 01e47021 */ addu $t6,$t7,$a0 +/* f0aa040: 01c6c021 */ addu $t8,$t6,$a2 +/* f0aa044: 2b010002 */ slti $at,$t8,0x2 +/* f0aa048: 54200070 */ bnezl $at,.NB0f0aa20c +/* f0aa04c: 8fbf0014 */ lw $ra,0x14($sp) +/* f0aa050: afa90020 */ sw $t1,0x20($sp) +/* f0aa054: 8124017c */ lb $a0,0x17c($t1) +/* f0aa058: 2401ffff */ addiu $at,$zero,-1 +/* f0aa05c: 54810008 */ bnel $a0,$at,.NB0f0aa080 +/* f0aa060: 2401ffff */ addiu $at,$zero,-1 +/* f0aa064: 0fc2938f */ jal bgunAllocateFireslot +/* f0aa068: afa30028 */ sw $v1,0x28($sp) +/* f0aa06c: 8fa50020 */ lw $a1,0x20($sp) +/* f0aa070: 8fa30028 */ lw $v1,0x28($sp) +/* f0aa074: a0a2017c */ sb $v0,0x17c($a1) +/* f0aa078: 80a4017c */ lb $a0,0x17c($a1) +/* f0aa07c: 2401ffff */ addiu $at,$zero,-1 +.NB0f0aa080: +/* f0aa080: 10810061 */ beq $a0,$at,.NB0f0aa208 +/* f0aa084: 8fac0078 */ lw $t4,0x78($sp) +/* f0aa088: 8fab0074 */ lw $t3,0x74($sp) +/* f0aa08c: 000c6880 */ sll $t5,$t4,0x2 +/* f0aa090: 01ac6823 */ subu $t5,$t5,$t4 +/* f0aa094: 000d6880 */ sll $t5,$t5,0x2 +/* f0aa098: 016d1021 */ addu $v0,$t3,$t5 +/* f0aa09c: c452197c */ lwc1 $f18,0x197c($v0) +/* f0aa0a0: c470055c */ lwc1 $f16,0x55c($v1) +/* f0aa0a4: 27a40050 */ addiu $a0,$sp,0x50 +/* f0aa0a8: 27a50054 */ addiu $a1,$sp,0x54 +/* f0aa0ac: 46128201 */ sub.s $f8,$f16,$f18 +/* f0aa0b0: 27a60058 */ addiu $a2,$sp,0x58 +/* f0aa0b4: e7a80050 */ swc1 $f8,0x50($sp) +/* f0aa0b8: c44a1980 */ lwc1 $f10,0x1980($v0) +/* f0aa0bc: c4660560 */ lwc1 $f6,0x560($v1) +/* f0aa0c0: 460a3101 */ sub.s $f4,$f6,$f10 +/* f0aa0c4: e7a40054 */ swc1 $f4,0x54($sp) +/* f0aa0c8: c4521984 */ lwc1 $f18,0x1984($v0) +/* f0aa0cc: c4700564 */ lwc1 $f16,0x564($v1) +/* f0aa0d0: afa30028 */ sw $v1,0x28($sp) +/* f0aa0d4: afa20024 */ sw $v0,0x24($sp) +/* f0aa0d8: 46128201 */ sub.s $f8,$f16,$f18 +/* f0aa0dc: 0c0012a8 */ jal guNormalize +/* f0aa0e0: e7a80058 */ swc1 $f8,0x58($sp) +/* f0aa0e4: 8fa30028 */ lw $v1,0x28($sp) +/* f0aa0e8: 27a40044 */ addiu $a0,$sp,0x44 +/* f0aa0ec: 27a50048 */ addiu $a1,$sp,0x48 +/* f0aa0f0: c466055c */ lwc1 $f6,0x55c($v1) +/* f0aa0f4: c46a0374 */ lwc1 $f10,0x374($v1) +/* f0aa0f8: 27a6004c */ addiu $a2,$sp,0x4c +/* f0aa0fc: 460a3101 */ sub.s $f4,$f6,$f10 +/* f0aa100: e7a40044 */ swc1 $f4,0x44($sp) +/* f0aa104: c4720378 */ lwc1 $f18,0x378($v1) +/* f0aa108: c4700560 */ lwc1 $f16,0x560($v1) +/* f0aa10c: 46128201 */ sub.s $f8,$f16,$f18 +/* f0aa110: e7a80048 */ swc1 $f8,0x48($sp) +/* f0aa114: c46a037c */ lwc1 $f10,0x37c($v1) +/* f0aa118: c4660564 */ lwc1 $f6,0x564($v1) +/* f0aa11c: 460a3101 */ sub.s $f4,$f6,$f10 +/* f0aa120: 0c0012a8 */ jal guNormalize +/* f0aa124: e7a4004c */ swc1 $f4,0x4c($sp) +/* f0aa128: c7b00050 */ lwc1 $f16,0x50($sp) +/* f0aa12c: c7b20044 */ lwc1 $f18,0x44($sp) +/* f0aa130: c7a60054 */ lwc1 $f6,0x54($sp) +/* f0aa134: c7aa0048 */ lwc1 $f10,0x48($sp) +/* f0aa138: 46128202 */ mul.s $f8,$f16,$f18 +/* f0aa13c: c7b2004c */ lwc1 $f18,0x4c($sp) +/* f0aa140: 460a3102 */ mul.s $f4,$f6,$f10 +/* f0aa144: c7a60058 */ lwc1 $f6,0x58($sp) +/* f0aa148: 46069282 */ mul.s $f10,$f18,$f6 +/* f0aa14c: 46044400 */ add.s $f16,$f8,$f4 +/* f0aa150: 0fc25258 */ jal func0f0969d0 +/* f0aa154: 46105300 */ add.s $f12,$f10,$f16 +/* f0aa158: 3c017f1a */ lui $at,0x7f1a +/* f0aa15c: c4286f98 */ lwc1 $f8,0x6f98($at) +/* f0aa160: 3c0a800a */ lui $t2,0x800a +/* f0aa164: 8fa20024 */ lw $v0,0x24($sp) +/* f0aa168: 4600403c */ c.lt.s $f8,$f0 +/* f0aa16c: 2401fffe */ addiu $at,$zero,-2 +/* f0aa170: 8faf0060 */ lw $t7,0x60($sp) +/* f0aa174: 254a1888 */ addiu $t2,$t2,0x1888 +/* f0aa178: 45000003 */ bc1f .NB0f0aa188 +/* f0aa17c: 8fae0020 */ lw $t6,0x20($sp) +/* f0aa180: 55e10022 */ bnel $t7,$at,.NB0f0aa20c +/* f0aa184: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0aa188: +/* f0aa188: 81d8017c */ lb $t8,0x17c($t6) +/* f0aa18c: 8fa50060 */ lw $a1,0x60($sp) +/* f0aa190: 2446197c */ addiu $a2,$v0,0x197c +/* f0aa194: 0018c8c0 */ sll $t9,$t8,0x3 +/* f0aa198: 0338c823 */ subu $t9,$t9,$t8 +/* f0aa19c: 0019c8c0 */ sll $t9,$t9,0x3 +/* f0aa1a0: 2729000c */ addiu $t1,$t9,0xc +/* f0aa1a4: 012a2021 */ addu $a0,$t1,$t2 +/* f0aa1a8: 0fc2a6f4 */ jal beamCreate +/* f0aa1ac: 8fa70018 */ lw $a3,0x18($sp) +/* f0aa1b0: 8fac0020 */ lw $t4,0x20($sp) +/* f0aa1b4: 3c0f800a */ lui $t7,0x800a +/* f0aa1b8: 25ef1888 */ addiu $t7,$t7,0x1888 +/* f0aa1bc: 818b017c */ lb $t3,0x17c($t4) +/* f0aa1c0: 8fb80074 */ lw $t8,0x74($sp) +/* f0aa1c4: 8fb9002c */ lw $t9,0x2c($sp) +/* f0aa1c8: 000b68c0 */ sll $t5,$t3,0x3 +/* f0aa1cc: 01ab6823 */ subu $t5,$t5,$t3 +/* f0aa1d0: 000d68c0 */ sll $t5,$t5,0x3 +/* f0aa1d4: 01af1021 */ addu $v0,$t5,$t7 +/* f0aa1d8: 804e000d */ lb $t6,0xd($v0) +/* f0aa1dc: 24010006 */ addiu $at,$zero,0x6 +/* f0aa1e0: 03194821 */ addu $t1,$t8,$t9 +/* f0aa1e4: 55c10009 */ bnel $t6,$at,.NB0f0aa20c +/* f0aa1e8: 8fbf0014 */ lw $ra,0x14($sp) +/* f0aa1ec: c5240874 */ lwc1 $f4,0x874($t1) +/* f0aa1f0: 240bfffd */ addiu $t3,$zero,-3 +/* f0aa1f4: 4600248d */ trunc.w.s $f18,$f4 +/* f0aa1f8: 440c9000 */ mfc1 $t4,$f18 +/* f0aa1fc: 00000000 */ sll $zero,$zero,0x0 +/* f0aa200: 016c6823 */ subu $t5,$t3,$t4 +/* f0aa204: a04d000d */ sb $t5,0xd($v0) +.NB0f0aa208: +/* f0aa208: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0aa20c: +/* f0aa20c: 27bd0078 */ addiu $sp,$sp,0x78 +/* f0aa210: 03e00008 */ jr $ra +/* f0aa214: 00000000 */ sll $zero,$zero,0x0 +); +#endif GLOBAL_ASM( glabel func0f0ac4b8 diff --git a/src/game/game_0b0fd0.c b/src/game/game_0b0fd0.c index 04714ecae..ee1b1b9be 100644 --- a/src/game/game_0b0fd0.c +++ b/src/game/game_0b0fd0.c @@ -22,7 +22,7 @@ struct weapon *weaponFindById(s32 itemid) return NULL; } - if (itemid >= NUM_WEAPONS) { + if (itemid >= ARRAYCOUNT(g_Weapons)) { return NULL; } diff --git a/src/game/game_0b69d0.c b/src/game/game_0b69d0.c index a1c08c009..4f84f4f74 100644 --- a/src/game/game_0b69d0.c +++ b/src/game/game_0b69d0.c @@ -508,6 +508,7 @@ f32 playerChooseGeneralSpawnLocation(f32 chrwidth, struct coord *pos, s16 *rooms return playerChooseSpawnLocation(chrwidth, pos, rooms, prop, g_SpawnPoints, g_NumSpawnPoints); } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel currentPlayerStartNewLife .late_rodata @@ -881,6 +882,381 @@ glabel var7f1ad568 /* f0b77c4: 03e00008 */ jr $ra /* f0b77c8: 27bd0118 */ addiu $sp,$sp,0x118 ); +#else +GLOBAL_ASM( +glabel currentPlayerStartNewLife +.late_rodata +glabel var7f1ad534 +.word 0x40c907a9 +glabel var7f1ad538 +.word 0x40c907a9 +glabel var7f1ad53c +.word currentPlayerStartNewLife+0x374 # f0b7650 +glabel var7f1ad540 +.word currentPlayerStartNewLife+0x38c # f0b7668 +glabel var7f1ad544 +.word currentPlayerStartNewLife+0x3c4 # f0b76a0 +glabel var7f1ad548 +.word currentPlayerStartNewLife+0x3e4 # f0b76c0 +glabel var7f1ad54c +.word currentPlayerStartNewLife+0x3ec # f0b76c8 +glabel var7f1ad550 +.word currentPlayerStartNewLife+0x3f4 # f0b76d0 +glabel var7f1ad554 +.word currentPlayerStartNewLife+0x3fc # f0b76d8 +glabel var7f1ad558 +.word currentPlayerStartNewLife+0x404 # f0b76e0 +glabel var7f1ad55c +.word currentPlayerStartNewLife+0x404 # f0b76e0 +glabel var7f1ad560 +.word currentPlayerStartNewLife+0x37c # f0b7658 +glabel var7f1ad564 +.word currentPlayerStartNewLife+0x37c # f0b7658 +glabel var7f1ad568 +.word currentPlayerStartNewLife+0x384 # f0b7660 +.text +/* f0b72dc: 27bdfee8 */ addiu $sp,$sp,-280 +/* f0b72e0: 3c0f8007 */ lui $t7,%hi(var80070780) +/* f0b72e4: afbf003c */ sw $ra,0x3c($sp) +/* f0b72e8: afb20038 */ sw $s2,0x38($sp) +/* f0b72ec: afb10034 */ sw $s1,0x34($sp) +/* f0b72f0: afb00030 */ sw $s0,0x30($sp) +/* f0b72f4: 25ef0780 */ addiu $t7,$t7,%lo(var80070780) +/* f0b72f8: 8de10000 */ lw $at,0x0($t7) +/* f0b72fc: 27ae010c */ addiu $t6,$sp,0x10c +/* f0b7300: 8de80004 */ lw $t0,0x4($t7) +/* f0b7304: adc10000 */ sw $at,0x0($t6) +/* f0b7308: 8de10008 */ lw $at,0x8($t7) +/* f0b730c: 3c12800a */ lui $s2,%hi(g_Vars) +/* f0b7310: 26529fc0 */ addiu $s2,$s2,%lo(g_Vars) +/* f0b7314: 3c11800a */ lui $s1,%hi(g_StageSetup+0xc) +/* f0b7318: adc80004 */ sw $t0,0x4($t6) +/* f0b731c: adc10008 */ sw $at,0x8($t6) +/* f0b7320: 8e31d03c */ lw $s1,%lo(g_StageSetup+0xc)($s1) +/* f0b7324: 0fc47788 */ jal pakEnableRumbleForPlayer +/* f0b7328: 8244028f */ lb $a0,0x28f($s2) +/* f0b732c: 8e490284 */ lw $t1,0x284($s2) +/* f0b7330: a12019b3 */ sb $zero,0x19b3($t1) +/* f0b7334: 8e4a0298 */ lw $t2,0x298($s2) +/* f0b7338: 05430010 */ bgezl $t2,.L0f0b737c +/* f0b733c: 8e580284 */ lw $t8,0x284($s2) +/* f0b7340: 8e4b0284 */ lw $t3,0x284($s2) +/* f0b7344: 8d6c00bc */ lw $t4,0xbc($t3) +/* f0b7348: 8d82001c */ lw $v0,0x1c($t4) +/* f0b734c: 5040000b */ beqzl $v0,.L0f0b737c +/* f0b7350: 8e580284 */ lw $t8,0x284($s2) +/* f0b7354: 8c430004 */ lw $v1,0x4($v0) +.L0f0b7358: +/* f0b7358: 50600005 */ beqzl $v1,.L0f0b7370 +/* f0b735c: 8c420020 */ lw $v0,0x20($v0) +/* f0b7360: 8c6d0040 */ lw $t5,0x40($v1) +/* f0b7364: 35b90004 */ ori $t9,$t5,0x4 +/* f0b7368: ac790040 */ sw $t9,0x40($v1) +/* f0b736c: 8c420020 */ lw $v0,0x20($v0) +.L0f0b7370: +/* f0b7370: 5440fff9 */ bnezl $v0,.L0f0b7358 +/* f0b7374: 8c430004 */ lw $v1,0x4($v0) +/* f0b7378: 8e580284 */ lw $t8,0x284($s2) +.L0f0b737c: +/* f0b737c: 8f0e00bc */ lw $t6,0xbc($t8) +/* f0b7380: 0fc52719 */ jal chrInitSplats +/* f0b7384: 8dc40004 */ lw $a0,0x4($t6) +/* f0b7388: 0fc2ddf3 */ jal currentPlayerResetToDefault +/* f0b738c: 00000000 */ nop +/* f0b7390: 8e4f0284 */ lw $t7,0x284($s2) +/* f0b7394: 24020007 */ addiu $v0,$zero,0x7 +/* f0b7398: 240b0002 */ addiu $t3,$zero,0x2 +/* f0b739c: ade000d8 */ sw $zero,0xd8($t7) +/* f0b73a0: 8e480284 */ lw $t0,0x284($s2) +/* f0b73a4: 2404ffff */ addiu $a0,$zero,-1 +/* f0b73a8: ad021924 */ sw $v0,0x1924($t0) +/* f0b73ac: 8e490284 */ lw $t1,0x284($s2) +/* f0b73b0: ad22193c */ sw $v0,0x193c($t1) +/* f0b73b4: 8e4a0284 */ lw $t2,0x284($s2) +/* f0b73b8: ad4016d8 */ sw $zero,0x16d8($t2) +/* f0b73bc: 8e4c0284 */ lw $t4,0x284($s2) +/* f0b73c0: 0fc37e87 */ jal currentPlayerSetHudmsgsOn +/* f0b73c4: ad8b17a4 */ sw $t3,0x17a4($t4) +/* f0b73c8: 8e4d0284 */ lw $t5,0x284($s2) +/* f0b73cc: 3c0141f0 */ lui $at,0x41f0 +/* f0b73d0: 44816000 */ mtc1 $at,$f12 +/* f0b73d4: 27a5010c */ addiu $a1,$sp,0x10c +/* f0b73d8: 27a600fc */ addiu $a2,$sp,0xfc +/* f0b73dc: 0fc6185f */ jal scenarioChooseSpawnLocation +/* f0b73e0: 8da700bc */ lw $a3,0xbc($t5) +/* f0b73e4: 3c017f1b */ lui $at,%hi(var7f1ad534) +/* f0b73e8: c424d534 */ lwc1 $f4,%lo(var7f1ad534)($at) +/* f0b73ec: 8e500284 */ lw $s0,0x284($s2) +/* f0b73f0: 27a4010c */ addiu $a0,$sp,0x10c +/* f0b73f4: 46002181 */ sub.s $f6,$f4,$f0 +/* f0b73f8: 2619161e */ addiu $t9,$s0,0x161e +/* f0b73fc: 2618161c */ addiu $t8,$s0,0x161c +/* f0b7400: 260e19b0 */ addiu $t6,$s0,0x19b0 +/* f0b7404: e7a600f8 */ swc1 $f6,0xf8($sp) +/* f0b7408: afae0018 */ sw $t6,0x18($sp) +/* f0b740c: afb80014 */ sw $t8,0x14($sp) +/* f0b7410: afb90010 */ sw $t9,0x10($sp) +/* f0b7414: 3c0541f0 */ lui $a1,0x41f0 +/* f0b7418: 27a600fc */ addiu $a2,$sp,0xfc +/* f0b741c: afa0001c */ sw $zero,0x1c($sp) +/* f0b7420: afa00020 */ sw $zero,0x20($sp) +/* f0b7424: 0c00a86c */ jal cdFindGroundY +/* f0b7428: 2607161a */ addiu $a3,$s0,0x161a +/* f0b742c: 8e500284 */ lw $s0,0x284($s2) +/* f0b7430: 3c0143b4 */ lui $at,0x43b4 +/* f0b7434: 44819000 */ mtc1 $at,$f18 +/* f0b7438: c60819c4 */ lwc1 $f8,0x19c4($s0) +/* f0b743c: 3c017f1b */ lui $at,%hi(var7f1ad538) +/* f0b7440: 27a5010c */ addiu $a1,$sp,0x10c +/* f0b7444: 46004280 */ add.s $f10,$f8,$f0 +/* f0b7448: e7aa0110 */ swc1 $f10,0x110($sp) +/* f0b744c: e6000074 */ swc1 $f0,0x74($s0) +/* f0b7450: c7b000f8 */ lwc1 $f16,0xf8($sp) +/* f0b7454: c426d538 */ lwc1 $f6,%lo(var7f1ad538)($at) +/* f0b7458: 8e4f0284 */ lw $t7,0x284($s2) +/* f0b745c: 46128102 */ mul.s $f4,$f16,$f18 +/* f0b7460: 46062203 */ div.s $f8,$f4,$f6 +/* f0b7464: e5e80144 */ swc1 $f8,0x144($t7) +/* f0b7468: 8e480284 */ lw $t0,0x284($s2) +/* f0b746c: e5000078 */ swc1 $f0,0x78($t0) +/* f0b7470: 8e440284 */ lw $a0,0x284($s2) +/* f0b7474: 0fc2e168 */ jal func0f0b85a0 +/* f0b7478: 2484036c */ addiu $a0,$a0,0x36c +/* f0b747c: 0c0068f7 */ jal sinf +/* f0b7480: c7ac00f8 */ lwc1 $f12,0xf8($sp) +/* f0b7484: 8e490284 */ lw $t1,0x284($s2) +/* f0b7488: 46000287 */ neg.s $f10,$f0 +/* f0b748c: 44808000 */ mtc1 $zero,$f16 +/* f0b7490: e52a036c */ swc1 $f10,0x36c($t1) +/* f0b7494: 8e4a0284 */ lw $t2,0x284($s2) +/* f0b7498: e5500370 */ swc1 $f16,0x370($t2) +/* f0b749c: 0c0068f4 */ jal cosf +/* f0b74a0: c7ac00f8 */ lwc1 $f12,0xf8($sp) +/* f0b74a4: 8e4b0284 */ lw $t3,0x284($s2) +/* f0b74a8: e5600374 */ swc1 $f0,0x374($t3) +/* f0b74ac: 8e4c0284 */ lw $t4,0x284($s2) +/* f0b74b0: c7a2010c */ lwc1 $f2,0x10c($sp) +/* f0b74b4: e5820310 */ swc1 $f2,0x310($t4) +/* f0b74b8: 8e4d0284 */ lw $t5,0x284($s2) +/* f0b74bc: 8db900bc */ lw $t9,0xbc($t5) +/* f0b74c0: e7220008 */ swc1 $f2,0x8($t9) +/* f0b74c4: 8e580284 */ lw $t8,0x284($s2) +/* f0b74c8: c7a20110 */ lwc1 $f2,0x110($sp) +/* f0b74cc: e7020314 */ swc1 $f2,0x314($t8) +/* f0b74d0: 8e4e0284 */ lw $t6,0x284($s2) +/* f0b74d4: 8dcf00bc */ lw $t7,0xbc($t6) +/* f0b74d8: e5e2000c */ swc1 $f2,0xc($t7) +/* f0b74dc: 8e480284 */ lw $t0,0x284($s2) +/* f0b74e0: c7a20114 */ lwc1 $f2,0x114($sp) +/* f0b74e4: e5020318 */ swc1 $f2,0x318($t0) +/* f0b74e8: 8e490284 */ lw $t1,0x284($s2) +/* f0b74ec: 8d2a00bc */ lw $t2,0xbc($t1) +/* f0b74f0: e5420010 */ swc1 $f2,0x10($t2) +/* f0b74f4: 8e4b0284 */ lw $t3,0x284($s2) +/* f0b74f8: 0fc19711 */ jal propDeregisterRooms +/* f0b74fc: 8d6400bc */ lw $a0,0xbc($t3) +/* f0b7500: 8e4d0284 */ lw $t5,0x284($s2) +/* f0b7504: 87ac00fc */ lh $t4,0xfc($sp) +/* f0b7508: 2418ffff */ addiu $t8,$zero,-1 +/* f0b750c: 8db900bc */ lw $t9,0xbc($t5) +/* f0b7510: 27a4010c */ addiu $a0,$sp,0x10c +/* f0b7514: a72c0028 */ sh $t4,0x28($t9) +/* f0b7518: 8e4e0284 */ lw $t6,0x284($s2) +/* f0b751c: 8dcf00bc */ lw $t7,0xbc($t6) +/* f0b7520: a5f8002a */ sh $t8,0x2a($t7) +/* f0b7524: 8e500284 */ lw $s0,0x284($s2) +/* f0b7528: 87a700fc */ lh $a3,0xfc($sp) +/* f0b752c: 26050394 */ addiu $a1,$s0,0x394 +/* f0b7530: 0fc30709 */ jal currentPlayerSetCamPropertiesWithRoom +/* f0b7534: 26060388 */ addiu $a2,$s0,0x388 +/* f0b7538: 8e480298 */ lw $t0,0x298($s2) +/* f0b753c: 27a2005c */ addiu $v0,$sp,0x5c +/* f0b7540: 27a300e0 */ addiu $v1,$sp,0xe0 +/* f0b7544: 05000023 */ bltz $t0,.L0f0b75d4 +.L0f0b7548: +/* f0b7548: 24420004 */ addiu $v0,$v0,0x4 +/* f0b754c: 1443fffe */ bne $v0,$v1,.L0f0b7548 +/* f0b7550: ac40fffc */ sw $zero,-0x4($v0) +/* f0b7554: 24100001 */ addiu $s0,$zero,0x1 +.L0f0b7558: +/* f0b7558: 0fc446b5 */ jal invHasSingleWeaponOrProp +/* f0b755c: 02002025 */ or $a0,$s0,$zero +/* f0b7560: 1040000a */ beqz $v0,.L0f0b758c +/* f0b7564: 02002025 */ or $a0,$s0,$zero +/* f0b7568: 0fc2a685 */ jal bgunGetAmmoTypeForWeapon +/* f0b756c: 00002825 */ or $a1,$zero,$zero +/* f0b7570: 04400006 */ bltz $v0,.L0f0b758c +/* f0b7574: 28410021 */ slti $at,$v0,0x21 +/* f0b7578: 10200004 */ beqz $at,.L0f0b758c +/* f0b757c: 24090001 */ addiu $t1,$zero,0x1 +/* f0b7580: 00025080 */ sll $t2,$v0,0x2 +/* f0b7584: 03aa5821 */ addu $t3,$sp,$t2 +/* f0b7588: ad69005c */ sw $t1,0x5c($t3) +.L0f0b758c: +/* f0b758c: 26100001 */ addiu $s0,$s0,0x1 +/* f0b7590: 2401005e */ addiu $at,$zero,0x5d +/* f0b7594: 1601fff0 */ bne $s0,$at,.L0f0b7558 +/* f0b7598: 00000000 */ nop +/* f0b759c: 00001825 */ or $v1,$zero,$zero +/* f0b75a0: 27a2005c */ addiu $v0,$sp,0x5c +/* f0b75a4: 27a400e0 */ addiu $a0,$sp,0xe0 +.L0f0b75a8: +/* f0b75a8: 8c4d0000 */ lw $t5,0x0($v0) +/* f0b75ac: 24420004 */ addiu $v0,$v0,0x4 +/* f0b75b0: 15a00004 */ bnez $t5,.L0f0b75c4 +/* f0b75b4: 00000000 */ nop +/* f0b75b8: 8e4c0284 */ lw $t4,0x284($s2) +/* f0b75bc: 0183c821 */ addu $t9,$t4,$v1 +/* f0b75c0: af2017a8 */ sw $zero,0x17a8($t9) +.L0f0b75c4: +/* f0b75c4: 1444fff8 */ bne $v0,$a0,.L0f0b75a8 +/* f0b75c8: 24630004 */ addiu $v1,$v1,0x4 +/* f0b75cc: 1000000a */ b .L0f0b75f8 +/* f0b75d0: 00000000 */ nop +.L0f0b75d4: +/* f0b75d4: 0fc44580 */ jal invClear +/* f0b75d8: 00000000 */ nop +/* f0b75dc: 00001825 */ or $v1,$zero,$zero +/* f0b75e0: 24020084 */ addiu $v0,$zero,0x84 +.L0f0b75e4: +/* f0b75e4: 8e4e0284 */ lw $t6,0x284($s2) +/* f0b75e8: 01c3c021 */ addu $t8,$t6,$v1 +/* f0b75ec: 24630004 */ addiu $v1,$v1,0x4 +/* f0b75f0: 1462fffc */ bne $v1,$v0,.L0f0b75e4 +/* f0b75f4: af0017a8 */ sw $zero,0x17a8($t8) +.L0f0b75f8: +/* f0b75f8: 0fc44762 */ jal invGiveSingleWeapon +/* f0b75fc: 24040001 */ addiu $a0,$zero,0x1 +/* f0b7600: 5220003c */ beqzl $s1,.L0f0b76f4 +/* f0b7604: 8e4c0298 */ lw $t4,0x298($s2) +/* f0b7608: 8e4f029c */ lw $t7,0x29c($s2) +/* f0b760c: 05e20006 */ bltzl $t7,.L0f0b7628 +/* f0b7610: 8e220000 */ lw $v0,0x0($s1) +/* f0b7614: 8e4802a8 */ lw $t0,0x2a8($s2) +/* f0b7618: 8e490284 */ lw $t1,0x284($s2) +/* f0b761c: 51090035 */ beql $t0,$t1,.L0f0b76f4 +/* f0b7620: 8e4c0298 */ lw $t4,0x298($s2) +/* f0b7624: 8e220000 */ lw $v0,0x0($s1) +.L0f0b7628: +/* f0b7628: 2410000c */ addiu $s0,$zero,0xc +/* f0b762c: 12020030 */ beq $s0,$v0,.L0f0b76f0 +/* f0b7630: 2c41000c */ sltiu $at,$v0,0xc +.L0f0b7634: +/* f0b7634: 1020002a */ beqz $at,.L0f0b76e0 +/* f0b7638: 00025080 */ sll $t2,$v0,0x2 +/* f0b763c: 3c017f1b */ lui $at,%hi(var7f1ad53c) +/* f0b7640: 002a0821 */ addu $at,$at,$t2 +/* f0b7644: 8c2ad53c */ lw $t2,%lo(var7f1ad53c)($at) +/* f0b7648: 01400008 */ jr $t2 +/* f0b764c: 00000000 */ nop +/* f0b7650: 10000024 */ b .L0f0b76e4 +/* f0b7654: 2631000c */ addiu $s1,$s1,12 +/* f0b7658: 10000022 */ b .L0f0b76e4 +/* f0b765c: 2631000c */ addiu $s1,$s1,0xc +/* f0b7660: 10000020 */ b .L0f0b76e4 +/* f0b7664: 26310008 */ addiu $s1,$s1,0x8 +/* f0b7668: 8e2b000c */ lw $t3,0xc($s1) +/* f0b766c: 1560000a */ bnez $t3,.L0f0b7698 +/* f0b7670: 00000000 */ nop +/* f0b7674: 8e250008 */ lw $a1,0x8($s1) +/* f0b7678: 04a00005 */ bltz $a1,.L0f0b7690 +/* f0b767c: 00000000 */ nop +/* f0b7680: 0fc4478a */ jal invGiveDoubleWeapon +/* f0b7684: 8e240004 */ lw $a0,0x4($s1) +/* f0b7688: 10000016 */ b .L0f0b76e4 +/* f0b768c: 26310010 */ addiu $s1,$s1,0x10 +.L0f0b7690: +/* f0b7690: 0fc44762 */ jal invGiveSingleWeapon +/* f0b7694: 8e240004 */ lw $a0,0x4($s1) +.L0f0b7698: +/* f0b7698: 10000012 */ b .L0f0b76e4 +/* f0b769c: 26310010 */ addiu $s1,$s1,0x10 +/* f0b76a0: 8e2d000c */ lw $t5,0xc($s1) +/* f0b76a4: 15a00004 */ bnez $t5,.L0f0b76b8 +/* f0b76a8: 00000000 */ nop +/* f0b76ac: 8e240004 */ lw $a0,0x4($s1) +/* f0b76b0: 0fc2a58a */ jal bgunSetAmmoQuantity +/* f0b76b4: 8e250008 */ lw $a1,0x8($s1) +.L0f0b76b8: +/* f0b76b8: 1000000a */ b .L0f0b76e4 +/* f0b76bc: 26310010 */ addiu $s1,$s1,0x10 +/* f0b76c0: 10000008 */ b .L0f0b76e4 +/* f0b76c4: 26310020 */ addiu $s1,$s1,0x20 +/* f0b76c8: 10000006 */ b .L0f0b76e4 +/* f0b76cc: 26310008 */ addiu $s1,$s1,0x8 +/* f0b76d0: 10000004 */ b .L0f0b76e4 +/* f0b76d4: 26310008 */ addiu $s1,$s1,0x8 +/* f0b76d8: 10000002 */ b .L0f0b76e4 +/* f0b76dc: 26310028 */ addiu $s1,$s1,0x28 +.L0f0b76e0: +/* f0b76e0: 26310004 */ addiu $s1,$s1,0x4 +.L0f0b76e4: +/* f0b76e4: 8e220000 */ lw $v0,0x0($s1) +/* f0b76e8: 5602ffd2 */ bnel $s0,$v0,.L0f0b7634 +/* f0b76ec: 2c41000c */ sltiu $at,$v0,0xc +.L0f0b76f0: +/* f0b76f0: 8e4c0298 */ lw $t4,0x298($s2) +.L0f0b76f4: +/* f0b76f4: 8e500284 */ lw $s0,0x284($s2) +/* f0b76f8: 05800011 */ bltz $t4,.L0f0b7740 +/* f0b76fc: 00000000 */ nop +/* f0b7700: 44801000 */ mtc1 $zero,$f2 +/* f0b7704: c6001c5c */ lwc1 $f0,0x1c5c($s0) +/* f0b7708: 4600103c */ c.lt.s $f2,$f0 +/* f0b770c: 00000000 */ nop +/* f0b7710: 4500000b */ bc1f .L0f0b7740 +/* f0b7714: 00000000 */ nop +/* f0b7718: e60000dc */ swc1 $f0,0xdc($s0) +/* f0b771c: 8e590284 */ lw $t9,0x284($s2) +/* f0b7720: e72200e4 */ swc1 $f2,0xe4($t9) +/* f0b7724: 8e4e0284 */ lw $t6,0x284($s2) +/* f0b7728: e5c200e8 */ swc1 $f2,0xe8($t6) +/* f0b772c: 8e580284 */ lw $t8,0x284($s2) +/* f0b7730: e70200ec */ swc1 $f2,0xec($t8) +/* f0b7734: 8e4f0284 */ lw $t7,0x284($s2) +/* f0b7738: e5e200f0 */ swc1 $f2,0xf0($t7) +/* f0b773c: 8e500284 */ lw $s0,0x284($s2) +.L0f0b7740: +/* f0b7740: 0fc32e31 */ jal bmove0f0cb8c4 +/* f0b7744: 02002025 */ or $a0,$s0,$zero +/* f0b7748: 0fc2e00b */ jal currentPlayerSpawn +/* f0b774c: 00000000 */ nop +/* f0b7750: 8e480318 */ lw $t0,0x318($s2) +/* f0b7754: 3c013f80 */ lui $at,0x3f80 +/* f0b7758: 5100000a */ beqzl $t0,.L0f0b7784 +/* f0b775c: 44806000 */ mtc1 $zero,$f12 +/* f0b7760: 3c0142f0 */ lui $at,0x42f0 +/* f0b7764: 44816000 */ mtc1 $at,$f12 +/* f0b7768: 3c013f80 */ lui $at,0x3f80 +/* f0b776c: 44817000 */ mtc1 $at,$f14 +/* f0b7770: 0fc2ed5f */ jal currentPlayerStartChrFade +/* f0b7774: 00000000 */ nop +/* f0b7778: 10000006 */ b .L0f0b7794 +/* f0b777c: 8e490284 */ lw $t1,0x284($s2) +/* f0b7780: 44806000 */ mtc1 $zero,$f12 +.L0f0b7784: +/* f0b7784: 44817000 */ mtc1 $at,$f14 +/* f0b7788: 0fc2ed5f */ jal currentPlayerStartChrFade +/* f0b778c: 00000000 */ nop +/* f0b7790: 8e490284 */ lw $t1,0x284($s2) +.L0f0b7794: +/* f0b7794: 8d2a00bc */ lw $t2,0xbc($t1) +/* f0b7798: 8d420004 */ lw $v0,0x4($t2) +/* f0b779c: 50400006 */ beqzl $v0,.L0f0b77b8 +/* f0b77a0: 8fbf003c */ lw $ra,0x3c($sp) +/* f0b77a4: 8c4b0018 */ lw $t3,0x18($v0) +/* f0b77a8: 2401fbff */ addiu $at,$zero,-1025 +/* f0b77ac: 01616824 */ and $t5,$t3,$at +/* f0b77b0: ac4d0018 */ sw $t5,0x18($v0) +/* f0b77b4: 8fbf003c */ lw $ra,0x3c($sp) +.L0f0b77b8: +/* f0b77b8: 8fb00030 */ lw $s0,0x30($sp) +/* f0b77bc: 8fb10034 */ lw $s1,0x34($sp) +/* f0b77c0: 8fb20038 */ lw $s2,0x38($sp) +/* f0b77c4: 03e00008 */ jr $ra +/* f0b77c8: 27bd0118 */ addiu $sp,$sp,0x118 +); +#endif // Mismatch: assigns to bondprevpos and player->prop->pos have extra loads // from pos. diff --git a/src/game/game_0f09f0.c b/src/game/game_0f09f0.c index c5513757c..5ab6886b8 100644 --- a/src/game/game_0f09f0.c +++ b/src/game/game_0f09f0.c @@ -42,10 +42,13 @@ #include "data.h" #include "types.h" -char g_CheatMarqueeString[252]; - #if VERSION >= VERSION_PAL_FINAL -u8 fill3[0x2c]; +char g_CheatMarqueeString[300]; +#elif VERSION >= VERSION_NTSC_1_0 +char g_CheatMarqueeString[252]; +#else +char g_StringPointer[104]; +char g_StringPointer2[100]; #endif u8 *g_BlurBuffer; @@ -95,9 +98,14 @@ u32 var800a20c4; u32 var800a20c8; u32 var800a20cc; +#if VERSION >= VERSION_NTSC_1_0 struct menudialog g_PakCannotReadGameBoyMenuDialog; struct menudialog g_PakDamagedMenuDialog; struct menudialog g_PakDataLostMenuDialog; +#else +struct menudialog g_PakDamagedMenuDialog; +#endif + struct menudialog g_PakFullMenuDialog; struct menudialog g_PakRemovedMenuDialog; struct menudialog g_PakRepairFailedMenuDialog; @@ -134,9 +142,6 @@ const struct menucolourpalette g_MenuColourPalettes3[] = { const u32 var7f1b23e8[] = {0x544d0000}; char *g_StringPointer = g_CheatMarqueeString; char *g_StringPointer2 = &g_CheatMarqueeString[PAL ? 150 : 125]; -#else -char g_StringPointer[125]; -char g_StringPointer2[125]; #endif s32 g_MpPlayerNum = 0; @@ -3363,6 +3368,7 @@ glabel var7f1acbecnb ); #endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f1d6c /* f0f1d6c: 27bdff98 */ addiu $sp,$sp,-104 @@ -3469,7 +3475,116 @@ glabel func0f0f1d6c /* f0f1eec: 03e00008 */ jr $ra /* f0f1ef0: 27bd0068 */ addiu $sp,$sp,0x68 ); +#else +GLOBAL_ASM( +glabel func0f0f1d6c +/* f0ee988: 27bdff98 */ addiu $sp,$sp,-104 +/* f0ee98c: afbe0038 */ sw $s8,0x38($sp) +/* f0ee990: afb30024 */ sw $s3,0x24($sp) +/* f0ee994: afbf003c */ sw $ra,0x3c($sp) +/* f0ee998: afb70034 */ sw $s7,0x34($sp) +/* f0ee99c: afb60030 */ sw $s6,0x30($sp) +/* f0ee9a0: afb5002c */ sw $s5,0x2c($sp) +/* f0ee9a4: afb40028 */ sw $s4,0x28($sp) +/* f0ee9a8: afb20020 */ sw $s2,0x20($sp) +/* f0ee9ac: afb1001c */ sw $s1,0x1c($sp) +/* f0ee9b0: afb00018 */ sw $s0,0x18($sp) +/* f0ee9b4: afa60070 */ sw $a2,0x70($sp) +/* f0ee9b8: 8cc20634 */ lw $v0,0x634($a2) +/* f0ee9bc: 8c910008 */ lw $s1,0x8($a0) +/* f0ee9c0: 84d7077a */ lh $s7,0x77a($a2) +/* f0ee9c4: 8cd605cc */ lw $s6,0x5cc($a2) +/* f0ee9c8: 2442ffff */ addiu $v0,$v0,-1 +/* f0ee9cc: 24580001 */ addiu $t8,$v0,0x1 +/* f0ee9d0: 00a0f025 */ or $s8,$a1,$zero +/* f0ee9d4: 00009825 */ or $s3,$zero,$zero +/* f0ee9d8: a0a00005 */ sb $zero,0x5($a1) +/* f0ee9dc: a0b80004 */ sb $t8,0x4($a1) +/* f0ee9e0: 1220003a */ beqz $s1,.NB0f0eeacc +/* f0ee9e4: a4b70006 */ sh $s7,0x6($a1) +/* f0ee9e8: 92390000 */ lbu $t9,0x0($s1) +/* f0ee9ec: 2401001a */ addiu $at,$zero,0x1a +/* f0ee9f0: 24140001 */ addiu $s4,$zero,0x1 +/* f0ee9f4: 13210035 */ beq $t9,$at,.NB0f0eeacc +/* f0ee9f8: 8fa80070 */ lw $t0,0x70($sp) +/* f0ee9fc: 00024880 */ sll $t1,$v0,0x2 +/* f0eea00: 01224821 */ addu $t1,$t1,$v0 +/* f0eea04: 00094840 */ sll $t1,$t1,0x1 +/* f0eea08: 00165080 */ sll $t2,$s6,0x2 +/* f0eea0c: 010a9021 */ addu $s2,$t0,$t2 +/* f0eea10: 01098021 */ addu $s0,$t0,$t1 +/* f0eea14: 2415ffff */ addiu $s5,$zero,-1 +.NB0f0eea18: +/* f0eea18: 8e2b0004 */ lw $t3,0x4($s1) +/* f0eea1c: 02202025 */ or $a0,$s1,$zero +/* f0eea20: 27a50058 */ addiu $a1,$sp,0x58 +/* f0eea24: 316c0001 */ andi $t4,$t3,0x1 +/* f0eea28: 11800002 */ beqz $t4,.NB0f0eea34 +/* f0eea2c: 00000000 */ sll $zero,$zero,0x0 +/* f0eea30: 24140001 */ addiu $s4,$zero,0x1 +.NB0f0eea34: +/* f0eea34: 5280000d */ beqzl $s4,.NB0f0eea6c +/* f0eea38: afb50058 */ sw $s5,0x58($sp) +/* f0eea3c: 93cd0005 */ lbu $t5,0x5($s8) +/* f0eea40: 24420001 */ addiu $v0,$v0,0x1 +/* f0eea44: 2610000a */ addiu $s0,$s0,0xa +/* f0eea48: 25ae0001 */ addiu $t6,$t5,0x1 +/* f0eea4c: a3ce0005 */ sb $t6,0x5($s8) +/* f0eea50: a60005d0 */ sh $zero,0x5d0($s0) +/* f0eea54: a60005d2 */ sh $zero,0x5d2($s0) +/* f0eea58: a20005d4 */ sb $zero,0x5d4($s0) +/* f0eea5c: a20005d8 */ sb $zero,0x5d8($s0) +/* f0eea60: a61605d6 */ sh $s6,0x5d6($s0) +/* f0eea64: 0000a025 */ or $s4,$zero,$zero +/* f0eea68: afb50058 */ sw $s5,0x58($sp) +.NB0f0eea6c: +/* f0eea6c: 0fc3b86d */ jal func0f0f15a4 +/* f0eea70: afa20064 */ sw $v0,0x64($sp) +/* f0eea74: 8faf0058 */ lw $t7,0x58($sp) +/* f0eea78: 8fa20064 */ lw $v0,0x64($sp) +/* f0eea7c: 51f50008 */ beql $t7,$s5,.NB0f0eeaa0 +/* f0eea80: a255048f */ sb $s5,0x48f($s2) +/* f0eea84: a257048f */ sb $s7,0x48f($s2) +/* f0eea88: 87b8005a */ lh $t8,0x5a($sp) +/* f0eea8c: 02f8b821 */ addu $s7,$s7,$t8 +/* f0eea90: 0017cc00 */ sll $t9,$s7,0x10 +/* f0eea94: 10000002 */ beqz $zero,.NB0f0eeaa0 +/* f0eea98: 0019bc03 */ sra $s7,$t9,0x10 +/* f0eea9c: a255048f */ sb $s5,0x48f($s2) +.NB0f0eeaa0: +/* f0eeaa0: a253048e */ sb $s3,0x48e($s2) +/* f0eeaa4: 920805d8 */ lbu $t0,0x5d8($s0) +/* f0eeaa8: 2401001a */ addiu $at,$zero,0x1a +/* f0eeaac: 26d60001 */ addiu $s6,$s6,0x1 +/* f0eeab0: 250a0001 */ addiu $t2,$t0,0x1 +/* f0eeab4: a20a05d8 */ sb $t2,0x5d8($s0) +/* f0eeab8: 922b0014 */ lbu $t3,0x14($s1) +/* f0eeabc: 26520004 */ addiu $s2,$s2,0x4 +/* f0eeac0: 26310014 */ addiu $s1,$s1,0x14 +/* f0eeac4: 1561ffd4 */ bne $t3,$at,.NB0f0eea18 +/* f0eeac8: 26730001 */ addiu $s3,$s3,0x1 +.NB0f0eeacc: +/* f0eeacc: 8fad0070 */ lw $t5,0x70($sp) +/* f0eead0: 244c0001 */ addiu $t4,$v0,0x1 +/* f0eead4: adac0634 */ sw $t4,0x634($t5) +/* f0eead8: adb605cc */ sw $s6,0x5cc($t5) +/* f0eeadc: adb70778 */ sw $s7,0x778($t5) +/* f0eeae0: 8fbf003c */ lw $ra,0x3c($sp) +/* f0eeae4: 8fbe0038 */ lw $s8,0x38($sp) +/* f0eeae8: 8fb70034 */ lw $s7,0x34($sp) +/* f0eeaec: 8fb60030 */ lw $s6,0x30($sp) +/* f0eeaf0: 8fb5002c */ lw $s5,0x2c($sp) +/* f0eeaf4: 8fb40028 */ lw $s4,0x28($sp) +/* f0eeaf8: 8fb30024 */ lw $s3,0x24($sp) +/* f0eeafc: 8fb20020 */ lw $s2,0x20($sp) +/* f0eeb00: 8fb1001c */ lw $s1,0x1c($sp) +/* f0eeb04: 8fb00018 */ lw $s0,0x18($sp) +/* f0eeb08: 03e00008 */ jr $ra +/* f0eeb0c: 27bd0068 */ addiu $sp,$sp,0x68 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f1ef4 /* f0f1ef4: 27bdffd8 */ addiu $sp,$sp,-40 @@ -3629,7 +3744,169 @@ glabel func0f0f1ef4 /* f0f212c: 03e00008 */ jr $ra /* f0f2130: 27bd0028 */ addiu $sp,$sp,0x28 ); +#else +GLOBAL_ASM( +glabel func0f0f1ef4 +/* f0eeb10: 27bdffd8 */ addiu $sp,$sp,-40 +/* f0eeb14: afb70024 */ sw $s7,0x24($sp) +/* f0eeb18: afb60020 */ sw $s6,0x20($sp) +/* f0eeb1c: afb5001c */ sw $s5,0x1c($sp) +/* f0eeb20: afb40018 */ sw $s4,0x18($sp) +/* f0eeb24: afb30014 */ sw $s3,0x14($sp) +/* f0eeb28: afb20010 */ sw $s2,0x10($sp) +/* f0eeb2c: afb1000c */ sw $s1,0xc($sp) +/* f0eeb30: afb00008 */ sw $s0,0x8($sp) +/* f0eeb34: 8c8e0000 */ lw $t6,0x0($a0) +/* f0eeb38: 8c8d0020 */ lw $t5,0x20($a0) +/* f0eeb3c: 00803025 */ or $a2,$a0,$zero +/* f0eeb40: 8dcf0010 */ lw $t7,0x10($t6) +/* f0eeb44: 3c19800a */ lui $t9,0x800a +/* f0eeb48: 25adfff4 */ addiu $t5,$t5,-12 +/* f0eeb4c: 31f80040 */ andi $t8,$t7,0x40 +/* f0eeb50: 57000076 */ bnezl $t8,.NB0f0eed2c +/* f0eeb54: 8fb00008 */ lw $s0,0x8($sp) +/* f0eeb58: 8f395eb4 */ lw $t9,0x5eb4($t9) +/* f0eeb5c: 2401000d */ addiu $at,$zero,0xd +/* f0eeb60: 53210072 */ beql $t9,$at,.NB0f0eed2c +/* f0eeb64: 8fb00008 */ lw $s0,0x8($sp) +/* f0eeb68: 8c8e0028 */ lw $t6,0x28($a0) +/* f0eeb6c: 01ae082a */ slt $at,$t5,$t6 +/* f0eeb70: 5020006e */ beqzl $at,.NB0f0eed2c +/* f0eeb74: 8fb00008 */ lw $s0,0x8($sp) +/* f0eeb78: 90910005 */ lbu $s1,0x5($a0) +/* f0eeb7c: 00006025 */ or $t4,$zero,$zero +/* f0eeb80: 3c0f8007 */ lui $t7,0x8007 +/* f0eeb84: 1a200068 */ blez $s1,.NB0f0eed28 +/* f0eeb88: 3c19800a */ lui $t9,0x800a +/* f0eeb8c: 8def3af0 */ lw $t7,0x3af0($t7) +/* f0eeb90: 273927c0 */ addiu $t9,$t9,0x27c0 +/* f0eeb94: 2410000a */ addiu $s0,$zero,0xa +/* f0eeb98: 000fc0c0 */ sll $t8,$t7,0x3 +/* f0eeb9c: 030fc023 */ subu $t8,$t8,$t7 +/* f0eeba0: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0eeba4: 030fc023 */ subu $t8,$t8,$t7 +/* f0eeba8: 0018c100 */ sll $t8,$t8,0x4 +/* f0eebac: 030fc023 */ subu $t8,$t8,$t7 +/* f0eebb0: 0018c080 */ sll $t8,$t8,0x2 +/* f0eebb4: 03192821 */ addu $a1,$t8,$t9 +/* f0eebb8: 3c0b0020 */ lui $t3,0x20 +/* f0eebbc: 240a0012 */ addiu $t2,$zero,0x12 +/* f0eebc0: 24090005 */ addiu $t1,$zero,0x5 +/* f0eebc4: 24080002 */ addiu $t0,$zero,0x2 +/* f0eebc8: 24070014 */ addiu $a3,$zero,0x14 +/* f0eebcc: 2404000b */ addiu $a0,$zero,0xb +/* f0eebd0: 90ce0004 */ lbu $t6,0x4($a2) +.NB0f0eebd4: +/* f0eebd4: 01cc9021 */ addu $s2,$t6,$t4 +/* f0eebd8: 02500019 */ multu $s2,$s0 +/* f0eebdc: 258c0001 */ addiu $t4,$t4,0x1 +/* f0eebe0: 00007812 */ mflo $t7 +/* f0eebe4: 00af1821 */ addu $v1,$a1,$t7 +/* f0eebe8: 847805d2 */ lh $t8,0x5d2($v1) +/* f0eebec: 030d1023 */ subu $v0,$t8,$t5 +/* f0eebf0: 5840004b */ blezl $v0,.NB0f0eed20 +/* f0eebf4: 0191082a */ slt $at,$t4,$s1 +/* f0eebf8: 907305d8 */ lbu $s3,0x5d8($v1) +/* f0eebfc: 00009025 */ or $s2,$zero,$zero +/* f0eec00: 5a600047 */ blezl $s3,.NB0f0eed20 +/* f0eec04: 0191082a */ slt $at,$t4,$s1 +.NB0f0eec08: +/* f0eec08: 58400040 */ blezl $v0,.NB0f0eed0c +/* f0eec0c: 26520001 */ addiu $s2,$s2,0x1 +/* f0eec10: 947905d6 */ lhu $t9,0x5d6($v1) +/* f0eec14: 00008825 */ or $s1,$zero,$zero +/* f0eec18: 0332a021 */ addu $s4,$t9,$s2 +/* f0eec1c: 00147080 */ sll $t6,$s4,0x2 +/* f0eec20: 00aeb021 */ addu $s6,$a1,$t6 +/* f0eec24: 92cf048e */ lbu $t7,0x48e($s6) +/* f0eec28: 8cd90000 */ lw $t9,0x0($a2) +/* f0eec2c: 01e70019 */ multu $t7,$a3 +/* f0eec30: 8f2e0008 */ lw $t6,0x8($t9) +/* f0eec34: 0000c012 */ mflo $t8 +/* f0eec38: 030ea821 */ addu $s5,$t8,$t6 +/* f0eec3c: 92b70000 */ lbu $s7,0x0($s5) +/* f0eec40: 52e80008 */ beql $s7,$t0,.NB0f0eec64 +/* f0eec44: 8eaf0004 */ lw $t7,0x4($s5) +/* f0eec48: 52e90022 */ beql $s7,$t1,.NB0f0eecd4 +/* f0eec4c: 86d4048c */ lh $s4,0x48c($s6) +/* f0eec50: 52ea0020 */ beql $s7,$t2,.NB0f0eecd4 +/* f0eec54: 86d4048c */ lh $s4,0x48c($s6) +/* f0eec58: 10000024 */ beqz $zero,.NB0f0eecec +/* f0eec5c: 00000000 */ sll $zero,$zero,0x0 +/* f0eec60: 8eaf0004 */ lw $t7,0x4($s5) +.NB0f0eec64: +/* f0eec64: 244e000a */ addiu $t6,$v0,0xa +/* f0eec68: 01ebc824 */ and $t9,$t7,$t3 +/* f0eec6c: 13200009 */ beqz $t9,.NB0f0eec94 +/* f0eec70: 00000000 */ sll $zero,$zero,0x0 +/* f0eec74: 86d4048c */ lh $s4,0x48c($s6) +/* f0eec78: 00408825 */ or $s1,$v0,$zero +/* f0eec7c: 0282c023 */ subu $t8,$s4,$v0 +/* f0eec80: 2b01001e */ slti $at,$t8,0x1e +/* f0eec84: 10200019 */ beqz $at,.NB0f0eecec +/* f0eec88: 00000000 */ sll $zero,$zero,0x0 +/* f0eec8c: 10000017 */ beqz $zero,.NB0f0eecec +/* f0eec90: 2691ffe2 */ addiu $s1,$s4,-30 +.NB0f0eec94: +/* f0eec94: 01c4001a */ div $zero,$t6,$a0 +/* f0eec98: 00007812 */ mflo $t7 +/* f0eec9c: 14800002 */ bnez $a0,.NB0f0eeca8 +/* f0eeca0: 00000000 */ sll $zero,$zero,0x0 +/* f0eeca4: 0007000d */ break 0x7 +.NB0f0eeca8: +/* f0eeca8: 2401ffff */ addiu $at,$zero,-1 +/* f0eecac: 14810004 */ bne $a0,$at,.NB0f0eecc0 +/* f0eecb0: 3c018000 */ lui $at,0x8000 +/* f0eecb4: 15c10002 */ bne $t6,$at,.NB0f0eecc0 +/* f0eecb8: 00000000 */ sll $zero,$zero,0x0 +/* f0eecbc: 0006000d */ break 0x6 +.NB0f0eecc0: +/* f0eecc0: 01e40019 */ multu $t7,$a0 +/* f0eecc4: 00008812 */ mflo $s1 +/* f0eecc8: 10000008 */ beqz $zero,.NB0f0eecec +/* f0eeccc: 00000000 */ sll $zero,$zero,0x0 +/* f0eecd0: 86d4048c */ lh $s4,0x48c($s6) +.NB0f0eecd4: +/* f0eecd4: 00408825 */ or $s1,$v0,$zero +/* f0eecd8: 0282c823 */ subu $t9,$s4,$v0 +/* f0eecdc: 2b210032 */ slti $at,$t9,0x32 +/* f0eece0: 10200002 */ beqz $at,.NB0f0eecec +/* f0eece4: 00000000 */ sll $zero,$zero,0x0 +/* f0eece8: 2691ffce */ addiu $s1,$s4,-50 +.NB0f0eecec: +/* f0eecec: 5a200007 */ blezl $s1,.NB0f0eed0c +/* f0eecf0: 26520001 */ addiu $s2,$s2,0x1 +/* f0eecf4: 86d8048c */ lh $t8,0x48c($s6) +/* f0eecf8: 00511023 */ subu $v0,$v0,$s1 +/* f0eecfc: 03117023 */ subu $t6,$t8,$s1 +/* f0eed00: a6ce048c */ sh $t6,0x48c($s6) +/* f0eed04: 907305d8 */ lbu $s3,0x5d8($v1) +/* f0eed08: 26520001 */ addiu $s2,$s2,0x1 +.NB0f0eed0c: +/* f0eed0c: 0253082a */ slt $at,$s2,$s3 +/* f0eed10: 1420ffbd */ bnez $at,.NB0f0eec08 +/* f0eed14: 00000000 */ sll $zero,$zero,0x0 +/* f0eed18: 90d10005 */ lbu $s1,0x5($a2) +/* f0eed1c: 0191082a */ slt $at,$t4,$s1 +.NB0f0eed20: +/* f0eed20: 5420ffac */ bnezl $at,.NB0f0eebd4 +/* f0eed24: 90ce0004 */ lbu $t6,0x4($a2) +.NB0f0eed28: +/* f0eed28: 8fb00008 */ lw $s0,0x8($sp) +.NB0f0eed2c: +/* f0eed2c: 8fb1000c */ lw $s1,0xc($sp) +/* f0eed30: 8fb20010 */ lw $s2,0x10($sp) +/* f0eed34: 8fb30014 */ lw $s3,0x14($sp) +/* f0eed38: 8fb40018 */ lw $s4,0x18($sp) +/* f0eed3c: 8fb5001c */ lw $s5,0x1c($sp) +/* f0eed40: 8fb60020 */ lw $s6,0x20($sp) +/* f0eed44: 8fb70024 */ lw $s7,0x24($sp) +/* f0eed48: 03e00008 */ jr $ra +/* f0eed4c: 27bd0028 */ addiu $sp,$sp,0x28 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f2134 /* f0f2134: 27bdff68 */ addiu $sp,$sp,-152 @@ -3780,7 +4057,160 @@ glabel func0f0f2134 /* f0f234c: 03e00008 */ jr $ra /* f0f2350: 27bd0098 */ addiu $sp,$sp,0x98 ); +#else +GLOBAL_ASM( +glabel func0f0f2134 +/* f0eed50: 27bdff68 */ addiu $sp,$sp,-152 +/* f0eed54: afbf0044 */ sw $ra,0x44($sp) +/* f0eed58: afbe0040 */ sw $s8,0x40($sp) +/* f0eed5c: afb7003c */ sw $s7,0x3c($sp) +/* f0eed60: afb60038 */ sw $s6,0x38($sp) +/* f0eed64: afb50034 */ sw $s5,0x34($sp) +/* f0eed68: afb40030 */ sw $s4,0x30($sp) +/* f0eed6c: afb3002c */ sw $s3,0x2c($sp) +/* f0eed70: afb20028 */ sw $s2,0x28($sp) +/* f0eed74: afb10024 */ sw $s1,0x24($sp) +/* f0eed78: afb00020 */ sw $s0,0x20($sp) +/* f0eed7c: afa5009c */ sw $a1,0x9c($sp) +/* f0eed80: 8c920008 */ lw $s2,0x8($a0) +/* f0eed84: 90a20004 */ lbu $v0,0x4($a1) +/* f0eed88: 00c0f025 */ or $s8,$a2,$zero +/* f0eed8c: 12400030 */ beqz $s2,.NB0f0eee50 +/* f0eed90: 2442ffff */ addiu $v0,$v0,-1 +/* f0eed94: 924f0000 */ lbu $t7,0x0($s2) +/* f0eed98: 2417001a */ addiu $s7,$zero,0x1a +/* f0eed9c: 24140001 */ addiu $s4,$zero,0x1 +/* f0eeda0: 12ef002b */ beq $s7,$t7,.NB0f0eee50 +/* f0eeda4: 0002c080 */ sll $t8,$v0,0x2 +/* f0eeda8: 0302c021 */ addu $t8,$t8,$v0 +/* f0eedac: 0018c040 */ sll $t8,$t8,0x1 +/* f0eedb0: 00d88021 */ addu $s0,$a2,$t8 +/* f0eedb4: 27b60068 */ addiu $s6,$sp,0x68 +/* f0eedb8: 27b5006a */ addiu $s5,$sp,0x6a +/* f0eedbc: 8fb30090 */ lw $s3,0x90($sp) +/* f0eedc0: 8e590004 */ lw $t9,0x4($s2) +.NB0f0eedc4: +/* f0eedc4: 02402025 */ or $a0,$s2,$zero +/* f0eedc8: 02a02825 */ or $a1,$s5,$zero +/* f0eedcc: 33280001 */ andi $t0,$t9,0x1 +/* f0eedd0: 11000002 */ beqz $t0,.NB0f0eeddc +/* f0eedd4: 02c03025 */ or $a2,$s6,$zero +/* f0eedd8: 24140001 */ addiu $s4,$zero,0x1 +.NB0f0eeddc: +/* f0eeddc: 52800007 */ beqzl $s4,.NB0f0eedfc +/* f0eede0: 00134880 */ sll $t1,$s3,0x2 +/* f0eede4: 2610000a */ addiu $s0,$s0,0xa +/* f0eede8: a60005d0 */ sh $zero,0x5d0($s0) +/* f0eedec: a60005d2 */ sh $zero,0x5d2($s0) +/* f0eedf0: 0000a025 */ or $s4,$zero,$zero +/* f0eedf4: 961305d6 */ lhu $s3,0x5d6($s0) +/* f0eedf8: 00134880 */ sll $t1,$s3,0x2 +.NB0f0eedfc: +/* f0eedfc: 03c98821 */ addu $s1,$s8,$t1 +/* f0eee00: 0fc3b88a */ jal func0f0f1618 +/* f0eee04: 8fa7009c */ lw $a3,0x9c($sp) +/* f0eee08: 860a05d0 */ lh $t2,0x5d0($s0) +/* f0eee0c: 87ab006a */ lh $t3,0x6a($sp) +/* f0eee10: 014b082a */ slt $at,$t2,$t3 +/* f0eee14: 50200003 */ beqzl $at,.NB0f0eee24 +/* f0eee18: 87ac0068 */ lh $t4,0x68($sp) +/* f0eee1c: a60b05d0 */ sh $t3,0x5d0($s0) +/* f0eee20: 87ac0068 */ lh $t4,0x68($sp) +.NB0f0eee24: +/* f0eee24: 26730001 */ addiu $s3,$s3,0x1 +/* f0eee28: 26520014 */ addiu $s2,$s2,0x14 +/* f0eee2c: a62c048c */ sh $t4,0x48c($s1) +/* f0eee30: 860d05d2 */ lh $t5,0x5d2($s0) +/* f0eee34: 87ae0068 */ lh $t6,0x68($sp) +/* f0eee38: 01ae7821 */ addu $t7,$t5,$t6 +/* f0eee3c: a60f05d2 */ sh $t7,0x5d2($s0) +/* f0eee40: 92580000 */ lbu $t8,0x0($s2) +/* f0eee44: 56f8ffdf */ bnel $s7,$t8,.NB0f0eedc4 +/* f0eee48: 8e590004 */ lw $t9,0x4($s2) +/* f0eee4c: afb30090 */ sw $s3,0x90($sp) +.NB0f0eee50: +/* f0eee50: 8fb9009c */ lw $t9,0x9c($sp) +/* f0eee54: 00008025 */ or $s0,$zero,$zero +/* f0eee58: 00008825 */ or $s1,$zero,$zero +/* f0eee5c: 93220005 */ lbu $v0,0x5($t9) +/* f0eee60: 00001825 */ or $v1,$zero,$zero +/* f0eee64: 8fab009c */ lw $t3,0x9c($sp) +/* f0eee68: 18400013 */ blez $v0,.NB0f0eeeb8 +/* f0eee6c: 00023080 */ sll $a2,$v0,0x2 +/* f0eee70: 93280004 */ lbu $t0,0x4($t9) +/* f0eee74: 00c23021 */ addu $a2,$a2,$v0 +/* f0eee78: 00063040 */ sll $a2,$a2,0x1 +/* f0eee7c: 00084880 */ sll $t1,$t0,0x2 +/* f0eee80: 01284821 */ addu $t1,$t1,$t0 +/* f0eee84: 00094840 */ sll $t1,$t1,0x1 +/* f0eee88: 03c92821 */ addu $a1,$s8,$t1 +/* f0eee8c: 00a31021 */ addu $v0,$a1,$v1 +.NB0f0eee90: +/* f0eee90: 844405d2 */ lh $a0,0x5d2($v0) +/* f0eee94: 844a05d0 */ lh $t2,0x5d0($v0) +/* f0eee98: 2463000a */ addiu $v1,$v1,0xa +/* f0eee9c: 0204082a */ slt $at,$s0,$a0 +/* f0eeea0: 10200002 */ beqz $at,.NB0f0eeeac +/* f0eeea4: 022a8821 */ addu $s1,$s1,$t2 +/* f0eeea8: 00808025 */ or $s0,$a0,$zero +.NB0f0eeeac: +/* f0eeeac: 0066082a */ slt $at,$v1,$a2 +/* f0eeeb0: 5420fff7 */ bnezl $at,.NB0f0eee90 +/* f0eeeb4: 00a31021 */ addu $v0,$a1,$v1 +.NB0f0eeeb8: +/* f0eeeb8: 2610000c */ addiu $s0,$s0,0xc +/* f0eeebc: 0fc3b864 */ jal menuResolveParam1Text +/* f0eeec0: 8d640000 */ lw $a0,0x0($t3) +/* f0eeec4: 3c0c8008 */ lui $t4,0x8008 +/* f0eeec8: 8d8c236c */ lw $t4,0x236c($t4) +/* f0eeecc: 3c078008 */ lui $a3,0x8008 +/* f0eeed0: 8ce72370 */ lw $a3,0x2370($a3) +/* f0eeed4: 27a4007c */ addiu $a0,$sp,0x7c +/* f0eeed8: 27a50080 */ addiu $a1,$sp,0x80 +/* f0eeedc: 00403025 */ or $a2,$v0,$zero +/* f0eeee0: afa00014 */ sw $zero,0x14($sp) +/* f0eeee4: 0fc54655 */ jal textMeasure +/* f0eeee8: afac0010 */ sw $t4,0x10($sp) +/* f0eeeec: 3c02800a */ lui $v0,0x800a +/* f0eeef0: 8c425eb4 */ lw $v0,0x5eb4($v0) +/* f0eeef4: 24010003 */ addiu $at,$zero,0x3 +/* f0eeef8: 24030008 */ addiu $v1,$zero,0x8 +/* f0eeefc: 10410008 */ beq $v0,$at,.NB0f0eef20 +/* f0eef00: 8fad0080 */ lw $t5,0x80($sp) +/* f0eef04: 24010004 */ addiu $at,$zero,0x4 +/* f0eef08: 10410005 */ beq $v0,$at,.NB0f0eef20 +/* f0eef0c: 24010005 */ addiu $at,$zero,0x5 +/* f0eef10: 10410003 */ beq $v0,$at,.NB0f0eef20 +/* f0eef14: 2401000b */ addiu $at,$zero,0xb +/* f0eef18: 54410003 */ bnel $v0,$at,.NB0f0eef28 +/* f0eef1c: 01a31021 */ addu $v0,$t5,$v1 +.NB0f0eef20: +/* f0eef20: 24030011 */ addiu $v1,$zero,0x11 +/* f0eef24: 01a31021 */ addu $v0,$t5,$v1 +.NB0f0eef28: +/* f0eef28: 0222082a */ slt $at,$s1,$v0 +/* f0eef2c: 10200002 */ beqz $at,.NB0f0eef38 +/* f0eef30: 8fae009c */ lw $t6,0x9c($sp) +/* f0eef34: 00408825 */ or $s1,$v0,$zero +.NB0f0eef38: +/* f0eef38: add10024 */ sw $s1,0x24($t6) +/* f0eef3c: add00028 */ sw $s0,0x28($t6) +/* f0eef40: 8fbf0044 */ lw $ra,0x44($sp) +/* f0eef44: 8fbe0040 */ lw $s8,0x40($sp) +/* f0eef48: 8fb7003c */ lw $s7,0x3c($sp) +/* f0eef4c: 8fb60038 */ lw $s6,0x38($sp) +/* f0eef50: 8fb50034 */ lw $s5,0x34($sp) +/* f0eef54: 8fb40030 */ lw $s4,0x30($sp) +/* f0eef58: 8fb3002c */ lw $s3,0x2c($sp) +/* f0eef5c: 8fb20028 */ lw $s2,0x28($sp) +/* f0eef60: 8fb10024 */ lw $s1,0x24($sp) +/* f0eef64: 8fb00020 */ lw $s0,0x20($sp) +/* f0eef68: 03e00008 */ jr $ra +/* f0eef6c: 27bd0098 */ addiu $sp,$sp,0x98 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f2354 /* f0f2354: 27bdfff0 */ addiu $sp,$sp,-16 @@ -3910,6 +4340,137 @@ glabel func0f0f2354 /* f0f252c: 03e00008 */ jr $ra /* f0f2530: 27bd0010 */ addiu $sp,$sp,0x10 ); +#else +GLOBAL_ASM( +glabel func0f0f2354 +/* f0eef70: 27bdfff0 */ addiu $sp,$sp,-16 +/* f0eef74: afb1000c */ sw $s1,0xc($sp) +/* f0eef78: afb00008 */ sw $s0,0x8($sp) +/* f0eef7c: 90820004 */ lbu $v0,0x4($a0) +/* f0eef80: 3c0c8007 */ lui $t4,0x8007 +/* f0eef84: 00a08025 */ or $s0,$a1,$zero +/* f0eef88: ace20000 */ sw $v0,0x0($a3) +/* f0eef8c: 908f0005 */ lbu $t7,0x5($a0) +/* f0eef90: 90830004 */ lbu $v1,0x4($a0) +/* f0eef94: 258c3af0 */ addiu $t4,$t4,0x3af0 +/* f0eef98: 24110014 */ addiu $s1,$zero,0x14 +/* f0eef9c: 006fc021 */ addu $t8,$v1,$t7 +/* f0eefa0: 0058082a */ slt $at,$v0,$t8 +/* f0eefa4: 10200051 */ beqz $at,.NB0f0ef0ec +/* f0eefa8: 240d000a */ addiu $t5,$zero,0xa +/* f0eefac: 3c0b800a */ lui $t3,0x800a +/* f0eefb0: 256b27c0 */ addiu $t3,$t3,0x27c0 +.NB0f0eefb4: +/* f0eefb4: 004d0019 */ multu $v0,$t5 +/* f0eefb8: 8d990000 */ lw $t9,0x0($t4) +/* f0eefbc: 00001825 */ or $v1,$zero,$zero +/* f0eefc0: 001970c0 */ sll $t6,$t9,0x3 +/* f0eefc4: 01d97023 */ subu $t6,$t6,$t9 +/* f0eefc8: 000e70c0 */ sll $t6,$t6,0x3 +/* f0eefcc: 01d97023 */ subu $t6,$t6,$t9 +/* f0eefd0: 000e7100 */ sll $t6,$t6,0x4 +/* f0eefd4: 01d97023 */ subu $t6,$t6,$t9 +/* f0eefd8: 000e7080 */ sll $t6,$t6,0x2 +/* f0eefdc: 0000c012 */ mflo $t8 +/* f0eefe0: 016e7821 */ addu $t7,$t3,$t6 +/* f0eefe4: 01f8c821 */ addu $t9,$t7,$t8 +/* f0eefe8: 972905d6 */ lhu $t1,0x5d6($t9) +/* f0eefec: acc90000 */ sw $t1,0x0($a2) +/* f0eeff0: 8ce20000 */ lw $v0,0x0($a3) +/* f0eeff4: 8d8f0000 */ lw $t7,0x0($t4) +/* f0eeff8: 004d0019 */ multu $v0,$t5 +/* f0eeffc: 000fc0c0 */ sll $t8,$t7,0x3 +/* f0ef000: 030fc023 */ subu $t8,$t8,$t7 +/* f0ef004: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0ef008: 030fc023 */ subu $t8,$t8,$t7 +/* f0ef00c: 0018c100 */ sll $t8,$t8,0x4 +/* f0ef010: 030fc023 */ subu $t8,$t8,$t7 +/* f0ef014: 0018c080 */ sll $t8,$t8,0x2 +/* f0ef018: 01782821 */ addu $a1,$t3,$t8 +/* f0ef01c: 0000c812 */ mflo $t9 +/* f0ef020: 00b94021 */ addu $t0,$a1,$t9 +/* f0ef024: 910e05d8 */ lbu $t6,0x5d8($t0) +/* f0ef028: 950f05d6 */ lhu $t7,0x5d6($t0) +/* f0ef02c: 01cfc021 */ addu $t8,$t6,$t7 +/* f0ef030: 0138082a */ slt $at,$t1,$t8 +/* f0ef034: 10200024 */ beqz $at,.NB0f0ef0c8 +/* f0ef038: 0009c880 */ sll $t9,$t1,0x2 +.NB0f0ef03c: +/* f0ef03c: 00b95021 */ addu $t2,$a1,$t9 +/* f0ef040: 914e048e */ lbu $t6,0x48e($t2) +/* f0ef044: 8c980000 */ lw $t8,0x0($a0) +/* f0ef048: 01d10019 */ multu $t6,$s1 +/* f0ef04c: 8f190008 */ lw $t9,0x8($t8) +/* f0ef050: 25380001 */ addiu $t8,$t1,0x1 +/* f0ef054: 00007812 */ mflo $t7 +/* f0ef058: 01f91021 */ addu $v0,$t7,$t9 +/* f0ef05c: 54500004 */ bnel $v0,$s0,.NB0f0ef070 +/* f0ef060: 854e048c */ lh $t6,0x48c($t2) +/* f0ef064: 10000036 */ beqz $zero,.NB0f0ef140 +/* f0ef068: 00601025 */ or $v0,$v1,$zero +/* f0ef06c: 854e048c */ lh $t6,0x48c($t2) +.NB0f0ef070: +/* f0ef070: acd80000 */ sw $t8,0x0($a2) +/* f0ef074: 8ce20000 */ lw $v0,0x0($a3) +/* f0ef078: 8d8f0000 */ lw $t7,0x0($t4) +/* f0ef07c: 01c31821 */ addu $v1,$t6,$v1 +/* f0ef080: 004d0019 */ multu $v0,$t5 +/* f0ef084: 000fc8c0 */ sll $t9,$t7,0x3 +/* f0ef088: 032fc823 */ subu $t9,$t9,$t7 +/* f0ef08c: 0019c8c0 */ sll $t9,$t9,0x3 +/* f0ef090: 032fc823 */ subu $t9,$t9,$t7 +/* f0ef094: 0019c900 */ sll $t9,$t9,0x4 +/* f0ef098: 032fc823 */ subu $t9,$t9,$t7 +/* f0ef09c: 0019c880 */ sll $t9,$t9,0x2 +/* f0ef0a0: 01792821 */ addu $a1,$t3,$t9 +/* f0ef0a4: 03004825 */ or $t1,$t8,$zero +/* f0ef0a8: 00007012 */ mflo $t6 +/* f0ef0ac: 00ae4021 */ addu $t0,$a1,$t6 +/* f0ef0b0: 911805d8 */ lbu $t8,0x5d8($t0) +/* f0ef0b4: 950f05d6 */ lhu $t7,0x5d6($t0) +/* f0ef0b8: 030fc821 */ addu $t9,$t8,$t7 +/* f0ef0bc: 0139082a */ slt $at,$t1,$t9 +/* f0ef0c0: 5420ffde */ bnezl $at,.NB0f0ef03c +/* f0ef0c4: 0009c880 */ sll $t9,$t1,0x2 +.NB0f0ef0c8: +/* f0ef0c8: 244e0001 */ addiu $t6,$v0,0x1 +/* f0ef0cc: acee0000 */ sw $t6,0x0($a3) +/* f0ef0d0: 90980005 */ lbu $t8,0x5($a0) +/* f0ef0d4: 90830004 */ lbu $v1,0x4($a0) +/* f0ef0d8: 01c01025 */ or $v0,$t6,$zero +/* f0ef0dc: 00787821 */ addu $t7,$v1,$t8 +/* f0ef0e0: 01cf082a */ slt $at,$t6,$t7 +/* f0ef0e4: 1420ffb3 */ bnez $at,.NB0f0eefb4 +/* f0ef0e8: 00000000 */ sll $zero,$zero,0x0 +.NB0f0ef0ec: +/* f0ef0ec: 3c0c8007 */ lui $t4,0x8007 +/* f0ef0f0: 258c3af0 */ addiu $t4,$t4,0x3af0 +/* f0ef0f4: 240d000a */ addiu $t5,$zero,0xa +/* f0ef0f8: ace30000 */ sw $v1,0x0($a3) +/* f0ef0fc: 006d0019 */ multu $v1,$t5 +/* f0ef100: 8d990000 */ lw $t9,0x0($t4) +/* f0ef104: 3c0b800a */ lui $t3,0x800a +/* f0ef108: 256b27c0 */ addiu $t3,$t3,0x27c0 +/* f0ef10c: 001970c0 */ sll $t6,$t9,0x3 +/* f0ef110: 01d97023 */ subu $t6,$t6,$t9 +/* f0ef114: 000e70c0 */ sll $t6,$t6,0x3 +/* f0ef118: 01d97023 */ subu $t6,$t6,$t9 +/* f0ef11c: 000e7100 */ sll $t6,$t6,0x4 +/* f0ef120: 01d97023 */ subu $t6,$t6,$t9 +/* f0ef124: 000e7080 */ sll $t6,$t6,0x2 +/* f0ef128: 016ec021 */ addu $t8,$t3,$t6 +/* f0ef12c: 0000c812 */ mflo $t9 +/* f0ef130: 03197021 */ addu $t6,$t8,$t9 +/* f0ef134: 95cf05d6 */ lhu $t7,0x5d6($t6) +/* f0ef138: 00001025 */ or $v0,$zero,$zero +/* f0ef13c: accf0000 */ sw $t7,0x0($a2) +.NB0f0ef140: +/* f0ef140: 8fb00008 */ lw $s0,0x8($sp) +/* f0ef144: 8fb1000c */ lw $s1,0xc($sp) +/* f0ef148: 03e00008 */ jr $ra +/* f0ef14c: 27bd0010 */ addiu $sp,$sp,0x10 +); +#endif /** * If this returns true, the scrollable is rendered with less padding and @@ -3994,6 +4555,7 @@ bool func0f0f2674(struct menuitem *item, struct menuframe *frame, u32 arg2) return true; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f26fc /* f0f26fc: 3c0e8007 */ lui $t6,%hi(g_MpPlayerNum) @@ -4100,6 +4662,114 @@ glabel func0f0f26fc /* f0f2884: 03e00008 */ jr $ra /* f0f2888: 27bd0060 */ addiu $sp,$sp,0x60 ); +#else +GLOBAL_ASM( +glabel func0f0f26fc +/* f0ef318: 3c0e8007 */ lui $t6,0x8007 +/* f0ef31c: 8dce3af0 */ lw $t6,0x3af0($t6) +/* f0ef320: 27bdffa0 */ addiu $sp,$sp,-96 +/* f0ef324: 3c18800a */ lui $t8,0x800a +/* f0ef328: 000e78c0 */ sll $t7,$t6,0x3 +/* f0ef32c: 01ee7823 */ subu $t7,$t7,$t6 +/* f0ef330: 000f78c0 */ sll $t7,$t7,0x3 +/* f0ef334: 01ee7823 */ subu $t7,$t7,$t6 +/* f0ef338: 000f7900 */ sll $t7,$t7,0x4 +/* f0ef33c: 00054080 */ sll $t0,$a1,0x2 +/* f0ef340: 01ee7823 */ subu $t7,$t7,$t6 +/* f0ef344: 000f7880 */ sll $t7,$t7,0x2 +/* f0ef348: 01054021 */ addu $t0,$t0,$a1 +/* f0ef34c: 271827c0 */ addiu $t8,$t8,0x27c0 +/* f0ef350: 01f81821 */ addu $v1,$t7,$t8 +/* f0ef354: 00084040 */ sll $t0,$t0,0x1 +/* f0ef358: 00681021 */ addu $v0,$v1,$t0 +/* f0ef35c: 905905d8 */ lbu $t9,0x5d8($v0) +/* f0ef360: afbe0038 */ sw $s8,0x38($sp) +/* f0ef364: afb5002c */ sw $s5,0x2c($sp) +/* f0ef368: afb40028 */ sw $s4,0x28($sp) +/* f0ef36c: afb30024 */ sw $s3,0x24($sp) +/* f0ef370: afb20020 */ sw $s2,0x20($sp) +/* f0ef374: afbf003c */ sw $ra,0x3c($sp) +/* f0ef378: afb70034 */ sw $s7,0x34($sp) +/* f0ef37c: afb60030 */ sw $s6,0x30($sp) +/* f0ef380: afb1001c */ sw $s1,0x1c($sp) +/* f0ef384: afb00018 */ sw $s0,0x18($sp) +/* f0ef388: afa40060 */ sw $a0,0x60($sp) +/* f0ef38c: afa60068 */ sw $a2,0x68($sp) +/* f0ef390: afa7006c */ sw $a3,0x6c($sp) +/* f0ef394: 0000f025 */ or $s8,$zero,$zero +/* f0ef398: 0000a825 */ or $s5,$zero,$zero +/* f0ef39c: 945205d6 */ lhu $s2,0x5d6($v0) +/* f0ef3a0: 00009825 */ or $s3,$zero,$zero +/* f0ef3a4: 1b200033 */ blez $t9,.NB0f0ef474 +/* f0ef3a8: 0000a025 */ or $s4,$zero,$zero +/* f0ef3ac: 00128880 */ sll $s1,$s2,0x2 +/* f0ef3b0: 00711021 */ addu $v0,$v1,$s1 +/* f0ef3b4: 24170014 */ addiu $s7,$zero,0x14 +/* f0ef3b8: 8fb60070 */ lw $s6,0x70($sp) +/* f0ef3bc: 9049048e */ lbu $t1,0x48e($v0) +.NB0f0ef3c0: +/* f0ef3c0: 8fab0068 */ lw $t3,0x68($sp) +/* f0ef3c4: 02c02825 */ or $a1,$s6,$zero +/* f0ef3c8: 01370019 */ multu $t1,$s7 +/* f0ef3cc: 8d6c0008 */ lw $t4,0x8($t3) +/* f0ef3d0: afa80040 */ sw $t0,0x40($sp) +/* f0ef3d4: 24060001 */ addiu $a2,$zero,0x1 +/* f0ef3d8: 00005012 */ mflo $t2 +/* f0ef3dc: 014c8021 */ addu $s0,$t2,$t4 +/* f0ef3e0: 0fc3bca4 */ jal func0f0f2674 +/* f0ef3e4: 02002025 */ or $a0,$s0,$zero +/* f0ef3e8: 10400009 */ beqz $v0,.NB0f0ef410 +/* f0ef3ec: 8fa80040 */ lw $t0,0x40($sp) +/* f0ef3f0: 8fad0060 */ lw $t5,0x60($sp) +/* f0ef3f4: 0200f025 */ or $s8,$s0,$zero +/* f0ef3f8: 8fae006c */ lw $t6,0x6c($sp) +/* f0ef3fc: 028d082a */ slt $at,$s4,$t5 +/* f0ef400: 54200003 */ bnezl $at,.NB0f0ef410 +/* f0ef404: add20000 */ sw $s2,0x0($t6) +/* f0ef408: 24150001 */ addiu $s5,$zero,0x1 +/* f0ef40c: add20000 */ sw $s2,0x0($t6) +.NB0f0ef410: +/* f0ef410: 3c0f8007 */ lui $t7,0x8007 +/* f0ef414: 8def3af0 */ lw $t7,0x3af0($t7) +/* f0ef418: 3c19800a */ lui $t9,0x800a +/* f0ef41c: 273927c0 */ addiu $t9,$t9,0x27c0 +/* f0ef420: 000fc0c0 */ sll $t8,$t7,0x3 +/* f0ef424: 030fc023 */ subu $t8,$t8,$t7 +/* f0ef428: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0ef42c: 030fc023 */ subu $t8,$t8,$t7 +/* f0ef430: 0018c100 */ sll $t8,$t8,0x4 +/* f0ef434: 030fc023 */ subu $t8,$t8,$t7 +/* f0ef438: 0018c080 */ sll $t8,$t8,0x2 +/* f0ef43c: 03191821 */ addu $v1,$t8,$t9 +/* f0ef440: 00711021 */ addu $v0,$v1,$s1 +/* f0ef444: 8449048c */ lh $t1,0x48c($v0) +/* f0ef448: 24420004 */ addiu $v0,$v0,0x4 +/* f0ef44c: 26310004 */ addiu $s1,$s1,0x4 +/* f0ef450: 26520001 */ addiu $s2,$s2,0x1 +/* f0ef454: 26730001 */ addiu $s3,$s3,0x1 +/* f0ef458: 16a00006 */ bnez $s5,.NB0f0ef474 +/* f0ef45c: 0134a021 */ addu $s4,$t1,$s4 +/* f0ef460: 00685821 */ addu $t3,$v1,$t0 +/* f0ef464: 916a05d8 */ lbu $t2,0x5d8($t3) +/* f0ef468: 026a082a */ slt $at,$s3,$t2 +/* f0ef46c: 5420ffd4 */ bnezl $at,.NB0f0ef3c0 +/* f0ef470: 9049048e */ lbu $t1,0x48e($v0) +.NB0f0ef474: +/* f0ef474: 8fbf003c */ lw $ra,0x3c($sp) +/* f0ef478: 03c01025 */ or $v0,$s8,$zero +/* f0ef47c: 8fbe0038 */ lw $s8,0x38($sp) +/* f0ef480: 8fb00018 */ lw $s0,0x18($sp) +/* f0ef484: 8fb1001c */ lw $s1,0x1c($sp) +/* f0ef488: 8fb20020 */ lw $s2,0x20($sp) +/* f0ef48c: 8fb30024 */ lw $s3,0x24($sp) +/* f0ef490: 8fb40028 */ lw $s4,0x28($sp) +/* f0ef494: 8fb5002c */ lw $s5,0x2c($sp) +/* f0ef498: 8fb60030 */ lw $s6,0x30($sp) +/* f0ef49c: 8fb70034 */ lw $s7,0x34($sp) +/* f0ef4a0: 03e00008 */ jr $ra +/* f0ef4a4: 27bd0060 */ addiu $sp,$sp,0x60 +); +#endif GLOBAL_ASM( glabel func0f0f288c @@ -4197,6 +4867,7 @@ glabel func0f0f2928 /* f0f29c8: 27bd0048 */ addiu $sp,$sp,0x48 ); +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f29cc /* f0f29cc: 27bdffa0 */ addiu $sp,$sp,-96 @@ -4293,6 +4964,104 @@ glabel func0f0f29cc /* f0f2b24: 03e00008 */ jr $ra /* f0f2b28: 27bd0060 */ addiu $sp,$sp,0x60 ); +#else +GLOBAL_ASM( +glabel func0f0f29cc +/* f0ef5e8: 27bdffa0 */ addiu $sp,$sp,-96 +/* f0ef5ec: afb30024 */ sw $s3,0x24($sp) +/* f0ef5f0: afb20020 */ sw $s2,0x20($sp) +/* f0ef5f4: 00a09025 */ or $s2,$a1,$zero +/* f0ef5f8: 00809825 */ or $s3,$a0,$zero +/* f0ef5fc: afbf003c */ sw $ra,0x3c($sp) +/* f0ef600: afbe0038 */ sw $s8,0x38($sp) +/* f0ef604: afb70034 */ sw $s7,0x34($sp) +/* f0ef608: afb60030 */ sw $s6,0x30($sp) +/* f0ef60c: afb5002c */ sw $s5,0x2c($sp) +/* f0ef610: afb40028 */ sw $s4,0x28($sp) +/* f0ef614: afb1001c */ sw $s1,0x1c($sp) +/* f0ef618: afb00018 */ sw $s0,0x18($sp) +/* f0ef61c: 00008025 */ or $s0,$zero,$zero +/* f0ef620: 8e650008 */ lw $a1,0x8($s3) +/* f0ef624: 27a6005c */ addiu $a2,$sp,0x5c +/* f0ef628: 0fc3bbdc */ jal func0f0f2354 +/* f0ef62c: 27a70058 */ addiu $a3,$sp,0x58 +/* f0ef630: 8fa5005c */ lw $a1,0x5c($sp) +/* f0ef634: 3c168007 */ lui $s6,0x8007 +/* f0ef638: 3c15800a */ lui $s5,0x800a +/* f0ef63c: 26b527c0 */ addiu $s5,$s5,0x27c0 +/* f0ef640: 26d63af0 */ addiu $s6,$s6,0x3af0 +/* f0ef644: 241e0014 */ addiu $s8,$zero,0x14 +/* f0ef648: 2417000a */ addiu $s7,$zero,0xa +/* f0ef64c: 00a0a025 */ or $s4,$a1,$zero +/* f0ef650: 8fb80058 */ lw $t8,0x58($sp) +.NB0f0ef654: +/* f0ef654: 8ece0000 */ lw $t6,0x0($s6) +/* f0ef658: 00b22821 */ addu $a1,$a1,$s2 +/* f0ef65c: 03170019 */ multu $t8,$s7 +/* f0ef660: 000e78c0 */ sll $t7,$t6,0x3 +/* f0ef664: 01ee7823 */ subu $t7,$t7,$t6 +/* f0ef668: 000f78c0 */ sll $t7,$t7,0x3 +/* f0ef66c: 01ee7823 */ subu $t7,$t7,$t6 +/* f0ef670: 000f7900 */ sll $t7,$t7,0x4 +/* f0ef674: 01ee7823 */ subu $t7,$t7,$t6 +/* f0ef678: 000f7880 */ sll $t7,$t7,0x2 +/* f0ef67c: 02af3821 */ addu $a3,$s5,$t7 +/* f0ef680: 0000c812 */ mflo $t9 +/* f0ef684: 00f91021 */ addu $v0,$a3,$t9 +/* f0ef688: 944305d6 */ lhu $v1,0x5d6($v0) +/* f0ef68c: 904805d8 */ lbu $t0,0x5d8($v0) +/* f0ef690: 01032021 */ addu $a0,$t0,$v1 +/* f0ef694: 00a4082a */ slt $at,$a1,$a0 +/* f0ef698: 54200003 */ bnezl $at,.NB0f0ef6a8 +/* f0ef69c: 00a3082a */ slt $at,$a1,$v1 +/* f0ef6a0: 00602825 */ or $a1,$v1,$zero +/* f0ef6a4: 00a3082a */ slt $at,$a1,$v1 +.NB0f0ef6a8: +/* f0ef6a8: 10200003 */ beqz $at,.NB0f0ef6b8 +/* f0ef6ac: afa5005c */ sw $a1,0x5c($sp) +/* f0ef6b0: 2485ffff */ addiu $a1,$a0,-1 +/* f0ef6b4: afa5005c */ sw $a1,0x5c($sp) +.NB0f0ef6b8: +/* f0ef6b8: 8fa9005c */ lw $t1,0x5c($sp) +/* f0ef6bc: 8e6e0000 */ lw $t6,0x0($s3) +/* f0ef6c0: 02602825 */ or $a1,$s3,$zero +/* f0ef6c4: 00095080 */ sll $t2,$t1,0x2 +/* f0ef6c8: 00ea5821 */ addu $t3,$a3,$t2 +/* f0ef6cc: 916c048e */ lbu $t4,0x48e($t3) +/* f0ef6d0: 8dcf0008 */ lw $t7,0x8($t6) +/* f0ef6d4: 02403025 */ or $a2,$s2,$zero +/* f0ef6d8: 019e0019 */ multu $t4,$s8 +/* f0ef6dc: 00006812 */ mflo $t5 +/* f0ef6e0: 01af8821 */ addu $s1,$t5,$t7 +/* f0ef6e4: 0fc3bca4 */ jal func0f0f2674 +/* f0ef6e8: 02202025 */ or $a0,$s1,$zero +/* f0ef6ec: 10400002 */ beqz $v0,.NB0f0ef6f8 +/* f0ef6f0: 8fa5005c */ lw $a1,0x5c($sp) +/* f0ef6f4: 24100001 */ addiu $s0,$zero,0x1 +.NB0f0ef6f8: +/* f0ef6f8: 14b40002 */ bne $a1,$s4,.NB0f0ef704 +/* f0ef6fc: 00000000 */ sll $zero,$zero,0x0 +/* f0ef700: 24100001 */ addiu $s0,$zero,0x1 +.NB0f0ef704: +/* f0ef704: 5200ffd3 */ beqzl $s0,.NB0f0ef654 +/* f0ef708: 8fb80058 */ lw $t8,0x58($sp) +/* f0ef70c: afa5005c */ sw $a1,0x5c($sp) +/* f0ef710: afb1004c */ sw $s1,0x4c($sp) +/* f0ef714: ae710008 */ sw $s1,0x8($s3) +/* f0ef718: 8fbf003c */ lw $ra,0x3c($sp) +/* f0ef71c: 8fbe0038 */ lw $s8,0x38($sp) +/* f0ef720: 8fb70034 */ lw $s7,0x34($sp) +/* f0ef724: 8fb60030 */ lw $s6,0x30($sp) +/* f0ef728: 8fb5002c */ lw $s5,0x2c($sp) +/* f0ef72c: 8fb40028 */ lw $s4,0x28($sp) +/* f0ef730: 8fb30024 */ lw $s3,0x24($sp) +/* f0ef734: 8fb20020 */ lw $s2,0x20($sp) +/* f0ef738: 8fb1001c */ lw $s1,0x1c($sp) +/* f0ef73c: 8fb00018 */ lw $s0,0x18($sp) +/* f0ef740: 03e00008 */ jr $ra +/* f0ef744: 27bd0060 */ addiu $sp,$sp,0x60 +); +#endif GLOBAL_ASM( glabel func0f0f2b2c @@ -4501,6 +5270,7 @@ void menuOpenDialog(struct menudialog *dialog, struct menuframe *frame, struct m frame->height = frame->unk38; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuPushDialog /* f0f2f4c: 27bdffc0 */ addiu $sp,$sp,-64 @@ -4694,6 +5464,201 @@ glabel menuPushDialog /* f0f3218: 03e00008 */ jr $ra /* f0f321c: 27bd0040 */ addiu $sp,$sp,0x40 ); +#else +GLOBAL_ASM( +glabel menuPushDialog +/* f0efb68: 27bdffc0 */ addiu $sp,$sp,-64 +/* f0efb6c: afbf003c */ sw $ra,0x3c($sp) +/* f0efb70: afbe0038 */ sw $s8,0x38($sp) +/* f0efb74: afb70034 */ sw $s7,0x34($sp) +/* f0efb78: afb60030 */ sw $s6,0x30($sp) +/* f0efb7c: afb5002c */ sw $s5,0x2c($sp) +/* f0efb80: afb40028 */ sw $s4,0x28($sp) +/* f0efb84: afb30024 */ sw $s3,0x24($sp) +/* f0efb88: afb20020 */ sw $s2,0x20($sp) +/* f0efb8c: afb1001c */ sw $s1,0x1c($sp) +/* f0efb90: afb00018 */ sw $s0,0x18($sp) +/* f0efb94: 1080009d */ beqz $a0,.NB0f0efe0c +/* f0efb98: afa40040 */ sw $a0,0x40($sp) +/* f0efb9c: 3c158007 */ lui $s5,0x8007 +/* f0efba0: 26b53af0 */ addiu $s5,$s5,0x3af0 +/* f0efba4: 8eaf0000 */ lw $t7,0x0($s5) +/* f0efba8: 24160dbc */ addiu $s6,$zero,0xdbc +/* f0efbac: 3c14800a */ lui $s4,0x800a +/* f0efbb0: 01f60019 */ multu $t7,$s6 +/* f0efbb4: 269427c0 */ addiu $s4,$s4,0x27c0 +/* f0efbb8: 0000c012 */ mflo $t8 +/* f0efbbc: 02982021 */ addu $a0,$s4,$t8 +/* f0efbc0: 0fc3c0ba */ jal func0f0f37a4 +/* f0efbc4: 2484079c */ addiu $a0,$a0,0x79c +/* f0efbc8: 8eb90000 */ lw $t9,0x0($s5) +/* f0efbcc: 03360019 */ multu $t9,$s6 +/* f0efbd0: 00004012 */ mflo $t0 +/* f0efbd4: 02881821 */ addu $v1,$s4,$t0 +/* f0efbd8: 84670484 */ lh $a3,0x484($v1) +/* f0efbdc: 28e10006 */ slti $at,$a3,0x6 +/* f0efbe0: 5020008b */ beqzl $at,.NB0f0efe10 +/* f0efbe4: 8fbf003c */ lw $ra,0x3c($sp) +/* f0efbe8: 846903f0 */ lh $t1,0x3f0($v1) +/* f0efbec: 00075080 */ sll $t2,$a3,0x2 +/* f0efbf0: 01475023 */ subu $t2,$t2,$a3 +/* f0efbf4: 29210009 */ slti $at,$t1,0x9 +/* f0efbf8: 10200084 */ beqz $at,.NB0f0efe0c +/* f0efbfc: 000a50c0 */ sll $t2,$t2,0x3 +/* f0efc00: 24eb0001 */ addiu $t3,$a3,0x1 +/* f0efc04: 006a8821 */ addu $s1,$v1,$t2 +/* f0efc08: a46b0484 */ sh $t3,0x484($v1) +/* f0efc0c: 240c0001 */ addiu $t4,$zero,0x1 +/* f0efc10: a22c0408 */ sb $t4,0x408($s1) +/* f0efc14: a2200409 */ sb $zero,0x409($s1) +/* f0efc18: 8ead0000 */ lw $t5,0x0($s5) +/* f0efc1c: 241e0070 */ addiu $s8,$zero,0x70 +/* f0efc20: 263103f4 */ addiu $s1,$s1,0x3f4 +/* f0efc24: 01b60019 */ multu $t5,$s6 +/* f0efc28: 00007012 */ mflo $t6 +/* f0efc2c: 028e1821 */ addu $v1,$s4,$t6 +/* f0efc30: 846203f0 */ lh $v0,0x3f0($v1) +/* f0efc34: 005e0019 */ multu $v0,$s8 +/* f0efc38: 24580001 */ addiu $t8,$v0,0x1 +/* f0efc3c: a47803f0 */ sh $t8,0x3f0($v1) +/* f0efc40: 00007812 */ mflo $t7 +/* f0efc44: 006f8021 */ addu $s0,$v1,$t7 +/* f0efc48: ae300000 */ sw $s0,0x0($s1) +/* f0efc4c: 8eb90000 */ lw $t9,0x0($s5) +/* f0efc50: 02002825 */ or $a1,$s0,$zero +/* f0efc54: 03360019 */ multu $t9,$s6 +/* f0efc58: 00004012 */ mflo $t0 +/* f0efc5c: 02884821 */ addu $t1,$s4,$t0 +/* f0efc60: ad300488 */ sw $s0,0x488($t1) +/* f0efc64: a200006d */ sb $zero,0x6d($s0) +/* f0efc68: 8eaa0000 */ lw $t2,0x0($s5) +/* f0efc6c: 8fa40040 */ lw $a0,0x40($sp) +/* f0efc70: 01560019 */ multu $t2,$s6 +/* f0efc74: 00005812 */ mflo $t3 +/* f0efc78: 028b3021 */ addu $a2,$s4,$t3 +/* f0efc7c: 0fc3be44 */ jal menuOpenDialog +/* f0efc80: 00000000 */ sll $zero,$zero,0x0 +/* f0efc84: 0c002f77 */ jal viGetWidth +/* f0efc88: 00000000 */ sll $zero,$zero,0x0 +/* f0efc8c: 8e0c001c */ lw $t4,0x1c($s0) +/* f0efc90: 004c6823 */ subu $t5,$v0,$t4 +/* f0efc94: 05a10003 */ bgez $t5,.NB0f0efca4 +/* f0efc98: 000d7043 */ sra $t6,$t5,0x1 +/* f0efc9c: 25a10001 */ addiu $at,$t5,0x1 +/* f0efca0: 00017043 */ sra $t6,$at,0x1 +.NB0f0efca4: +/* f0efca4: 0c002f7b */ jal viGetHeight +/* f0efca8: ae0e002c */ sw $t6,0x2c($s0) +/* f0efcac: 8e0f0020 */ lw $t7,0x20($s0) +/* f0efcb0: 004fc023 */ subu $t8,$v0,$t7 +/* f0efcb4: 07010003 */ bgez $t8,.NB0f0efcc4 +/* f0efcb8: 0018c843 */ sra $t9,$t8,0x1 +/* f0efcbc: 27010001 */ addiu $at,$t8,0x1 +/* f0efcc0: 0001c843 */ sra $t9,$at,0x1 +.NB0f0efcc4: +/* f0efcc4: ae190030 */ sw $t9,0x30($s0) +/* f0efcc8: 8ea80000 */ lw $t0,0x0($s5) +/* f0efccc: 8fad0040 */ lw $t5,0x40($sp) +/* f0efcd0: 01160019 */ multu $t0,$s6 +/* f0efcd4: 00004812 */ mflo $t1 +/* f0efcd8: 02891821 */ addu $v1,$s4,$t1 +/* f0efcdc: 906b0d9c */ lbu $t3,0xd9c($v1) +/* f0efce0: 356c0080 */ ori $t4,$t3,0x80 +/* f0efce4: a06c0d9c */ sb $t4,0xd9c($v1) +/* f0efce8: 8db20014 */ lw $s2,0x14($t5) +/* f0efcec: 12400037 */ beqz $s2,.NB0f0efdcc +/* f0efcf0: 00000000 */ sll $zero,$zero,0x0 +/* f0efcf4: 822e0014 */ lb $t6,0x14($s1) +/* f0efcf8: 2417ffff */ addiu $s7,$zero,-1 +/* f0efcfc: 2413fec0 */ addiu $s3,$zero,-320 +/* f0efd00: 29c10005 */ slti $at,$t6,0x5 +/* f0efd04: 10200031 */ beqz $at,.NB0f0efdcc +/* f0efd08: 00000000 */ sll $zero,$zero,0x0 +/* f0efd0c: 8eaf0000 */ lw $t7,0x0($s5) +.NB0f0efd10: +/* f0efd10: 01f60019 */ multu $t7,$s6 +/* f0efd14: 0000c012 */ mflo $t8 +/* f0efd18: 02981821 */ addu $v1,$s4,$t8 +/* f0efd1c: 846203f0 */ lh $v0,0x3f0($v1) +/* f0efd20: 28410009 */ slti $at,$v0,0x9 +/* f0efd24: 10200023 */ beqz $at,.NB0f0efdb4 +/* f0efd28: 00000000 */ sll $zero,$zero,0x0 +/* f0efd2c: 005e0019 */ multu $v0,$s8 +/* f0efd30: 24480001 */ addiu $t0,$v0,0x1 +/* f0efd34: a46803f0 */ sh $t0,0x3f0($v1) +/* f0efd38: 82290014 */ lb $t1,0x14($s1) +/* f0efd3c: 02402025 */ or $a0,$s2,$zero +/* f0efd40: 00095080 */ sll $t2,$t1,0x2 +/* f0efd44: 022a5821 */ addu $t3,$s1,$t2 +/* f0efd48: 0000c812 */ mflo $t9 +/* f0efd4c: 00798021 */ addu $s0,$v1,$t9 +/* f0efd50: ad700000 */ sw $s0,0x0($t3) +/* f0efd54: 822c0014 */ lb $t4,0x14($s1) +/* f0efd58: 02002825 */ or $a1,$s0,$zero +/* f0efd5c: 258d0001 */ addiu $t5,$t4,0x1 +/* f0efd60: a22d0014 */ sb $t5,0x14($s1) +/* f0efd64: a217006d */ sb $s7,0x6d($s0) +/* f0efd68: 8eae0000 */ lw $t6,0x0($s5) +/* f0efd6c: 01d60019 */ multu $t6,$s6 +/* f0efd70: 00007812 */ mflo $t7 +/* f0efd74: 028f3021 */ addu $a2,$s4,$t7 +/* f0efd78: 0fc3be44 */ jal menuOpenDialog +/* f0efd7c: 00000000 */ sll $zero,$zero,0x0 +/* f0efd80: ae130014 */ sw $s3,0x14($s0) +/* f0efd84: 0c002f7b */ jal viGetHeight +/* f0efd88: ae13002c */ sw $s3,0x2c($s0) +/* f0efd8c: 8e180020 */ lw $t8,0x20($s0) +/* f0efd90: a200003c */ sb $zero,0x3c($s0) +/* f0efd94: 00581823 */ subu $v1,$v0,$t8 +/* f0efd98: 04610003 */ bgez $v1,.NB0f0efda8 +/* f0efd9c: 0003c843 */ sra $t9,$v1,0x1 +/* f0efda0: 24610001 */ addiu $at,$v1,0x1 +/* f0efda4: 0001c843 */ sra $t9,$at,0x1 +.NB0f0efda8: +/* f0efda8: ae190018 */ sw $t9,0x18($s0) +/* f0efdac: ae190030 */ sw $t9,0x30($s0) +/* f0efdb0: 8e520014 */ lw $s2,0x14($s2) +.NB0f0efdb4: +/* f0efdb4: 12400005 */ beqz $s2,.NB0f0efdcc +/* f0efdb8: 00000000 */ sll $zero,$zero,0x0 +/* f0efdbc: 82280014 */ lb $t0,0x14($s1) +/* f0efdc0: 29010005 */ slti $at,$t0,0x5 +/* f0efdc4: 5420ffd2 */ bnezl $at,.NB0f0efd10 +/* f0efdc8: 8eaf0000 */ lw $t7,0x0($s5) +.NB0f0efdcc: +/* f0efdcc: 0fc3b5c8 */ jal menuPlaySound +/* f0efdd0: 24040001 */ addiu $a0,$zero,0x1 +/* f0efdd4: 8fa90040 */ lw $t1,0x40($sp) +/* f0efdd8: 24010002 */ addiu $at,$zero,0x2 +/* f0efddc: 91220000 */ lbu $v0,0x0($t1) +/* f0efde0: 54410006 */ bnel $v0,$at,.NB0f0efdfc +/* f0efde4: 24010003 */ addiu $at,$zero,0x3 +/* f0efde8: 0fc3b5c8 */ jal menuPlaySound +/* f0efdec: 24040004 */ addiu $a0,$zero,0x4 +/* f0efdf0: 8faa0040 */ lw $t2,0x40($sp) +/* f0efdf4: 91420000 */ lbu $v0,0x0($t2) +/* f0efdf8: 24010003 */ addiu $at,$zero,0x3 +.NB0f0efdfc: +/* f0efdfc: 54410004 */ bnel $v0,$at,.NB0f0efe10 +/* f0efe00: 8fbf003c */ lw $ra,0x3c($sp) +/* f0efe04: 0fc3b5c8 */ jal menuPlaySound +/* f0efe08: 2404000e */ addiu $a0,$zero,0xe +.NB0f0efe0c: +/* f0efe0c: 8fbf003c */ lw $ra,0x3c($sp) +.NB0f0efe10: +/* f0efe10: 8fb00018 */ lw $s0,0x18($sp) +/* f0efe14: 8fb1001c */ lw $s1,0x1c($sp) +/* f0efe18: 8fb20020 */ lw $s2,0x20($sp) +/* f0efe1c: 8fb30024 */ lw $s3,0x24($sp) +/* f0efe20: 8fb40028 */ lw $s4,0x28($sp) +/* f0efe24: 8fb5002c */ lw $s5,0x2c($sp) +/* f0efe28: 8fb60030 */ lw $s6,0x30($sp) +/* f0efe2c: 8fb70034 */ lw $s7,0x34($sp) +/* f0efe30: 8fbe0038 */ lw $s8,0x38($sp) +/* f0efe34: 03e00008 */ jr $ra +/* f0efe38: 27bd0040 */ addiu $sp,$sp,0x40 +); +#endif // regalloc: s1 (layer) and s2 (sibling) are swapped //void menuPushDialog(struct menudialog *dialog) @@ -14891,6 +15856,7 @@ glabel var7f1b296c u32 var800714d8 = 0x00000001; +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f7594 /* f0f7594: 3c0e800a */ lui $t6,%hi(g_MenuData+0x4) @@ -15013,6 +15979,130 @@ glabel func0f0f7594 /* f0f7720: 03e00008 */ jr $ra /* f0f7724: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f0f7594 +/* f0f3f0c: 3c0e800a */ lui $t6,0x800a +/* f0f3f10: 8dce5eb4 */ lw $t6,0x5eb4($t6) +/* f0f3f14: 24010003 */ addiu $at,$zero,0x3 +/* f0f3f18: 3c0f8007 */ lui $t7,0x8007 +/* f0f3f1c: 55c1005d */ bnel $t6,$at,.NB0f0f4094 +/* f0f3f20: aca00000 */ sw $zero,0x0($a1) +/* f0f3f24: 8def3af0 */ lw $t7,0x3af0($t7) +/* f0f3f28: 3c02800a */ lui $v0,0x800a +/* f0f3f2c: 3c038007 */ lui $v1,0x8007 +/* f0f3f30: 000fc0c0 */ sll $t8,$t7,0x3 +/* f0f3f34: 030fc023 */ subu $t8,$t8,$t7 +/* f0f3f38: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0f3f3c: 030fc023 */ subu $t8,$t8,$t7 +/* f0f3f40: 0018c100 */ sll $t8,$t8,0x4 +/* f0f3f44: 030fc023 */ subu $t8,$t8,$t7 +/* f0f3f48: 0018c080 */ sll $t8,$t8,0x2 +/* f0f3f4c: 00581021 */ addu $v0,$v0,$t8 +/* f0f3f50: 90422f57 */ lbu $v0,0x2f57($v0) +/* f0f3f54: aca00000 */ sw $zero,0x0($a1) +/* f0f3f58: acc00000 */ sw $zero,0x0($a2) +/* f0f3f5c: 8c633b8c */ lw $v1,0x3b8c($v1) +/* f0f3f60: 24010001 */ addiu $at,$zero,0x1 +/* f0f3f64: 10610009 */ beq $v1,$at,.NB0f0f3f8c +/* f0f3f68: 24010002 */ addiu $at,$zero,0x2 +/* f0f3f6c: 10610009 */ beq $v1,$at,.NB0f0f3f94 +/* f0f3f70: 24010003 */ addiu $at,$zero,0x3 +/* f0f3f74: 10610017 */ beq $v1,$at,.NB0f0f3fd4 +/* f0f3f78: 24010004 */ addiu $at,$zero,0x4 +/* f0f3f7c: 1061002a */ beq $v1,$at,.NB0f0f4028 +/* f0f3f80: 00000000 */ sll $zero,$zero,0x0 +/* f0f3f84: 03e00008 */ jr $ra +/* f0f3f88: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f3f8c: +/* f0f3f8c: 03e00008 */ jr $ra +/* f0f3f90: acc40000 */ sw $a0,0x0($a2) +.NB0f0f3f94: +/* f0f3f94: 14400008 */ bnez $v0,.NB0f0f3fb8 +/* f0f3f98: 00000000 */ sll $zero,$zero,0x0 +/* f0f3f9c: 04810004 */ bgez $a0,.NB0f0f3fb0 +/* f0f3fa0: 2408ffff */ addiu $t0,$zero,-1 +/* f0f3fa4: 2419ffff */ addiu $t9,$zero,-1 +/* f0f3fa8: 03e00008 */ jr $ra +/* f0f3fac: acd90000 */ sw $t9,0x0($a2) +.NB0f0f3fb0: +/* f0f3fb0: 03e00008 */ jr $ra +/* f0f3fb4: aca80000 */ sw $t0,0x0($a1) +.NB0f0f3fb8: +/* f0f3fb8: 18800004 */ blez $a0,.NB0f0f3fcc +/* f0f3fbc: 24030001 */ addiu $v1,$zero,0x1 +/* f0f3fc0: 24030001 */ addiu $v1,$zero,0x1 +/* f0f3fc4: 03e00008 */ jr $ra +/* f0f3fc8: acc30000 */ sw $v1,0x0($a2) +.NB0f0f3fcc: +/* f0f3fcc: 03e00008 */ jr $ra +/* f0f3fd0: aca30000 */ sw $v1,0x0($a1) +.NB0f0f3fd4: +/* f0f3fd4: 24010002 */ addiu $at,$zero,0x2 +/* f0f3fd8: 14410003 */ bne $v0,$at,.NB0f0f3fe8 +/* f0f3fdc: 00000000 */ sll $zero,$zero,0x0 +/* f0f3fe0: 03e00008 */ jr $ra +/* f0f3fe4: acc40000 */ sw $a0,0x0($a2) +.NB0f0f3fe8: +/* f0f3fe8: 14400008 */ bnez $v0,.NB0f0f400c +/* f0f3fec: 00000000 */ sll $zero,$zero,0x0 +/* f0f3ff0: 04810004 */ bgez $a0,.NB0f0f4004 +/* f0f3ff4: 240affff */ addiu $t2,$zero,-1 +/* f0f3ff8: 2409ffff */ addiu $t1,$zero,-1 +/* f0f3ffc: 03e00008 */ jr $ra +/* f0f4000: acc90000 */ sw $t1,0x0($a2) +.NB0f0f4004: +/* f0f4004: 03e00008 */ jr $ra +/* f0f4008: acaa0000 */ sw $t2,0x0($a1) +.NB0f0f400c: +/* f0f400c: 18800004 */ blez $a0,.NB0f0f4020 +/* f0f4010: 240bffff */ addiu $t3,$zero,-1 +/* f0f4014: 24030001 */ addiu $v1,$zero,0x1 +/* f0f4018: 03e00008 */ jr $ra +/* f0f401c: acc30000 */ sw $v1,0x0($a2) +.NB0f0f4020: +/* f0f4020: 03e00008 */ jr $ra +/* f0f4024: acab0000 */ sw $t3,0x0($a1) +.NB0f0f4028: +/* f0f4028: 10400003 */ beqz $v0,.NB0f0f4038 +/* f0f402c: 24010002 */ addiu $at,$zero,0x2 +/* f0f4030: 1441000c */ bne $v0,$at,.NB0f0f4064 +/* f0f4034: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f4038: +/* f0f4038: 04810003 */ bgez $a0,.NB0f0f4048 +/* f0f403c: 240cffff */ addiu $t4,$zero,-1 +/* f0f4040: 03e00008 */ jr $ra +/* f0f4044: accc0000 */ sw $t4,0x0($a2) +.NB0f0f4048: +/* f0f4048: 14400004 */ bnez $v0,.NB0f0f405c +/* f0f404c: 24030001 */ addiu $v1,$zero,0x1 +/* f0f4050: 240dffff */ addiu $t5,$zero,-1 +/* f0f4054: 03e00008 */ jr $ra +/* f0f4058: acad0000 */ sw $t5,0x0($a1) +.NB0f0f405c: +/* f0f405c: 03e00008 */ jr $ra +/* f0f4060: aca30000 */ sw $v1,0x0($a1) +.NB0f0f4064: +/* f0f4064: 18800004 */ blez $a0,.NB0f0f4078 +/* f0f4068: 24030001 */ addiu $v1,$zero,0x1 +/* f0f406c: 24030001 */ addiu $v1,$zero,0x1 +/* f0f4070: 03e00008 */ jr $ra +/* f0f4074: acc30000 */ sw $v1,0x0($a2) +.NB0f0f4078: +/* f0f4078: 14430003 */ bne $v0,$v1,.NB0f0f4088 +/* f0f407c: 240effff */ addiu $t6,$zero,-1 +/* f0f4080: 03e00008 */ jr $ra +/* f0f4084: acae0000 */ sw $t6,0x0($a1) +.NB0f0f4088: +/* f0f4088: 03e00008 */ jr $ra +/* f0f408c: aca30000 */ sw $v1,0x0($a1) +/* f0f4090: aca00000 */ sw $zero,0x0($a1) +.NB0f0f4094: +/* f0f4094: acc40000 */ sw $a0,0x0($a2) +/* f0f4098: 03e00008 */ jr $ra +/* f0f409c: 00000000 */ sll $zero,$zero,0x0 +); +#endif #if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( @@ -16234,6 +17324,7 @@ glabel func0f0f7e98 /* f0f803c: 00000000 */ nop ); +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f8040 /* f0f8040: 3c0e8007 */ lui $t6,%hi(g_MpPlayerNum) @@ -16297,6 +17388,71 @@ glabel func0f0f8040 /* f0f8118: 03e00008 */ jr $ra /* f0f811c: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f0f8040 +/* f0f49a8: 3c0e8007 */ lui $t6,0x8007 +/* f0f49ac: 8dce3af0 */ lw $t6,0x3af0($t6) +/* f0f49b0: 3c18800a */ lui $t8,0x800a +/* f0f49b4: 271827c0 */ addiu $t8,$t8,0x27c0 +/* f0f49b8: 000e78c0 */ sll $t7,$t6,0x3 +/* f0f49bc: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f49c0: 000f78c0 */ sll $t7,$t7,0x3 +/* f0f49c4: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f49c8: 000f7900 */ sll $t7,$t7,0x4 +/* f0f49cc: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f49d0: 000f7880 */ sll $t7,$t7,0x2 +/* f0f49d4: 01f81021 */ addu $v0,$t7,$t8 +/* f0f49d8: 3c04800a */ lui $a0,0x800a +/* f0f49dc: 24845eb0 */ addiu $a0,$a0,0x5eb0 +/* f0f49e0: 8c830004 */ lw $v1,0x4($a0) +/* f0f49e4: 27bdffe8 */ addiu $sp,$sp,-24 +/* f0f49e8: 24050004 */ addiu $a1,$zero,0x4 +/* f0f49ec: 2419000a */ addiu $t9,$zero,0xa +/* f0f49f0: afbf0014 */ sw $ra,0x14($sp) +/* f0f49f4: a4400484 */ sh $zero,0x484($v0) +/* f0f49f8: a44003f0 */ sh $zero,0x3f0($v0) +/* f0f49fc: ac4005cc */ sw $zero,0x5cc($v0) +/* f0f4a00: ac400634 */ sw $zero,0x634($v0) +/* f0f4a04: ac400778 */ sw $zero,0x778($v0) +/* f0f4a08: ac400488 */ sw $zero,0x488($v0) +/* f0f4a0c: 14a30007 */ bne $a1,$v1,.NB0f0f4a2c +/* f0f4a10: a0590798 */ sb $t9,0x798($v0) +/* f0f4a14: 90490797 */ lbu $t1,0x797($v0) +/* f0f4a18: 3c018007 */ lui $at,0x8007 +/* f0f4a1c: 24080001 */ addiu $t0,$zero,0x1 +/* f0f4a20: 00095080 */ sll $t2,$t1,0x2 +/* f0f4a24: 002a0821 */ addu $at,$at,$t2 +/* f0f4a28: ac282e10 */ sw $t0,0x2e10($at) +.NB0f0f4a2c: +/* f0f4a2c: 8c8b0000 */ lw $t3,0x0($a0) +/* f0f4a30: 3c02800a */ lui $v0,0x800a +/* f0f4a34: 256cffff */ addiu $t4,$t3,-1 +/* f0f4a38: 14a3000a */ bne $a1,$v1,.NB0f0f4a64 +/* f0f4a3c: ac8c0000 */ sw $t4,0x0($a0) +/* f0f4a40: 8c42e944 */ lw $v0,-0x16bc($v0) +/* f0f4a44: 24010002 */ addiu $at,$zero,0x2 +/* f0f4a48: 240e0001 */ addiu $t6,$zero,0x1 +/* f0f4a4c: 904d0250 */ lbu $t5,0x250($v0) +/* f0f4a50: 55a10005 */ bnel $t5,$at,.NB0f0f4a68 +/* f0f4a54: 24010007 */ addiu $at,$zero,0x7 +/* f0f4a58: a04e0250 */ sb $t6,0x250($v0) +/* f0f4a5c: 3c03800a */ lui $v1,0x800a +/* f0f4a60: 8c635eb4 */ lw $v1,0x5eb4($v1) +.NB0f0f4a64: +/* f0f4a64: 24010007 */ addiu $at,$zero,0x7 +.NB0f0f4a68: +/* f0f4a68: 54610004 */ bnel $v1,$at,.NB0f0f4a7c +/* f0f4a6c: 8fbf0014 */ lw $ra,0x14($sp) +/* f0f4a70: 0c003c56 */ jal mainChangeToStage +/* f0f4a74: 2404005a */ addiu $a0,$zero,0x5a +/* f0f4a78: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0f4a7c: +/* f0f4a7c: 27bd0018 */ addiu $sp,$sp,0x18 +/* f0f4a80: 03e00008 */ jr $ra +/* f0f4a84: 00000000 */ sll $zero,$zero,0x0 +); +#endif void func0f0f8120(void) { @@ -16362,6 +17518,7 @@ void func0f0f8300(void) } } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuPushRootDialog .late_rodata @@ -16600,6 +17757,246 @@ glabel var7f1b29f8 /* f0f85d8: 03e00008 */ jr $ra /* f0f85dc: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel menuPushRootDialog +.late_rodata +glabel var7f1b2994 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b2998 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b299c +.word menuPushRootDialog+0x13c # f0f846c +glabel var7f1b29a0 +.word menuPushRootDialog+0x13c # f0f846c +glabel var7f1b29a4 +.word menuPushRootDialog+0x13c # f0f846c +glabel var7f1b29a8 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b29ac +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b29b0 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b29b4 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b29b8 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b29bc +.word menuPushRootDialog+0x13c # f0f846c +glabel var7f1b29c0 +.word menuPushRootDialog+0x13c # f0f846c +glabel var7f1b29c4 +.word menuPushRootDialog+0x134 # f0f8464 +glabel var7f1b29c8 +.word menuPushRootDialog+0x23c # f0f856c +glabel var7f1b29cc +.word menuPushRootDialog+0x260 # f0f8590 +glabel var7f1b29d0 +.word menuPushRootDialog+0x204 # f0f8534 +glabel var7f1b29d4 +.word menuPushRootDialog+0x288 # f0f85b8 +glabel var7f1b29d8 +.word menuPushRootDialog+0x260 # f0f8590 +glabel var7f1b29dc +.word menuPushRootDialog+0x260 # f0f8590 +glabel var7f1b29e0 +.word menuPushRootDialog+0x270 # f0f85a0 +glabel var7f1b29e4 +.word menuPushRootDialog+0x288 # f0f85b8 +glabel var7f1b29e8 +.word menuPushRootDialog+0x260 # f0f8590 +glabel var7f1b29ec +.word menuPushRootDialog+0x214 # f0f8544 +glabel var7f1b29f0 +.word menuPushRootDialog+0x230 # f0f8560 +glabel var7f1b29f4 +.word menuPushRootDialog+0x288 # f0f85b8 +glabel var7f1b29f8 +.word menuPushRootDialog+0x260 # f0f8590 +.text +/* f0f4c98: 3c0e8007 */ lui $t6,0x8007 +/* f0f4c9c: 8dce3af0 */ lw $t6,0x3af0($t6) +/* f0f4ca0: 3c03800a */ lui $v1,0x800a +/* f0f4ca4: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f4ca8: 000e78c0 */ sll $t7,$t6,0x3 +/* f0f4cac: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f4cb0: 000f78c0 */ sll $t7,$t7,0x3 +/* f0f4cb4: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f4cb8: 000f7900 */ sll $t7,$t7,0x4 +/* f0f4cbc: 3c18800a */ lui $t8,0x800a +/* f0f4cc0: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f4cc4: 907905d5 */ lbu $t9,0x5d5($v1) +/* f0f4cc8: 000f7880 */ sll $t7,$t7,0x2 +/* f0f4ccc: 271827c0 */ addiu $t8,$t8,0x27c0 +/* f0f4cd0: 01f81021 */ addu $v0,$t7,$t8 +/* f0f4cd4: 904b0797 */ lbu $t3,0x797($v0) +/* f0f4cd8: 3329ff7f */ andi $t1,$t9,0xff7f +/* f0f4cdc: 27bdffe0 */ addiu $sp,$sp,-32 +/* f0f4ce0: a06905d5 */ sb $t1,0x5d5($v1) +/* f0f4ce4: 312a00ef */ andi $t2,$t1,0xef +/* f0f4ce8: 3c018007 */ lui $at,0x8007 +/* f0f4cec: 000b6080 */ sll $t4,$t3,0x2 +/* f0f4cf0: afbf0014 */ sw $ra,0x14($sp) +/* f0f4cf4: a44003f0 */ sh $zero,0x3f0($v0) +/* f0f4cf8: a4400484 */ sh $zero,0x484($v0) +/* f0f4cfc: a06a05d5 */ sb $t2,0x5d5($v1) +/* f0f4d00: 002c0821 */ addu $at,$at,$t4 +/* f0f4d04: afa40020 */ sw $a0,0x20($sp) +/* f0f4d08: ac202e10 */ sw $zero,0x2e10($at) +/* f0f4d0c: 0fc3b828 */ jal func0f0f1494 +/* f0f4d10: afa50024 */ sw $a1,0x24($sp) +/* f0f4d14: 3c03800a */ lui $v1,0x800a +/* f0f4d18: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f4d1c: 8c6d0000 */ lw $t5,0x0($v1) +/* f0f4d20: 8fa50024 */ lw $a1,0x24($sp) +/* f0f4d24: 24010008 */ addiu $at,$zero,0x8 +/* f0f4d28: 25ae0001 */ addiu $t6,$t5,0x1 +/* f0f4d2c: 14a10011 */ bne $a1,$at,.NB0f0f4d74 +/* f0f4d30: ac6e0000 */ sw $t6,0x0($v1) +/* f0f4d34: 3c0f8007 */ lui $t7,0x8007 +/* f0f4d38: 8def3af0 */ lw $t7,0x3af0($t7) +/* f0f4d3c: 3c19800a */ lui $t9,0x800a +/* f0f4d40: 273927c0 */ addiu $t9,$t9,0x27c0 +/* f0f4d44: 000fc0c0 */ sll $t8,$t7,0x3 +/* f0f4d48: 030fc023 */ subu $t8,$t8,$t7 +/* f0f4d4c: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0f4d50: 030fc023 */ subu $t8,$t8,$t7 +/* f0f4d54: 0018c100 */ sll $t8,$t8,0x4 +/* f0f4d58: 030fc023 */ subu $t8,$t8,$t7 +/* f0f4d5c: 0018c080 */ sll $t8,$t8,0x2 +/* f0f4d60: 03191021 */ addu $v0,$t8,$t9 +/* f0f4d64: 90490d9c */ lbu $t1,0xd9c($v0) +/* f0f4d68: 24050004 */ addiu $a1,$zero,0x4 +/* f0f4d6c: 352a0080 */ ori $t2,$t1,0x80 +/* f0f4d70: a04a0d9c */ sb $t2,0xd9c($v0) +.NB0f0f4d74: +/* f0f4d74: 3c0b8007 */ lui $t3,0x8007 +/* f0f4d78: 8d6b3af0 */ lw $t3,0x3af0($t3) +/* f0f4d7c: 3c0d800a */ lui $t5,0x800a +/* f0f4d80: 24aeffff */ addiu $t6,$a1,-1 +/* f0f4d84: 000b60c0 */ sll $t4,$t3,0x3 +/* f0f4d88: 018b6023 */ subu $t4,$t4,$t3 +/* f0f4d8c: 000c60c0 */ sll $t4,$t4,0x3 +/* f0f4d90: 018b6023 */ subu $t4,$t4,$t3 +/* f0f4d94: 000c6100 */ sll $t4,$t4,0x4 +/* f0f4d98: 018b6023 */ subu $t4,$t4,$t3 +/* f0f4d9c: 000c6080 */ sll $t4,$t4,0x2 +/* f0f4da0: 2dc1000d */ sltiu $at,$t6,0xd +/* f0f4da4: 25ad27c0 */ addiu $t5,$t5,0x27c0 +/* f0f4da8: 018d1021 */ addu $v0,$t4,$t5 +/* f0f4dac: 10200009 */ beqz $at,.NB0f0f4dd4 +/* f0f4db0: 00a03025 */ or $a2,$a1,$zero +/* f0f4db4: 000e7080 */ sll $t6,$t6,0x2 +/* f0f4db8: 3c017f1b */ lui $at,0x7f1b +/* f0f4dbc: 002e0821 */ addu $at,$at,$t6 +/* f0f4dc0: 8c2eccc0 */ lw $t6,-0x3340($at) +/* f0f4dc4: 01c00008 */ jr $t6 +/* f0f4dc8: 00000000 */ sll $zero,$zero,0x0 +/* f0f4dcc: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f4dd0: ac6f0000 */ sw $t7,0x0($v1) +.NB0f0f4dd4: +/* f0f4dd4: 906805d5 */ lbu $t0,0x5d5($v1) +/* f0f4dd8: 24180001 */ addiu $t8,$zero,0x1 +/* f0f4ddc: 2419ffff */ addiu $t9,$zero,-1 +/* f0f4de0: 24010002 */ addiu $at,$zero,0x2 +/* f0f4de4: 3109ffbf */ andi $t1,$t0,0xffbf +/* f0f4de8: a058077c */ sb $t8,0x77c($v0) +/* f0f4dec: ac650004 */ sw $a1,0x4($v1) +/* f0f4df0: ac790008 */ sw $t9,0x8($v1) +/* f0f4df4: 10c10007 */ beq $a2,$at,.NB0f0f4e14 +/* f0f4df8: a06905d5 */ sb $t1,0x5d5($v1) +/* f0f4dfc: 24010003 */ addiu $at,$zero,0x3 +/* f0f4e00: 10c10004 */ beq $a2,$at,.NB0f0f4e14 +/* f0f4e04: 2401000d */ addiu $at,$zero,0xd +/* f0f4e08: 10c10002 */ beq $a2,$at,.NB0f0f4e14 +/* f0f4e0c: 24010006 */ addiu $at,$zero,0x6 +/* f0f4e10: 14c10013 */ bne $a2,$at,.NB0f0f4e60 +.NB0f0f4e14: +/* f0f4e14: 3c0a8009 */ lui $t2,0x8009 +/* f0f4e18: 914a30e0 */ lbu $t2,0x30e0($t2) +/* f0f4e1c: 24010001 */ addiu $at,$zero,0x1 +/* f0f4e20: 51410010 */ beql $t2,$at,.NB0f0f4e64 +/* f0f4e24: 8fa40020 */ lw $a0,0x20($sp) +/* f0f4e28: 906b05d4 */ lbu $t3,0x5d4($v1) +/* f0f4e2c: 51600006 */ beqzl $t3,.NB0f0f4e48 +/* f0f4e30: 8c6f05d4 */ lw $t7,0x5d4($v1) +/* f0f4e34: 8c6c05cc */ lw $t4,0x5cc($v1) +/* f0f4e38: 000c72c0 */ sll $t6,$t4,0xb +/* f0f4e3c: 05c30009 */ bgezl $t6,.NB0f0f4e64 +/* f0f4e40: 8fa40020 */ lw $a0,0x20($sp) +/* f0f4e44: 8c6f05d4 */ lw $t7,0x5d4($v1) +.NB0f0f4e48: +/* f0f4e48: 000fcac0 */ sll $t9,$t7,0xb +/* f0f4e4c: 07220005 */ bltzl $t9,.NB0f0f4e64 +/* f0f4e50: 8fa40020 */ lw $a0,0x20($sp) +/* f0f4e54: 906905d5 */ lbu $t1,0x5d5($v1) +/* f0f4e58: 352a0008 */ ori $t2,$t1,0x8 +/* f0f4e5c: a06a05d5 */ sb $t2,0x5d5($v1) +.NB0f0f4e60: +/* f0f4e60: 8fa40020 */ lw $a0,0x20($sp) +.NB0f0f4e64: +/* f0f4e64: 0fc3beda */ jal menuPushDialog +/* f0f4e68: afa60018 */ sw $a2,0x18($sp) +/* f0f4e6c: 8fa60018 */ lw $a2,0x18($sp) +/* f0f4e70: 3c03800a */ lui $v1,0x800a +/* f0f4e74: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f4e78: 24cbffff */ addiu $t3,$a2,-1 +/* f0f4e7c: 2d61000d */ sltiu $at,$t3,0xd +/* f0f4e80: 10200027 */ beqz $at,.NB0f0f4f20 +/* f0f4e84: 000b5880 */ sll $t3,$t3,0x2 +/* f0f4e88: 3c017f1b */ lui $at,0x7f1b +/* f0f4e8c: 002b0821 */ addu $at,$at,$t3 +/* f0f4e90: 8c2bccf4 */ lw $t3,-0x330c($at) +/* f0f4e94: 01600008 */ jr $t3 +/* f0f4e98: 00000000 */ sll $zero,$zero,0x0 +/* f0f4e9c: 0fc3d304 */ jal func0f0f82a8 +/* f0f4ea0: 24040004 */ addiu $a0,$zero,0x4 +/* f0f4ea4: 1000001e */ beqz $zero,.NB0f0f4f20 +/* f0f4ea8: 00000000 */ sll $zero,$zero,0x0 +/* f0f4eac: 0fc5a1e8 */ jal musicStartForMenu +/* f0f4eb0: 00000000 */ sll $zero,$zero,0x0 +/* f0f4eb4: 3c03800a */ lui $v1,0x800a +/* f0f4eb8: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f4ebc: 240c0009 */ addiu $t4,$zero,0x9 +/* f0f4ec0: 10000017 */ beqz $zero,.NB0f0f4f20 +/* f0f4ec4: a06c0014 */ sb $t4,0x14($v1) +/* f0f4ec8: 240d0009 */ addiu $t5,$zero,0x9 +/* f0f4ecc: 10000014 */ beqz $zero,.NB0f0f4f20 +/* f0f4ed0: a06d0014 */ sb $t5,0x14($v1) +/* f0f4ed4: 8fae0020 */ lw $t6,0x20($sp) +/* f0f4ed8: 24010002 */ addiu $at,$zero,0x2 +/* f0f4edc: 24180003 */ addiu $t8,$zero,0x3 +/* f0f4ee0: 91cf0000 */ lbu $t7,0x0($t6) +/* f0f4ee4: 15e10004 */ bne $t7,$at,.NB0f0f4ef8 +/* f0f4ee8: 00000000 */ sll $zero,$zero,0x0 +/* f0f4eec: a06005d4 */ sb $zero,0x5d4($v1) +/* f0f4ef0: 1000000b */ beqz $zero,.NB0f0f4f20 +/* f0f4ef4: a0780015 */ sb $t8,0x15($v1) +.NB0f0f4ef8: +/* f0f4ef8: 0fc3d304 */ jal func0f0f82a8 +/* f0f4efc: 24040001 */ addiu $a0,$zero,0x1 +/* f0f4f00: 10000007 */ beqz $zero,.NB0f0f4f20 +/* f0f4f04: 00000000 */ sll $zero,$zero,0x0 +/* f0f4f08: 0fc5a1e8 */ jal musicStartForMenu +/* f0f4f0c: 00000000 */ sll $zero,$zero,0x0 +/* f0f4f10: 3c03800a */ lui $v1,0x800a +/* f0f4f14: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f4f18: 24190005 */ addiu $t9,$zero,0x5 +/* f0f4f1c: a0790014 */ sb $t9,0x14($v1) +.NB0f0f4f20: +/* f0f4f20: 0fc3b625 */ jal menuIsSoloMissionOrMp +/* f0f4f24: 00000000 */ sll $zero,$zero,0x0 +/* f0f4f28: 50400004 */ beqzl $v0,.NB0f0f4f3c +/* f0f4f2c: 8fbf0014 */ lw $ra,0x14($sp) +/* f0f4f30: 0fc2e4dc */ jal currentPlayerDisplayHealth +/* f0f4f34: 00000000 */ sll $zero,$zero,0x0 +/* f0f4f38: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0f4f3c: +/* f0f4f3c: 27bd0020 */ addiu $sp,$sp,0x20 +/* f0f4f40: 03e00008 */ jr $ra +/* f0f4f44: 00000000 */ sll $zero,$zero,0x0 +); +#endif void func0f0f85e0(struct menudialog *dialog, s32 root) { @@ -17344,6 +18741,7 @@ glabel func0f0f8bb4 /* f0f8c94: 00000000 */ nop ); +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuInit .late_rodata @@ -17605,7 +19003,271 @@ glabel var7f1b2a0c /* f0f9028: 03e00008 */ jr $ra /* f0f902c: 27bd0030 */ addiu $sp,$sp,0x30 ); +#else +GLOBAL_ASM( +glabel menuInit +.late_rodata +glabel var7f1b29fc +.word 0xc0490fdb +glabel var7f1b2a00 +.word 0xc34d8000 +glabel var7f1b2a04 +.word 0x4374b333 +glabel var7f1b2a08 +.word 0x4288999a +glabel var7f1b2a0c +.word 0x3dfa0a52 +.text +/* f0f54ec: 27bdffd0 */ addiu $sp,$sp,-48 +/* f0f54f0: afbf0024 */ sw $ra,0x24($sp) +/* f0f54f4: afb20020 */ sw $s2,0x20($sp) +/* f0f54f8: afb1001c */ sw $s1,0x1c($sp) +/* f0f54fc: 0fc42c18 */ jal func0f110bf0 +/* f0f5500: afb00018 */ sw $s0,0x18($sp) +/* f0f5504: 3c0e8009 */ lui $t6,0x8009 +/* f0f5508: 91ce30e0 */ lbu $t6,0x30e0($t6) +/* f0f550c: 3c01800a */ lui $at,0x800a +/* f0f5510: ac202780 */ sw $zero,0x2780($at) +/* f0f5514: 24010001 */ addiu $at,$zero,0x1 +/* f0f5518: 11c10005 */ beq $t6,$at,.NB0f0f5530 +/* f0f551c: 24044b00 */ addiu $a0,$zero,0x4b00 +/* f0f5520: 0c004a0e */ jal malloc +/* f0f5524: 24050004 */ addiu $a1,$zero,0x4 +/* f0f5528: 3c01800a */ lui $at,0x800a +/* f0f552c: ac22277c */ sw $v0,0x277c($at) +.NB0f0f5530: +/* f0f5530: 3c11800a */ lui $s1,0x800a +/* f0f5534: 26315eb0 */ addiu $s1,$s1,0x5eb0 +/* f0f5538: 922f05d5 */ lbu $t7,0x5d5($s1) +/* f0f553c: 3c12800b */ lui $s2,0x800b +/* f0f5540: 2652fe58 */ addiu $s2,$s2,-424 +/* f0f5544: 8e440000 */ lw $a0,0x0($s2) +/* f0f5548: 31f8ff7f */ andi $t8,$t7,0xff7f +/* f0f554c: a23805d5 */ sb $t8,0x5d5($s1) +/* f0f5550: 0fc2c5ba */ jal func0f0b3988 +/* f0f5554: 2484000c */ addiu $a0,$a0,0xc +/* f0f5558: 8e440000 */ lw $a0,0x0($s2) +/* f0f555c: 0fc2c5ba */ jal func0f0b3988 +/* f0f5560: 24840048 */ addiu $a0,$a0,0x48 +/* f0f5564: 8e440000 */ lw $a0,0x0($s2) +/* f0f5568: 0fc2c5ba */ jal func0f0b3988 +/* f0f556c: 24840264 */ addiu $a0,$a0,0x264 +/* f0f5570: 8e440000 */ lw $a0,0x0($s2) +/* f0f5574: 0fc2c5ba */ jal func0f0b3988 +/* f0f5578: 24840270 */ addiu $a0,$a0,0x270 +/* f0f557c: 8e440000 */ lw $a0,0x0($s2) +/* f0f5580: 0fc2c5ba */ jal func0f0b3988 +/* f0f5584: 2484027c */ addiu $a0,$a0,0x27c +/* f0f5588: 8e440000 */ lw $a0,0x0($s2) +/* f0f558c: 0fc2c5ba */ jal func0f0b3988 +/* f0f5590: 24840288 */ addiu $a0,$a0,0x288 +/* f0f5594: 8e440000 */ lw $a0,0x0($s2) +/* f0f5598: 0fc2c5ba */ jal func0f0b3988 +/* f0f559c: 24840294 */ addiu $a0,$a0,0x294 +/* f0f55a0: 3c19800a */ lui $t9,0x800a +/* f0f55a4: 8f39eb74 */ lw $t9,-0x148c($t9) +/* f0f55a8: 24010026 */ addiu $at,$zero,0x26 +/* f0f55ac: 24100090 */ addiu $s0,$zero,0x90 +/* f0f55b0: 17210011 */ bne $t9,$at,.NB0f0f55f8 +/* f0f55b4: 00000000 */ sll $zero,$zero,0x0 +/* f0f55b8: 8e480000 */ lw $t0,0x0($s2) +.NB0f0f55bc: +/* f0f55bc: 0fc2c5ba */ jal func0f0b3988 +/* f0f55c0: 02082021 */ addu $a0,$s0,$t0 +/* f0f55c4: 2610000c */ addiu $s0,$s0,0xc +/* f0f55c8: 24010198 */ addiu $at,$zero,0x198 +/* f0f55cc: 5601fffb */ bnel $s0,$at,.NB0f0f55bc +/* f0f55d0: 8e480000 */ lw $t0,0x0($s2) +/* f0f55d4: 8e440000 */ lw $a0,0x0($s2) +/* f0f55d8: 0fc2c5ba */ jal func0f0b3988 +/* f0f55dc: 24840198 */ addiu $a0,$a0,0x198 +/* f0f55e0: 8e440000 */ lw $a0,0x0($s2) +/* f0f55e4: 0fc2c5ba */ jal func0f0b3988 +/* f0f55e8: 248401b0 */ addiu $a0,$a0,0x1b0 +/* f0f55ec: 8e440000 */ lw $a0,0x0($s2) +/* f0f55f0: 0fc2c5ba */ jal func0f0b3988 +/* f0f55f4: 248401a4 */ addiu $a0,$a0,0x1a4 +.NB0f0f55f8: +/* f0f55f8: 3c05800a */ lui $a1,0x800a +/* f0f55fc: 8ca5e9d4 */ lw $a1,-0x162c($a1) +/* f0f5600: 10a00006 */ beqz $a1,.NB0f0f561c +/* f0f5604: 00000000 */ sll $zero,$zero,0x0 +/* f0f5608: 8e440000 */ lw $a0,0x0($s2) +/* f0f560c: 0fc2c5ba */ jal func0f0b3988 +/* f0f5610: 248401a4 */ addiu $a0,$a0,0x1a4 +/* f0f5614: 3c05800a */ lui $a1,0x800a +/* f0f5618: 8ca5e9d4 */ lw $a1,-0x162c($a1) +.NB0f0f561c: +/* f0f561c: 3c04800a */ lui $a0,0x800a +/* f0f5620: 3c02800a */ lui $v0,0x800a +/* f0f5624: 3c03800a */ lui $v1,0x800a +/* f0f5628: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f562c: 244227c0 */ addiu $v0,$v0,0x27c0 +/* f0f5630: 8c84eb74 */ lw $a0,-0x148c($a0) +.NB0f0f5634: +/* f0f5634: 24420dbc */ addiu $v0,$v0,0xdbc +/* f0f5638: 0043082b */ sltu $at,$v0,$v1 +/* f0f563c: 1420fffd */ bnez $at,.NB0f0f5634 +/* f0f5640: ac40f9e4 */ sw $zero,-0x61c($v0) +/* f0f5644: 24010026 */ addiu $at,$zero,0x26 +/* f0f5648: 1481000b */ bne $a0,$at,.NB0f0f5678 +/* f0f564c: ae200020 */ sw $zero,0x20($s1) +/* f0f5650: 3c02800a */ lui $v0,0x800a +/* f0f5654: 244227a8 */ addiu $v0,$v0,0x27a8 +/* f0f5658: 90490003 */ lbu $t1,0x3($v0) +/* f0f565c: 904d0000 */ lbu $t5,0x0($v0) +/* f0f5660: 312bff7f */ andi $t3,$t1,0xff7f +/* f0f5664: a04b0003 */ sb $t3,0x3($v0) +/* f0f5668: 316c00bf */ andi $t4,$t3,0xbf +/* f0f566c: 31aefffe */ andi $t6,$t5,0xfffe +/* f0f5670: a04c0003 */ sb $t4,0x3($v0) +/* f0f5674: a04e0000 */ sb $t6,0x0($v0) +.NB0f0f5678: +/* f0f5678: 14a0004e */ bnez $a1,.NB0f0f57b4 +/* f0f567c: 24010026 */ addiu $at,$zero,0x26 +/* f0f5680: 14810002 */ bne $a0,$at,.NB0f0f568c +/* f0f5684: 00001025 */ or $v0,$zero,$zero +/* f0f5688: 24020004 */ addiu $v0,$zero,0x4 +.NB0f0f568c: +/* f0f568c: 2401005d */ addiu $at,$zero,0x5d +/* f0f5690: 14810002 */ bne $a0,$at,.NB0f0f569c +/* f0f5694: 3c10800a */ lui $s0,0x800a +/* f0f5698: 24020004 */ addiu $v0,$zero,0x4 +.NB0f0f569c: +/* f0f569c: 18400015 */ blez $v0,.NB0f0f56f4 +/* f0f56a0: 00001825 */ or $v1,$zero,$zero +/* f0f56a4: 26102f5c */ addiu $s0,$s0,0x2f5c +.NB0f0f56a8: +/* f0f56a8: 3c0f8009 */ lui $t7,0x8009 +/* f0f56ac: 91ef30e0 */ lbu $t7,0x30e0($t7) +/* f0f56b0: 24010001 */ addiu $at,$zero,0x1 +/* f0f56b4: 02002025 */ or $a0,$s0,$zero +/* f0f56b8: 15e10003 */ bne $t7,$at,.NB0f0f56c8 +/* f0f56bc: 24060001 */ addiu $a2,$zero,0x1 +/* f0f56c0: 10000003 */ beqz $zero,.NB0f0f56d0 +/* f0f56c4: 3405b400 */ dli $a1,0xb400 +.NB0f0f56c8: +/* f0f56c8: 3c050002 */ lui $a1,0x2 +/* f0f56cc: 34a55800 */ ori $a1,$a1,0x5800 +.NB0f0f56d0: +/* f0f56d0: afa20028 */ sw $v0,0x28($sp) +/* f0f56d4: 0fc3d502 */ jal func0f0f8bb4 +/* f0f56d8: afa3002c */ sw $v1,0x2c($sp) +/* f0f56dc: 8fa3002c */ lw $v1,0x2c($sp) +/* f0f56e0: 8fa20028 */ lw $v0,0x28($sp) +/* f0f56e4: 26100dbc */ addiu $s0,$s0,0xdbc +/* f0f56e8: 24630001 */ addiu $v1,$v1,0x1 +/* f0f56ec: 1462ffee */ bne $v1,$v0,.NB0f0f56a8 +/* f0f56f0: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f56f4: +/* f0f56f4: 3c188009 */ lui $t8,0x8009 +/* f0f56f8: 931830e0 */ lbu $t8,0x30e0($t8) +/* f0f56fc: 24010001 */ addiu $at,$zero,0x1 +/* f0f5700: 3c04800a */ lui $a0,0x800a +/* f0f5704: 13010004 */ beq $t8,$at,.NB0f0f5718 +/* f0f5708: 24845ecc */ addiu $a0,$a0,0x5ecc +/* f0f570c: 3405c800 */ dli $a1,0xc800 +/* f0f5710: 0fc3d502 */ jal func0f0f8bb4 +/* f0f5714: 24060001 */ addiu $a2,$zero,0x1 +.NB0f0f5718: +/* f0f5718: 24190259 */ addiu $t9,$zero,0x259 +/* f0f571c: 44800000 */ mtc1 $zero,$f0 +/* f0f5720: ae390028 */ sw $t9,0x28($s1) +/* f0f5724: 3c017f1b */ lui $at,0x7f1b +/* f0f5728: c424cd28 */ lwc1 $f4,-0x32d8($at) +/* f0f572c: e6200564 */ swc1 $f0,0x564($s1) +/* f0f5730: e620056c */ swc1 $f0,0x56c($s1) +/* f0f5734: e6240568 */ swc1 $f4,0x568($s1) +/* f0f5738: c6260568 */ lwc1 $f6,0x568($s1) +/* f0f573c: c6280564 */ lwc1 $f8,0x564($s1) +/* f0f5740: c62a056c */ lwc1 $f10,0x56c($s1) +/* f0f5744: 3c017f1b */ lui $at,0x7f1b +/* f0f5748: e6260540 */ swc1 $f6,0x540($s1) +/* f0f574c: e628053c */ swc1 $f8,0x53c($s1) +/* f0f5750: e62a0544 */ swc1 $f10,0x544($s1) +/* f0f5754: c430cd2c */ lwc1 $f16,-0x32d4($at) +/* f0f5758: 3c017f1b */ lui $at,0x7f1b +/* f0f575c: 922805cd */ lbu $t0,0x5cd($s1) +/* f0f5760: e6300554 */ swc1 $f16,0x554($s1) +/* f0f5764: c6320554 */ lwc1 $f18,0x554($s1) +/* f0f5768: 3109ff7f */ andi $t1,$t0,0xff7f +/* f0f576c: e632052c */ swc1 $f18,0x52c($s1) +/* f0f5770: c424cd30 */ lwc1 $f4,-0x32d0($at) +/* f0f5774: 3c017f1b */ lui $at,0x7f1b +/* f0f5778: e6240558 */ swc1 $f4,0x558($s1) +/* f0f577c: c6260558 */ lwc1 $f6,0x558($s1) +/* f0f5780: e6260530 */ swc1 $f6,0x530($s1) +/* f0f5784: c428cd34 */ lwc1 $f8,-0x32cc($at) +/* f0f5788: 3c017f1b */ lui $at,0x7f1b +/* f0f578c: e628055c */ swc1 $f8,0x55c($s1) +/* f0f5790: c62a055c */ lwc1 $f10,0x55c($s1) +/* f0f5794: e62a0534 */ swc1 $f10,0x534($s1) +/* f0f5798: c430cd38 */ lwc1 $f16,-0x32c8($at) +/* f0f579c: a22905cd */ sb $t1,0x5cd($s1) +/* f0f57a0: ae200590 */ sw $zero,0x590($s1) +/* f0f57a4: e6300560 */ swc1 $f16,0x560($s1) +/* f0f57a8: c6320560 */ lwc1 $f18,0x560($s1) +/* f0f57ac: ae20059c */ sw $zero,0x59c($s1) +/* f0f57b0: e6320538 */ swc1 $f18,0x538($s1) +.NB0f0f57b4: +/* f0f57b4: 922a05d5 */ lbu $t2,0x5d5($s1) +/* f0f57b8: 3c02800a */ lui $v0,0x800a +/* f0f57bc: 3c03800a */ lui $v1,0x800a +/* f0f57c0: 314bfff7 */ andi $t3,$t2,0xfff7 +/* f0f57c4: 44800000 */ mtc1 $zero,$f0 +/* f0f57c8: a22005d4 */ sb $zero,0x5d4($s1) +/* f0f57cc: a22b05d5 */ sb $t3,0x5d5($s1) +/* f0f57d0: 24635eb0 */ addiu $v1,$v1,0x5eb0 +/* f0f57d4: 244227c0 */ addiu $v0,$v0,0x27c0 +/* f0f57d8: 2404ffff */ addiu $a0,$zero,-1 +.NB0f0f57dc: +/* f0f57dc: 24420dbc */ addiu $v0,$v0,0xdbc +/* f0f57e0: 0043082b */ sltu $at,$v0,$v1 +/* f0f57e4: ac40f6cc */ sw $zero,-0x934($v0) +/* f0f57e8: a440f6c8 */ sh $zero,-0x938($v0) +/* f0f57ec: a440f634 */ sh $zero,-0x9cc($v0) +/* f0f57f0: a040f9c0 */ sb $zero,-0x640($v0) +/* f0f57f4: ac40f810 */ sw $zero,-0x7f0($v0) +/* f0f57f8: ac40f9bc */ sw $zero,-0x644($v0) +/* f0f57fc: ac40f878 */ sw $zero,-0x788($v0) +/* f0f5800: a044ff98 */ sb $a0,-0x68($v0) +/* f0f5804: a040ffe1 */ sb $zero,-0x1f($v0) +/* f0f5808: ac40fff4 */ sw $zero,-0xc($v0) +/* f0f580c: 1420fff3 */ bnez $at,.NB0f0f57dc +/* f0f5810: ac40fff8 */ sw $zero,-0x8($v0) +/* f0f5814: 922c05d5 */ lbu $t4,0x5d5($s1) +/* f0f5818: 240500ff */ addiu $a1,$zero,0xff +/* f0f581c: 3c02800a */ lui $v0,0x800a +/* f0f5820: 3c03800a */ lui $v1,0x800a +/* f0f5824: 318dfffb */ andi $t5,$t4,0xfffb +/* f0f5828: a2240668 */ sb $a0,0x668($s1) +/* f0f582c: ae20000c */ sw $zero,0xc($s1) +/* f0f5830: ae240008 */ sw $a0,0x8($s1) +/* f0f5834: ae200000 */ sw $zero,0x0($s1) +/* f0f5838: ae200004 */ sw $zero,0x4($s1) +/* f0f583c: e6200010 */ swc1 $f0,0x10($s1) +/* f0f5840: a2200014 */ sb $zero,0x14($s1) +/* f0f5844: a22d05d5 */ sb $t5,0x5d5($s1) +/* f0f5848: a2250015 */ sb $a1,0x15($s1) +/* f0f584c: a224001b */ sb $a0,0x1b($s1) +/* f0f5850: 24635eb5 */ addiu $v1,$v1,0x5eb5 +/* f0f5854: 24425eb0 */ addiu $v0,$v0,0x5eb0 +.NB0f0f5858: +/* f0f5858: 24420001 */ addiu $v0,$v0,0x1 +/* f0f585c: 1443fffe */ bne $v0,$v1,.NB0f0f5858 +/* f0f5860: a0450668 */ sb $a1,0x668($v0) +/* f0f5864: 8fbf0024 */ lw $ra,0x24($sp) +/* f0f5868: a220066e */ sb $zero,0x66e($s1) +/* f0f586c: a220066f */ sb $zero,0x66f($s1) +/* f0f5870: 8fb1001c */ lw $s1,0x1c($sp) +/* f0f5874: 8fb00018 */ lw $s0,0x18($sp) +/* f0f5878: 8fb20020 */ lw $s2,0x20($sp) +/* f0f587c: 03e00008 */ jr $ra +/* f0f5880: 27bd0030 */ addiu $sp,$sp,0x30 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0f9030 /* f0f9030: 27bdff98 */ addiu $sp,$sp,-104 @@ -17821,6 +19483,223 @@ glabel func0f0f9030 /* f0f9354: 03e00008 */ jr $ra /* f0f9358: 27bd0068 */ addiu $sp,$sp,0x68 ); +#else +GLOBAL_ASM( +glabel func0f0f9030 +/* f0f5884: 27bdff98 */ addiu $sp,$sp,-104 +/* f0f5888: afb40024 */ sw $s4,0x24($sp) +/* f0f588c: 3c148007 */ lui $s4,0x8007 +/* f0f5890: 26943af0 */ addiu $s4,$s4,0x3af0 +/* f0f5894: 8e8e0000 */ lw $t6,0x0($s4) +/* f0f5898: afb50028 */ sw $s5,0x28($sp) +/* f0f589c: 24150dbc */ addiu $s5,$zero,0xdbc +/* f0f58a0: 01d50019 */ multu $t6,$s5 +/* f0f58a4: afb30020 */ sw $s3,0x20($sp) +/* f0f58a8: 3c13800a */ lui $s3,0x800a +/* f0f58ac: 267327c0 */ addiu $s3,$s3,0x27c0 +/* f0f58b0: afbf002c */ sw $ra,0x2c($sp) +/* f0f58b4: afb2001c */ sw $s2,0x1c($sp) +/* f0f58b8: afb10018 */ sw $s1,0x18($sp) +/* f0f58bc: afb00014 */ sw $s0,0x14($sp) +/* f0f58c0: 00802825 */ or $a1,$a0,$zero +/* f0f58c4: 00007812 */ mflo $t7 +/* f0f58c8: 026f1821 */ addu $v1,$s3,$t7 +/* f0f58cc: 84780484 */ lh $t8,0x484($v1) +/* f0f58d0: 0018c880 */ sll $t9,$t8,0x2 +/* f0f58d4: 0338c823 */ subu $t9,$t9,$t8 +/* f0f58d8: 0019c8c0 */ sll $t9,$t9,0x3 +/* f0f58dc: 00791021 */ addu $v0,$v1,$t9 +/* f0f58e0: 804803f0 */ lb $t0,0x3f0($v0) +/* f0f58e4: 244203dc */ addiu $v0,$v0,0x3dc +/* f0f58e8: 29010002 */ slti $at,$t0,0x2 +/* f0f58ec: 542000a8 */ bnezl $at,.NB0f0f5b90 +/* f0f58f0: 8fbf002c */ lw $ra,0x2c($sp) +/* f0f58f4: 8c6a0488 */ lw $t2,0x488($v1) +/* f0f58f8: 00044823 */ negu $t1,$a0 +/* f0f58fc: 00806825 */ or $t5,$a0,$zero +/* f0f5900: a149006d */ sb $t1,0x6d($t2) +/* f0f5904: 804b0015 */ lb $t3,0x15($v0) +/* f0f5908: 016d7021 */ addu $t6,$t3,$t5 +/* f0f590c: a04e0015 */ sb $t6,0x15($v0) +/* f0f5910: 80440015 */ lb $a0,0x15($v0) +/* f0f5914: 04830006 */ bgezl $a0,.NB0f0f5930 +/* f0f5918: 80590014 */ lb $t9,0x14($v0) +/* f0f591c: 804f0014 */ lb $t7,0x14($v0) +/* f0f5920: 25f8ffff */ addiu $t8,$t7,-1 +/* f0f5924: a0580015 */ sb $t8,0x15($v0) +/* f0f5928: 80440015 */ lb $a0,0x15($v0) +/* f0f592c: 80590014 */ lb $t9,0x14($v0) +.NB0f0f5930: +/* f0f5930: 0099082a */ slt $at,$a0,$t9 +/* f0f5934: 54200004 */ bnezl $at,.NB0f0f5948 +/* f0f5938: 8e880000 */ lw $t0,0x0($s4) +/* f0f593c: a0400015 */ sb $zero,0x15($v0) +/* f0f5940: 80440015 */ lb $a0,0x15($v0) +/* f0f5944: 8e880000 */ lw $t0,0x0($s4) +.NB0f0f5948: +/* f0f5948: 00045080 */ sll $t2,$a0,0x2 +/* f0f594c: 004a6021 */ addu $t4,$v0,$t2 +/* f0f5950: 01150019 */ multu $t0,$s5 +/* f0f5954: 8d8b0000 */ lw $t3,0x0($t4) +/* f0f5958: 24010001 */ addiu $at,$zero,0x1 +/* f0f595c: 01602025 */ or $a0,$t3,$zero +/* f0f5960: 00004812 */ mflo $t1 +/* f0f5964: 02691821 */ addu $v1,$s3,$t1 +/* f0f5968: 14a1000a */ bne $a1,$at,.NB0f0f5994 +/* f0f596c: ac6b0488 */ sw $t3,0x488($v1) +/* f0f5970: 0fc3bd2a */ jal func0f0f288c +/* f0f5974: afa50068 */ sw $a1,0x68($sp) +/* f0f5978: 8e8d0000 */ lw $t5,0x0($s4) +/* f0f597c: 01b50019 */ multu $t5,$s5 +/* f0f5980: 00007012 */ mflo $t6 +/* f0f5984: 026e7821 */ addu $t7,$s3,$t6 +/* f0f5988: 8df80488 */ lw $t8,0x488($t7) +/* f0f598c: 1000000a */ beqz $zero,.NB0f0f59b8 +/* f0f5990: af020008 */ sw $v0,0x8($t8) +.NB0f0f5994: +/* f0f5994: 8c640488 */ lw $a0,0x488($v1) +/* f0f5998: 0fc3bd51 */ jal func0f0f2928 +/* f0f599c: afa50068 */ sw $a1,0x68($sp) +/* f0f59a0: 8e990000 */ lw $t9,0x0($s4) +/* f0f59a4: 03350019 */ multu $t9,$s5 +/* f0f59a8: 00004012 */ mflo $t0 +/* f0f59ac: 02684821 */ addu $t1,$s3,$t0 +/* f0f59b0: 8d2a0488 */ lw $t2,0x488($t1) +/* f0f59b4: ad420008 */ sw $v0,0x8($t2) +.NB0f0f59b8: +/* f0f59b8: 8e8c0000 */ lw $t4,0x0($s4) +/* f0f59bc: 2411001a */ addiu $s1,$zero,0x1a +/* f0f59c0: 27b20050 */ addiu $s2,$sp,0x50 +/* f0f59c4: 01950019 */ multu $t4,$s5 +/* f0f59c8: 00005812 */ mflo $t3 +/* f0f59cc: 026b6821 */ addu $t5,$s3,$t3 +/* f0f59d0: 8da30488 */ lw $v1,0x488($t5) +/* f0f59d4: 8c6e0000 */ lw $t6,0x0($v1) +/* f0f59d8: 8dd00008 */ lw $s0,0x8($t6) +/* f0f59dc: 920f0000 */ lbu $t7,0x0($s0) +/* f0f59e0: 522f0023 */ beql $s1,$t7,.NB0f0f5a70 +/* f0f59e4: 8c650008 */ lw $a1,0x8($v1) +/* f0f59e8: 8e020010 */ lw $v0,0x10($s0) +.NB0f0f59ec: +/* f0f59ec: 50400012 */ beqzl $v0,.NB0f0f5a38 +/* f0f59f0: 920b0014 */ lbu $t3,0x14($s0) +/* f0f59f4: 8e180004 */ lw $t8,0x4($s0) +/* f0f59f8: 2404000f */ addiu $a0,$zero,0xf +/* f0f59fc: 02002825 */ or $a1,$s0,$zero +/* f0f5a00: 33190004 */ andi $t9,$t8,0x4 +/* f0f5a04: 5720000c */ bnezl $t9,.NB0f0f5a38 +/* f0f5a08: 920b0014 */ lbu $t3,0x14($s0) +/* f0f5a0c: 0040f809 */ jalr $v0 +/* f0f5a10: 02403025 */ or $a2,$s2,$zero +/* f0f5a14: 50400008 */ beqzl $v0,.NB0f0f5a38 +/* f0f5a18: 920b0014 */ lbu $t3,0x14($s0) +/* f0f5a1c: 8e880000 */ lw $t0,0x0($s4) +/* f0f5a20: 01150019 */ multu $t0,$s5 +/* f0f5a24: 00004812 */ mflo $t1 +/* f0f5a28: 02695021 */ addu $t2,$s3,$t1 +/* f0f5a2c: 8d4c0488 */ lw $t4,0x488($t2) +/* f0f5a30: ad900008 */ sw $s0,0x8($t4) +/* f0f5a34: 920b0014 */ lbu $t3,0x14($s0) +.NB0f0f5a38: +/* f0f5a38: 26100014 */ addiu $s0,$s0,0x14 +/* f0f5a3c: 562bffeb */ bnel $s1,$t3,.NB0f0f59ec +/* f0f5a40: 8e020010 */ lw $v0,0x10($s0) +/* f0f5a44: 8e8d0000 */ lw $t5,0x0($s4) +/* f0f5a48: 000d70c0 */ sll $t6,$t5,0x3 +/* f0f5a4c: 01cd7023 */ subu $t6,$t6,$t5 +/* f0f5a50: 000e70c0 */ sll $t6,$t6,0x3 +/* f0f5a54: 01cd7023 */ subu $t6,$t6,$t5 +/* f0f5a58: 000e7100 */ sll $t6,$t6,0x4 +/* f0f5a5c: 01cd7023 */ subu $t6,$t6,$t5 +/* f0f5a60: 000e7080 */ sll $t6,$t6,0x2 +/* f0f5a64: 026e7821 */ addu $t7,$s3,$t6 +/* f0f5a68: 8de30488 */ lw $v1,0x488($t7) +/* f0f5a6c: 8c650008 */ lw $a1,0x8($v1) +.NB0f0f5a70: +/* f0f5a70: 50a00016 */ beqzl $a1,.NB0f0f5acc +/* f0f5a74: 8fac0068 */ lw $t4,0x68($sp) +/* f0f5a78: 8ca20010 */ lw $v0,0x10($a1) +/* f0f5a7c: 50400013 */ beqzl $v0,.NB0f0f5acc +/* f0f5a80: 8fac0068 */ lw $t4,0x68($sp) +/* f0f5a84: 8cb80004 */ lw $t8,0x4($a1) +/* f0f5a88: 2404000d */ addiu $a0,$zero,0xd +/* f0f5a8c: 33190004 */ andi $t9,$t8,0x4 +/* f0f5a90: 5720000e */ bnezl $t9,.NB0f0f5acc +/* f0f5a94: 8fac0068 */ lw $t4,0x68($sp) +/* f0f5a98: 0040f809 */ jalr $v0 +/* f0f5a9c: 27a60040 */ addiu $a2,$sp,0x40 +/* f0f5aa0: 8e880000 */ lw $t0,0x0($s4) +/* f0f5aa4: 000848c0 */ sll $t1,$t0,0x3 +/* f0f5aa8: 01284823 */ subu $t1,$t1,$t0 +/* f0f5aac: 000948c0 */ sll $t1,$t1,0x3 +/* f0f5ab0: 01284823 */ subu $t1,$t1,$t0 +/* f0f5ab4: 00094900 */ sll $t1,$t1,0x4 +/* f0f5ab8: 01284823 */ subu $t1,$t1,$t0 +/* f0f5abc: 00094880 */ sll $t1,$t1,0x2 +/* f0f5ac0: 02695021 */ addu $t2,$s3,$t1 +/* f0f5ac4: 8d430488 */ lw $v1,0x488($t2) +/* f0f5ac8: 8fac0068 */ lw $t4,0x68($sp) +.NB0f0f5acc: +/* f0f5acc: a06c006d */ sb $t4,0x6d($v1) +/* f0f5ad0: 8e8b0000 */ lw $t3,0x0($s4) +/* f0f5ad4: 01750019 */ multu $t3,$s5 +/* f0f5ad8: 00006812 */ mflo $t5 +/* f0f5adc: 026d7021 */ addu $t6,$s3,$t5 +/* f0f5ae0: 0fc3d200 */ jal func0f0f7e98 +/* f0f5ae4: 8dc40488 */ lw $a0,0x488($t6) +/* f0f5ae8: 8e8f0000 */ lw $t7,0x0($s4) +/* f0f5aec: 44802000 */ mtc1 $zero,$f4 +/* f0f5af0: 01f50019 */ multu $t7,$s5 +/* f0f5af4: 0000c012 */ mflo $t8 +/* f0f5af8: 0278c821 */ addu $t9,$s3,$t8 +/* f0f5afc: 8f230488 */ lw $v1,0x488($t9) +/* f0f5b00: 8c68002c */ lw $t0,0x2c($v1) +/* f0f5b04: ac680014 */ sw $t0,0x14($v1) +/* f0f5b08: 8e890000 */ lw $t1,0x0($s4) +/* f0f5b0c: 01350019 */ multu $t1,$s5 +/* f0f5b10: 00005012 */ mflo $t2 +/* f0f5b14: 026a6021 */ addu $t4,$s3,$t2 +/* f0f5b18: 8d830488 */ lw $v1,0x488($t4) +/* f0f5b1c: 8c6b0030 */ lw $t3,0x30($v1) +/* f0f5b20: ac6b0018 */ sw $t3,0x18($v1) +/* f0f5b24: 8e8d0000 */ lw $t5,0x0($s4) +/* f0f5b28: 01b50019 */ multu $t5,$s5 +/* f0f5b2c: 00007012 */ mflo $t6 +/* f0f5b30: 026e7821 */ addu $t7,$s3,$t6 +/* f0f5b34: 8df80488 */ lw $t8,0x488($t7) +/* f0f5b38: a300006d */ sb $zero,0x6d($t8) +/* f0f5b3c: 8e990000 */ lw $t9,0x0($s4) +/* f0f5b40: 03350019 */ multu $t9,$s5 +/* f0f5b44: 00004012 */ mflo $t0 +/* f0f5b48: 02684821 */ addu $t1,$s3,$t0 +/* f0f5b4c: 8d2a0488 */ lw $t2,0x488($t1) +/* f0f5b50: a1400060 */ sb $zero,0x60($t2) +/* f0f5b54: 8e8c0000 */ lw $t4,0x0($s4) +/* f0f5b58: 01950019 */ multu $t4,$s5 +/* f0f5b5c: 00005812 */ mflo $t3 +/* f0f5b60: 026b6821 */ addu $t5,$s3,$t3 +/* f0f5b64: 8dae0488 */ lw $t6,0x488($t5) +/* f0f5b68: e5c40050 */ swc1 $f4,0x50($t6) +/* f0f5b6c: 8e8f0000 */ lw $t7,0x0($s4) +/* f0f5b70: 01f50019 */ multu $t7,$s5 +/* f0f5b74: 0000c012 */ mflo $t8 +/* f0f5b78: 02782021 */ addu $a0,$s3,$t8 +/* f0f5b7c: 0fc3c0ba */ jal func0f0f37a4 +/* f0f5b80: 2484079c */ addiu $a0,$a0,0x79c +/* f0f5b84: 0fc3b5c8 */ jal menuPlaySound +/* f0f5b88: 00002025 */ or $a0,$zero,$zero +/* f0f5b8c: 8fbf002c */ lw $ra,0x2c($sp) +.NB0f0f5b90: +/* f0f5b90: 8fb00014 */ lw $s0,0x14($sp) +/* f0f5b94: 8fb10018 */ lw $s1,0x18($sp) +/* f0f5b98: 8fb2001c */ lw $s2,0x1c($sp) +/* f0f5b9c: 8fb30020 */ lw $s3,0x20($sp) +/* f0f5ba0: 8fb40024 */ lw $s4,0x24($sp) +/* f0f5ba4: 8fb50028 */ lw $s5,0x28($sp) +/* f0f5ba8: 03e00008 */ jr $ra +/* f0f5bac: 27bd0068 */ addiu $sp,$sp,0x68 +); +#endif #if VERSION >= VERSION_PAL_FINAL GLOBAL_ASM( @@ -21681,6 +23560,7 @@ glabel var7f1b2a64 ); #endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0fa574 /* f0fa574: 27bdffc8 */ addiu $sp,$sp,-56 @@ -21767,6 +23647,94 @@ glabel func0f0fa574 /* f0fa6a4: 03e00008 */ jr $ra /* f0fa6a8: 27bd0038 */ addiu $sp,$sp,0x38 ); +#else +GLOBAL_ASM( +glabel func0f0fa574 +/* f0f6cc4: 27bdffc8 */ addiu $sp,$sp,-56 +/* f0f6cc8: 3c0e8007 */ lui $t6,0x8007 +/* f0f6ccc: 8dce3af0 */ lw $t6,0x3af0($t6) +/* f0f6cd0: afbf0034 */ sw $ra,0x34($sp) +/* f0f6cd4: afb70030 */ sw $s7,0x30($sp) +/* f0f6cd8: 000e78c0 */ sll $t7,$t6,0x3 +/* f0f6cdc: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f6ce0: 000f78c0 */ sll $t7,$t7,0x3 +/* f0f6ce4: afb6002c */ sw $s6,0x2c($sp) +/* f0f6ce8: afb50028 */ sw $s5,0x28($sp) +/* f0f6cec: afb40024 */ sw $s4,0x24($sp) +/* f0f6cf0: afb30020 */ sw $s3,0x20($sp) +/* f0f6cf4: afb2001c */ sw $s2,0x1c($sp) +/* f0f6cf8: afb10018 */ sw $s1,0x18($sp) +/* f0f6cfc: afb00014 */ sw $s0,0x14($sp) +/* f0f6d00: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f6d04: 90830005 */ lbu $v1,0x5($a0) +/* f0f6d08: 000f7900 */ sll $t7,$t7,0x4 +/* f0f6d0c: 3c18800a */ lui $t8,0x800a +/* f0f6d10: 01ee7823 */ subu $t7,$t7,$t6 +/* f0f6d14: 000f7880 */ sll $t7,$t7,0x2 +/* f0f6d18: 271827c0 */ addiu $t8,$t8,0x27c0 +/* f0f6d1c: 0080a825 */ or $s5,$a0,$zero +/* f0f6d20: 01f89021 */ addu $s2,$t7,$t8 +/* f0f6d24: 1860002a */ blez $v1,.NB0f0f6dd0 +/* f0f6d28: 0000b025 */ or $s6,$zero,$zero +/* f0f6d2c: 2417000a */ addiu $s7,$zero,0xa +/* f0f6d30: 2414ffff */ addiu $s4,$zero,-1 +/* f0f6d34: 24130014 */ addiu $s3,$zero,0x14 +/* f0f6d38: 92b90004 */ lbu $t9,0x4($s5) +.NB0f0f6d3c: +/* f0f6d3c: 00008025 */ or $s0,$zero,$zero +/* f0f6d40: 03361021 */ addu $v0,$t9,$s6 +/* f0f6d44: 00570019 */ multu $v0,$s7 +/* f0f6d48: 00004012 */ mflo $t0 +/* f0f6d4c: 02488821 */ addu $s1,$s2,$t0 +/* f0f6d50: 922905d8 */ lbu $t1,0x5d8($s1) +/* f0f6d54: 5920001b */ blezl $t1,.NB0f0f6dc4 +/* f0f6d58: 26d60001 */ addiu $s6,$s6,0x1 +/* f0f6d5c: 962a05d6 */ lhu $t2,0x5d6($s1) +.NB0f0f6d60: +/* f0f6d60: 8eae0000 */ lw $t6,0x0($s5) +/* f0f6d64: 00002825 */ or $a1,$zero,$zero +/* f0f6d68: 01501821 */ addu $v1,$t2,$s0 +/* f0f6d6c: 00035880 */ sll $t3,$v1,0x2 +/* f0f6d70: 024b1021 */ addu $v0,$s2,$t3 +/* f0f6d74: 904c048e */ lbu $t4,0x48e($v0) +/* f0f6d78: 8044048f */ lb $a0,0x48f($v0) +/* f0f6d7c: 8dcf0008 */ lw $t7,0x8($t6) +/* f0f6d80: 01930019 */ multu $t4,$s3 +/* f0f6d84: 0004c080 */ sll $t8,$a0,0x2 +/* f0f6d88: 00006812 */ mflo $t5 +/* f0f6d8c: 01af3021 */ addu $a2,$t5,$t7 +/* f0f6d90: 12840003 */ beq $s4,$a0,.NB0f0f6da0 +/* f0f6d94: 00000000 */ sll $zero,$zero,0x0 +/* f0f6d98: 02582821 */ addu $a1,$s2,$t8 +/* f0f6d9c: 24a50638 */ addiu $a1,$a1,0x638 +.NB0f0f6da0: +/* f0f6da0: 0fc3b564 */ jal menuInitItem +/* f0f6da4: 00c02025 */ or $a0,$a2,$zero +/* f0f6da8: 923905d8 */ lbu $t9,0x5d8($s1) +/* f0f6dac: 26100001 */ addiu $s0,$s0,0x1 +/* f0f6db0: 0219082a */ slt $at,$s0,$t9 +/* f0f6db4: 5420ffea */ bnezl $at,.NB0f0f6d60 +/* f0f6db8: 962a05d6 */ lhu $t2,0x5d6($s1) +/* f0f6dbc: 92a30005 */ lbu $v1,0x5($s5) +/* f0f6dc0: 26d60001 */ addiu $s6,$s6,0x1 +.NB0f0f6dc4: +/* f0f6dc4: 02c3082a */ slt $at,$s6,$v1 +/* f0f6dc8: 5420ffdc */ bnezl $at,.NB0f0f6d3c +/* f0f6dcc: 92b90004 */ lbu $t9,0x4($s5) +.NB0f0f6dd0: +/* f0f6dd0: 8fbf0034 */ lw $ra,0x34($sp) +/* f0f6dd4: 8fb00014 */ lw $s0,0x14($sp) +/* f0f6dd8: 8fb10018 */ lw $s1,0x18($sp) +/* f0f6ddc: 8fb2001c */ lw $s2,0x1c($sp) +/* f0f6de0: 8fb30020 */ lw $s3,0x20($sp) +/* f0f6de4: 8fb40024 */ lw $s4,0x24($sp) +/* f0f6de8: 8fb50028 */ lw $s5,0x28($sp) +/* f0f6dec: 8fb6002c */ lw $s6,0x2c($sp) +/* f0f6df0: 8fb70030 */ lw $s7,0x30($sp) +/* f0f6df4: 03e00008 */ jr $ra +/* f0f6df8: 27bd0038 */ addiu $sp,$sp,0x38 +); +#endif void func0f0fa6ac(void) { @@ -22832,7 +24800,7 @@ glabel var7f1b2ac8 /* f0fbc10: 03e00008 */ jr $ra /* f0fbc14: 27bd0130 */ addiu $sp,$sp,0x130 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0fa704 .late_rodata @@ -23859,6 +25827,1033 @@ glabel var7f1b2ac8 /* f0fb480: 03e00008 */ jr $ra /* f0fb484: 27bd0130 */ addiu $sp,$sp,0x130 ); +#else +GLOBAL_ASM( +glabel func0f0fa704 +.late_rodata +glabel var7f1b2a98 +.word func0f0fa704+0xd10 +glabel var7f1b2a9c +.word func0f0fa704+0xd10 +glabel var7f1b2aa0 +.word func0f0fa704+0xc38 +glabel var7f1b2aa4 +.word func0f0fa704+0xcc0 +glabel var7f1b2aa8 +.word func0f0fa704+0xd10 +glabel var7f1b2aac +.word func0f0fa704+0xd54 +glabel var7f1b2ab0 +.word func0f0fa704+0xd54 +glabel var7f1b2ab4 +.word func0f0fa704+0xd54 +glabel var7f1b2ab8 +.word func0f0fa704+0xd54 +glabel var7f1b2abc +.word func0f0fa704+0xd54 +glabel var7f1b2ac0 +.word func0f0fa704+0xc38 +glabel var7f1b2ac4 +.word func0f0fa704+0xd54 +glabel var7f1b2ac8 +.word func0f0fa704+0xd10 +.text +/* f0f6e54: 27bdfed0 */ addiu $sp,$sp,-304 +/* f0f6e58: afb70034 */ sw $s7,0x34($sp) +/* f0f6e5c: 3c178007 */ lui $s7,0x8007 +/* f0f6e60: 26f73af0 */ addiu $s7,$s7,0x3af0 +/* f0f6e64: 8eee0000 */ lw $t6,0x0($s7) +/* f0f6e68: afbe0038 */ sw $s8,0x38($sp) +/* f0f6e6c: 241e0dbc */ addiu $s8,$zero,0xdbc +/* f0f6e70: 01de0019 */ multu $t6,$s8 +/* f0f6e74: afb60030 */ sw $s6,0x30($sp) +/* f0f6e78: 3c16800a */ lui $s6,0x800a +/* f0f6e7c: 26d627c0 */ addiu $s6,$s6,0x27c0 +/* f0f6e80: 3c19800a */ lui $t9,0x800a +/* f0f6e84: 8f395eb4 */ lw $t9,0x5eb4($t9) +/* f0f6e88: afb5002c */ sw $s5,0x2c($sp) +/* f0f6e8c: 24010004 */ addiu $at,$zero,0x4 +/* f0f6e90: afbf003c */ sw $ra,0x3c($sp) +/* f0f6e94: afb40028 */ sw $s4,0x28($sp) +/* f0f6e98: 00007812 */ mflo $t7 +/* f0f6e9c: 02cf3821 */ addu $a3,$s6,$t7 +/* f0f6ea0: 8cf80488 */ lw $t8,0x488($a3) +/* f0f6ea4: afb30024 */ sw $s3,0x24($sp) +/* f0f6ea8: afb20020 */ sw $s2,0x20($sp) +/* f0f6eac: afb1001c */ sw $s1,0x1c($sp) +/* f0f6eb0: afb00018 */ sw $s0,0x18($sp) +/* f0f6eb4: 00006025 */ or $t4,$zero,$zero +/* f0f6eb8: 00004825 */ or $t1,$zero,$zero +/* f0f6ebc: 00004025 */ or $t0,$zero,$zero +/* f0f6ec0: 0000a825 */ or $s5,$zero,$zero +/* f0f6ec4: afa0011c */ sw $zero,0x11c($sp) +/* f0f6ec8: afa700fc */ sw $a3,0xfc($sp) +/* f0f6ecc: 17210005 */ bne $t9,$at,.NB0f0f6ee4 +/* f0f6ed0: afb80100 */ sw $t8,0x100($sp) +/* f0f6ed4: 3c0e800a */ lui $t6,0x800a +/* f0f6ed8: 8dcee94c */ lw $t6,-0x16b4($t6) +/* f0f6edc: 3c01800a */ lui $at,0x800a +/* f0f6ee0: ac2e66a8 */ sw $t6,0x66a8($at) +.NB0f0f6ee4: +/* f0f6ee4: afa80124 */ sw $t0,0x124($sp) +/* f0f6ee8: afa90128 */ sw $t1,0x128($sp) +/* f0f6eec: 0fc3b809 */ jal func0f0f1418 +/* f0f6ef0: afac012c */ sw $t4,0x12c($sp) +/* f0f6ef4: 8eef0000 */ lw $t7,0x0($s7) +/* f0f6ef8: 8fa80124 */ lw $t0,0x124($sp) +/* f0f6efc: 8fa90128 */ lw $t1,0x128($sp) +/* f0f6f00: 01fe0019 */ multu $t7,$s8 +/* f0f6f04: 8fac012c */ lw $t4,0x12c($sp) +/* f0f6f08: a3a00106 */ sb $zero,0x106($sp) +/* f0f6f0c: a3a00107 */ sb $zero,0x107($sp) +/* f0f6f10: a3a0010a */ sb $zero,0x10a($sp) +/* f0f6f14: a3a0010b */ sb $zero,0x10b($sp) +/* f0f6f18: 00005025 */ or $t2,$zero,$zero +/* f0f6f1c: 00005825 */ or $t3,$zero,$zero +/* f0f6f20: 3c0f800a */ lui $t7,0x800a +/* f0f6f24: 0000c012 */ mflo $t8 +/* f0f6f28: 02d8c821 */ addu $t9,$s6,$t8 +/* f0f6f2c: 8f2e0488 */ lw $t6,0x488($t9) +/* f0f6f30: 51c0031e */ beqzl $t6,.NB0f0f7bac +/* f0f6f34: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f6f38: 8def5eb4 */ lw $t7,0x5eb4($t7) +/* f0f6f3c: 24010007 */ addiu $at,$zero,0x7 +/* f0f6f40: afa000f8 */ sw $zero,0xf8($sp) +/* f0f6f44: 15e1000b */ bne $t7,$at,.NB0f0f6f74 +/* f0f6f48: afa000ec */ sw $zero,0xec($sp) +/* f0f6f4c: 24180001 */ addiu $t8,$zero,0x1 +/* f0f6f50: 24190002 */ addiu $t9,$zero,0x2 +/* f0f6f54: 240e0003 */ addiu $t6,$zero,0x3 +/* f0f6f58: 240f0004 */ addiu $t7,$zero,0x4 +/* f0f6f5c: afa000d8 */ sw $zero,0xd8($sp) +/* f0f6f60: afb800dc */ sw $t8,0xdc($sp) +/* f0f6f64: afb900e0 */ sw $t9,0xe0($sp) +/* f0f6f68: afae00e4 */ sw $t6,0xe4($sp) +/* f0f6f6c: 1000001b */ beqz $zero,.NB0f0f6fdc +/* f0f6f70: afaf00ec */ sw $t7,0xec($sp) +.NB0f0f6f74: +/* f0f6f74: 27a400d7 */ addiu $a0,$sp,0xd7 +/* f0f6f78: 27a500d6 */ addiu $a1,$sp,0xd6 +/* f0f6f7c: afa80124 */ sw $t0,0x124($sp) +/* f0f6f80: afa90128 */ sw $t1,0x128($sp) +/* f0f6f84: afaa00f4 */ sw $t2,0xf4($sp) +/* f0f6f88: afab00f0 */ sw $t3,0xf0($sp) +/* f0f6f8c: 0fc3cf88 */ jal func0f0f74a8 +/* f0f6f90: afac012c */ sw $t4,0x12c($sp) +/* f0f6f94: 83a200d7 */ lb $v0,0xd7($sp) +/* f0f6f98: 8fa80124 */ lw $t0,0x124($sp) +/* f0f6f9c: 8fa90128 */ lw $t1,0x128($sp) +/* f0f6fa0: 8faa00f4 */ lw $t2,0xf4($sp) +/* f0f6fa4: 8fab00f0 */ lw $t3,0xf0($sp) +/* f0f6fa8: 04400004 */ bltz $v0,.NB0f0f6fbc +/* f0f6fac: 8fac012c */ lw $t4,0x12c($sp) +/* f0f6fb0: 24030001 */ addiu $v1,$zero,0x1 +/* f0f6fb4: afa200d8 */ sw $v0,0xd8($sp) +/* f0f6fb8: afa300ec */ sw $v1,0xec($sp) +.NB0f0f6fbc: +/* f0f6fbc: 83a200d6 */ lb $v0,0xd6($sp) +/* f0f6fc0: 8fa300ec */ lw $v1,0xec($sp) +/* f0f6fc4: 04400005 */ bltz $v0,.NB0f0f6fdc +/* f0f6fc8: 0003c080 */ sll $t8,$v1,0x2 +/* f0f6fcc: 03b8c821 */ addu $t9,$sp,$t8 +/* f0f6fd0: af2200d8 */ sw $v0,0xd8($t9) +/* f0f6fd4: 24630001 */ addiu $v1,$v1,0x1 +/* f0f6fd8: afa300ec */ sw $v1,0xec($sp) +.NB0f0f6fdc: +/* f0f6fdc: 8eee0000 */ lw $t6,0x0($s7) +/* f0f6fe0: 01de0019 */ multu $t6,$s8 +/* f0f6fe4: 00007812 */ mflo $t7 +/* f0f6fe8: 02cf3821 */ addu $a3,$s6,$t7 +/* f0f6fec: 90e20d9d */ lbu $v0,0xd9d($a3) +/* f0f6ff0: 1840001a */ blez $v0,.NB0f0f705c +/* f0f6ff4: 2458ffff */ addiu $t8,$v0,-1 +/* f0f6ff8: 331900ff */ andi $t9,$t8,0xff +/* f0f6ffc: 17200014 */ bnez $t9,.NB0f0f7050 +/* f0f7000: a0f80d9d */ sb $t8,0xd9d($a3) +/* f0f7004: 8cee0da4 */ lw $t6,0xda4($a3) +/* f0f7008: 8cef0da8 */ lw $t7,0xda8($a3) +/* f0f700c: 27a400cc */ addiu $a0,$sp,0xcc +/* f0f7010: 2405ffff */ addiu $a1,$zero,-1 +/* f0f7014: 00003025 */ or $a2,$zero,$zero +/* f0f7018: afa80124 */ sw $t0,0x124($sp) +/* f0f701c: afa90128 */ sw $t1,0x128($sp) +/* f0f7020: afaa00f4 */ sw $t2,0xf4($sp) +/* f0f7024: afab00f0 */ sw $t3,0xf0($sp) +/* f0f7028: afac012c */ sw $t4,0x12c($sp) +/* f0f702c: afae00cc */ sw $t6,0xcc($sp) +/* f0f7030: 0fc41358 */ jal filemgrSaveOrLoad +/* f0f7034: a7af00d0 */ sh $t7,0xd0($sp) +/* f0f7038: 8fa80124 */ lw $t0,0x124($sp) +/* f0f703c: 8fa90128 */ lw $t1,0x128($sp) +/* f0f7040: 8faa00f4 */ lw $t2,0xf4($sp) +/* f0f7044: 8fab00f0 */ lw $t3,0xf0($sp) +/* f0f7048: 10000004 */ beqz $zero,.NB0f0f705c +/* f0f704c: 8fac012c */ lw $t4,0x12c($sp) +.NB0f0f7050: +/* f0f7050: 90f90d9c */ lbu $t9,0xd9c($a3) +/* f0f7054: 372e0080 */ ori $t6,$t9,0x80 +/* f0f7058: a0ee0d9c */ sb $t6,0xd9c($a3) +.NB0f0f705c: +/* f0f705c: 8faf00ec */ lw $t7,0xec($sp) +/* f0f7060: 0000a025 */ or $s4,$zero,$zero +/* f0f7064: 19e00083 */ blez $t7,.NB0f0f7274 +/* f0f7068: 27b300d8 */ addiu $s3,$sp,0xd8 +.NB0f0f706c: +/* f0f706c: 82640003 */ lb $a0,0x3($s3) +/* f0f7070: afac012c */ sw $t4,0x12c($sp) +/* f0f7074: afab00f0 */ sw $t3,0xf0($sp) +/* f0f7078: afaa00f4 */ sw $t2,0xf4($sp) +/* f0f707c: afa90128 */ sw $t1,0x128($sp) +/* f0f7080: 0c00573c */ jal joyGetStickX +/* f0f7084: afa80124 */ sw $t0,0x124($sp) +/* f0f7088: 00028600 */ sll $s0,$v0,0x18 +/* f0f708c: 0010c603 */ sra $t8,$s0,0x18 +/* f0f7090: 03008025 */ or $s0,$t8,$zero +/* f0f7094: 0c005766 */ jal joyGetStickY +/* f0f7098: 82640003 */ lb $a0,0x3($s3) +/* f0f709c: 00028e00 */ sll $s1,$v0,0x18 +/* f0f70a0: 0011ce03 */ sra $t9,$s1,0x18 +/* f0f70a4: 03208825 */ or $s1,$t9,$zero +/* f0f70a8: 82640003 */ lb $a0,0x3($s3) +/* f0f70ac: 0c005790 */ jal joyGetButtons +/* f0f70b0: 3405ffff */ dli $a1,0xffff +/* f0f70b4: 3052ffff */ andi $s2,$v0,0xffff +/* f0f70b8: 82640003 */ lb $a0,0x3($s3) +/* f0f70bc: 0c0057c0 */ jal joyGetButtonsPressedThisFrame +/* f0f70c0: 3405ffff */ dli $a1,0xffff +/* f0f70c4: 304e8000 */ andi $t6,$v0,0x8000 +/* f0f70c8: 8fa80124 */ lw $t0,0x124($sp) +/* f0f70cc: 8fa90128 */ lw $t1,0x128($sp) +/* f0f70d0: 8faa00f4 */ lw $t2,0xf4($sp) +/* f0f70d4: 8fab00f0 */ lw $t3,0xf0($sp) +/* f0f70d8: 8fac012c */ lw $t4,0x12c($sp) +/* f0f70dc: 11c00003 */ beqz $t6,.NB0f0f70ec +/* f0f70e0: 00403025 */ or $a2,$v0,$zero +/* f0f70e4: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f70e8: a3af0106 */ sb $t7,0x106($sp) +.NB0f0f70ec: +/* f0f70ec: 30d84000 */ andi $t8,$a2,0x4000 +/* f0f70f0: 13000003 */ beqz $t8,.NB0f0f7100 +/* f0f70f4: 30ce2000 */ andi $t6,$a2,0x2000 +/* f0f70f8: 24190001 */ addiu $t9,$zero,0x1 +/* f0f70fc: a3b90107 */ sb $t9,0x107($sp) +.NB0f0f7100: +/* f0f7100: 11c00003 */ beqz $t6,.NB0f0f7110 +/* f0f7104: 30d81000 */ andi $t8,$a2,0x1000 +/* f0f7108: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f710c: a3af0106 */ sb $t7,0x106($sp) +.NB0f0f7110: +/* f0f7110: 13000003 */ beqz $t8,.NB0f0f7120 +/* f0f7114: 324e0010 */ andi $t6,$s2,0x10 +/* f0f7118: 24190001 */ addiu $t9,$zero,0x1 +/* f0f711c: afb900f8 */ sw $t9,0xf8($sp) +.NB0f0f7120: +/* f0f7120: 11c00003 */ beqz $t6,.NB0f0f7130 +/* f0f7124: 02402825 */ or $a1,$s2,$zero +/* f0f7128: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f712c: a3af010a */ sb $t7,0x10a($sp) +.NB0f0f7130: +/* f0f7130: 30b80020 */ andi $t8,$a1,0x20 +/* f0f7134: 13000003 */ beqz $t8,.NB0f0f7144 +/* f0f7138: 30ae0008 */ andi $t6,$a1,0x8 +/* f0f713c: 24190001 */ addiu $t9,$zero,0x1 +/* f0f7140: a3b9010a */ sb $t9,0x10a($sp) +.NB0f0f7144: +/* f0f7144: 05410003 */ bgez $t2,.NB0f0f7154 +/* f0f7148: 30cf0008 */ andi $t7,$a2,0x8 +/* f0f714c: 10000002 */ beqz $zero,.NB0f0f7158 +/* f0f7150: 000a2023 */ negu $a0,$t2 +.NB0f0f7154: +/* f0f7154: 01402025 */ or $a0,$t2,$zero +.NB0f0f7158: +/* f0f7158: 06010003 */ bgez $s0,.NB0f0f7168 +/* f0f715c: 30b80004 */ andi $t8,$a1,0x4 +/* f0f7160: 10000002 */ beqz $zero,.NB0f0f716c +/* f0f7164: 00101823 */ negu $v1,$s0 +.NB0f0f7168: +/* f0f7168: 02001825 */ or $v1,$s0,$zero +.NB0f0f716c: +/* f0f716c: 0083082a */ slt $at,$a0,$v1 +/* f0f7170: 10200002 */ beqz $at,.NB0f0f717c +/* f0f7174: 30d90004 */ andi $t9,$a2,0x4 +/* f0f7178: 02005025 */ or $t2,$s0,$zero +.NB0f0f717c: +/* f0f717c: 05610003 */ bgez $t3,.NB0f0f718c +/* f0f7180: 01602025 */ or $a0,$t3,$zero +/* f0f7184: 10000001 */ beqz $zero,.NB0f0f718c +/* f0f7188: 000b2023 */ negu $a0,$t3 +.NB0f0f718c: +/* f0f718c: 06210003 */ bgez $s1,.NB0f0f719c +/* f0f7190: 02201825 */ or $v1,$s1,$zero +/* f0f7194: 10000001 */ beqz $zero,.NB0f0f719c +/* f0f7198: 00111823 */ negu $v1,$s1 +.NB0f0f719c: +/* f0f719c: 0083082a */ slt $at,$a0,$v1 +/* f0f71a0: 10200002 */ beqz $at,.NB0f0f71ac +/* f0f71a4: 00000000 */ sll $zero,$zero,0x0 +/* f0f71a8: 02205825 */ or $t3,$s1,$zero +.NB0f0f71ac: +/* f0f71ac: 11c00002 */ beqz $t6,.NB0f0f71b8 +/* f0f71b0: 00000000 */ sll $zero,$zero,0x0 +/* f0f71b4: 240cffff */ addiu $t4,$zero,-1 +.NB0f0f71b8: +/* f0f71b8: 11e00002 */ beqz $t7,.NB0f0f71c4 +/* f0f71bc: 30ae0002 */ andi $t6,$a1,0x2 +/* f0f71c0: 2408ffff */ addiu $t0,$zero,-1 +.NB0f0f71c4: +/* f0f71c4: 13000002 */ beqz $t8,.NB0f0f71d0 +/* f0f71c8: 30cf0002 */ andi $t7,$a2,0x2 +/* f0f71cc: 240c0001 */ addiu $t4,$zero,0x1 +.NB0f0f71d0: +/* f0f71d0: 13200002 */ beqz $t9,.NB0f0f71dc +/* f0f71d4: 30b80001 */ andi $t8,$a1,0x1 +/* f0f71d8: 24080001 */ addiu $t0,$zero,0x1 +.NB0f0f71dc: +/* f0f71dc: 11c00002 */ beqz $t6,.NB0f0f71e8 +/* f0f71e0: 30d90001 */ andi $t9,$a2,0x1 +/* f0f71e4: 2409ffff */ addiu $t1,$zero,-1 +.NB0f0f71e8: +/* f0f71e8: 11e00002 */ beqz $t7,.NB0f0f71f4 +/* f0f71ec: 30ae0800 */ andi $t6,$a1,0x800 +/* f0f71f0: 2415ffff */ addiu $s5,$zero,-1 +.NB0f0f71f4: +/* f0f71f4: 13000002 */ beqz $t8,.NB0f0f7200 +/* f0f71f8: 30cf0800 */ andi $t7,$a2,0x800 +/* f0f71fc: 24090001 */ addiu $t1,$zero,0x1 +.NB0f0f7200: +/* f0f7200: 13200002 */ beqz $t9,.NB0f0f720c +/* f0f7204: 30b80400 */ andi $t8,$a1,0x400 +/* f0f7208: 24150001 */ addiu $s5,$zero,0x1 +.NB0f0f720c: +/* f0f720c: 11c00002 */ beqz $t6,.NB0f0f7218 +/* f0f7210: 30d90400 */ andi $t9,$a2,0x400 +/* f0f7214: 240cffff */ addiu $t4,$zero,-1 +.NB0f0f7218: +/* f0f7218: 11e00002 */ beqz $t7,.NB0f0f7224 +/* f0f721c: 30ae0200 */ andi $t6,$a1,0x200 +/* f0f7220: 2408ffff */ addiu $t0,$zero,-1 +.NB0f0f7224: +/* f0f7224: 13000002 */ beqz $t8,.NB0f0f7230 +/* f0f7228: 30cf0200 */ andi $t7,$a2,0x200 +/* f0f722c: 240c0001 */ addiu $t4,$zero,0x1 +.NB0f0f7230: +/* f0f7230: 13200002 */ beqz $t9,.NB0f0f723c +/* f0f7234: 30b80100 */ andi $t8,$a1,0x100 +/* f0f7238: 24080001 */ addiu $t0,$zero,0x1 +.NB0f0f723c: +/* f0f723c: 11c00002 */ beqz $t6,.NB0f0f7248 +/* f0f7240: 30d90100 */ andi $t9,$a2,0x100 +/* f0f7244: 2409ffff */ addiu $t1,$zero,-1 +.NB0f0f7248: +/* f0f7248: 11e00002 */ beqz $t7,.NB0f0f7254 +/* f0f724c: 8fae00ec */ lw $t6,0xec($sp) +/* f0f7250: 2415ffff */ addiu $s5,$zero,-1 +.NB0f0f7254: +/* f0f7254: 13000002 */ beqz $t8,.NB0f0f7260 +/* f0f7258: 26940001 */ addiu $s4,$s4,0x1 +/* f0f725c: 24090001 */ addiu $t1,$zero,0x1 +.NB0f0f7260: +/* f0f7260: 13200002 */ beqz $t9,.NB0f0f726c +/* f0f7264: 00000000 */ sll $zero,$zero,0x0 +/* f0f7268: 24150001 */ addiu $s5,$zero,0x1 +.NB0f0f726c: +/* f0f726c: 168eff7f */ bne $s4,$t6,.NB0f0f706c +/* f0f7270: 26730004 */ addiu $s3,$s3,0x4 +.NB0f0f7274: +/* f0f7274: 8eef0000 */ lw $t7,0x0($s7) +/* f0f7278: 93ae0106 */ lbu $t6,0x106($sp) +/* f0f727c: 2410000a */ addiu $s0,$zero,0xa +/* f0f7280: 000fc0c0 */ sll $t8,$t7,0x3 +/* f0f7284: 030fc023 */ subu $t8,$t8,$t7 +/* f0f7288: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0f728c: 030fc023 */ subu $t8,$t8,$t7 +/* f0f7290: 0018c100 */ sll $t8,$t8,0x4 +/* f0f7294: 030fc023 */ subu $t8,$t8,$t7 +/* f0f7298: 0018c080 */ sll $t8,$t8,0x2 +/* f0f729c: 02d8c821 */ addu $t9,$s6,$t8 +/* f0f72a0: 11c00002 */ beqz $t6,.NB0f0f72ac +/* f0f72a4: 8f240488 */ lw $a0,0x488($t9) +/* f0f72a8: a3a00107 */ sb $zero,0x107($sp) +.NB0f0f72ac: +/* f0f72ac: 11000002 */ beqz $t0,.NB0f0f72b8 +/* f0f72b0: 2406001e */ addiu $a2,$zero,0x1e +/* f0f72b4: 01006025 */ or $t4,$t0,$zero +.NB0f0f72b8: +/* f0f72b8: 12a00002 */ beqz $s5,.NB0f0f72c4 +/* f0f72bc: 2413003c */ addiu $s3,$zero,0x3c +/* f0f72c0: 02a04825 */ or $t1,$s5,$zero +.NB0f0f72c4: +/* f0f72c4: 24110021 */ addiu $s1,$zero,0x21 +/* f0f72c8: 2414002c */ addiu $s4,$zero,0x2c +/* f0f72cc: 10800019 */ beqz $a0,.NB0f0f7334 +/* f0f72d0: 00009025 */ or $s2,$zero,$zero +/* f0f72d4: 8c820008 */ lw $v0,0x8($a0) +/* f0f72d8: 10400016 */ beqz $v0,.NB0f0f7334 +/* f0f72dc: 00000000 */ sll $zero,$zero,0x0 +/* f0f72e0: 90430000 */ lbu $v1,0x0($v0) +/* f0f72e4: 24010008 */ addiu $at,$zero,0x8 +/* f0f72e8: 10610003 */ beq $v1,$at,.NB0f0f72f8 +/* f0f72ec: 24010010 */ addiu $at,$zero,0x10 +/* f0f72f0: 54610009 */ bnel $v1,$at,.NB0f0f7318 +/* f0f72f4: 2401000d */ addiu $at,$zero,0xd +.NB0f0f72f8: +/* f0f72f8: 8c8f000c */ lw $t7,0xc($a0) +/* f0f72fc: 51e00006 */ beqzl $t7,.NB0f0f7318 +/* f0f7300: 2401000d */ addiu $at,$zero,0xd +/* f0f7304: 24100005 */ addiu $s0,$zero,0x5 +/* f0f7308: 24060014 */ addiu $a2,$zero,0x14 +/* f0f730c: 2413001e */ addiu $s3,$zero,0x1e +/* f0f7310: 2411000a */ addiu $s1,$zero,0xa +/* f0f7314: 2401000d */ addiu $at,$zero,0xd +.NB0f0f7318: +/* f0f7318: 14610006 */ bne $v1,$at,.NB0f0f7334 +/* f0f731c: 00000000 */ sll $zero,$zero,0x0 +/* f0f7320: 24120001 */ addiu $s2,$zero,0x1 +/* f0f7324: 24100005 */ addiu $s0,$zero,0x5 +/* f0f7328: 24060014 */ addiu $a2,$zero,0x14 +/* f0f732c: 2411000a */ addiu $s1,$zero,0xa +/* f0f7330: 2414000a */ addiu $s4,$zero,0xa +.NB0f0f7334: +/* f0f7334: 15200004 */ bnez $t1,.NB0f0f7348 +/* f0f7338: 0000f825 */ or $ra,$zero,$zero +/* f0f733c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7340: 2418ffff */ addiu $t8,$zero,-1 +/* f0f7344: a4780788 */ sh $t8,0x788($v1) +.NB0f0f7348: +/* f0f7348: 12a00006 */ beqz $s5,.NB0f0f7364 +/* f0f734c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7350: a4600788 */ sh $zero,0x788($v1) +/* f0f7354: ac600780 */ sw $zero,0x780($v1) +/* f0f7358: a4750786 */ sh $s5,0x786($v1) +/* f0f735c: 10000004 */ beqz $zero,.NB0f0f7370 +/* f0f7360: 241f0001 */ addiu $ra,$zero,0x1 +.NB0f0f7364: +/* f0f7364: 51200003 */ beqzl $t1,.NB0f0f7374 +/* f0f7368: 8c620780 */ lw $v0,0x780($v1) +/* f0f736c: 84690786 */ lh $t1,0x786($v1) +.NB0f0f7370: +/* f0f7370: 8c620780 */ lw $v0,0x780($v1) +.NB0f0f7374: +/* f0f7374: 3c0e800a */ lui $t6,0x800a +/* f0f7378: 2841003d */ slti $at,$v0,0x3d +/* f0f737c: 14200004 */ bnez $at,.NB0f0f7390 +/* f0f7380: 00000000 */ sll $zero,$zero,0x0 +/* f0f7384: 24190001 */ addiu $t9,$zero,0x1 +/* f0f7388: a4790788 */ sh $t9,0x788($v1) +/* f0f738c: 8c620780 */ lw $v0,0x780($v1) +.NB0f0f7390: +/* f0f7390: 0050001a */ div $zero,$v0,$s0 +/* f0f7394: 8dcee6c0 */ lw $t6,-0x1940($t6) +/* f0f7398: 00003812 */ mflo $a3 +/* f0f739c: 84780788 */ lh $t8,0x788($v1) +/* f0f73a0: 004e7821 */ addu $t7,$v0,$t6 +/* f0f73a4: 01f0001a */ div $zero,$t7,$s0 +/* f0f73a8: 16000002 */ bnez $s0,.NB0f0f73b4 +/* f0f73ac: 00000000 */ sll $zero,$zero,0x0 +/* f0f73b0: 0007000d */ break 0x7 +.NB0f0f73b4: +/* f0f73b4: 2401ffff */ addiu $at,$zero,-1 +/* f0f73b8: 16010004 */ bne $s0,$at,.NB0f0f73cc +/* f0f73bc: 3c018000 */ lui $at,0x8000 +/* f0f73c0: 14410002 */ bne $v0,$at,.NB0f0f73cc +/* f0f73c4: 00000000 */ sll $zero,$zero,0x0 +/* f0f73c8: 0006000d */ break 0x6 +.NB0f0f73cc: +/* f0f73cc: 00006812 */ mflo $t5 +/* f0f73d0: 16000002 */ bnez $s0,.NB0f0f73dc +/* f0f73d4: 00000000 */ sll $zero,$zero,0x0 +/* f0f73d8: 0007000d */ break 0x7 +.NB0f0f73dc: +/* f0f73dc: 2401ffff */ addiu $at,$zero,-1 +/* f0f73e0: 16010004 */ bne $s0,$at,.NB0f0f73f4 +/* f0f73e4: 3c018000 */ lui $at,0x8000 +/* f0f73e8: 15e10002 */ bne $t7,$at,.NB0f0f73f4 +/* f0f73ec: 00000000 */ sll $zero,$zero,0x0 +/* f0f73f0: 0006000d */ break 0x6 +.NB0f0f73f4: +/* f0f73f4: 1700000b */ bnez $t8,.NB0f0f7424 +/* f0f73f8: 00000000 */ sll $zero,$zero,0x0 +/* f0f73fc: 04e10003 */ bgez $a3,.NB0f0f740c +/* f0f7400: 0007c843 */ sra $t9,$a3,0x1 +/* f0f7404: 24e10001 */ addiu $at,$a3,0x1 +/* f0f7408: 0001c843 */ sra $t9,$at,0x1 +.NB0f0f740c: +/* f0f740c: 03203825 */ or $a3,$t9,$zero +/* f0f7410: 05a10003 */ bgez $t5,.NB0f0f7420 +/* f0f7414: 000d7043 */ sra $t6,$t5,0x1 +/* f0f7418: 25a10001 */ addiu $at,$t5,0x1 +/* f0f741c: 00017043 */ sra $t6,$at,0x1 +.NB0f0f7420: +/* f0f7420: 01c06825 */ or $t5,$t6,$zero +.NB0f0f7424: +/* f0f7424: 05410003 */ bgez $t2,.NB0f0f7434 +/* f0f7428: a3a9010c */ sb $t1,0x10c($sp) +/* f0f742c: 10000002 */ beqz $zero,.NB0f0f7438 +/* f0f7430: 000a1023 */ negu $v0,$t2 +.NB0f0f7434: +/* f0f7434: 01401025 */ or $v0,$t2,$zero +.NB0f0f7438: +/* f0f7438: 05610003 */ bgez $t3,.NB0f0f7448 +/* f0f743c: 0046082a */ slt $at,$v0,$a2 +/* f0f7440: 10000002 */ beqz $zero,.NB0f0f744c +/* f0f7444: 000b1823 */ negu $v1,$t3 +.NB0f0f7448: +/* f0f7448: 01601825 */ or $v1,$t3,$zero +.NB0f0f744c: +/* f0f744c: 14200065 */ bnez $at,.NB0f0f75e4 +/* f0f7450: 0062082a */ slt $at,$v1,$v0 +/* f0f7454: 14200003 */ bnez $at,.NB0f0f7464 +/* f0f7458: 00000000 */ sll $zero,$zero,0x0 +/* f0f745c: 52400062 */ beqzl $s2,.NB0f0f75e8 +/* f0f7460: 8fb800fc */ lw $t8,0xfc($sp) +.NB0f0f7464: +/* f0f7464: 05410006 */ bgez $t2,.NB0f0f7480 +/* f0f7468: 28410047 */ slti $at,$v0,0x47 +/* f0f746c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7470: 846f0784 */ lh $t7,0x784($v1) +/* f0f7474: 59e00003 */ blezl $t7,.NB0f0f7484 +/* f0f7478: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f747c: a4600784 */ sh $zero,0x784($v1) +.NB0f0f7480: +/* f0f7480: 8fa300fc */ lw $v1,0xfc($sp) +.NB0f0f7484: +/* f0f7484: 19400005 */ blez $t2,.NB0f0f749c +/* f0f7488: 84640784 */ lh $a0,0x784($v1) +/* f0f748c: 04810003 */ bgez $a0,.NB0f0f749c +/* f0f7490: 00000000 */ sll $zero,$zero,0x0 +/* f0f7494: a4600784 */ sh $zero,0x784($v1) +/* f0f7498: 84640784 */ lh $a0,0x784($v1) +.NB0f0f749c: +/* f0f749c: 14800003 */ bnez $a0,.NB0f0f74ac +/* f0f74a0: 00000000 */ sll $zero,$zero,0x0 +/* f0f74a4: ac600780 */ sw $zero,0x780($v1) +/* f0f74a8: 84640784 */ lh $a0,0x784($v1) +.NB0f0f74ac: +/* f0f74ac: 54200003 */ bnezl $at,.NB0f0f74bc +/* f0f74b0: 00461023 */ subu $v0,$v0,$a2 +/* f0f74b4: 24020046 */ addiu $v0,$zero,0x46 +/* f0f74b8: 00461023 */ subu $v0,$v0,$a2 +.NB0f0f74bc: +/* f0f74bc: 02220019 */ multu $s1,$v0 +/* f0f74c0: 24190046 */ addiu $t9,$zero,0x46 +/* f0f74c4: 03267023 */ subu $t6,$t9,$a2 +/* f0f74c8: 0000c012 */ mflo $t8 +/* f0f74cc: 00000000 */ sll $zero,$zero,0x0 +/* f0f74d0: 00000000 */ sll $zero,$zero,0x0 +/* f0f74d4: 030e001a */ div $zero,$t8,$t6 +/* f0f74d8: 15c00002 */ bnez $t6,.NB0f0f74e4 +/* f0f74dc: 00000000 */ sll $zero,$zero,0x0 +/* f0f74e0: 0007000d */ break 0x7 +.NB0f0f74e4: +/* f0f74e4: 2401ffff */ addiu $at,$zero,-1 +/* f0f74e8: 15c10004 */ bne $t6,$at,.NB0f0f74fc +/* f0f74ec: 3c018000 */ lui $at,0x8000 +/* f0f74f0: 17010002 */ bne $t8,$at,.NB0f0f74fc +/* f0f74f4: 00000000 */ sll $zero,$zero,0x0 +/* f0f74f8: 0006000d */ break 0x6 +.NB0f0f74fc: +/* f0f74fc: 00007812 */ mflo $t7 +/* f0f7500: 026f2823 */ subu $a1,$s3,$t7 +/* f0f7504: 28810003 */ slti $at,$a0,0x3 +/* f0f7508: 10200004 */ beqz $at,.NB0f0f751c +/* f0f750c: 00a01825 */ or $v1,$a1,$zero +/* f0f7510: 2881fffe */ slti $at,$a0,-2 +/* f0f7514: 10200005 */ beqz $at,.NB0f0f752c +/* f0f7518: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f751c: +/* f0f751c: 04a10003 */ bgez $a1,.NB0f0f752c +/* f0f7520: 00051843 */ sra $v1,$a1,0x1 +/* f0f7524: 24a10001 */ addiu $at,$a1,0x1 +/* f0f7528: 00011843 */ sra $v1,$at,0x1 +.NB0f0f752c: +/* f0f752c: 1860002f */ blez $v1,.NB0f0f75ec +/* f0f7530: 00000000 */ sll $zero,$zero,0x0 +/* f0f7534: 8fb900fc */ lw $t9,0xfc($sp) +/* f0f7538: 3c18800a */ lui $t8,0x800a +/* f0f753c: 8f18e6c0 */ lw $t8,-0x1940($t8) +/* f0f7540: 8f220780 */ lw $v0,0x780($t9) +/* f0f7544: 24090001 */ addiu $t1,$zero,0x1 +/* f0f7548: 0043001a */ div $zero,$v0,$v1 +/* f0f754c: 00587021 */ addu $t6,$v0,$t8 +/* f0f7550: 00003812 */ mflo $a3 +/* f0f7554: 14600002 */ bnez $v1,.NB0f0f7560 +/* f0f7558: 00000000 */ sll $zero,$zero,0x0 +/* f0f755c: 0007000d */ break 0x7 +.NB0f0f7560: +/* f0f7560: 2401ffff */ addiu $at,$zero,-1 +/* f0f7564: 14610004 */ bne $v1,$at,.NB0f0f7578 +/* f0f7568: 3c018000 */ lui $at,0x8000 +/* f0f756c: 14410002 */ bne $v0,$at,.NB0f0f7578 +/* f0f7570: 00000000 */ sll $zero,$zero,0x0 +/* f0f7574: 0006000d */ break 0x6 +.NB0f0f7578: +/* f0f7578: 01c3001a */ div $zero,$t6,$v1 +/* f0f757c: 00006812 */ mflo $t5 +/* f0f7580: 14600002 */ bnez $v1,.NB0f0f758c +/* f0f7584: 00000000 */ sll $zero,$zero,0x0 +/* f0f7588: 0007000d */ break 0x7 +.NB0f0f758c: +/* f0f758c: 2401ffff */ addiu $at,$zero,-1 +/* f0f7590: 14610004 */ bne $v1,$at,.NB0f0f75a4 +/* f0f7594: 3c018000 */ lui $at,0x8000 +/* f0f7598: 15c10002 */ bne $t6,$at,.NB0f0f75a4 +/* f0f759c: 00000000 */ sll $zero,$zero,0x0 +/* f0f75a0: 0006000d */ break 0x6 +.NB0f0f75a4: +/* f0f75a4: 05410003 */ bgez $t2,.NB0f0f75b4 +/* f0f75a8: 00000000 */ sll $zero,$zero,0x0 +/* f0f75ac: 10000001 */ beqz $zero,.NB0f0f75b4 +/* f0f75b0: 2409ffff */ addiu $t1,$zero,-1 +.NB0f0f75b4: +/* f0f75b4: 10ed0002 */ beq $a3,$t5,.NB0f0f75c0 +/* f0f75b8: 00000000 */ sll $zero,$zero,0x0 +/* f0f75bc: 241f0001 */ addiu $ra,$zero,0x1 +.NB0f0f75c0: +/* f0f75c0: 14800002 */ bnez $a0,.NB0f0f75cc +/* f0f75c4: 00000000 */ sll $zero,$zero,0x0 +/* f0f75c8: 241f0001 */ addiu $ra,$zero,0x1 +.NB0f0f75cc: +/* f0f75cc: 13e00007 */ beqz $ra,.NB0f0f75ec +/* f0f75d0: 00000000 */ sll $zero,$zero,0x0 +/* f0f75d4: 8fb900fc */ lw $t9,0xfc($sp) +/* f0f75d8: 00897821 */ addu $t7,$a0,$t1 +/* f0f75dc: 10000003 */ beqz $zero,.NB0f0f75ec +/* f0f75e0: a72f0784 */ sh $t7,0x784($t9) +.NB0f0f75e4: +/* f0f75e4: 8fb800fc */ lw $t8,0xfc($sp) +.NB0f0f75e8: +/* f0f75e8: a7000784 */ sh $zero,0x784($t8) +.NB0f0f75ec: +/* f0f75ec: 10ed0002 */ beq $a3,$t5,.NB0f0f75f8 +/* f0f75f0: 3c19800a */ lui $t9,0x800a +/* f0f75f4: 241f0001 */ addiu $ra,$zero,0x1 +.NB0f0f75f8: +/* f0f75f8: 17e00002 */ bnez $ra,.NB0f0f7604 +/* f0f75fc: 00000000 */ sll $zero,$zero,0x0 +/* f0f7600: 00004825 */ or $t1,$zero,$zero +.NB0f0f7604: +/* f0f7604: 11000007 */ beqz $t0,.NB0f0f7624 +/* f0f7608: 00006825 */ or $t5,$zero,$zero +/* f0f760c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7610: 240d0001 */ addiu $t5,$zero,0x1 +/* f0f7614: a4600794 */ sh $zero,0x794($v1) +/* f0f7618: ac60078c */ sw $zero,0x78c($v1) +/* f0f761c: 10000005 */ beqz $zero,.NB0f0f7634 +/* f0f7620: a4680792 */ sh $t0,0x792($v1) +.NB0f0f7624: +/* f0f7624: 51800004 */ beqzl $t4,.NB0f0f7638 +/* f0f7628: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f762c: 8fae00fc */ lw $t6,0xfc($sp) +/* f0f7630: 85cc0792 */ lh $t4,0x792($t6) +.NB0f0f7634: +/* f0f7634: 8fa300fc */ lw $v1,0xfc($sp) +.NB0f0f7638: +/* f0f7638: 8c62078c */ lw $v0,0x78c($v1) +/* f0f763c: 2841003d */ slti $at,$v0,0x3d +/* f0f7640: 14200004 */ bnez $at,.NB0f0f7654 +/* f0f7644: 00000000 */ sll $zero,$zero,0x0 +/* f0f7648: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f764c: a46f0794 */ sh $t7,0x794($v1) +/* f0f7650: 8c62078c */ lw $v0,0x78c($v1) +.NB0f0f7654: +/* f0f7654: 0050001a */ div $zero,$v0,$s0 +/* f0f7658: 8f39e6c0 */ lw $t9,-0x1940($t9) +/* f0f765c: 00003812 */ mflo $a3 +/* f0f7660: 846e0794 */ lh $t6,0x794($v1) +/* f0f7664: 0059c021 */ addu $t8,$v0,$t9 +/* f0f7668: 0310001a */ div $zero,$t8,$s0 +/* f0f766c: 16000002 */ bnez $s0,.NB0f0f7678 +/* f0f7670: 00000000 */ sll $zero,$zero,0x0 +/* f0f7674: 0007000d */ break 0x7 +.NB0f0f7678: +/* f0f7678: 2401ffff */ addiu $at,$zero,-1 +/* f0f767c: 16010004 */ bne $s0,$at,.NB0f0f7690 +/* f0f7680: 3c018000 */ lui $at,0x8000 +/* f0f7684: 14410002 */ bne $v0,$at,.NB0f0f7690 +/* f0f7688: 00000000 */ sll $zero,$zero,0x0 +/* f0f768c: 0006000d */ break 0x6 +.NB0f0f7690: +/* f0f7690: 00004012 */ mflo $t0 +/* f0f7694: 01601025 */ or $v0,$t3,$zero +/* f0f7698: 16000002 */ bnez $s0,.NB0f0f76a4 +/* f0f769c: 00000000 */ sll $zero,$zero,0x0 +/* f0f76a0: 0007000d */ break 0x7 +.NB0f0f76a4: +/* f0f76a4: 2401ffff */ addiu $at,$zero,-1 +/* f0f76a8: 16010004 */ bne $s0,$at,.NB0f0f76bc +/* f0f76ac: 3c018000 */ lui $at,0x8000 +/* f0f76b0: 17010002 */ bne $t8,$at,.NB0f0f76bc +/* f0f76b4: 00000000 */ sll $zero,$zero,0x0 +/* f0f76b8: 0006000d */ break 0x6 +.NB0f0f76bc: +/* f0f76bc: 15c0000b */ bnez $t6,.NB0f0f76ec +/* f0f76c0: 00000000 */ sll $zero,$zero,0x0 +/* f0f76c4: 04e10003 */ bgez $a3,.NB0f0f76d4 +/* f0f76c8: 00077843 */ sra $t7,$a3,0x1 +/* f0f76cc: 24e10001 */ addiu $at,$a3,0x1 +/* f0f76d0: 00017843 */ sra $t7,$at,0x1 +.NB0f0f76d4: +/* f0f76d4: 01e03825 */ or $a3,$t7,$zero +/* f0f76d8: 05010003 */ bgez $t0,.NB0f0f76e8 +/* f0f76dc: 0008c843 */ sra $t9,$t0,0x1 +/* f0f76e0: 25010001 */ addiu $at,$t0,0x1 +/* f0f76e4: 0001c843 */ sra $t9,$at,0x1 +.NB0f0f76e8: +/* f0f76e8: 03204025 */ or $t0,$t9,$zero +.NB0f0f76ec: +/* f0f76ec: 05610003 */ bgez $t3,.NB0f0f76fc +/* f0f76f0: a3ac010d */ sb $t4,0x10d($sp) +/* f0f76f4: 10000001 */ beqz $zero,.NB0f0f76fc +/* f0f76f8: 000b1023 */ negu $v0,$t3 +.NB0f0f76fc: +/* f0f76fc: 05410003 */ bgez $t2,.NB0f0f770c +/* f0f7700: 28410014 */ slti $at,$v0,0x14 +/* f0f7704: 10000002 */ beqz $zero,.NB0f0f7710 +/* f0f7708: 000a1823 */ negu $v1,$t2 +.NB0f0f770c: +/* f0f770c: 01401825 */ or $v1,$t2,$zero +.NB0f0f7710: +/* f0f7710: 1420005d */ bnez $at,.NB0f0f7888 +/* f0f7714: 0062082a */ slt $at,$v1,$v0 +/* f0f7718: 14200003 */ bnez $at,.NB0f0f7728 +/* f0f771c: 3c06800a */ lui $a2,0x800a +/* f0f7720: 5240005a */ beqzl $s2,.NB0f0f788c +/* f0f7724: 8fa300fc */ lw $v1,0xfc($sp) +.NB0f0f7728: +/* f0f7728: 05610006 */ bgez $t3,.NB0f0f7744 +/* f0f772c: 28410047 */ slti $at,$v0,0x47 +/* f0f7730: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7734: 84780790 */ lh $t8,0x790($v1) +/* f0f7738: 07030003 */ bgezl $t8,.NB0f0f7748 +/* f0f773c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7740: a4600790 */ sh $zero,0x790($v1) +.NB0f0f7744: +/* f0f7744: 8fa300fc */ lw $v1,0xfc($sp) +.NB0f0f7748: +/* f0f7748: 19600005 */ blez $t3,.NB0f0f7760 +/* f0f774c: 84640790 */ lh $a0,0x790($v1) +/* f0f7750: 18800003 */ blez $a0,.NB0f0f7760 +/* f0f7754: 00000000 */ sll $zero,$zero,0x0 +/* f0f7758: a4600790 */ sh $zero,0x790($v1) +/* f0f775c: 84640790 */ lh $a0,0x790($v1) +.NB0f0f7760: +/* f0f7760: 14800003 */ bnez $a0,.NB0f0f7770 +/* f0f7764: 00000000 */ sll $zero,$zero,0x0 +/* f0f7768: ac60078c */ sw $zero,0x78c($v1) +/* f0f776c: 84640790 */ lh $a0,0x790($v1) +.NB0f0f7770: +/* f0f7770: 14200002 */ bnez $at,.NB0f0f777c +/* f0f7774: 8cc6e6c0 */ lw $a2,-0x1940($a2) +/* f0f7778: 24020046 */ addiu $v0,$zero,0x46 +.NB0f0f777c: +/* f0f777c: 2442ffec */ addiu $v0,$v0,-20 +/* f0f7780: 02820019 */ multu $s4,$v0 +/* f0f7784: 24010032 */ addiu $at,$zero,0x32 +/* f0f7788: 8fb900fc */ lw $t9,0xfc($sp) +/* f0f778c: 00007012 */ mflo $t6 +/* f0f7790: 00000000 */ sll $zero,$zero,0x0 +/* f0f7794: 00000000 */ sll $zero,$zero,0x0 +/* f0f7798: 01c1001a */ div $zero,$t6,$at +/* f0f779c: 00007812 */ mflo $t7 +/* f0f77a0: 026f2823 */ subu $a1,$s3,$t7 +/* f0f77a4: 28810003 */ slti $at,$a0,0x3 +/* f0f77a8: 10200004 */ beqz $at,.NB0f0f77bc +/* f0f77ac: 00a01825 */ or $v1,$a1,$zero +/* f0f77b0: 2881fffe */ slti $at,$a0,-2 +/* f0f77b4: 10200006 */ beqz $at,.NB0f0f77d0 +/* f0f77b8: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f77bc: +/* f0f77bc: 24010003 */ addiu $at,$zero,0x3 +/* f0f77c0: 00a1001a */ div $zero,$a1,$at +/* f0f77c4: 00001812 */ mflo $v1 +/* f0f77c8: 00000000 */ sll $zero,$zero,0x0 +/* f0f77cc: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f77d0: +/* f0f77d0: 5860002b */ blezl $v1,.NB0f0f7880 +/* f0f77d4: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f77d8: 8f22078c */ lw $v0,0x78c($t9) +/* f0f77dc: 240c0001 */ addiu $t4,$zero,0x1 +/* f0f77e0: 0043001a */ div $zero,$v0,$v1 +/* f0f77e4: 0046c021 */ addu $t8,$v0,$a2 +/* f0f77e8: 00003812 */ mflo $a3 +/* f0f77ec: 14600002 */ bnez $v1,.NB0f0f77f8 +/* f0f77f0: 00000000 */ sll $zero,$zero,0x0 +/* f0f77f4: 0007000d */ break 0x7 +.NB0f0f77f8: +/* f0f77f8: 2401ffff */ addiu $at,$zero,-1 +/* f0f77fc: 14610004 */ bne $v1,$at,.NB0f0f7810 +/* f0f7800: 3c018000 */ lui $at,0x8000 +/* f0f7804: 14410002 */ bne $v0,$at,.NB0f0f7810 +/* f0f7808: 00000000 */ sll $zero,$zero,0x0 +/* f0f780c: 0006000d */ break 0x6 +.NB0f0f7810: +/* f0f7810: 0303001a */ div $zero,$t8,$v1 +/* f0f7814: 00004012 */ mflo $t0 +/* f0f7818: 14600002 */ bnez $v1,.NB0f0f7824 +/* f0f781c: 00000000 */ sll $zero,$zero,0x0 +/* f0f7820: 0007000d */ break 0x7 +.NB0f0f7824: +/* f0f7824: 2401ffff */ addiu $at,$zero,-1 +/* f0f7828: 14610004 */ bne $v1,$at,.NB0f0f783c +/* f0f782c: 3c018000 */ lui $at,0x8000 +/* f0f7830: 17010002 */ bne $t8,$at,.NB0f0f783c +/* f0f7834: 00000000 */ sll $zero,$zero,0x0 +/* f0f7838: 0006000d */ break 0x6 +.NB0f0f783c: +/* f0f783c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7840: 19600003 */ blez $t3,.NB0f0f7850 +/* f0f7844: 00000000 */ sll $zero,$zero,0x0 +/* f0f7848: 10000001 */ beqz $zero,.NB0f0f7850 +/* f0f784c: 240cffff */ addiu $t4,$zero,-1 +.NB0f0f7850: +/* f0f7850: 10e80002 */ beq $a3,$t0,.NB0f0f785c +/* f0f7854: 008c7021 */ addu $t6,$a0,$t4 +/* f0f7858: 240d0001 */ addiu $t5,$zero,0x1 +.NB0f0f785c: +/* f0f785c: 14800002 */ bnez $a0,.NB0f0f7868 +/* f0f7860: 00000000 */ sll $zero,$zero,0x0 +/* f0f7864: 240d0001 */ addiu $t5,$zero,0x1 +.NB0f0f7868: +/* f0f7868: 51a00005 */ beqzl $t5,.NB0f0f7880 +/* f0f786c: 8fa300fc */ lw $v1,0xfc($sp) +/* f0f7870: a46e0790 */ sh $t6,0x790($v1) +/* f0f7874: 3c06800a */ lui $a2,0x800a +/* f0f7878: 8cc6e6c0 */ lw $a2,-0x1940($a2) +/* f0f787c: 8fa300fc */ lw $v1,0xfc($sp) +.NB0f0f7880: +/* f0f7880: 10000006 */ beqz $zero,.NB0f0f789c +/* f0f7884: 8c62078c */ lw $v0,0x78c($v1) +.NB0f0f7888: +/* f0f7888: 8fa300fc */ lw $v1,0xfc($sp) +.NB0f0f788c: +/* f0f788c: 3c06800a */ lui $a2,0x800a +/* f0f7890: a4600790 */ sh $zero,0x790($v1) +/* f0f7894: 8cc6e6c0 */ lw $a2,-0x1940($a2) +/* f0f7898: 8c62078c */ lw $v0,0x78c($v1) +.NB0f0f789c: +/* f0f789c: 10e80002 */ beq $a3,$t0,.NB0f0f78a8 +/* f0f78a0: 27b50104 */ addiu $s5,$sp,0x104 +/* f0f78a4: 240d0001 */ addiu $t5,$zero,0x1 +.NB0f0f78a8: +/* f0f78a8: 55a00003 */ bnezl $t5,.NB0f0f78b8 +/* f0f78ac: 8c6f0780 */ lw $t7,0x780($v1) +/* f0f78b0: 00006025 */ or $t4,$zero,$zero +/* f0f78b4: 8c6f0780 */ lw $t7,0x780($v1) +.NB0f0f78b8: +/* f0f78b8: 8fa500f8 */ lw $a1,0xf8($sp) +/* f0f78bc: 3c18800a */ lui $t8,0x800a +/* f0f78c0: 01e6c821 */ addu $t9,$t7,$a2 +/* f0f78c4: ac790780 */ sw $t9,0x780($v1) +/* f0f78c8: 8f18e6c0 */ lw $t8,-0x1940($t8) +/* f0f78cc: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f78d0: 00587021 */ addu $t6,$v0,$t8 +/* f0f78d4: ac6e078c */ sw $t6,0x78c($v1) +/* f0f78d8: a3a90104 */ sb $t1,0x104($sp) +/* f0f78dc: a3ac0105 */ sb $t4,0x105($sp) +/* f0f78e0: a3aa0108 */ sb $t2,0x108($sp) +/* f0f78e4: a3ab0109 */ sb $t3,0x109($sp) +/* f0f78e8: 10a00003 */ beqz $a1,.NB0f0f78f8 +/* f0f78ec: a3a00118 */ sb $zero,0x118($sp) +/* f0f78f0: 10000002 */ beqz $zero,.NB0f0f78fc +/* f0f78f4: a3af010e */ sb $t7,0x10e($sp) +.NB0f0f78f8: +/* f0f78f8: a3a0010e */ sb $zero,0x10e($sp) +.NB0f0f78fc: +/* f0f78fc: 8ee30000 */ lw $v1,0x0($s7) +/* f0f7900: 007e0019 */ multu $v1,$s8 +/* f0f7904: 0000c812 */ mflo $t9 +/* f0f7908: 02d93821 */ addu $a3,$s6,$t9 +/* f0f790c: 8ce40488 */ lw $a0,0x488($a3) +/* f0f7910: 50800016 */ beqzl $a0,.NB0f0f796c +/* f0f7914: 84e20484 */ lh $v0,0x484($a3) +/* f0f7918: 50a00014 */ beqzl $a1,.NB0f0f796c +/* f0f791c: 84e20484 */ lh $v0,0x484($a3) +/* f0f7920: 8c980000 */ lw $t8,0x0($a0) +/* f0f7924: 24190001 */ addiu $t9,$zero,0x1 +/* f0f7928: 8f0e0010 */ lw $t6,0x10($t8) +/* f0f792c: 24180001 */ addiu $t8,$zero,0x1 +/* f0f7930: 31cf0004 */ andi $t7,$t6,0x4 +/* f0f7934: 51e00004 */ beqzl $t7,.NB0f0f7948 +/* f0f7938: 8c820008 */ lw $v0,0x8($a0) +/* f0f793c: a3b90106 */ sb $t9,0x106($sp) +/* f0f7940: afb8011c */ sw $t8,0x11c($sp) +/* f0f7944: 8c820008 */ lw $v0,0x8($a0) +.NB0f0f7948: +/* f0f7948: 50400008 */ beqzl $v0,.NB0f0f796c +/* f0f794c: 84e20484 */ lh $v0,0x484($a3) +/* f0f7950: 904e0000 */ lbu $t6,0x0($v0) +/* f0f7954: 24010002 */ addiu $at,$zero,0x2 +/* f0f7958: 240f0001 */ addiu $t7,$zero,0x1 +/* f0f795c: 55c10003 */ bnel $t6,$at,.NB0f0f796c +/* f0f7960: 84e20484 */ lh $v0,0x484($a3) +/* f0f7964: a3af0106 */ sb $t7,0x106($sp) +/* f0f7968: 84e20484 */ lh $v0,0x484($a3) +.NB0f0f796c: +/* f0f796c: 00009825 */ or $s3,$zero,$zero +/* f0f7970: 0000a025 */ or $s4,$zero,$zero +/* f0f7974: 1840003a */ blez $v0,.NB0f0f7a60 +/* f0f7978: 00000000 */ sll $zero,$zero,0x0 +/* f0f797c: afa00044 */ sw $zero,0x44($sp) +.NB0f0f7980: +/* f0f7980: 0003c8c0 */ sll $t9,$v1,0x3 +/* f0f7984: 0323c823 */ subu $t9,$t9,$v1 +/* f0f7988: 0019c8c0 */ sll $t9,$t9,0x3 +/* f0f798c: 0323c823 */ subu $t9,$t9,$v1 +/* f0f7990: 0019c900 */ sll $t9,$t9,0x4 +/* f0f7994: 8fae0044 */ lw $t6,0x44($sp) +/* f0f7998: 0323c823 */ subu $t9,$t9,$v1 +/* f0f799c: 0019c880 */ sll $t9,$t9,0x2 +/* f0f79a0: 02d9c021 */ addu $t8,$s6,$t9 +/* f0f79a4: 030e9021 */ addu $s2,$t8,$t6 +/* f0f79a8: 824f0408 */ lb $t7,0x408($s2) +/* f0f79ac: 265203f4 */ addiu $s2,$s2,0x3f4 +/* f0f79b0: 02408825 */ or $s1,$s2,$zero +/* f0f79b4: 19e00024 */ blez $t7,.NB0f0f7a48 +/* f0f79b8: 00008025 */ or $s0,$zero,$zero +/* f0f79bc: 8ef80000 */ lw $t8,0x0($s7) +.NB0f0f79c0: +/* f0f79c0: 26990001 */ addiu $t9,$s4,0x1 +/* f0f79c4: 00003025 */ or $a2,$zero,$zero +/* f0f79c8: 031e0019 */ multu $t8,$s8 +/* f0f79cc: 02a02825 */ or $a1,$s5,$zero +/* f0f79d0: 00007012 */ mflo $t6 +/* f0f79d4: 02ce7821 */ addu $t7,$s6,$t6 +/* f0f79d8: 85f80484 */ lh $t8,0x484($t7) +/* f0f79dc: 17380008 */ bne $t9,$t8,.NB0f0f7a00 +/* f0f79e0: 00000000 */ sll $zero,$zero,0x0 +/* f0f79e4: 824e0015 */ lb $t6,0x15($s2) +/* f0f79e8: 160e0005 */ bne $s0,$t6,.NB0f0f7a00 +/* f0f79ec: 00000000 */ sll $zero,$zero,0x0 +/* f0f79f0: 16600003 */ bnez $s3,.NB0f0f7a00 +/* f0f79f4: 00000000 */ sll $zero,$zero,0x0 +/* f0f79f8: 24060001 */ addiu $a2,$zero,0x1 +/* f0f79fc: 24130001 */ addiu $s3,$zero,0x1 +.NB0f0f7a00: +/* f0f7a00: 0fc3d6ec */ jal func0f0f935c +/* f0f7a04: 8e240000 */ lw $a0,0x0($s1) +/* f0f7a08: 824f0014 */ lb $t7,0x14($s2) +/* f0f7a0c: 26100001 */ addiu $s0,$s0,0x1 +/* f0f7a10: 26310004 */ addiu $s1,$s1,0x4 +/* f0f7a14: 020f082a */ slt $at,$s0,$t7 +/* f0f7a18: 5420ffe9 */ bnezl $at,.NB0f0f79c0 +/* f0f7a1c: 8ef80000 */ lw $t8,0x0($s7) +/* f0f7a20: 8ee30000 */ lw $v1,0x0($s7) +/* f0f7a24: 0003c8c0 */ sll $t9,$v1,0x3 +/* f0f7a28: 0323c823 */ subu $t9,$t9,$v1 +/* f0f7a2c: 0019c8c0 */ sll $t9,$t9,0x3 +/* f0f7a30: 0323c823 */ subu $t9,$t9,$v1 +/* f0f7a34: 0019c900 */ sll $t9,$t9,0x4 +/* f0f7a38: 0323c823 */ subu $t9,$t9,$v1 +/* f0f7a3c: 0019c880 */ sll $t9,$t9,0x2 +/* f0f7a40: 02d93821 */ addu $a3,$s6,$t9 +/* f0f7a44: 84e20484 */ lh $v0,0x484($a3) +.NB0f0f7a48: +/* f0f7a48: 8fb80044 */ lw $t8,0x44($sp) +/* f0f7a4c: 26940001 */ addiu $s4,$s4,0x1 +/* f0f7a50: 0282082a */ slt $at,$s4,$v0 +/* f0f7a54: 270e0018 */ addiu $t6,$t8,0x18 +/* f0f7a58: 1420ffc9 */ bnez $at,.NB0f0f7980 +/* f0f7a5c: afae0044 */ sw $t6,0x44($sp) +.NB0f0f7a60: +/* f0f7a60: 3c0f800a */ lui $t7,0x800a +/* f0f7a64: 8def5eb4 */ lw $t7,0x5eb4($t7) +/* f0f7a68: 25f9ffff */ addiu $t9,$t7,-1 +/* f0f7a6c: 2f21000d */ sltiu $at,$t9,0xd +/* f0f7a70: 1020004d */ beqz $at,.NB0f0f7ba8 +/* f0f7a74: 0019c880 */ sll $t9,$t9,0x2 +/* f0f7a78: 3c017f1b */ lui $at,0x7f1b +/* f0f7a7c: 00390821 */ addu $at,$at,$t9 +/* f0f7a80: 8c39cdb4 */ lw $t9,-0x324c($at) +/* f0f7a84: 03200008 */ jr $t9 +/* f0f7a88: 00000000 */ sll $zero,$zero,0x0 +/* f0f7a8c: 83b8010e */ lb $t8,0x10e($sp) +/* f0f7a90: 8fae011c */ lw $t6,0x11c($sp) +/* f0f7a94: 53000045 */ beqzl $t8,.NB0f0f7bac +/* f0f7a98: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7a9c: 55c00043 */ bnezl $t6,.NB0f0f7bac +/* f0f7aa0: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7aa4: 8ce40488 */ lw $a0,0x488($a3) +/* f0f7aa8: 8faf0100 */ lw $t7,0x100($sp) +/* f0f7aac: 5080003f */ beqzl $a0,.NB0f0f7bac +/* f0f7ab0: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7ab4: 8df9000c */ lw $t9,0xc($t7) +/* f0f7ab8: 3c18800a */ lui $t8,0x800a +/* f0f7abc: 5720003b */ bnezl $t9,.NB0f0f7bac +/* f0f7ac0: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7ac4: 8f18eb50 */ lw $t8,-0x14b0($t8) +/* f0f7ac8: 8c820000 */ lw $v0,0x0($a0) +/* f0f7acc: 24010002 */ addiu $at,$zero,0x2 +/* f0f7ad0: 13010008 */ beq $t8,$at,.NB0f0f7af4 +/* f0f7ad4: 3c048008 */ lui $a0,0x8008 +/* f0f7ad8: 24847f34 */ addiu $a0,$a0,0x7f34 +/* f0f7adc: 10820005 */ beq $a0,$v0,.NB0f0f7af4 +/* f0f7ae0: 00000000 */ sll $zero,$zero,0x0 +/* f0f7ae4: 0fc3beda */ jal menuPushDialog +/* f0f7ae8: 00000000 */ sll $zero,$zero,0x0 +/* f0f7aec: 1000002f */ beqz $zero,.NB0f0f7bac +/* f0f7af0: 8fbf003c */ lw $ra,0x3c($sp) +.NB0f0f7af4: +/* f0f7af4: 3c0e8009 */ lui $t6,0x8009 +/* f0f7af8: 25ce8dfc */ addiu $t6,$t6,-29188 +/* f0f7afc: 55c2002b */ bnel $t6,$v0,.NB0f0f7bac +/* f0f7b00: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7b04: 0fc5e6b1 */ jal func0f17f428 +/* f0f7b08: 00000000 */ sll $zero,$zero,0x0 +/* f0f7b0c: 10000027 */ beqz $zero,.NB0f0f7bac +/* f0f7b10: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7b14: 3c0f8007 */ lui $t7,0x8007 +/* f0f7b18: 8def2e24 */ lw $t7,0x2e24($t7) +/* f0f7b1c: 51e00010 */ beqzl $t7,.NB0f0f7b60 +/* f0f7b20: 240f000a */ addiu $t7,$zero,0xa +/* f0f7b24: 0fc3d2a2 */ jal func0f0f8120 +/* f0f7b28: 00000000 */ sll $zero,$zero,0x0 +/* f0f7b2c: 3c198007 */ lui $t9,0x8007 +/* f0f7b30: 8f393af0 */ lw $t9,0x3af0($t9) +/* f0f7b34: 3c0e800a */ lui $t6,0x800a +/* f0f7b38: 25ce27c0 */ addiu $t6,$t6,0x27c0 +/* f0f7b3c: 0019c0c0 */ sll $t8,$t9,0x3 +/* f0f7b40: 0319c023 */ subu $t8,$t8,$t9 +/* f0f7b44: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0f7b48: 0319c023 */ subu $t8,$t8,$t9 +/* f0f7b4c: 0018c100 */ sll $t8,$t8,0x4 +/* f0f7b50: 0319c023 */ subu $t8,$t8,$t9 +/* f0f7b54: 0018c080 */ sll $t8,$t8,0x2 +/* f0f7b58: 030e3821 */ addu $a3,$t8,$t6 +/* f0f7b5c: 240f000a */ addiu $t7,$zero,0xa +.NB0f0f7b60: +/* f0f7b60: a0ef0798 */ sb $t7,0x798($a3) +/* f0f7b64: 83b9010e */ lb $t9,0x10e($sp) +/* f0f7b68: 8fb8011c */ lw $t8,0x11c($sp) +/* f0f7b6c: 5320000f */ beqzl $t9,.NB0f0f7bac +/* f0f7b70: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7b74: 5700000d */ bnezl $t8,.NB0f0f7bac +/* f0f7b78: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7b7c: 8cee0488 */ lw $t6,0x488($a3) +/* f0f7b80: 8faf0100 */ lw $t7,0x100($sp) +/* f0f7b84: 51c00009 */ beqzl $t6,.NB0f0f7bac +/* f0f7b88: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7b8c: 8df90000 */ lw $t9,0x0($t7) +/* f0f7b90: 8f380010 */ lw $t8,0x10($t9) +/* f0f7b94: 330e0020 */ andi $t6,$t8,0x20 +/* f0f7b98: 55c00004 */ bnezl $t6,.NB0f0f7bac +/* f0f7b9c: 8fbf003c */ lw $ra,0x3c($sp) +/* f0f7ba0: 0fc3d2a2 */ jal func0f0f8120 +/* f0f7ba4: 00000000 */ sll $zero,$zero,0x0 +.NB0f0f7ba8: +/* f0f7ba8: 8fbf003c */ lw $ra,0x3c($sp) +.NB0f0f7bac: +/* f0f7bac: 8fb00018 */ lw $s0,0x18($sp) +/* f0f7bb0: 8fb1001c */ lw $s1,0x1c($sp) +/* f0f7bb4: 8fb20020 */ lw $s2,0x20($sp) +/* f0f7bb8: 8fb30024 */ lw $s3,0x24($sp) +/* f0f7bbc: 8fb40028 */ lw $s4,0x28($sp) +/* f0f7bc0: 8fb5002c */ lw $s5,0x2c($sp) +/* f0f7bc4: 8fb60030 */ lw $s6,0x30($sp) +/* f0f7bc8: 8fb70034 */ lw $s7,0x34($sp) +/* f0f7bcc: 8fbe0038 */ lw $s8,0x38($sp) +/* f0f7bd0: 03e00008 */ jr $ra +/* f0f7bd4: 27bd0130 */ addiu $sp,$sp,0x130 +); #endif u32 var800714ec = 0x00000001; @@ -27540,6 +30535,7 @@ s32 menuhandlerRepairPak(s32 operation, struct menuitem *item, union handlerdata return 0; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0fce8c /* f0fce8c: 0005c0c0 */ sll $t8,$a1,0x3 @@ -27626,6 +30622,94 @@ glabel func0f0fce8c /* f0fcfb0: 03e00008 */ jr $ra /* f0fcfb4: ac2a1448 */ sw $t2,%lo(g_MpPlayerNum)($at) ); +#else +GLOBAL_ASM( +glabel func0f0fce8c +/* f0f947c: 0005c0c0 */ sll $t8,$a1,0x3 +/* f0f9480: 0305c023 */ subu $t8,$t8,$a1 +/* f0f9484: 0018c0c0 */ sll $t8,$t8,0x3 +/* f0f9488: 0305c023 */ subu $t8,$t8,$a1 +/* f0f948c: 0018c100 */ sll $t8,$t8,0x4 +/* f0f9490: 0305c023 */ subu $t8,$t8,$a1 +/* f0f9494: 3c19800a */ lui $t9,0x800a +/* f0f9498: 273927c0 */ addiu $t9,$t9,0x27c0 +/* f0f949c: 0018c080 */ sll $t8,$t8,0x2 +/* f0f94a0: 3c088007 */ lui $t0,0x8007 +/* f0f94a4: 03191021 */ addu $v0,$t8,$t9 +/* f0f94a8: 8c490488 */ lw $t1,0x488($v0) +/* f0f94ac: 25083af0 */ addiu $t0,$t0,0x3af0 +/* f0f94b0: 8d0e0000 */ lw $t6,0x0($t0) +/* f0f94b4: 27bdffe0 */ addiu $sp,$sp,-32 +/* f0f94b8: afbf0014 */ sw $ra,0x14($sp) +/* f0f94bc: 00803825 */ or $a3,$a0,$zero +/* f0f94c0: ad050000 */ sw $a1,0x0($t0) +/* f0f94c4: a0460db8 */ sb $a2,0xdb8($v0) +/* f0f94c8: 1520002f */ bnez $t1,.NB0f0f9588 +/* f0f94cc: afae001c */ sw $t6,0x1c($sp) +/* f0f94d0: 3c06800a */ lui $a2,0x800a +/* f0f94d4: 24c6e6c0 */ addiu $a2,$a2,-6464 +/* f0f94d8: 8cca006c */ lw $t2,0x6c($a2) +/* f0f94dc: 24010001 */ addiu $at,$zero,0x1 +/* f0f94e0: 00002825 */ or $a1,$zero,$zero +/* f0f94e4: 11400003 */ beqz $t2,.NB0f0f94f4 +/* f0f94e8: 00001825 */ or $v1,$zero,$zero +/* f0f94ec: 10000001 */ beqz $zero,.NB0f0f94f4 +/* f0f94f0: 24050001 */ addiu $a1,$zero,0x1 +.NB0f0f94f4: +/* f0f94f4: 8ccb0068 */ lw $t3,0x68($a2) +/* f0f94f8: 00002025 */ or $a0,$zero,$zero +/* f0f94fc: 00001025 */ or $v0,$zero,$zero +/* f0f9500: 11600003 */ beqz $t3,.NB0f0f9510 +/* f0f9504: 00000000 */ sll $zero,$zero,0x0 +/* f0f9508: 10000001 */ beqz $zero,.NB0f0f9510 +/* f0f950c: 24030001 */ addiu $v1,$zero,0x1 +.NB0f0f9510: +/* f0f9510: 8ccc0064 */ lw $t4,0x64($a2) +/* f0f9514: 11800003 */ beqz $t4,.NB0f0f9524 +/* f0f9518: 00000000 */ sll $zero,$zero,0x0 +/* f0f951c: 10000001 */ beqz $zero,.NB0f0f9524 +/* f0f9520: 24040001 */ addiu $a0,$zero,0x1 +.NB0f0f9524: +/* f0f9524: 8ccd0070 */ lw $t5,0x70($a2) +/* f0f9528: 11a00003 */ beqz $t5,.NB0f0f9538 +/* f0f952c: 00000000 */ sll $zero,$zero,0x0 +/* f0f9530: 10000001 */ beqz $zero,.NB0f0f9538 +/* f0f9534: 24020001 */ addiu $v0,$zero,0x1 +.NB0f0f9538: +/* f0f9538: 00447021 */ addu $t6,$v0,$a0 +/* f0f953c: 01c37821 */ addu $t7,$t6,$v1 +/* f0f9540: 01e5c021 */ addu $t8,$t7,$a1 +/* f0f9544: 1701000b */ bne $t8,$at,.NB0f0f9574 +/* f0f9548: 00e02025 */ or $a0,$a3,$zero +/* f0f954c: 0fc3d326 */ jal menuPushRootDialog +/* f0f9550: 24050002 */ addiu $a1,$zero,0x2 +/* f0f9554: 0fc59ebc */ jal lvSetPaused +/* f0f9558: 24040001 */ addiu $a0,$zero,0x1 +/* f0f955c: 3c06800a */ lui $a2,0x800a +/* f0f9560: 24c6e6c0 */ addiu $a2,$a2,-6464 +/* f0f9564: 8cc90284 */ lw $t1,0x284($a2) +/* f0f9568: 24190003 */ addiu $t9,$zero,0x3 +/* f0f956c: 10000008 */ beqz $zero,.NB0f0f9590 +/* f0f9570: ad391a24 */ sw $t9,0x1a24($t1) +.NB0f0f9574: +/* f0f9574: 00e02025 */ or $a0,$a3,$zero +/* f0f9578: 0fc3d326 */ jal menuPushRootDialog +/* f0f957c: 24050004 */ addiu $a1,$zero,0x4 +/* f0f9580: 10000004 */ beqz $zero,.NB0f0f9594 +/* f0f9584: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0f9588: +/* f0f9588: 0fc3beda */ jal menuPushDialog +/* f0f958c: 00e02025 */ or $a0,$a3,$zero +.NB0f0f9590: +/* f0f9590: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0f9594: +/* f0f9594: 8faa001c */ lw $t2,0x1c($sp) +/* f0f9598: 3c018007 */ lui $at,0x8007 +/* f0f959c: 27bd0020 */ addiu $sp,$sp,0x20 +/* f0f95a0: 03e00008 */ jr $ra +/* f0f95a4: ac2a3af0 */ sw $t2,0x3af0($at) +); +#endif struct menuitem g_PakRemovedMenuItems[] = { { MENUITEMTYPE_LABEL, 0, 0x00000010, L_MPWEAPONS_174, 0x00000000, NULL }, // "The Controller Pak has been removed." @@ -27817,15 +30901,15 @@ bool func0f0fd1f4(s32 arg0, s32 arg1) if (g_Menus[playernum].curframe) { if (g_Menus[playernum].curframe->dialog == &g_PakDamagedMenuDialog +#if VERSION >= VERSION_NTSC_1_0 || g_Menus[playernum].curframe->dialog == &g_PakCannotReadGameBoyMenuDialog || g_Menus[playernum].curframe->dialog == &g_PakDataLostMenuDialog +#endif || g_Menus[playernum].curframe->dialog == &g_PakFullMenuDialog || g_Menus[playernum].curframe->dialog == &g_PakAttemptRepairMenuDialog || g_Menus[playernum].curframe->dialog == &g_PakRemovedMenuDialog -#if VERSION >= VERSION_NTSC_1_0 || g_Menus[playernum].curframe->dialog == &g_PakRepairSuccessMenuDialog || g_Menus[playernum].curframe->dialog == &g_PakRepairFailedMenuDialog -#endif ) { result = false; } @@ -28064,6 +31148,7 @@ void func0f0fd548(s32 arg0) g_MenuData.unk66f = 0; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuIsDialogOpen /* f0fd570: 3c028007 */ lui $v0,%hi(g_MpPlayerNum) @@ -28129,6 +31214,73 @@ glabel menuIsDialogOpen /* f0fd648: 03e00008 */ jr $ra /* f0fd64c: 27bd0008 */ addiu $sp,$sp,0x8 ); +#else +GLOBAL_ASM( +glabel menuIsDialogOpen +/* f0f9ad4: 3c028007 */ lui $v0,0x8007 +/* f0f9ad8: 8c423af0 */ lw $v0,0x3af0($v0) +/* f0f9adc: 3c0f800a */ lui $t7,0x800a +/* f0f9ae0: 25ef27c0 */ addiu $t7,$t7,0x27c0 +/* f0f9ae4: 000270c0 */ sll $t6,$v0,0x3 +/* f0f9ae8: 01c27023 */ subu $t6,$t6,$v0 +/* f0f9aec: 000e70c0 */ sll $t6,$t6,0x3 +/* f0f9af0: 01c27023 */ subu $t6,$t6,$v0 +/* f0f9af4: 000e7100 */ sll $t6,$t6,0x4 +/* f0f9af8: 01c27023 */ subu $t6,$t6,$v0 +/* f0f9afc: 000e7080 */ sll $t6,$t6,0x2 +/* f0f9b00: 01cf1821 */ addu $v1,$t6,$t7 +/* f0f9b04: 8c780488 */ lw $t8,0x488($v1) +/* f0f9b08: 27bdfff8 */ addiu $sp,$sp,-8 +/* f0f9b0c: afb00004 */ sw $s0,0x4($sp) +/* f0f9b10: 13000024 */ beqz $t8,.NB0f0f9ba4 +/* f0f9b14: 00808025 */ or $s0,$a0,$zero +/* f0f9b18: 84650484 */ lh $a1,0x484($v1) +/* f0f9b1c: 0002c8c0 */ sll $t9,$v0,0x3 +/* f0f9b20: 0322c823 */ subu $t9,$t9,$v0 +/* f0f9b24: 18a0001f */ blez $a1,.NB0f0f9ba4 +/* f0f9b28: 00002025 */ or $a0,$zero,$zero +/* f0f9b2c: 0019c8c0 */ sll $t9,$t9,0x3 +/* f0f9b30: 0322c823 */ subu $t9,$t9,$v0 +/* f0f9b34: 0019c900 */ sll $t9,$t9,0x4 +/* f0f9b38: 0322c823 */ subu $t9,$t9,$v0 +/* f0f9b3c: 0019c880 */ sll $t9,$t9,0x2 +/* f0f9b40: 032f1821 */ addu $v1,$t9,$t7 +/* f0f9b44: 00603025 */ or $a2,$v1,$zero +.NB0f0f9b48: +/* f0f9b48: 80c70408 */ lb $a3,0x408($a2) +/* f0f9b4c: 00045080 */ sll $t2,$a0,0x2 +/* f0f9b50: 01445023 */ subu $t2,$t2,$a0 +/* f0f9b54: 18e0000f */ blez $a3,.NB0f0f9b94 +/* f0f9b58: 00001025 */ or $v0,$zero,$zero +/* f0f9b5c: 000a50c0 */ sll $t2,$t2,0x3 +/* f0f9b60: 006a4021 */ addu $t0,$v1,$t2 +.NB0f0f9b64: +/* f0f9b64: 8d0903f4 */ lw $t1,0x3f4($t0) +/* f0f9b68: 24420001 */ addiu $v0,$v0,0x1 +/* f0f9b6c: 0047082a */ slt $at,$v0,$a3 +/* f0f9b70: 11200006 */ beqz $t1,.NB0f0f9b8c +/* f0f9b74: 00000000 */ sll $zero,$zero,0x0 +/* f0f9b78: 8d2b0000 */ lw $t3,0x0($t1) +/* f0f9b7c: 160b0003 */ bne $s0,$t3,.NB0f0f9b8c +/* f0f9b80: 00000000 */ sll $zero,$zero,0x0 +/* f0f9b84: 10000008 */ beqz $zero,.NB0f0f9ba8 +/* f0f9b88: 01201025 */ or $v0,$t1,$zero +.NB0f0f9b8c: +/* f0f9b8c: 1420fff5 */ bnez $at,.NB0f0f9b64 +/* f0f9b90: 25080004 */ addiu $t0,$t0,0x4 +.NB0f0f9b94: +/* f0f9b94: 24840001 */ addiu $a0,$a0,0x1 +/* f0f9b98: 0085082a */ slt $at,$a0,$a1 +/* f0f9b9c: 1420ffea */ bnez $at,.NB0f0f9b48 +/* f0f9ba0: 24c60018 */ addiu $a2,$a2,0x18 +.NB0f0f9ba4: +/* f0f9ba4: 00001025 */ or $v0,$zero,$zero +.NB0f0f9ba8: +/* f0f9ba8: 8fb00004 */ lw $s0,0x4($sp) +/* f0f9bac: 03e00008 */ jr $ra +/* f0f9bb0: 27bd0008 */ addiu $sp,$sp,0x8 +); +#endif struct menuitem g_PakDamagedMenuItems[] = { { MENUITEMTYPE_LABEL, 0, 0x00000030, (u32)&menuTextSaveDeviceName, 0x00000000, NULL }, diff --git a/src/game/game_127910.c b/src/game/game_127910.c index 80160731f..0d26737c5 100644 --- a/src/game/game_127910.c +++ b/src/game/game_127910.c @@ -701,6 +701,7 @@ void currentPlayerSetAspectRatio(f32 aspect) g_Vars.currentplayer->aspect = aspect; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel weaponGetModel .late_rodata @@ -941,6 +942,248 @@ glabel var7f1b522c /* f128ce8: 03e00008 */ jr $ra /* f128cec: 00601025 */ or $v0,$v1,$zero ); +#else +GLOBAL_ASM( +glabel weaponGetModel +.late_rodata +glabel var7f1b5168 +.word weaponGetModel+0x60 # f128b54 +glabel var7f1b516c +.word weaponGetModel+0x60 # f128b54 +glabel var7f1b5170 +.word weaponGetModel+0x68 # f128b5c +glabel var7f1b5174 +.word weaponGetModel+0x98 # f128b8c +glabel var7f1b5178 +.word weaponGetModel+0xa0 # f128b94 +glabel var7f1b517c +.word weaponGetModel+0x70 # f128b64 +glabel var7f1b5180 +.word weaponGetModel+0x78 # f128b6c +glabel var7f1b5184 +.word weaponGetModel+0x90 # f128b84 +glabel var7f1b5188 +.word weaponGetModel+0x80 # f128b74 +glabel var7f1b518c +.word weaponGetModel+0x88 # f128b7c +glabel var7f1b5190 +.word weaponGetModel+0xa8 # f128b9c +glabel var7f1b5194 +.word weaponGetModel+0xd0 # f128bc4 +glabel var7f1b5198 +.word weaponGetModel+0xd8 # f128bcc +glabel var7f1b519c +.word weaponGetModel+0xe0 # f128bd4 +glabel var7f1b51a0 +.word weaponGetModel+0xe8 # f128bdc +glabel var7f1b51a4 +.word weaponGetModel+0xb8 # f128bac +glabel var7f1b51a8 +.word weaponGetModel+0xc8 # f128bbc +glabel var7f1b51ac +.word weaponGetModel+0xb0 # f128ba4 +glabel var7f1b51b0 +.word weaponGetModel+0xc0 # f128bb4 +glabel var7f1b51b4 +.word weaponGetModel+0xf0 # f128be4 +glabel var7f1b51b8 +.word weaponGetModel+0xf8 # f128bec +glabel var7f1b51bc +.word weaponGetModel+0x120 # f128c14 +glabel var7f1b51c0 +.word weaponGetModel+0x118 # f128c0c +glabel var7f1b51c4 +.word weaponGetModel+0x108 # f128bfc +glabel var7f1b51c8 +.word weaponGetModel+0x100 # f128bf4 +glabel var7f1b51cc +.word weaponGetModel+0x110 # f128c04 +glabel var7f1b51d0 +.word weaponGetModel+0x138 # f128c2c +glabel var7f1b51d4 +.word weaponGetModel+0x128 # f128c1c +glabel var7f1b51d8 +.word weaponGetModel+0x140 # f128c34 +glabel var7f1b51dc +.word weaponGetModel+0x130 # f128c24 +glabel var7f1b51e0 +.word weaponGetModel+0x158 # f128c4c +glabel var7f1b51e4 +.word weaponGetModel+0x150 # f128c44 +glabel var7f1b51e8 +.word weaponGetModel+0x170 # f128c64 +glabel var7f1b51ec +.word weaponGetModel+0x168 # f128c5c +glabel var7f1b51f0 +.word weaponGetModel+0x160 # f128c54 +glabel var7f1b51f4 +.word weaponGetModel+0x1c8 # f128cbc +glabel var7f1b51f8 +.word weaponGetModel+0x188 # f128c7c +glabel var7f1b51fc +.word weaponGetModel+0x190 # f128c84 +glabel var7f1b5200 +.word weaponGetModel+0x198 # f128c8c +glabel var7f1b5204 +.word weaponGetModel+0x1a0 # f128c94 +glabel var7f1b5208 +.word weaponGetModel+0x1a8 # f128c9c +glabel var7f1b520c +.word weaponGetModel+0x1b0 # f128ca4 +glabel var7f1b5210 +.word weaponGetModel+0x1b8 # f128cac +glabel var7f1b5214 +.word weaponGetModel+0x1c0 # f128cb4 +glabel var7f1b5218 +.word weaponGetModel+0x148 # f128c3c +glabel var7f1b521c +.word weaponGetModel+0x1e0 # f128cd4 +glabel var7f1b5220 +.word weaponGetModel+0x1e0 # f128cd4 +glabel var7f1b5224 +.word weaponGetModel+0x1e0 # f128cd4 +glabel var7f1b5228 +.word weaponGetModel+0x1e0 # f128cd4 +glabel var7f1b522c +.word weaponGetModel+0x180 # f128c74 +.text +/* f128af4: 28810052 */ slti $at,$a0,0x51 +/* f128af8: 14200007 */ bnez $at,.L0f128b18 +/* f128afc: 24010052 */ addiu $at,$zero,0x51 +/* f128b00: 10810072 */ beq $a0,$at,.L0f128ccc +/* f128b04: 24010057 */ addiu $at,$zero,0x56 +/* f128b08: 10810058 */ beq $a0,$at,.L0f128c6c +/* f128b0c: 00000000 */ nop +/* f128b10: 10000071 */ b .L0f128cd8 +/* f128b14: 2881002d */ slti $at,$a0,0x2d +.L0f128b18: +/* f128b18: 28810032 */ slti $at,$a0,0x32 +/* f128b1c: 14200005 */ bnez $at,.L0f128b34 +/* f128b20: 24010051 */ addiu $at,$zero,0x50 +/* f128b24: 10810067 */ beq $a0,$at,.L0f128cc4 +/* f128b28: 00000000 */ nop +/* f128b2c: 1000006a */ b .L0f128cd8 +/* f128b30: 2881002d */ slti $at,$a0,0x2d +.L0f128b34: +/* f128b34: 2c810032 */ sltiu $at,$a0,0x32 +/* f128b38: 10200066 */ beqz $at,.L0f128cd4 +/* f128b3c: 00047080 */ sll $t6,$a0,0x2 +/* f128b40: 3c017f1b */ lui $at,%hi(var7f1b5168) +/* f128b44: 002e0821 */ addu $at,$at,$t6 +/* f128b48: 8c2e5168 */ lw $t6,%lo(var7f1b5168)($at) +/* f128b4c: 01c00008 */ jr $t6 +/* f128b50: 00000000 */ nop +/* f128b54: 03e00008 */ jr $ra +/* f128b58: 2402ffff */ addiu $v0,$zero,-1 +/* f128b5c: 03e00008 */ jr $ra +/* f128b60: 240200f5 */ addiu $v0,$zero,0xf5 +/* f128b64: 03e00008 */ jr $ra +/* f128b68: 240200f6 */ addiu $v0,$zero,0xf6 +/* f128b6c: 03e00008 */ jr $ra +/* f128b70: 240200f7 */ addiu $v0,$zero,0xf7 +/* f128b74: 03e00008 */ jr $ra +/* f128b78: 240200f8 */ addiu $v0,$zero,0xf8 +/* f128b7c: 03e00008 */ jr $ra +/* f128b80: 240200f9 */ addiu $v0,$zero,0xf9 +/* f128b84: 03e00008 */ jr $ra +/* f128b88: 240200fa */ addiu $v0,$zero,0xfa +/* f128b8c: 03e00008 */ jr $ra +/* f128b90: 240200fb */ addiu $v0,$zero,0xfb +/* f128b94: 03e00008 */ jr $ra +/* f128b98: 240200fc */ addiu $v0,$zero,0xfc +/* f128b9c: 03e00008 */ jr $ra +/* f128ba0: 240200fd */ addiu $v0,$zero,0xfd +/* f128ba4: 03e00008 */ jr $ra +/* f128ba8: 240200fe */ addiu $v0,$zero,0xfe +/* f128bac: 03e00008 */ jr $ra +/* f128bb0: 240200ff */ addiu $v0,$zero,0xff +/* f128bb4: 03e00008 */ jr $ra +/* f128bb8: 24020100 */ addiu $v0,$zero,0x100 +/* f128bbc: 03e00008 */ jr $ra +/* f128bc0: 24020101 */ addiu $v0,$zero,0x101 +/* f128bc4: 03e00008 */ jr $ra +/* f128bc8: 24020102 */ addiu $v0,$zero,0x102 +/* f128bcc: 03e00008 */ jr $ra +/* f128bd0: 24020103 */ addiu $v0,$zero,0x103 +/* f128bd4: 03e00008 */ jr $ra +/* f128bd8: 24020104 */ addiu $v0,$zero,0x104 +/* f128bdc: 03e00008 */ jr $ra +/* f128be0: 24020105 */ addiu $v0,$zero,0x105 +/* f128be4: 03e00008 */ jr $ra +/* f128be8: 24020106 */ addiu $v0,$zero,0x106 +/* f128bec: 03e00008 */ jr $ra +/* f128bf0: 24020107 */ addiu $v0,$zero,0x107 +/* f128bf4: 03e00008 */ jr $ra +/* f128bf8: 24020108 */ addiu $v0,$zero,0x108 +/* f128bfc: 03e00008 */ jr $ra +/* f128c00: 24020109 */ addiu $v0,$zero,0x109 +/* f128c04: 03e00008 */ jr $ra +/* f128c08: 2402010a */ addiu $v0,$zero,0x10a +/* f128c0c: 03e00008 */ jr $ra +/* f128c10: 2402010b */ addiu $v0,$zero,0x10b +/* f128c14: 03e00008 */ jr $ra +/* f128c18: 2402010c */ addiu $v0,$zero,0x10c +/* f128c1c: 03e00008 */ jr $ra +/* f128c20: 2402010d */ addiu $v0,$zero,0x10d +/* f128c24: 03e00008 */ jr $ra +/* f128c28: 24020195 */ addiu $v0,$zero,0x195 +/* f128c2c: 03e00008 */ jr $ra +/* f128c30: 2402010f */ addiu $v0,$zero,0x10f +/* f128c34: 03e00008 */ jr $ra +/* f128c38: 2402010e */ addiu $v0,$zero,0x10e +/* f128c3c: 03e00008 */ jr $ra +/* f128c40: 2402010e */ addiu $v0,$zero,0x10e +/* f128c44: 03e00008 */ jr $ra +/* f128c48: 24020110 */ addiu $v0,$zero,0x110 +/* f128c4c: 03e00008 */ jr $ra +/* f128c50: 24020112 */ addiu $v0,$zero,0x112 +/* f128c54: 03e00008 */ jr $ra +/* f128c58: 24020115 */ addiu $v0,$zero,0x115 +/* f128c5c: 03e00008 */ jr $ra +/* f128c60: 24020114 */ addiu $v0,$zero,0x114 +/* f128c64: 03e00008 */ jr $ra +/* f128c68: 24020113 */ addiu $v0,$zero,0x113 +.L0f128c6c: +/* f128c6c: 03e00008 */ jr $ra +/* f128c70: 24020011 */ addiu $v0,$zero,0x11 +/* f128c74: 03e00008 */ jr $ra +/* f128c78: 2402012e */ addiu $v0,$zero,0x12e +/* f128c7c: 03e00008 */ jr $ra +/* f128c80: 24020117 */ addiu $v0,$zero,0x117 +/* f128c84: 03e00008 */ jr $ra +/* f128c88: 24020118 */ addiu $v0,$zero,0x118 +/* f128c8c: 03e00008 */ jr $ra +/* f128c90: 24020119 */ addiu $v0,$zero,0x119 +/* f128c94: 03e00008 */ jr $ra +/* f128c98: 2402011a */ addiu $v0,$zero,0x11a +/* f128c9c: 03e00008 */ jr $ra +/* f128ca0: 2402011b */ addiu $v0,$zero,0x11b +/* f128ca4: 03e00008 */ jr $ra +/* f128ca8: 2402011c */ addiu $v0,$zero,0x11c +/* f128cac: 03e00008 */ jr $ra +/* f128cb0: 2402011d */ addiu $v0,$zero,0x11d +/* f128cb4: 03e00008 */ jr $ra +/* f128cb8: 2402011e */ addiu $v0,$zero,0x11e +/* f128cbc: 03e00008 */ jr $ra +/* f128cc0: 2402ffff */ addiu $v0,$zero,-1 +.L0f128cc4: +/* f128cc4: 03e00008 */ jr $ra +/* f128cc8: 24020198 */ addiu $v0,$zero,0x198 +.L0f128ccc: +/* f128ccc: 03e00008 */ jr $ra +/* f128cd0: 24020197 */ addiu $v0,$zero,0x197 +.L0f128cd4: +/* f128cd4: 2881002d */ slti $at,$a0,0x2d +.L0f128cd8: +/* f128cd8: 10200003 */ beqz $at,.L0f128ce8 +/* f128cdc: 2403ffff */ addiu $v1,$zero,-1 +/* f128ce0: 03e00008 */ jr $ra +/* f128ce4: 2402010c */ addiu $v0,$zero,0x10c +.L0f128ce8: +/* f128ce8: 03e00008 */ jr $ra +/* f128cec: 00601025 */ or $v0,$v1,$zero +); +#endif //s32 weaponGetModel(s32 weapon) //{ diff --git a/src/game/game_190260.c b/src/game/game_190260.c index aa78c6920..c33274517 100644 --- a/src/game/game_190260.c +++ b/src/game/game_190260.c @@ -5418,6 +5418,7 @@ void func0f19369c(struct chrdata *chr, s32 arg1) } } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f1937a4 .late_rodata @@ -6473,6 +6474,1063 @@ glabel var7f1b8f50 /* f194668: 03e00008 */ jr $ra /* f19466c: 27bd0278 */ addiu $sp,$sp,0x278 ); +#else +GLOBAL_ASM( +glabel func0f1937a4 +.late_rodata +glabel var7f1b8f48 +.word 0x40fccccd +glabel var7f1b8f4c +.word 0x4101999a +glabel var7f1b8f50 +.word 0x40fccccd +.text +/* f1937a4: 27bdfd88 */ addiu $sp,$sp,-632 +/* f1937a8: afbf0044 */ sw $ra,0x44($sp) +/* f1937ac: afbe0040 */ sw $s8,0x40($sp) +/* f1937b0: afb7003c */ sw $s7,0x3c($sp) +/* f1937b4: afb60038 */ sw $s6,0x38($sp) +/* f1937b8: afb50034 */ sw $s5,0x34($sp) +/* f1937bc: afb40030 */ sw $s4,0x30($sp) +/* f1937c0: afb3002c */ sw $s3,0x2c($sp) +/* f1937c4: afb20028 */ sw $s2,0x28($sp) +/* f1937c8: afb10024 */ sw $s1,0x24($sp) +/* f1937cc: afb00020 */ sw $s0,0x20($sp) +/* f1937d0: f7b40018 */ sdc1 $f20,0x18($sp) +/* f1937d4: afa5027c */ sw $a1,0x27c($sp) +/* f1937d8: 8c8e02d4 */ lw $t6,0x2d4($a0) +/* f1937dc: afa000c8 */ sw $zero,0xc8($sp) +/* f1937e0: afa000c4 */ sw $zero,0xc4($sp) +/* f1937e4: afae0274 */ sw $t6,0x274($sp) +/* f1937e8: 81d9004f */ lb $t9,0x4f($t6) +/* f1937ec: 0080f025 */ or $s8,$a0,$zero +/* f1937f0: 07210017 */ bgez $t9,.L0f193850 +/* f1937f4: 3c08800b */ lui $t0,%hi(g_MpSetup+0x10) +/* f1937f8: 9108cb98 */ lbu $t0,%lo(g_MpSetup+0x10)($t0) +/* f1937fc: 24010004 */ addiu $at,$zero,0x4 +/* f193800: 55010014 */ bnel $t0,$at,.L0f193854 +/* f193804: 03c02025 */ or $a0,$s8,$zero +/* f193808: 8c89001c */ lw $t1,0x1c($a0) +/* f19380c: 3c0b800b */ lui $t3,%hi(g_ScenarioData+0xe) +/* f193810: 856bc11e */ lh $t3,%lo(g_ScenarioData+0xe)($t3) +/* f193814: 852a0028 */ lh $t2,0x28($t1) +/* f193818: 554b000e */ bnel $t2,$t3,.L0f193854 +/* f19381c: 03c02025 */ or $a0,$s8,$zero +/* f193820: 0fc65241 */ jal mpGetNumTeammatesDefendingHill +/* f193824: 00000000 */ nop +/* f193828: 00408025 */ or $s0,$v0,$zero +/* f19382c: 0fc65264 */ jal mpGetNumOpponentsInHill +/* f193830: 03c02025 */ or $a0,$s8,$zero +/* f193834: 0202082a */ slt $at,$s0,$v0 +/* f193838: 14200005 */ bnez $at,.L0f193850 +/* f19383c: 244c0002 */ addiu $t4,$v0,0x2 +/* f193840: 0190082a */ slt $at,$t4,$s0 +/* f193844: 14200002 */ bnez $at,.L0f193850 +/* f193848: 240d0001 */ addiu $t5,$zero,0x1 +/* f19384c: afad00c4 */ sw $t5,0xc4($sp) +.L0f193850: +/* f193850: 03c02025 */ or $a0,$s8,$zero +.L0f193854: +/* f193854: 27a5025c */ addiu $a1,$sp,0x25c +/* f193858: 27a60244 */ addiu $a2,$sp,0x244 +/* f19385c: 0fc6601a */ jal func0f198068 +/* f193860: 27a7022c */ addiu $a3,$sp,0x22c +/* f193864: 27b00214 */ addiu $s0,$sp,0x214 +/* f193868: 24140001 */ addiu $s4,$zero,0x1 +.L0f19386c: +/* f19386c: 26940001 */ addiu $s4,$s4,0x1 +/* f193870: 2a810007 */ slti $at,$s4,0x7 +/* f193874: 26100004 */ addiu $s0,$s0,0x4 +/* f193878: 1420fffc */ bnez $at,.L0f19386c +/* f19387c: ae00fffc */ sw $zero,-0x4($s0) +/* f193880: 24140001 */ addiu $s4,$zero,0x1 +/* f193884: 27a20178 */ addiu $v0,$sp,0x178 +/* f193888: 27a301fc */ addiu $v1,$sp,0x1fc +.L0f19388c: +/* f19388c: 24420004 */ addiu $v0,$v0,0x4 +/* f193890: 0043082b */ sltu $at,$v0,$v1 +/* f193894: 26940001 */ addiu $s4,$s4,0x1 +/* f193898: 1420fffc */ bnez $at,.L0f19388c +/* f19389c: ac40fffc */ sw $zero,-0x4($v0) +/* f1938a0: 24140001 */ addiu $s4,$zero,0x1 +/* f1938a4: 27b3025c */ addiu $s3,$sp,0x25c +/* f1938a8: 27b000dc */ addiu $s0,$sp,0xdc +/* f1938ac: 27b100f4 */ addiu $s1,$sp,0xf4 +.L0f1938b0: +/* f1938b0: 03c02025 */ or $a0,$s8,$zero +/* f1938b4: 0fc65f3c */ jal aibotGetInvItem +/* f1938b8: 8e650000 */ lw $a1,0x0($s3) +/* f1938bc: 26100004 */ addiu $s0,$s0,0x4 +/* f1938c0: 26940001 */ addiu $s4,$s4,0x1 +/* f1938c4: 26730004 */ addiu $s3,$s3,0x4 +/* f1938c8: 1611fff9 */ bne $s0,$s1,.L0f1938b0 +/* f1938cc: ae02fffc */ sw $v0,-0x4($s0) +/* f1938d0: 3c15800a */ lui $s5,%hi(g_Vars+0x33c) +/* f1938d4: 8eb5a2fc */ lw $s5,%lo(g_Vars+0x33c)($s5) +/* f1938d8: 27b701fc */ addiu $s7,$sp,0x1fc +/* f1938dc: 27b20274 */ addiu $s2,$sp,0x274 +/* f1938e0: 52a000db */ beqzl $s5,.L0f193c50 +/* f1938e4: afa000a0 */ sw $zero,0xa0($sp) +/* f1938e8: 8eaf0018 */ lw $t7,0x18($s5) +.L0f1938ec: +/* f1938ec: 55e000d5 */ bnezl $t7,.L0f193c44 +/* f1938f0: 8eb50020 */ lw $s5,0x20($s5) +/* f1938f4: 86b80002 */ lh $t8,0x2($s5) +/* f1938f8: 570000d2 */ bnezl $t8,.L0f193c44 +/* f1938fc: 8eb50020 */ lw $s5,0x20($s5) +/* f193900: 92a20000 */ lbu $v0,0x0($s5) +/* f193904: 24010004 */ addiu $at,$zero,0x4 +/* f193908: 5441004f */ bnel $v0,$at,.L0f193a48 +/* f19390c: 24010001 */ addiu $at,$zero,0x1 +/* f193910: 8eb10004 */ lw $s1,0x4($s5) +/* f193914: 03c02025 */ or $a0,$s8,$zero +/* f193918: 26a50008 */ addiu $a1,$s5,0x8 +/* f19391c: 8e390010 */ lw $t9,0x10($s1) +/* f193920: 33284000 */ andi $t0,$t9,0x4000 +/* f193924: 15000045 */ bnez $t0,.L0f193a3c +/* f193928: 00000000 */ nop +/* f19392c: 0fc12555 */ jal chrGetSquaredDistanceToCoord +/* f193930: 00001025 */ or $v0,$zero,$zero +/* f193934: 46000506 */ mov.s $f20,$f0 +/* f193938: 0000b025 */ or $s6,$zero,$zero +/* f19393c: 27b3025c */ addiu $s3,$sp,0x25c +/* f193940: 9224005c */ lbu $a0,0x5c($s1) +/* f193944: 27a20274 */ addiu $v0,$sp,0x274 +.L0f193948: +/* f193948: 8e650000 */ lw $a1,0x0($s3) +/* f19394c: 26730004 */ addiu $s3,$s3,0x4 +/* f193950: 28a10002 */ slti $at,$a1,0x2 +/* f193954: 1420001b */ bnez $at,.L0f1939c4 +/* f193958: 00000000 */ nop +/* f19395c: 14850019 */ bne $a0,$a1,.L0f1939c4 +/* f193960: 00000000 */ nop +/* f193964: 0c004b70 */ jal random +/* f193968: 00000000 */ nop +/* f19396c: 3049000f */ andi $t1,$v0,0xf +/* f193970: 11200012 */ beqz $t1,.L0f1939bc +/* f193974: 27aa0214 */ addiu $t2,$sp,0x214 +/* f193978: 02ca8021 */ addu $s0,$s6,$t2 +/* f19397c: 8e0b0000 */ lw $t3,0x0($s0) +/* f193980: 02f66021 */ addu $t4,$s7,$s6 +/* f193984: 5160000b */ beqzl $t3,.L0f1939b4 +/* f193988: 02f67021 */ addu $t6,$s7,$s6 +/* f19398c: c5840000 */ lwc1 $f4,0x0($t4) +/* f193990: 4604a03c */ c.lt.s $f20,$f4 +/* f193994: 00000000 */ nop +/* f193998: 45030006 */ bc1tl .L0f1939b4 +/* f19399c: 02f67021 */ addu $t6,$s7,$s6 +/* f1939a0: 0c004b70 */ jal random +/* f1939a4: 00000000 */ nop +/* f1939a8: 304d000f */ andi $t5,$v0,0xf +/* f1939ac: 15a00003 */ bnez $t5,.L0f1939bc +/* f1939b0: 02f67021 */ addu $t6,$s7,$s6 +.L0f1939b4: +/* f1939b4: ae150000 */ sw $s5,0x0($s0) +/* f1939b8: e5d40000 */ swc1 $f20,0x0($t6) +.L0f1939bc: +/* f1939bc: 10000003 */ b .L0f1939cc +/* f1939c0: 9224005c */ lbu $a0,0x5c($s1) +.L0f1939c4: +/* f1939c4: 1662ffe0 */ bne $s3,$v0,.L0f193948 +/* f1939c8: 26d60004 */ addiu $s6,$s6,0x4 +.L0f1939cc: +/* f1939cc: 0fc6666c */ jal weaponGetAmmoTypeByFunction +/* f1939d0: 00002825 */ or $a1,$zero,$zero +/* f1939d4: 18400019 */ blez $v0,.L0f193a3c +/* f1939d8: 00408825 */ or $s1,$v0,$zero +/* f1939dc: 0c004b70 */ jal random +/* f1939e0: 00000000 */ nop +/* f1939e4: 304f000f */ andi $t7,$v0,0xf +/* f1939e8: 11e00014 */ beqz $t7,.L0f193a3c +/* f1939ec: 00118080 */ sll $s0,$s1,0x2 +/* f1939f0: 27b80178 */ addiu $t8,$sp,0x178 +/* f1939f4: 02189821 */ addu $s3,$s0,$t8 +/* f1939f8: 8e790000 */ lw $t9,0x0($s3) +/* f1939fc: 03b04021 */ addu $t0,$sp,$s0 +/* f193a00: 5320000c */ beqzl $t9,.L0f193a34 +/* f193a04: ae750000 */ sw $s5,0x0($s3) +/* f193a08: c50600f4 */ lwc1 $f6,0xf4($t0) +/* f193a0c: 4606a03c */ c.lt.s $f20,$f6 +/* f193a10: 00000000 */ nop +/* f193a14: 45030007 */ bc1tl .L0f193a34 +/* f193a18: ae750000 */ sw $s5,0x0($s3) +/* f193a1c: 0c004b70 */ jal random +/* f193a20: 00000000 */ nop +/* f193a24: 3049000f */ andi $t1,$v0,0xf +/* f193a28: 15200004 */ bnez $t1,.L0f193a3c +/* f193a2c: 00000000 */ nop +/* f193a30: ae750000 */ sw $s5,0x0($s3) +.L0f193a34: +/* f193a34: 03b05021 */ addu $t2,$sp,$s0 +/* f193a38: e55400f4 */ swc1 $f20,0xf4($t2) +.L0f193a3c: +/* f193a3c: 10000081 */ b .L0f193c44 +/* f193a40: 8eb50020 */ lw $s5,0x20($s5) +/* f193a44: 24010001 */ addiu $at,$zero,0x1 +.L0f193a48: +/* f193a48: 5441007e */ bnel $v0,$at,.L0f193c44 +/* f193a4c: 8eb50020 */ lw $s5,0x20($s5) +/* f193a50: 8ea20004 */ lw $v0,0x4($s5) +/* f193a54: 8c4b0010 */ lw $t3,0x10($v0) +/* f193a58: 316c4000 */ andi $t4,$t3,0x4000 +/* f193a5c: 55800079 */ bnezl $t4,.L0f193c44 +/* f193a60: 8eb50020 */ lw $s5,0x20($s5) +/* f193a64: 90440003 */ lbu $a0,0x3($v0) +/* f193a68: 24010014 */ addiu $at,$zero,0x14 +/* f193a6c: 00408025 */ or $s0,$v0,$zero +/* f193a70: 1481004d */ bne $a0,$at,.L0f193ba8 +/* f193a74: 26a50008 */ addiu $a1,$s5,0x8 +/* f193a78: 03c02025 */ or $a0,$s8,$zero +/* f193a7c: 0fc12555 */ jal chrGetSquaredDistanceToCoord +/* f193a80: afa000d8 */ sw $zero,0xd8($sp) +/* f193a84: 46000506 */ mov.s $f20,$f0 +/* f193a88: 24140001 */ addiu $s4,$zero,0x1 +/* f193a8c: 02009825 */ or $s3,$s0,$zero +.L0f193a90: +/* f193a90: 966d005e */ lhu $t5,0x5e($s3) +/* f193a94: 59a0003f */ blezl $t5,.L0f193b94 +/* f193a98: 26940001 */ addiu $s4,$s4,0x1 +/* f193a9c: 0fc668c7 */ jal ammotypeGetWeapon +/* f193aa0: 02802025 */ or $a0,$s4,$zero +/* f193aa4: 18400022 */ blez $v0,.L0f193b30 +/* f193aa8: 00008025 */ or $s0,$zero,$zero +/* f193aac: 27a3025c */ addiu $v1,$sp,0x25c +.L0f193ab0: +/* f193ab0: 8c640000 */ lw $a0,0x0($v1) +/* f193ab4: 24630004 */ addiu $v1,$v1,0x4 +/* f193ab8: 28810002 */ slti $at,$a0,0x2 +/* f193abc: 1420001a */ bnez $at,.L0f193b28 +/* f193ac0: 00000000 */ nop +/* f193ac4: 14440018 */ bne $v0,$a0,.L0f193b28 +/* f193ac8: 00000000 */ nop +/* f193acc: 0c004b70 */ jal random +/* f193ad0: 00000000 */ nop +/* f193ad4: 304e000f */ andi $t6,$v0,0xf +/* f193ad8: 11c00015 */ beqz $t6,.L0f193b30 +/* f193adc: 27af0214 */ addiu $t7,$sp,0x214 +/* f193ae0: 020f8821 */ addu $s1,$s0,$t7 +/* f193ae4: 8e380000 */ lw $t8,0x0($s1) +/* f193ae8: 02f0c821 */ addu $t9,$s7,$s0 +/* f193aec: 5300000b */ beqzl $t8,.L0f193b1c +/* f193af0: 02f04821 */ addu $t1,$s7,$s0 +/* f193af4: c7280000 */ lwc1 $f8,0x0($t9) +/* f193af8: 4608a03c */ c.lt.s $f20,$f8 +/* f193afc: 00000000 */ nop +/* f193b00: 45030006 */ bc1tl .L0f193b1c +/* f193b04: 02f04821 */ addu $t1,$s7,$s0 +/* f193b08: 0c004b70 */ jal random +/* f193b0c: 00000000 */ nop +/* f193b10: 3048000f */ andi $t0,$v0,0xf +/* f193b14: 15000006 */ bnez $t0,.L0f193b30 +/* f193b18: 02f04821 */ addu $t1,$s7,$s0 +.L0f193b1c: +/* f193b1c: ae350000 */ sw $s5,0x0($s1) +/* f193b20: 10000003 */ b .L0f193b30 +/* f193b24: e5340000 */ swc1 $f20,0x0($t1) +.L0f193b28: +/* f193b28: 1472ffe1 */ bne $v1,$s2,.L0f193ab0 +/* f193b2c: 26100004 */ addiu $s0,$s0,0x4 +.L0f193b30: +/* f193b30: 0c004b70 */ jal random +/* f193b34: 00000000 */ nop +/* f193b38: 304a000f */ andi $t2,$v0,0xf +/* f193b3c: 11400014 */ beqz $t2,.L0f193b90 +/* f193b40: 00141080 */ sll $v0,$s4,0x2 +/* f193b44: 27ab0178 */ addiu $t3,$sp,0x178 +/* f193b48: 004b8021 */ addu $s0,$v0,$t3 +/* f193b4c: 8e0d0000 */ lw $t5,0x0($s0) +/* f193b50: 27ac00f4 */ addiu $t4,$sp,0xf4 +/* f193b54: 004c8821 */ addu $s1,$v0,$t4 +/* f193b58: 51a0000c */ beqzl $t5,.L0f193b8c +/* f193b5c: ae150000 */ sw $s5,0x0($s0) +/* f193b60: c62a0000 */ lwc1 $f10,0x0($s1) +/* f193b64: 460aa03c */ c.lt.s $f20,$f10 +/* f193b68: 00000000 */ nop +/* f193b6c: 45030007 */ bc1tl .L0f193b8c +/* f193b70: ae150000 */ sw $s5,0x0($s0) +/* f193b74: 0c004b70 */ jal random +/* f193b78: 00000000 */ nop +/* f193b7c: 304e000f */ andi $t6,$v0,0xf +/* f193b80: 55c00004 */ bnezl $t6,.L0f193b94 +/* f193b84: 26940001 */ addiu $s4,$s4,0x1 +/* f193b88: ae150000 */ sw $s5,0x0($s0) +.L0f193b8c: +/* f193b8c: e6340000 */ swc1 $f20,0x0($s1) +.L0f193b90: +/* f193b90: 26940001 */ addiu $s4,$s4,0x1 +.L0f193b94: +/* f193b94: 24010014 */ addiu $at,$zero,0x14 +/* f193b98: 1681ffbd */ bne $s4,$at,.L0f193a90 +/* f193b9c: 26730004 */ addiu $s3,$s3,0x4 +/* f193ba0: 10000028 */ b .L0f193c44 +/* f193ba4: 8eb50020 */ lw $s5,0x20($s5) +.L0f193ba8: +/* f193ba8: 24010015 */ addiu $at,$zero,0x15 +/* f193bac: 14810024 */ bne $a0,$at,.L0f193c40 +/* f193bb0: 0000b025 */ or $s6,$zero,$zero +/* f193bb4: afa000d8 */ sw $zero,0xd8($sp) +/* f193bb8: 27b3025c */ addiu $s3,$sp,0x25c +/* f193bbc: 27a30274 */ addiu $v1,$sp,0x274 +.L0f193bc0: +/* f193bc0: 8e6f0000 */ lw $t7,0x0($s3) +/* f193bc4: 2401005b */ addiu $at,$zero,0x5a +/* f193bc8: 26730004 */ addiu $s3,$s3,0x4 +/* f193bcc: 15e1001a */ bne $t7,$at,.L0f193c38 +/* f193bd0: 03c02025 */ or $a0,$s8,$zero +/* f193bd4: 0fc12555 */ jal chrGetSquaredDistanceToCoord +/* f193bd8: 26a50008 */ addiu $a1,$s5,0x8 +/* f193bdc: 0c004b70 */ jal random +/* f193be0: 46000506 */ mov.s $f20,$f0 +/* f193be4: 3058000f */ andi $t8,$v0,0xf +/* f193be8: 13000015 */ beqz $t8,.L0f193c40 +/* f193bec: 27b90214 */ addiu $t9,$sp,0x214 +/* f193bf0: 02d98021 */ addu $s0,$s6,$t9 +/* f193bf4: 8e080000 */ lw $t0,0x0($s0) +/* f193bf8: 02f64821 */ addu $t1,$s7,$s6 +/* f193bfc: 5100000b */ beqzl $t0,.L0f193c2c +/* f193c00: 02f65821 */ addu $t3,$s7,$s6 +/* f193c04: c5240000 */ lwc1 $f4,0x0($t1) +/* f193c08: 4604a03c */ c.lt.s $f20,$f4 +/* f193c0c: 00000000 */ nop +/* f193c10: 45030006 */ bc1tl .L0f193c2c +/* f193c14: 02f65821 */ addu $t3,$s7,$s6 +/* f193c18: 0c004b70 */ jal random +/* f193c1c: 00000000 */ nop +/* f193c20: 304a000f */ andi $t2,$v0,0xf +/* f193c24: 15400006 */ bnez $t2,.L0f193c40 +/* f193c28: 02f65821 */ addu $t3,$s7,$s6 +.L0f193c2c: +/* f193c2c: ae150000 */ sw $s5,0x0($s0) +/* f193c30: 10000003 */ b .L0f193c40 +/* f193c34: e5740000 */ swc1 $f20,0x0($t3) +.L0f193c38: +/* f193c38: 1663ffe1 */ bne $s3,$v1,.L0f193bc0 +/* f193c3c: 26d60004 */ addiu $s6,$s6,0x4 +.L0f193c40: +/* f193c40: 8eb50020 */ lw $s5,0x20($s5) +.L0f193c44: +/* f193c44: 56a0ff29 */ bnezl $s5,.L0f1938ec +/* f193c48: 8eaf0018 */ lw $t7,0x18($s5) +/* f193c4c: afa000a0 */ sw $zero,0xa0($sp) +.L0f193c50: +/* f193c50: afa0009c */ sw $zero,0x9c($sp) +/* f193c54: 0000b025 */ or $s6,$zero,$zero +/* f193c58: 24140001 */ addiu $s4,$zero,0x1 +/* f193c5c: 27b3025c */ addiu $s3,$sp,0x25c +/* f193c60: 27b00274 */ addiu $s0,$sp,0x274 +.L0f193c64: +/* f193c64: 03c02025 */ or $a0,$s8,$zero +/* f193c68: 8e650000 */ lw $a1,0x0($s3) +/* f193c6c: 0fc6639e */ jal func0f198e78 +/* f193c70: 00003025 */ or $a2,$zero,$zero +/* f193c74: 14400006 */ bnez $v0,.L0f193c90 +/* f193c78: 03c02025 */ or $a0,$s8,$zero +/* f193c7c: 8e650000 */ lw $a1,0x0($s3) +/* f193c80: 0fc6639e */ jal func0f198e78 +/* f193c84: 24060001 */ addiu $a2,$zero,0x1 +/* f193c88: 50400013 */ beqzl $v0,.L0f193cd8 +/* f193c8c: 26730004 */ addiu $s3,$s3,0x4 +.L0f193c90: +/* f193c90: 8e6c0000 */ lw $t4,0x0($s3) +/* f193c94: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f193c98: 03b61021 */ addu $v0,$sp,$s6 +/* f193c9c: 000c6900 */ sll $t5,$t4,0x4 +/* f193ca0: 006d1821 */ addu $v1,$v1,$t5 +/* f193ca4: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +/* f193ca8: 8fb900a0 */ lw $t9,0xa0($sp) +/* f193cac: 000373c2 */ srl $t6,$v1,0xf +/* f193cb0: 15c00003 */ bnez $t6,.L0f193cc0 +/* f193cb4: 0003c440 */ sll $t8,$v1,0x11 +/* f193cb8: 07030007 */ bgezl $t8,.L0f193cd8 +/* f193cbc: 26730004 */ addiu $s3,$s3,0x4 +.L0f193cc0: +/* f193cc0: 8c420244 */ lw $v0,0x244($v0) +/* f193cc4: 0322082a */ slt $at,$t9,$v0 +/* f193cc8: 50200003 */ beqzl $at,.L0f193cd8 +/* f193ccc: 26730004 */ addiu $s3,$s3,0x4 +/* f193cd0: afa200a0 */ sw $v0,0xa0($sp) +/* f193cd4: 26730004 */ addiu $s3,$s3,0x4 +.L0f193cd8: +/* f193cd8: 0270082b */ sltu $at,$s3,$s0 +/* f193cdc: 26d60004 */ addiu $s6,$s6,0x4 +/* f193ce0: 1420ffe0 */ bnez $at,.L0f193c64 +/* f193ce4: 26940001 */ addiu $s4,$s4,0x1 +/* f193ce8: 3c017f1c */ lui $at,%hi(var7f1b8f48) +/* f193cec: c4328f48 */ lwc1 $f18,%lo(var7f1b8f48)($at) +/* f193cf0: 3c014080 */ lui $at,0x4080 +/* f193cf4: 27a8025c */ addiu $t0,$sp,0x25c +/* f193cf8: 44818000 */ mtc1 $at,$f16 +/* f193cfc: 44806000 */ mtc1 $zero,$f12 +/* f193d00: 00089821 */ addu $s3,$zero,$t0 +/* f193d04: afa000d8 */ sw $zero,0xd8($sp) +/* f193d08: 0000b025 */ or $s6,$zero,$zero +/* f193d0c: 27b00274 */ addiu $s0,$sp,0x274 +/* f193d10: 8e690000 */ lw $t1,0x0($s3) +.L0f193d14: +/* f193d14: 2401005b */ addiu $at,$zero,0x5a +/* f193d18: 3c03800b */ lui $v1,%hi(g_MpSetup+0x10) +/* f193d1c: 552100d0 */ bnel $t1,$at,.L0f194060 +/* f193d20: 26730004 */ addiu $s3,$s3,0x4 +/* f193d24: 9063cb98 */ lbu $v1,%lo(g_MpSetup+0x10)($v1) +/* f193d28: 24010001 */ addiu $at,$zero,0x1 +/* f193d2c: 8fad0274 */ lw $t5,0x274($sp) +/* f193d30: 54610007 */ bnel $v1,$at,.L0f193d50 +/* f193d34: 8da20004 */ lw $v0,0x4($t5) +/* f193d38: 8fca02d4 */ lw $t2,0x2d4($s8) +/* f193d3c: 8d4b009c */ lw $t3,0x9c($t2) +/* f193d40: 000b67c2 */ srl $t4,$t3,0x1f +/* f193d44: 558000c6 */ bnezl $t4,.L0f194060 +/* f193d48: 26730004 */ addiu $s3,$s3,0x4 +/* f193d4c: 8da20004 */ lw $v0,0x4($t5) +.L0f193d50: +/* f193d50: 3c017f1c */ lui $at,%hi(var7f1b8f4c) +/* f193d54: c4228f4c */ lwc1 $f2,%lo(var7f1b8f4c)($at) +/* f193d58: 904e0047 */ lbu $t6,0x47($v0) +/* f193d5c: 24010002 */ addiu $at,$zero,0x2 +/* f193d60: 46006506 */ mov.s $f20,$f12 +/* f193d64: 15c1001b */ bne $t6,$at,.L0f193dd4 +/* f193d68: 8faa00c4 */ lw $t2,0xc4($sp) +/* f193d6c: 8faf027c */ lw $t7,0x27c($sp) +/* f193d70: c7c60104 */ lwc1 $f6,0x104($s8) +/* f193d74: c7c80100 */ lwc1 $f8,0x100($s8) +/* f193d78: 24010002 */ addiu $at,$zero,0x2 +/* f193d7c: 90430048 */ lbu $v1,0x48($v0) +/* f193d80: 15e10003 */ bne $t7,$at,.L0f193d90 +/* f193d84: 46083381 */ sub.s $f14,$f6,$f8 +/* f193d88: 1000005b */ b .L0f193ef8 +/* f193d8c: 46009506 */ mov.s $f20,$f18 +.L0f193d90: +/* f193d90: 8fb8027c */ lw $t8,0x27c($sp) +/* f193d94: 8fb90274 */ lw $t9,0x274($sp) +/* f193d98: 8fa8027c */ lw $t0,0x27c($sp) +/* f193d9c: 17000007 */ bnez $t8,.L0f193dbc +/* f193da0: 24010001 */ addiu $at,$zero,0x1 +/* f193da4: c72002d4 */ lwc1 $f0,0x2d4($t9) +/* f193da8: 3c0140c0 */ lui $at,0x40c0 +/* f193dac: 44815000 */ mtc1 $at,$f10 +/* f193db0: 46000100 */ add.s $f4,$f0,$f0 +/* f193db4: 10000050 */ b .L0f193ef8 +/* f193db8: 46045501 */ sub.s $f20,$f10,$f4 +.L0f193dbc: +/* f193dbc: 1501004e */ bne $t0,$at,.L0f193ef8 +/* f193dc0: 8fa90274 */ lw $t1,0x274($sp) +/* f193dc4: c52002d4 */ lwc1 $f0,0x2d4($t1) +/* f193dc8: 46000180 */ add.s $f6,$f0,$f0 +/* f193dcc: 1000004a */ b .L0f193ef8 +/* f193dd0: 46068501 */ sub.s $f20,$f16,$f6 +.L0f193dd4: +/* f193dd4: 1140000d */ beqz $t2,.L0f193e0c +/* f193dd8: 24010005 */ addiu $at,$zero,0x5 +/* f193ddc: 8fab0274 */ lw $t3,0x274($sp) +/* f193de0: 3c013f80 */ lui $at,0x3f80 +/* f193de4: 44815000 */ mtc1 $at,$f10 +/* f193de8: c56002d4 */ lwc1 $f0,0x2d4($t3) +/* f193dec: c7c40104 */ lwc1 $f4,0x104($s8) +/* f193df0: c7c60100 */ lwc1 $f6,0x100($s8) +/* f193df4: 46000200 */ add.s $f8,$f0,$f0 +/* f193df8: 90430048 */ lbu $v1,0x48($v0) +/* f193dfc: 46005501 */ sub.s $f20,$f10,$f0 +/* f193e00: 46088081 */ sub.s $f2,$f16,$f8 +/* f193e04: 1000003c */ b .L0f193ef8 +/* f193e08: 46062381 */ sub.s $f14,$f4,$f6 +.L0f193e0c: +/* f193e0c: 14610016 */ bne $v1,$at,.L0f193e68 +/* f193e10: 03c02025 */ or $a0,$s8,$zero +/* f193e14: 0fc65227 */ jal func0f19489c +/* f193e18: e7a20094 */ swc1 $f2,0x94($sp) +/* f193e1c: 3c014080 */ lui $at,0x4080 +/* f193e20: 44818000 */ mtc1 $at,$f16 +/* f193e24: 3c017f1c */ lui $at,%hi(var7f1b8f50) +/* f193e28: 44806000 */ mtc1 $zero,$f12 +/* f193e2c: c4328f50 */ lwc1 $f18,%lo(var7f1b8f50)($at) +/* f193e30: 1040000d */ beqz $v0,.L0f193e68 +/* f193e34: c7a20094 */ lwc1 $f2,0x94($sp) +/* f193e38: 8fac0274 */ lw $t4,0x274($sp) +/* f193e3c: 3c014040 */ lui $at,0x4040 +/* f193e40: 44814000 */ mtc1 $at,$f8 +/* f193e44: c58002d4 */ lwc1 $f0,0x2d4($t4) +/* f193e48: c7c40104 */ lwc1 $f4,0x104($s8) +/* f193e4c: c7c60100 */ lwc1 $f6,0x100($s8) +/* f193e50: 46000280 */ add.s $f10,$f0,$f0 +/* f193e54: 8d8d0004 */ lw $t5,0x4($t4) +/* f193e58: 46062381 */ sub.s $f14,$f4,$f6 +/* f193e5c: 91a30048 */ lbu $v1,0x48($t5) +/* f193e60: 10000025 */ b .L0f193ef8 +/* f193e64: 460a4081 */ sub.s $f2,$f8,$f10 +.L0f193e68: +/* f193e68: 8fae0274 */ lw $t6,0x274($sp) +/* f193e6c: 93d802a0 */ lbu $t8,0x2a0($s8) +/* f193e70: c7c80104 */ lwc1 $f8,0x104($s8) +/* f193e74: c7ca0100 */ lwc1 $f10,0x100($s8) +/* f193e78: 8dcf0004 */ lw $t7,0x4($t6) +/* f193e7c: 2401002e */ addiu $at,$zero,0x2e +/* f193e80: 460a4381 */ sub.s $f14,$f8,$f10 +/* f193e84: 17010007 */ bne $t8,$at,.L0f193ea4 +/* f193e88: 91e30048 */ lbu $v1,0x48($t7) +/* f193e8c: c5c002d4 */ lwc1 $f0,0x2d4($t6) +/* f193e90: 3c013f80 */ lui $at,0x3f80 +/* f193e94: 4481a000 */ mtc1 $at,$f20 +/* f193e98: 46000100 */ add.s $f4,$f0,$f0 +/* f193e9c: 10000016 */ b .L0f193ef8 +/* f193ea0: 46048081 */ sub.s $f2,$f16,$f4 +.L0f193ea4: +/* f193ea4: 8fb9027c */ lw $t9,0x27c($sp) +/* f193ea8: 24010002 */ addiu $at,$zero,0x2 +/* f193eac: 8fa8027c */ lw $t0,0x27c($sp) +/* f193eb0: 17210003 */ bne $t9,$at,.L0f193ec0 +/* f193eb4: 00000000 */ nop +/* f193eb8: 1000000f */ b .L0f193ef8 +/* f193ebc: 46009506 */ mov.s $f20,$f18 +.L0f193ec0: +/* f193ec0: 15000006 */ bnez $t0,.L0f193edc +/* f193ec4: 8faa027c */ lw $t2,0x27c($sp) +/* f193ec8: 8fa90274 */ lw $t1,0x274($sp) +/* f193ecc: c52002d4 */ lwc1 $f0,0x2d4($t1) +/* f193ed0: 46000180 */ add.s $f6,$f0,$f0 +/* f193ed4: 10000008 */ b .L0f193ef8 +/* f193ed8: 46068501 */ sub.s $f20,$f16,$f6 +.L0f193edc: +/* f193edc: 24010001 */ addiu $at,$zero,0x1 +/* f193ee0: 15410005 */ bne $t2,$at,.L0f193ef8 +/* f193ee4: 8fab0274 */ lw $t3,0x274($sp) +/* f193ee8: 3c014000 */ lui $at,0x4000 +/* f193eec: 44814000 */ mtc1 $at,$f8 +/* f193ef0: c56a02d4 */ lwc1 $f10,0x2d4($t3) +/* f193ef4: 460a4501 */ sub.s $f20,$f8,$f10 +.L0f193ef8: +/* f193ef8: 1460001f */ bnez $v1,.L0f193f78 +/* f193efc: 24010001 */ addiu $at,$zero,0x1 +/* f193f00: 8fac0274 */ lw $t4,0x274($sp) +/* f193f04: 8faf0274 */ lw $t7,0x274($sp) +/* f193f08: 8d8202d0 */ lw $v0,0x2d0($t4) +/* f193f0c: 304d0007 */ andi $t5,$v0,0x7 +/* f193f10: 29a10002 */ slti $at,$t5,0x2 +/* f193f14: 10200004 */ beqz $at,.L0f193f28 +/* f193f18: 01a01025 */ or $v0,$t5,$zero +/* f193f1c: 46006506 */ mov.s $f20,$f12 +/* f193f20: 10000038 */ b .L0f194004 +/* f193f24: 46006086 */ mov.s $f2,$f12 +.L0f193f28: +/* f193f28: 28410004 */ slti $at,$v0,0x4 +/* f193f2c: 10200006 */ beqz $at,.L0f193f48 +/* f193f30: c5e002d4 */ lwc1 $f0,0x2d4($t7) +/* f193f34: 3c014000 */ lui $at,0x4000 +/* f193f38: 44812000 */ mtc1 $at,$f4 +/* f193f3c: 46006506 */ mov.s $f20,$f12 +/* f193f40: 10000030 */ b .L0f194004 +/* f193f44: 46002081 */ sub.s $f2,$f4,$f0 +.L0f193f48: +/* f193f48: 3c014180 */ lui $at,0x4180 +/* f193f4c: 44813000 */ mtc1 $at,$f6 +/* f193f50: 00000000 */ nop +/* f193f54: 46060202 */ mul.s $f8,$f0,$f6 +/* f193f58: 4608a501 */ sub.s $f20,$f20,$f8 +/* f193f5c: 460ca03e */ c.le.s $f20,$f12 +/* f193f60: 00000000 */ nop +/* f193f64: 45020028 */ bc1fl .L0f194008 +/* f193f68: 4602703c */ c.lt.s $f14,$f2 +/* f193f6c: 46141080 */ add.s $f2,$f2,$f20 +/* f193f70: 10000024 */ b .L0f194004 +/* f193f74: 46006506 */ mov.s $f20,$f12 +.L0f193f78: +/* f193f78: 14610016 */ bne $v1,$at,.L0f193fd4 +/* f193f7c: 8fb80274 */ lw $t8,0x274($sp) +/* f193f80: 8f0202d0 */ lw $v0,0x2d0($t8) +/* f193f84: 8fb90274 */ lw $t9,0x274($sp) +/* f193f88: 3c014130 */ lui $at,0x4130 +/* f193f8c: 304e0007 */ andi $t6,$v0,0x7 +/* f193f90: 5dc00005 */ bgtzl $t6,.L0f193fa8 +/* f193f94: c72a02d4 */ lwc1 $f10,0x2d4($t9) +/* f193f98: 46006506 */ mov.s $f20,$f12 +/* f193f9c: 10000019 */ b .L0f194004 +/* f193fa0: 46006086 */ mov.s $f2,$f12 +/* f193fa4: c72a02d4 */ lwc1 $f10,0x2d4($t9) +.L0f193fa8: +/* f193fa8: 44812000 */ mtc1 $at,$f4 +/* f193fac: 00000000 */ nop +/* f193fb0: 46045182 */ mul.s $f6,$f10,$f4 +/* f193fb4: 4606a501 */ sub.s $f20,$f20,$f6 +/* f193fb8: 460ca03e */ c.le.s $f20,$f12 +/* f193fbc: 00000000 */ nop +/* f193fc0: 45020011 */ bc1fl .L0f194008 +/* f193fc4: 4602703c */ c.lt.s $f14,$f2 +/* f193fc8: 46141080 */ add.s $f2,$f2,$f20 +/* f193fcc: 1000000d */ b .L0f194004 +/* f193fd0: 46006506 */ mov.s $f20,$f12 +.L0f193fd4: +/* f193fd4: 24010002 */ addiu $at,$zero,0x2 +/* f193fd8: 1461000a */ bne $v1,$at,.L0f194004 +/* f193fdc: 8fa80274 */ lw $t0,0x274($sp) +/* f193fe0: c50802d4 */ lwc1 $f8,0x2d4($t0) +/* f193fe4: 46104282 */ mul.s $f10,$f8,$f16 +/* f193fe8: 460aa501 */ sub.s $f20,$f20,$f10 +/* f193fec: 460ca03e */ c.le.s $f20,$f12 +/* f193ff0: 00000000 */ nop +/* f193ff4: 45020004 */ bc1fl .L0f194008 +/* f193ff8: 4602703c */ c.lt.s $f14,$f2 +/* f193ffc: 46141080 */ add.s $f2,$f2,$f20 +/* f194000: 46006506 */ mov.s $f20,$f12 +.L0f194004: +/* f194004: 4602703c */ c.lt.s $f14,$f2 +.L0f194008: +/* f194008: 00000000 */ nop +/* f19400c: 45020014 */ bc1fl .L0f194060 +/* f194010: 26730004 */ addiu $s3,$s3,0x4 +/* f194014: c7c40180 */ lwc1 $f4,0x180($s8) +/* f194018: 03b61021 */ addu $v0,$sp,$s6 +/* f19401c: 4614203e */ c.le.s $f4,$f20 +/* f194020: 00000000 */ nop +/* f194024: 4502000e */ bc1fl .L0f194060 +/* f194028: 26730004 */ addiu $s3,$s3,0x4 +/* f19402c: 8c420214 */ lw $v0,0x214($v0) +/* f194030: 03b64821 */ addu $t1,$sp,$s6 +/* f194034: 8faa00a0 */ lw $t2,0xa0($sp) +/* f194038: 50400009 */ beqzl $v0,.L0f194060 +/* f19403c: 26730004 */ addiu $s3,$s3,0x4 +/* f194040: 8d29022c */ lw $t1,0x22c($t1) +/* f194044: 012a082a */ slt $at,$t1,$t2 +/* f194048: 14200004 */ bnez $at,.L0f19405c +/* f19404c: 240b0001 */ addiu $t3,$zero,0x1 +/* f194050: afa200c8 */ sw $v0,0xc8($sp) +/* f194054: 10000008 */ b .L0f194078 +/* f194058: afab009c */ sw $t3,0x9c($sp) +.L0f19405c: +/* f19405c: 26730004 */ addiu $s3,$s3,0x4 +.L0f194060: +/* f194060: 0270082b */ sltu $at,$s3,$s0 +/* f194064: 10200004 */ beqz $at,.L0f194078 +/* f194068: 26d60004 */ addiu $s6,$s6,0x4 +/* f19406c: 8fac009c */ lw $t4,0x9c($sp) +/* f194070: 5180ff28 */ beqzl $t4,.L0f193d14 +/* f194074: 8e690000 */ lw $t1,0x0($s3) +.L0f194078: +/* f194078: 8fad009c */ lw $t5,0x9c($sp) +/* f19407c: afa000d8 */ sw $zero,0xd8($sp) +/* f194080: 0000b025 */ or $s6,$zero,$zero +/* f194084: 15a000fe */ bnez $t5,.L0f194480 +/* f194088: 27af025c */ addiu $t7,$sp,0x25c +/* f19408c: 000f9821 */ addu $s3,$zero,$t7 +/* f194090: 8fb70088 */ lw $s7,0x88($sp) +/* f194094: 8fb50084 */ lw $s5,0x84($sp) +/* f194098: 8e650000 */ lw $a1,0x0($s3) +.L0f19409c: +/* f19409c: 2401005b */ addiu $at,$zero,0x5a +/* f1940a0: 03b6c021 */ addu $t8,$sp,$s6 +/* f1940a4: 50a100ea */ beql $a1,$at,.L0f194450 +/* f1940a8: 8fb400d8 */ lw $s4,0xd8($sp) +/* f1940ac: 8f1800dc */ lw $t8,0xdc($t8) +/* f1940b0: 00057100 */ sll $t6,$a1,0x4 +/* f1940b4: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f1940b8: 130000e4 */ beqz $t8,.L0f19444c +/* f1940bc: 006e1821 */ addu $v1,$v1,$t6 +/* f1940c0: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +/* f1940c4: 03b65021 */ addu $t2,$sp,$s6 +/* f1940c8: 8fab00a0 */ lw $t3,0xa0($sp) +/* f1940cc: 0003cbc2 */ srl $t9,$v1,0xf +/* f1940d0: 17200003 */ bnez $t9,.L0f1940e0 +/* f1940d4: 00034c40 */ sll $t1,$v1,0x11 +/* f1940d8: 052300dd */ bgezl $t1,.L0f194450 +/* f1940dc: 8fb400d8 */ lw $s4,0xd8($sp) +.L0f1940e0: +/* f1940e0: 8d4a022c */ lw $t2,0x22c($t2) +/* f1940e4: 3c0c800b */ lui $t4,%hi(g_MpSetup+0x10) +/* f1940e8: 014b082a */ slt $at,$t2,$t3 +/* f1940ec: 542000d8 */ bnezl $at,.L0f194450 +/* f1940f0: 8fb400d8 */ lw $s4,0xd8($sp) +/* f1940f4: 918ccb98 */ lbu $t4,%lo(g_MpSetup+0x10)($t4) +/* f1940f8: 24010005 */ addiu $at,$zero,0x5 +/* f1940fc: 24140001 */ addiu $s4,$zero,0x1 +/* f194100: 55810008 */ bnel $t4,$at,.L0f194124 +/* f194104: 93cf02a0 */ lbu $t7,0x2a0($s8) +/* f194108: 0fc65227 */ jal func0f19489c +/* f19410c: 03c02025 */ or $a0,$s8,$zero +/* f194110: 10400003 */ beqz $v0,.L0f194120 +/* f194114: 240d0001 */ addiu $t5,$zero,0x1 +/* f194118: 100000d9 */ b .L0f194480 +/* f19411c: afad009c */ sw $t5,0x9c($sp) +.L0f194120: +/* f194120: 93cf02a0 */ lbu $t7,0x2a0($s8) +.L0f194124: +/* f194124: 2401002e */ addiu $at,$zero,0x2e +/* f194128: 8fae00c4 */ lw $t6,0xc4($sp) +/* f19412c: 15e10004 */ bne $t7,$at,.L0f194140 +/* f194130: 8fad027c */ lw $t5,0x27c($sp) +/* f194134: 24180001 */ addiu $t8,$zero,0x1 +/* f194138: 100000d1 */ b .L0f194480 +/* f19413c: afb8009c */ sw $t8,0x9c($sp) +.L0f194140: +/* f194140: 11c0002a */ beqz $t6,.L0f1941ec +/* f194144: 24010002 */ addiu $at,$zero,0x2 +/* f194148: 8e650000 */ lw $a1,0x0($s3) +/* f19414c: 3c088008 */ lui $t0,%hi(g_AibotWeaponPreferences) +/* f194150: 25087eb0 */ addiu $t0,$t0,%lo(g_AibotWeaponPreferences) +/* f194154: 0005c900 */ sll $t9,$a1,0x4 +/* f194158: 03281021 */ addu $v0,$t9,$t0 +/* f19415c: 9457000a */ lhu $s7,0xa($v0) +/* f194160: 94430004 */ lhu $v1,0x4($v0) +/* f194164: 00003025 */ or $a2,$zero,$zero +/* f194168: 2ae10002 */ slti $at,$s7,0x2 +/* f19416c: 14200002 */ bnez $at,.L0f194178 +/* f194170: 000323c2 */ srl $a0,$v1,0xf +/* f194174: 24170001 */ addiu $s7,$zero,0x1 +.L0f194178: +/* f194178: 9455000c */ lhu $s5,0xc($v0) +/* f19417c: 24070001 */ addiu $a3,$zero,0x1 +/* f194180: 2aa10002 */ slti $at,$s5,0x2 +/* f194184: 14200002 */ bnez $at,.L0f194190 +/* f194188: 00000000 */ nop +/* f19418c: 24150001 */ addiu $s5,$zero,0x1 +.L0f194190: +/* f194190: 5080000c */ beqzl $a0,.L0f1941c4 +/* f194194: 00035c40 */ sll $t3,$v1,0x11 +/* f194198: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f19419c: 8fa40274 */ lw $a0,0x274($sp) +/* f1941a0: 0057082a */ slt $at,$v0,$s7 +/* f1941a4: 5020000f */ beqzl $at,.L0f1941e4 +/* f1941a8: 240c0001 */ addiu $t4,$zero,0x1 +/* f1941ac: 8e650000 */ lw $a1,0x0($s3) +/* f1941b0: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f1941b4: 00054900 */ sll $t1,$a1,0x4 +/* f1941b8: 00691821 */ addu $v1,$v1,$t1 +/* f1941bc: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +/* f1941c0: 00035c40 */ sll $t3,$v1,0x11 +.L0f1941c4: +/* f1941c4: 05610080 */ bgez $t3,.L0f1943c8 +/* f1941c8: 8fa40274 */ lw $a0,0x274($sp) +/* f1941cc: 24060001 */ addiu $a2,$zero,0x1 +/* f1941d0: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f1941d4: 24070001 */ addiu $a3,$zero,0x1 +/* f1941d8: 0055082a */ slt $at,$v0,$s5 +/* f1941dc: 1420007a */ bnez $at,.L0f1943c8 +/* f1941e0: 240c0001 */ addiu $t4,$zero,0x1 +.L0f1941e4: +/* f1941e4: 100000a6 */ b .L0f194480 +/* f1941e8: afac009c */ sw $t4,0x9c($sp) +.L0f1941ec: +/* f1941ec: 15a1002f */ bne $t5,$at,.L0f1942ac +/* f1941f0: 8fa9027c */ lw $t1,0x27c($sp) +/* f1941f4: 8e640000 */ lw $a0,0x0($s3) +/* f1941f8: 0fc6666c */ jal weaponGetAmmoTypeByFunction +/* f1941fc: 00002825 */ or $a1,$zero,$zero +/* f194200: 0fc2a63d */ jal bgunGetCapacityByAmmotype +/* f194204: 00402025 */ or $a0,$v0,$zero +/* f194208: 0040b825 */ or $s7,$v0,$zero +/* f19420c: 8e640000 */ lw $a0,0x0($s3) +/* f194210: 0fc6666c */ jal weaponGetAmmoTypeByFunction +/* f194214: 24050001 */ addiu $a1,$zero,0x1 +/* f194218: 0fc2a63d */ jal bgunGetCapacityByAmmotype +/* f19421c: 00402025 */ or $a0,$v0,$zero +/* f194220: 8e650000 */ lw $a1,0x0($s3) +/* f194224: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f194228: 0040a825 */ or $s5,$v0,$zero +/* f19422c: 00057900 */ sll $t7,$a1,0x4 +/* f194230: 006f1821 */ addu $v1,$v1,$t7 +/* f194234: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +/* f194238: 8fa40274 */ lw $a0,0x274($sp) +/* f19423c: 00003025 */ or $a2,$zero,$zero +/* f194240: 0003c3c2 */ srl $t8,$v1,0xf +/* f194244: 5300000c */ beqzl $t8,.L0f194278 +/* f194248: 00034440 */ sll $t0,$v1,0x11 +/* f19424c: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f194250: 00003825 */ or $a3,$zero,$zero +/* f194254: 0057082a */ slt $at,$v0,$s7 +/* f194258: 14200012 */ bnez $at,.L0f1942a4 +/* f19425c: 00000000 */ nop +/* f194260: 8e650000 */ lw $a1,0x0($s3) +/* f194264: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f194268: 00057100 */ sll $t6,$a1,0x4 +/* f19426c: 006e1821 */ addu $v1,$v1,$t6 +/* f194270: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +/* f194274: 00034440 */ sll $t0,$v1,0x11 +.L0f194278: +/* f194278: 05010007 */ bgez $t0,.L0f194298 +/* f19427c: 8fa40274 */ lw $a0,0x274($sp) +/* f194280: 24060001 */ addiu $a2,$zero,0x1 +/* f194284: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f194288: 00003825 */ or $a3,$zero,$zero +/* f19428c: 0055082a */ slt $at,$v0,$s5 +/* f194290: 14200004 */ bnez $at,.L0f1942a4 +/* f194294: 00000000 */ nop +.L0f194298: +/* f194298: 8fb400d8 */ lw $s4,0xd8($sp) +/* f19429c: 1000006d */ b .L0f194454 +/* f1942a0: 26940001 */ addiu $s4,$s4,0x1 +.L0f1942a4: +/* f1942a4: 10000048 */ b .L0f1943c8 +/* f1942a8: 0000a025 */ or $s4,$zero,$zero +.L0f1942ac: +/* f1942ac: 15200022 */ bnez $t1,.L0f194338 +/* f1942b0: 8fb9027c */ lw $t9,0x27c($sp) +/* f1942b4: 8e650000 */ lw $a1,0x0($s3) +/* f1942b8: 3c0b8008 */ lui $t3,%hi(g_AibotWeaponPreferences) +/* f1942bc: 256b7eb0 */ addiu $t3,$t3,%lo(g_AibotWeaponPreferences) +/* f1942c0: 00055100 */ sll $t2,$a1,0x4 +/* f1942c4: 014b1021 */ addu $v0,$t2,$t3 +/* f1942c8: 94430004 */ lhu $v1,0x4($v0) +/* f1942cc: 94570006 */ lhu $s7,0x6($v0) +/* f1942d0: 94550008 */ lhu $s5,0x8($v0) +/* f1942d4: 000363c2 */ srl $t4,$v1,0xf +/* f1942d8: 1180000c */ beqz $t4,.L0f19430c +/* f1942dc: 8fa40274 */ lw $a0,0x274($sp) +/* f1942e0: 00003025 */ or $a2,$zero,$zero +/* f1942e4: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f1942e8: 24070001 */ addiu $a3,$zero,0x1 +/* f1942ec: 0057082a */ slt $at,$v0,$s7 +/* f1942f0: 5020000f */ beqzl $at,.L0f194330 +/* f1942f4: 240e0001 */ addiu $t6,$zero,0x1 +/* f1942f8: 8e650000 */ lw $a1,0x0($s3) +/* f1942fc: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f194300: 00056900 */ sll $t5,$a1,0x4 +/* f194304: 006d1821 */ addu $v1,$v1,$t5 +/* f194308: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +.L0f19430c: +/* f19430c: 0003c440 */ sll $t8,$v1,0x11 +/* f194310: 0701002d */ bgez $t8,.L0f1943c8 +/* f194314: 8fa40274 */ lw $a0,0x274($sp) +/* f194318: 24060001 */ addiu $a2,$zero,0x1 +/* f19431c: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f194320: 24070001 */ addiu $a3,$zero,0x1 +/* f194324: 0055082a */ slt $at,$v0,$s5 +/* f194328: 14200027 */ bnez $at,.L0f1943c8 +/* f19432c: 240e0001 */ addiu $t6,$zero,0x1 +.L0f194330: +/* f194330: 10000053 */ b .L0f194480 +/* f194334: afae009c */ sw $t6,0x9c($sp) +.L0f194338: +/* f194338: 24010001 */ addiu $at,$zero,0x1 +/* f19433c: 57210023 */ bnel $t9,$at,.L0f1943cc +/* f194340: 00008025 */ or $s0,$zero,$zero +/* f194344: 8e650000 */ lw $a1,0x0($s3) +/* f194348: 3c098008 */ lui $t1,%hi(g_AibotWeaponPreferences) +/* f19434c: 25297eb0 */ addiu $t1,$t1,%lo(g_AibotWeaponPreferences) +/* f194350: 00054100 */ sll $t0,$a1,0x4 +/* f194354: 01091021 */ addu $v0,$t0,$t1 +/* f194358: 94430004 */ lhu $v1,0x4($v0) +/* f19435c: 9457000a */ lhu $s7,0xa($v0) +/* f194360: 9455000c */ lhu $s5,0xc($v0) +/* f194364: 000353c2 */ srl $t2,$v1,0xf +/* f194368: 1140000c */ beqz $t2,.L0f19439c +/* f19436c: 8fa40274 */ lw $a0,0x274($sp) +/* f194370: 00003025 */ or $a2,$zero,$zero +/* f194374: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f194378: 24070001 */ addiu $a3,$zero,0x1 +/* f19437c: 0057082a */ slt $at,$v0,$s7 +/* f194380: 5020000f */ beqzl $at,.L0f1943c0 +/* f194384: 240f0001 */ addiu $t7,$zero,0x1 +/* f194388: 8e650000 */ lw $a1,0x0($s3) +/* f19438c: 3c038008 */ lui $v1,%hi(g_AibotWeaponPreferences+0x4) +/* f194390: 00055900 */ sll $t3,$a1,0x4 +/* f194394: 006b1821 */ addu $v1,$v1,$t3 +/* f194398: 94637eb4 */ lhu $v1,%lo(g_AibotWeaponPreferences+0x4)($v1) +.L0f19439c: +/* f19439c: 00036c40 */ sll $t5,$v1,0x11 +/* f1943a0: 05a10009 */ bgez $t5,.L0f1943c8 +/* f1943a4: 8fa40274 */ lw $a0,0x274($sp) +/* f1943a8: 24060001 */ addiu $a2,$zero,0x1 +/* f1943ac: 0fc666f9 */ jal aibotGetAmmoQuantityByWeapon +/* f1943b0: 24070001 */ addiu $a3,$zero,0x1 +/* f1943b4: 0055082a */ slt $at,$v0,$s5 +/* f1943b8: 14200003 */ bnez $at,.L0f1943c8 +/* f1943bc: 240f0001 */ addiu $t7,$zero,0x1 +.L0f1943c0: +/* f1943c0: 1000002f */ b .L0f194480 +/* f1943c4: afaf009c */ sw $t7,0x9c($sp) +.L0f1943c8: +/* f1943c8: 00008025 */ or $s0,$zero,$zero +.L0f1943cc: +/* f1943cc: 03c02025 */ or $a0,$s8,$zero +.L0f1943d0: +/* f1943d0: 8e650000 */ lw $a1,0x0($s3) +/* f1943d4: 0fc6639e */ jal func0f198e78 +/* f1943d8: 02003025 */ or $a2,$s0,$zero +/* f1943dc: 10400017 */ beqz $v0,.L0f19443c +/* f1943e0: 02002825 */ or $a1,$s0,$zero +/* f1943e4: 0fc6666c */ jal weaponGetAmmoTypeByFunction +/* f1943e8: 8e640000 */ lw $a0,0x0($s3) +/* f1943ec: 18400013 */ blez $v0,.L0f19443c +/* f1943f0: 00409025 */ or $s2,$v0,$zero +/* f1943f4: 12000003 */ beqz $s0,.L0f194404 +/* f1943f8: 8fa40274 */ lw $a0,0x274($sp) +/* f1943fc: 10000002 */ b .L0f194408 +/* f194400: 02a08825 */ or $s1,$s5,$zero +.L0f194404: +/* f194404: 02e08825 */ or $s1,$s7,$zero +.L0f194408: +/* f194408: 02402825 */ or $a1,$s2,$zero +/* f19440c: 0fc6672e */ jal aibotGetAmmoQuantityByType +/* f194410: 02803025 */ or $a2,$s4,$zero +/* f194414: 0051082a */ slt $at,$v0,$s1 +/* f194418: 10200008 */ beqz $at,.L0f19443c +/* f19441c: 0012c080 */ sll $t8,$s2,0x2 +/* f194420: 03b81021 */ addu $v0,$sp,$t8 +/* f194424: 8c420178 */ lw $v0,0x178($v0) +/* f194428: 10400004 */ beqz $v0,.L0f19443c +/* f19442c: 240e0001 */ addiu $t6,$zero,0x1 +/* f194430: afa200c8 */ sw $v0,0xc8($sp) +/* f194434: 10000005 */ b .L0f19444c +/* f194438: afae009c */ sw $t6,0x9c($sp) +.L0f19443c: +/* f19443c: 26100001 */ addiu $s0,$s0,0x1 +/* f194440: 24010002 */ addiu $at,$zero,0x2 +/* f194444: 5601ffe2 */ bnel $s0,$at,.L0f1943d0 +/* f194448: 03c02025 */ or $a0,$s8,$zero +.L0f19444c: +/* f19444c: 8fb400d8 */ lw $s4,0xd8($sp) +.L0f194450: +/* f194450: 26940001 */ addiu $s4,$s4,0x1 +.L0f194454: +/* f194454: afb400d8 */ sw $s4,0xd8($sp) +/* f194458: 8fb900d8 */ lw $t9,0xd8($sp) +/* f19445c: 26d60004 */ addiu $s6,$s6,0x4 +/* f194460: 26730004 */ addiu $s3,$s3,0x4 +/* f194464: 2b210006 */ slti $at,$t9,0x6 +/* f194468: 10200005 */ beqz $at,.L0f194480 +/* f19446c: 8fa8009c */ lw $t0,0x9c($sp) +/* f194470: 5100ff0a */ beqzl $t0,.L0f19409c +/* f194474: 8e650000 */ lw $a1,0x0($s3) +/* f194478: afb70088 */ sw $s7,0x88($sp) +/* f19447c: afb50084 */ sw $s5,0x84($sp) +.L0f194480: +/* f194480: 8fa9009c */ lw $t1,0x9c($sp) +/* f194484: afa000d8 */ sw $zero,0xd8($sp) +/* f194488: 0000b025 */ or $s6,$zero,$zero +/* f19448c: 15200036 */ bnez $t1,.L0f194568 +/* f194490: 27aa025c */ addiu $t2,$sp,0x25c +/* f194494: 000a9821 */ addu $s3,$zero,$t2 +/* f194498: 27b00274 */ addiu $s0,$sp,0x274 +/* f19449c: 8e6b0000 */ lw $t3,0x0($s3) +.L0f1944a0: +/* f1944a0: 2401005b */ addiu $at,$zero,0x5a +/* f1944a4: 3c0c800b */ lui $t4,%hi(g_MpSetup+0x10) +/* f1944a8: 51610029 */ beql $t3,$at,.L0f194550 +/* f1944ac: 26730004 */ addiu $s3,$s3,0x4 +/* f1944b0: 918ccb98 */ lbu $t4,%lo(g_MpSetup+0x10)($t4) +/* f1944b4: 24010005 */ addiu $at,$zero,0x5 +/* f1944b8: 55810008 */ bnel $t4,$at,.L0f1944dc +/* f1944bc: 93cf02a0 */ lbu $t7,0x2a0($s8) +/* f1944c0: 0fc65227 */ jal func0f19489c +/* f1944c4: 03c02025 */ or $a0,$s8,$zero +/* f1944c8: 10400003 */ beqz $v0,.L0f1944d8 +/* f1944cc: 240d0001 */ addiu $t5,$zero,0x1 +/* f1944d0: 10000025 */ b .L0f194568 +/* f1944d4: afad009c */ sw $t5,0x9c($sp) +.L0f1944d8: +/* f1944d8: 93cf02a0 */ lbu $t7,0x2a0($s8) +.L0f1944dc: +/* f1944dc: 2401002e */ addiu $at,$zero,0x2e +/* f1944e0: 8fae00c4 */ lw $t6,0xc4($sp) +/* f1944e4: 15e10004 */ bne $t7,$at,.L0f1944f8 +/* f1944e8: 03c02025 */ or $a0,$s8,$zero +/* f1944ec: 24180001 */ addiu $t8,$zero,0x1 +/* f1944f0: 1000001d */ b .L0f194568 +/* f1944f4: afb8009c */ sw $t8,0x9c($sp) +.L0f1944f8: +/* f1944f8: 15c00014 */ bnez $t6,.L0f19454c +/* f1944fc: 00003025 */ or $a2,$zero,$zero +/* f194500: 0fc6639e */ jal func0f198e78 +/* f194504: 8e650000 */ lw $a1,0x0($s3) +/* f194508: 14400005 */ bnez $v0,.L0f194520 +/* f19450c: 03c02025 */ or $a0,$s8,$zero +/* f194510: 8e650000 */ lw $a1,0x0($s3) +/* f194514: 0fc6639e */ jal func0f198e78 +/* f194518: 24060001 */ addiu $a2,$zero,0x1 +/* f19451c: 1040000b */ beqz $v0,.L0f19454c +.L0f194520: +/* f194520: 03b6c821 */ addu $t9,$sp,$s6 +/* f194524: 8f3900dc */ lw $t9,0xdc($t9) +/* f194528: 03b61021 */ addu $v0,$sp,$s6 +/* f19452c: 57200008 */ bnezl $t9,.L0f194550 +/* f194530: 26730004 */ addiu $s3,$s3,0x4 +/* f194534: 8c420214 */ lw $v0,0x214($v0) +/* f194538: 10400004 */ beqz $v0,.L0f19454c +/* f19453c: 24080001 */ addiu $t0,$zero,0x1 +/* f194540: afa200c8 */ sw $v0,0xc8($sp) +/* f194544: 10000008 */ b .L0f194568 +/* f194548: afa8009c */ sw $t0,0x9c($sp) +.L0f19454c: +/* f19454c: 26730004 */ addiu $s3,$s3,0x4 +.L0f194550: +/* f194550: 0270082b */ sltu $at,$s3,$s0 +/* f194554: 10200004 */ beqz $at,.L0f194568 +/* f194558: 26d60004 */ addiu $s6,$s6,0x4 +/* f19455c: 8fa9009c */ lw $t1,0x9c($sp) +/* f194560: 5120ffcf */ beqzl $t1,.L0f1944a0 +/* f194564: 8e6b0000 */ lw $t3,0x0($s3) +.L0f194568: +/* f194568: 8faa027c */ lw $t2,0x27c($sp) +/* f19456c: 24010002 */ addiu $at,$zero,0x2 +/* f194570: 55410032 */ bnel $t2,$at,.L0f19463c +/* f194574: 8fbf0044 */ lw $ra,0x44($sp) +/* f194578: 8fab009c */ lw $t3,0x9c($sp) +/* f19457c: afa000d8 */ sw $zero,0xd8($sp) +/* f194580: 24140001 */ addiu $s4,$zero,0x1 +/* f194584: 1560002c */ bnez $t3,.L0f194638 +/* f194588: 27b3025c */ addiu $s3,$sp,0x25c +/* f19458c: 27b50274 */ addiu $s5,$sp,0x274 +/* f194590: 8e6c0000 */ lw $t4,0x0($s3) +.L0f194594: +/* f194594: 2401005b */ addiu $at,$zero,0x5a +/* f194598: 00008825 */ or $s1,$zero,$zero +/* f19459c: 1181001f */ beq $t4,$at,.L0f19461c +/* f1945a0: 03c02025 */ or $a0,$s8,$zero +.L0f1945a4: +/* f1945a4: 8e650000 */ lw $a1,0x0($s3) +/* f1945a8: 0fc6639e */ jal func0f198e78 +/* f1945ac: 02203025 */ or $a2,$s1,$zero +/* f1945b0: 10400016 */ beqz $v0,.L0f19460c +/* f1945b4: 02202825 */ or $a1,$s1,$zero +/* f1945b8: 0fc6666c */ jal weaponGetAmmoTypeByFunction +/* f1945bc: 8e640000 */ lw $a0,0x0($s3) +/* f1945c0: 18400012 */ blez $v0,.L0f19460c +/* f1945c4: 00408025 */ or $s0,$v0,$zero +/* f1945c8: 8fa40274 */ lw $a0,0x274($sp) +/* f1945cc: 00402825 */ or $a1,$v0,$zero +/* f1945d0: 0fc6672e */ jal aibotGetAmmoQuantityByType +/* f1945d4: 00003025 */ or $a2,$zero,$zero +/* f1945d8: 00409025 */ or $s2,$v0,$zero +/* f1945dc: 0fc2a63d */ jal bgunGetCapacityByAmmotype +/* f1945e0: 02002025 */ or $a0,$s0,$zero +/* f1945e4: 0242082a */ slt $at,$s2,$v0 +/* f1945e8: 10200008 */ beqz $at,.L0f19460c +/* f1945ec: 00106880 */ sll $t5,$s0,0x2 +/* f1945f0: 03ad1021 */ addu $v0,$sp,$t5 +/* f1945f4: 8c420178 */ lw $v0,0x178($v0) +/* f1945f8: 10400004 */ beqz $v0,.L0f19460c +/* f1945fc: 240f0001 */ addiu $t7,$zero,0x1 +/* f194600: afa200c8 */ sw $v0,0xc8($sp) +/* f194604: 10000005 */ b .L0f19461c +/* f194608: afaf009c */ sw $t7,0x9c($sp) +.L0f19460c: +/* f19460c: 26310001 */ addiu $s1,$s1,0x1 +/* f194610: 24010002 */ addiu $at,$zero,0x2 +/* f194614: 5621ffe3 */ bnel $s1,$at,.L0f1945a4 +/* f194618: 03c02025 */ or $a0,$s8,$zero +.L0f19461c: +/* f19461c: 26730004 */ addiu $s3,$s3,0x4 +/* f194620: 0275082b */ sltu $at,$s3,$s5 +/* f194624: 10200004 */ beqz $at,.L0f194638 +/* f194628: 26940001 */ addiu $s4,$s4,0x1 +/* f19462c: 8fb8009c */ lw $t8,0x9c($sp) +/* f194630: 5300ffd8 */ beqzl $t8,.L0f194594 +/* f194634: 8e6c0000 */ lw $t4,0x0($s3) +.L0f194638: +/* f194638: 8fbf0044 */ lw $ra,0x44($sp) +.L0f19463c: +/* f19463c: 8fa200c8 */ lw $v0,0xc8($sp) +/* f194640: d7b40018 */ ldc1 $f20,0x18($sp) +/* f194644: 8fb00020 */ lw $s0,0x20($sp) +/* f194648: 8fb10024 */ lw $s1,0x24($sp) +/* f19464c: 8fb20028 */ lw $s2,0x28($sp) +/* f194650: 8fb3002c */ lw $s3,0x2c($sp) +/* f194654: 8fb40030 */ lw $s4,0x30($sp) +/* f194658: 8fb50034 */ lw $s5,0x34($sp) +/* f19465c: 8fb60038 */ lw $s6,0x38($sp) +/* f194660: 8fb7003c */ lw $s7,0x3c($sp) +/* f194664: 8fbe0040 */ lw $s8,0x40($sp) +/* f194668: 03e00008 */ jr $ra +/* f19466c: 27bd0278 */ addiu $sp,$sp,0x278 +); +#endif bool func0f194670(struct chrdata *chr) { diff --git a/src/game/game_19aa80.c b/src/game/game_19aa80.c index 18e684687..c8fd3edbd 100644 --- a/src/game/game_19aa80.c +++ b/src/game/game_19aa80.c @@ -109,6 +109,8 @@ void func0f19ab40(void) #else const char var7f1b3750nb[] = "VM: Page Misses %d (%d Replaces)"; const char var7f1b3774nb[] = "VM: TLB Misses %d"; +const char var7f1b3788nb[] = ""; +const char var7f1b378cnb[] = ""; GLOBAL_ASM( glabel func0f19ab40 diff --git a/src/game/gamefile.c b/src/game/gamefile.c index 121ad7ec0..b29baf420 100644 --- a/src/game/gamefile.c +++ b/src/game/gamefile.c @@ -798,8 +798,13 @@ void gamefileLoadDefaults(struct gamefile *file) file->autodifficulty = 0; file->autostageindex = 0; file->totaltime = 0; +#if VERSION >= VERSION_NTSC_1_0 sndSetSfxVolume(0x5000); optionsSetMusicVolume(0x5000); +#else + sndSetSfxVolume(0x7f80); + optionsSetMusicVolume(0x7f80); +#endif sndSetSoundMode(SOUNDMODE_STEREO); optionsSetControlMode(player1, CONTROLMODE_11); optionsSetControlMode(player2, CONTROLMODE_11); @@ -876,7 +881,12 @@ void gamefileLoadDefaults(struct gamefile *file) g_GameFile.firingrangescores[i] = 0; } - for (i = 0; i < ARRAYCOUNT(g_GameFile.weaponsfound); i++) { +#if VERSION >= VERSION_NTSC_1_0 + for (i = 0; i < ARRAYCOUNT(g_GameFile.weaponsfound); i++) +#else + for (i = 0; i < ARRAYCOUNT(g_GameFile.weaponsfound) - 2; i++) +#endif + { g_GameFile.weaponsfound[i] = 0; } @@ -997,6 +1007,7 @@ s32 gamefileLoad(s32 device) return -1; } +#if VERSION >= VERSION_NTSC_1_0 s32 gamefileSave(s32 device, s32 fileid, u16 deviceserial) { u32 stack; @@ -1147,6 +1158,470 @@ s32 gamefileSave(s32 device, s32 fileid, u16 deviceserial) return -1; } +#else +GLOBAL_ASM( +glabel gamefileSave +/* f10a380: 27bdfeb8 */ addiu $sp,$sp,-328 +/* f10a384: afb4002c */ sw $s4,0x2c($sp) +/* f10a388: 3c14800a */ lui $s4,0x800a +/* f10a38c: 2694e6c0 */ addiu $s4,$s4,-6464 +/* f10a390: 8e820298 */ lw $v0,0x298($s4) +/* f10a394: afbf0034 */ sw $ra,0x34($sp) +/* f10a398: afb50030 */ sw $s5,0x30($sp) +/* f10a39c: afb30028 */ sw $s3,0x28($sp) +/* f10a3a0: afb20024 */ sw $s2,0x24($sp) +/* f10a3a4: afb10020 */ sw $s1,0x20($sp) +/* f10a3a8: afb0001c */ sw $s0,0x1c($sp) +/* f10a3ac: afa40148 */ sw $a0,0x148($sp) +/* f10a3b0: afa5014c */ sw $a1,0x14c($sp) +/* f10a3b4: 04410005 */ bgez $v0,.NB0f10a3cc +/* f10a3b8: afa60150 */ sw $a2,0x150($sp) +/* f10a3bc: 8e8e029c */ lw $t6,0x29c($s4) +/* f10a3c0: 24110004 */ addiu $s1,$zero,0x4 +/* f10a3c4: 05c00003 */ bltz $t6,.NB0f10a3d4 +/* f10a3c8: 00000000 */ sll $zero,$zero,0x0 +.NB0f10a3cc: +/* f10a3cc: 10000001 */ beqz $zero,.NB0f10a3d4 +/* f10a3d0: 00008825 */ or $s1,$zero,$zero +.NB0f10a3d4: +/* f10a3d4: 04410005 */ bgez $v0,.NB0f10a3ec +/* f10a3d8: 24120001 */ addiu $s2,$zero,0x1 +/* f10a3dc: 8e8f029c */ lw $t7,0x29c($s4) +/* f10a3e0: 24130005 */ addiu $s3,$zero,0x5 +/* f10a3e4: 05e00003 */ bltz $t7,.NB0f10a3f4 +/* f10a3e8: 00000000 */ sll $zero,$zero,0x0 +.NB0f10a3ec: +/* f10a3ec: 10000001 */ beqz $zero,.NB0f10a3f4 +/* f10a3f0: 24130001 */ addiu $s3,$zero,0x1 +.NB0f10a3f4: +/* f10a3f4: 3c018007 */ lui $at,0x8007 +/* f10a3f8: ac327f70 */ sw $s2,0x7f70($at) +/* f10a3fc: 0fc5339c */ jal optionsGetForwardPitch +/* f10a400: 02202025 */ or $a0,$s1,$zero +/* f10a404: 3c10800a */ lui $s0,0x800a +/* f10a408: 26106704 */ addiu $s0,$s0,0x6704 +/* f10a40c: 02002825 */ or $a1,$s0,$zero +/* f10a410: 00002025 */ or $a0,$zero,$zero +/* f10a414: 0fc460eb */ jal pakSetBitflag +/* f10a418: 00403025 */ or $a2,$v0,$zero +/* f10a41c: 0fc533a5 */ jal optionsGetAutoAim +/* f10a420: 02202025 */ or $a0,$s1,$zero +/* f10a424: 02402025 */ or $a0,$s2,$zero +/* f10a428: 02002825 */ or $a1,$s0,$zero +/* f10a42c: 0fc460eb */ jal pakSetBitflag +/* f10a430: 00403025 */ or $a2,$v0,$zero +/* f10a434: 0fc533b7 */ jal optionsGetAimControl +/* f10a438: 02202025 */ or $a0,$s1,$zero +/* f10a43c: 24040002 */ addiu $a0,$zero,0x2 +/* f10a440: 02002825 */ or $a1,$s0,$zero +/* f10a444: 0fc460eb */ jal pakSetBitflag +/* f10a448: 00403025 */ or $a2,$v0,$zero +/* f10a44c: 0fc533c0 */ jal optionsGetSightOnScreen +/* f10a450: 02202025 */ or $a0,$s1,$zero +/* f10a454: 24040003 */ addiu $a0,$zero,0x3 +/* f10a458: 02002825 */ or $a1,$s0,$zero +/* f10a45c: 0fc460eb */ jal pakSetBitflag +/* f10a460: 00403025 */ or $a2,$v0,$zero +/* f10a464: 0fc533ae */ jal optionsGetLookAhead +/* f10a468: 02202025 */ or $a0,$s1,$zero +/* f10a46c: 24040004 */ addiu $a0,$zero,0x4 +/* f10a470: 02002825 */ or $a1,$s0,$zero +/* f10a474: 0fc460eb */ jal pakSetBitflag +/* f10a478: 00403025 */ or $a2,$v0,$zero +/* f10a47c: 0fc533c9 */ jal optionsGetAmmoOnScreen +/* f10a480: 02202025 */ or $a0,$s1,$zero +/* f10a484: 24040005 */ addiu $a0,$zero,0x5 +/* f10a488: 02002825 */ or $a1,$s0,$zero +/* f10a48c: 0fc460eb */ jal pakSetBitflag +/* f10a490: 00403025 */ or $a2,$v0,$zero +/* f10a494: 0fc53405 */ jal optionsGetHeadRoll +/* f10a498: 02202025 */ or $a0,$s1,$zero +/* f10a49c: 24040009 */ addiu $a0,$zero,0x9 +/* f10a4a0: 02002825 */ or $a1,$s0,$zero +/* f10a4a4: 0fc460eb */ jal pakSetBitflag +/* f10a4a8: 00403025 */ or $a2,$v0,$zero +/* f10a4ac: 0fc533d2 */ jal optionsGetShowGunFunction +/* f10a4b0: 02202025 */ or $a0,$s1,$zero +/* f10a4b4: 2404000a */ addiu $a0,$zero,0xa +/* f10a4b8: 02002825 */ or $a1,$s0,$zero +/* f10a4bc: 0fc460eb */ jal pakSetBitflag +/* f10a4c0: 00403025 */ or $a2,$v0,$zero +/* f10a4c4: 0fc533db */ jal optionsGetAlwaysShowTarget +/* f10a4c8: 02202025 */ or $a0,$s1,$zero +/* f10a4cc: 24040015 */ addiu $a0,$zero,0x15 +/* f10a4d0: 02002825 */ or $a1,$s0,$zero +/* f10a4d4: 0fc460eb */ jal pakSetBitflag +/* f10a4d8: 00403025 */ or $a2,$v0,$zero +/* f10a4dc: 0fc533e4 */ jal optionsGetShowZoomRange +/* f10a4e0: 02202025 */ or $a0,$s1,$zero +/* f10a4e4: 24040017 */ addiu $a0,$zero,0x17 +/* f10a4e8: 02002825 */ or $a1,$s0,$zero +/* f10a4ec: 0fc460eb */ jal pakSetBitflag +/* f10a4f0: 00403025 */ or $a2,$v0,$zero +/* f10a4f4: 0fc533f6 */ jal optionsGetShowMissionTime +/* f10a4f8: 02202025 */ or $a0,$s1,$zero +/* f10a4fc: 2404001a */ addiu $a0,$zero,0x1a +/* f10a500: 02002825 */ or $a1,$s0,$zero +/* f10a504: 0fc460eb */ jal pakSetBitflag +/* f10a508: 00403025 */ or $a2,$v0,$zero +/* f10a50c: 0fc533ed */ jal optionsGetPaintball +/* f10a510: 02202025 */ or $a0,$s1,$zero +/* f10a514: 24040020 */ addiu $a0,$zero,0x20 +/* f10a518: 02002825 */ or $a1,$s0,$zero +/* f10a51c: 0fc460eb */ jal pakSetBitflag +/* f10a520: 00403025 */ or $a2,$v0,$zero +/* f10a524: 0fc5339c */ jal optionsGetForwardPitch +/* f10a528: 02602025 */ or $a0,$s3,$zero +/* f10a52c: 2404000c */ addiu $a0,$zero,0xc +/* f10a530: 02002825 */ or $a1,$s0,$zero +/* f10a534: 0fc460eb */ jal pakSetBitflag +/* f10a538: 00403025 */ or $a2,$v0,$zero +/* f10a53c: 0fc533a5 */ jal optionsGetAutoAim +/* f10a540: 02602025 */ or $a0,$s3,$zero +/* f10a544: 2404000d */ addiu $a0,$zero,0xd +/* f10a548: 02002825 */ or $a1,$s0,$zero +/* f10a54c: 0fc460eb */ jal pakSetBitflag +/* f10a550: 00403025 */ or $a2,$v0,$zero +/* f10a554: 0fc533b7 */ jal optionsGetAimControl +/* f10a558: 02602025 */ or $a0,$s3,$zero +/* f10a55c: 2404000e */ addiu $a0,$zero,0xe +/* f10a560: 02002825 */ or $a1,$s0,$zero +/* f10a564: 0fc460eb */ jal pakSetBitflag +/* f10a568: 00403025 */ or $a2,$v0,$zero +/* f10a56c: 0fc533c0 */ jal optionsGetSightOnScreen +/* f10a570: 02602025 */ or $a0,$s3,$zero +/* f10a574: 2404000f */ addiu $a0,$zero,0xf +/* f10a578: 02002825 */ or $a1,$s0,$zero +/* f10a57c: 0fc460eb */ jal pakSetBitflag +/* f10a580: 00403025 */ or $a2,$v0,$zero +/* f10a584: 0fc533ae */ jal optionsGetLookAhead +/* f10a588: 02602025 */ or $a0,$s3,$zero +/* f10a58c: 24040010 */ addiu $a0,$zero,0x10 +/* f10a590: 02002825 */ or $a1,$s0,$zero +/* f10a594: 0fc460eb */ jal pakSetBitflag +/* f10a598: 00403025 */ or $a2,$v0,$zero +/* f10a59c: 0fc533c9 */ jal optionsGetAmmoOnScreen +/* f10a5a0: 02602025 */ or $a0,$s3,$zero +/* f10a5a4: 24040011 */ addiu $a0,$zero,0x11 +/* f10a5a8: 02002825 */ or $a1,$s0,$zero +/* f10a5ac: 0fc460eb */ jal pakSetBitflag +/* f10a5b0: 00403025 */ or $a2,$v0,$zero +/* f10a5b4: 0fc53405 */ jal optionsGetHeadRoll +/* f10a5b8: 02602025 */ or $a0,$s3,$zero +/* f10a5bc: 24040012 */ addiu $a0,$zero,0x12 +/* f10a5c0: 02002825 */ or $a1,$s0,$zero +/* f10a5c4: 0fc460eb */ jal pakSetBitflag +/* f10a5c8: 00403025 */ or $a2,$v0,$zero +/* f10a5cc: 0fc533d2 */ jal optionsGetShowGunFunction +/* f10a5d0: 02602025 */ or $a0,$s3,$zero +/* f10a5d4: 24040013 */ addiu $a0,$zero,0x13 +/* f10a5d8: 02002825 */ or $a1,$s0,$zero +/* f10a5dc: 0fc460eb */ jal pakSetBitflag +/* f10a5e0: 00403025 */ or $a2,$v0,$zero +/* f10a5e4: 0fc533db */ jal optionsGetAlwaysShowTarget +/* f10a5e8: 02602025 */ or $a0,$s3,$zero +/* f10a5ec: 24040016 */ addiu $a0,$zero,0x16 +/* f10a5f0: 02002825 */ or $a1,$s0,$zero +/* f10a5f4: 0fc460eb */ jal pakSetBitflag +/* f10a5f8: 00403025 */ or $a2,$v0,$zero +/* f10a5fc: 0fc533e4 */ jal optionsGetShowZoomRange +/* f10a600: 02602025 */ or $a0,$s3,$zero +/* f10a604: 24040018 */ addiu $a0,$zero,0x18 +/* f10a608: 02002825 */ or $a1,$s0,$zero +/* f10a60c: 0fc460eb */ jal pakSetBitflag +/* f10a610: 00403025 */ or $a2,$v0,$zero +/* f10a614: 0fc533f6 */ jal optionsGetShowMissionTime +/* f10a618: 02602025 */ or $a0,$s3,$zero +/* f10a61c: 2404001b */ addiu $a0,$zero,0x1b +/* f10a620: 02002825 */ or $a1,$s0,$zero +/* f10a624: 0fc460eb */ jal pakSetBitflag +/* f10a628: 00403025 */ or $a2,$v0,$zero +/* f10a62c: 0fc533ed */ jal optionsGetPaintball +/* f10a630: 02602025 */ or $a0,$s3,$zero +/* f10a634: 24040021 */ addiu $a0,$zero,0x21 +/* f10a638: 02002825 */ or $a1,$s0,$zero +/* f10a63c: 0fc460eb */ jal pakSetBitflag +/* f10a640: 00403025 */ or $a2,$v0,$zero +/* f10a644: 0fc53588 */ jal optionsGetScreenSplit +/* f10a648: 00000000 */ sll $zero,$zero,0x0 +/* f10a64c: 24040019 */ addiu $a0,$zero,0x19 +/* f10a650: 02002825 */ or $a1,$s0,$zero +/* f10a654: 0fc460eb */ jal pakSetBitflag +/* f10a658: 00403025 */ or $a2,$v0,$zero +/* f10a65c: 0fc53582 */ jal optionsGetScreenRatio +/* f10a660: 00000000 */ sll $zero,$zero,0x0 +/* f10a664: 24040007 */ addiu $a0,$zero,0x7 +/* f10a668: 02002825 */ or $a1,$s0,$zero +/* f10a66c: 0fc460eb */ jal pakSetBitflag +/* f10a670: 00403025 */ or $a2,$v0,$zero +/* f10a674: 0fc5351c */ jal optionsGetEffectiveScreenSize +/* f10a678: 00000000 */ sll $zero,$zero,0x0 +/* f10a67c: 00523026 */ xor $a2,$v0,$s2 +/* f10a680: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a684: 24040006 */ addiu $a0,$zero,0x6 +/* f10a688: 0fc460eb */ jal pakSetBitflag +/* f10a68c: 02002825 */ or $a1,$s0,$zero +/* f10a690: 0fc5351c */ jal optionsGetEffectiveScreenSize +/* f10a694: 00000000 */ sll $zero,$zero,0x0 +/* f10a698: 24150002 */ addiu $s5,$zero,0x2 +/* f10a69c: 00553026 */ xor $a2,$v0,$s5 +/* f10a6a0: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a6a4: 24040008 */ addiu $a0,$zero,0x8 +/* f10a6a8: 0fc460eb */ jal pakSetBitflag +/* f10a6ac: 02002825 */ or $a1,$s0,$zero +/* f10a6b0: 3c188007 */ lui $t8,0x8007 +/* f10a6b4: 8f182d88 */ lw $t8,0x2d88($t8) +/* f10a6b8: 24040022 */ addiu $a0,$zero,0x22 +/* f10a6bc: 02002825 */ or $a1,$s0,$zero +/* f10a6c0: 02583026 */ xor $a2,$s2,$t8 +/* f10a6c4: 0fc460eb */ jal pakSetBitflag +/* f10a6c8: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a6cc: 0fc533ff */ jal optionsGetInGameSubtitles +/* f10a6d0: 00000000 */ sll $zero,$zero,0x0 +/* f10a6d4: 2404000b */ addiu $a0,$zero,0xb +/* f10a6d8: 02002825 */ or $a1,$s0,$zero +/* f10a6dc: 0fc460eb */ jal pakSetBitflag +/* f10a6e0: 00403025 */ or $a2,$v0,$zero +/* f10a6e4: 0fc53402 */ jal optionsGetCutsceneSubtitles +/* f10a6e8: 00000000 */ sll $zero,$zero,0x0 +/* f10a6ec: 24040014 */ addiu $a0,$zero,0x14 +/* f10a6f0: 02002825 */ or $a1,$s0,$zero +/* f10a6f4: 0fc460eb */ jal pakSetBitflag +/* f10a6f8: 00403025 */ or $a2,$v0,$zero +/* f10a6fc: 24040040 */ addiu $a0,$zero,0x40 +/* f10a700: 02002825 */ or $a1,$s0,$zero +/* f10a704: 0fc460eb */ jal pakSetBitflag +/* f10a708: 928604e3 */ lbu $a2,0x4e3($s4) +/* f10a70c: 0fc5351c */ jal optionsGetEffectiveScreenSize +/* f10a710: 00000000 */ sll $zero,$zero,0x0 +/* f10a714: 50400002 */ beqzl $v0,.NB0f10a720 +/* f10a718: 8e990450 */ lw $t9,0x450($s4) +/* f10a71c: 8e990450 */ lw $t9,0x450($s4) +.NB0f10a720: +/* f10a720: 2404001f */ addiu $a0,$zero,0x1f +/* f10a724: 02002825 */ or $a1,$s0,$zero +/* f10a728: 02593026 */ xor $a2,$s2,$t9 +/* f10a72c: 0fc460eb */ jal pakSetBitflag +/* f10a730: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a734: 8e880448 */ lw $t0,0x448($s4) +/* f10a738: 2404001c */ addiu $a0,$zero,0x1c +/* f10a73c: 02002825 */ or $a1,$s0,$zero +/* f10a740: 02483026 */ xor $a2,$s2,$t0 +/* f10a744: 0fc460eb */ jal pakSetBitflag +/* f10a748: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a74c: 8e890454 */ lw $t1,0x454($s4) +/* f10a750: 2404001d */ addiu $a0,$zero,0x1d +/* f10a754: 02002825 */ or $a1,$s0,$zero +/* f10a758: 02493026 */ xor $a2,$s2,$t1 +/* f10a75c: 0fc460eb */ jal pakSetBitflag +/* f10a760: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a764: 8e8a044c */ lw $t2,0x44c($s4) +/* f10a768: 2404001e */ addiu $a0,$zero,0x1e +/* f10a76c: 02002825 */ or $a1,$s0,$zero +/* f10a770: 024a3026 */ xor $a2,$s2,$t2 +/* f10a774: 0fc460eb */ jal pakSetBitflag +/* f10a778: 2cc60001 */ sltiu $a2,$a2,0x1 +/* f10a77c: 8fab0148 */ lw $t3,0x148($sp) +/* f10a780: 27b4004c */ addiu $s4,$sp,0x4c +/* f10a784: 2402ffff */ addiu $v0,$zero,-1 +/* f10a788: 056000ae */ bltz $t3,.NB0f10aa44 +/* f10a78c: 00000000 */ sll $zero,$zero,0x0 +/* f10a790: 0fc34ad1 */ jal savebufferClear +/* f10a794: 02802025 */ or $a0,$s4,$zero +/* f10a798: 3c12800a */ lui $s2,0x800a +/* f10a79c: 265266f0 */ addiu $s2,$s2,0x66f0 +/* f10a7a0: 02402825 */ or $a1,$s2,$zero +/* f10a7a4: 0fc34b23 */ jal func0f0d55a4 +/* f10a7a8: 02802025 */ or $a0,$s4,$zero +/* f10a7ac: 9245000b */ lbu $a1,0xb($s2) +/* f10a7b0: 02802025 */ or $a0,$s4,$zero +/* f10a7b4: 24060005 */ addiu $a2,$zero,0x5 +/* f10a7b8: 000560c2 */ srl $t4,$a1,0x3 +/* f10a7bc: 0fc34a9e */ jal savebufferOr +/* f10a7c0: 01802825 */ or $a1,$t4,$zero +/* f10a7c4: 02802025 */ or $a0,$s4,$zero +/* f10a7c8: 8e450010 */ lw $a1,0x10($s2) +/* f10a7cc: 0fc34a9e */ jal savebufferOr +/* f10a7d0: 24060020 */ addiu $a2,$zero,0x20 +/* f10a7d4: 8e450008 */ lw $a1,0x8($s2) +/* f10a7d8: 02802025 */ or $a0,$s4,$zero +/* f10a7dc: 24060002 */ addiu $a2,$zero,0x2 +/* f10a7e0: 30ad0007 */ andi $t5,$a1,0x7 +/* f10a7e4: 0fc34a9e */ jal savebufferOr +/* f10a7e8: 01a02825 */ or $a1,$t5,$zero +/* f10a7ec: 02802025 */ or $a0,$s4,$zero +/* f10a7f0: 9245000c */ lbu $a1,0xc($s2) +/* f10a7f4: 0fc34a9e */ jal savebufferOr +/* f10a7f8: 24060005 */ addiu $a2,$zero,0x5 +/* f10a7fc: 3c078006 */ lui $a3,0x8006 +/* f10a800: 94e7f6e8 */ lhu $a3,-0x918($a3) +/* f10a804: 02802025 */ or $a0,$s4,$zero +/* f10a808: 24060006 */ addiu $a2,$zero,0x6 +/* f10a80c: 000771c3 */ sra $t6,$a3,0x7 +/* f10a810: 0fc34a9e */ jal savebufferOr +/* f10a814: 000e2882 */ srl $a1,$t6,0x2 +/* f10a818: 0fc5358f */ jal optionsGetMusicVolume +/* f10a81c: 00000000 */ sll $zero,$zero,0x0 +/* f10a820: 000229c3 */ sra $a1,$v0,0x7 +/* f10a824: 00057882 */ srl $t7,$a1,0x2 +/* f10a828: 01e02825 */ or $a1,$t7,$zero +/* f10a82c: 02802025 */ or $a0,$s4,$zero +/* f10a830: 0fc34a9e */ jal savebufferOr +/* f10a834: 24060006 */ addiu $a2,$zero,0x6 +/* f10a838: 3c078006 */ lui $a3,0x8006 +/* f10a83c: 8ce5f6ec */ lw $a1,-0x914($a3) +/* f10a840: 02802025 */ or $a0,$s4,$zero +/* f10a844: 0fc34a9e */ jal savebufferOr +/* f10a848: 24060002 */ addiu $a2,$zero,0x2 +/* f10a84c: 0fc53380 */ jal optionsGetControlMode +/* f10a850: 02202025 */ or $a0,$s1,$zero +/* f10a854: 02802025 */ or $a0,$s4,$zero +/* f10a858: 00402825 */ or $a1,$v0,$zero +/* f10a85c: 0fc34a9e */ jal savebufferOr +/* f10a860: 24060003 */ addiu $a2,$zero,0x3 +/* f10a864: 0fc53380 */ jal optionsGetControlMode +/* f10a868: 02602025 */ or $a0,$s3,$zero +/* f10a86c: 02802025 */ or $a0,$s4,$zero +/* f10a870: 00402825 */ or $a1,$v0,$zero +/* f10a874: 0fc34a9e */ jal savebufferOr +/* f10a878: 24060003 */ addiu $a2,$zero,0x3 +/* f10a87c: 3c10800a */ lui $s0,0x800a +/* f10a880: 3c11800a */ lui $s1,0x800a +/* f10a884: 263166fa */ addiu $s1,$s1,0x66fa +/* f10a888: 261066f0 */ addiu $s0,$s0,0x66f0 +/* f10a88c: 02802025 */ or $a0,$s4,$zero +.NB0f10a890: +/* f10a890: 92050014 */ lbu $a1,0x14($s0) +/* f10a894: 0fc34a9e */ jal savebufferOr +/* f10a898: 24060008 */ addiu $a2,$zero,0x8 +/* f10a89c: 26100001 */ addiu $s0,$s0,0x1 +/* f10a8a0: 0211082b */ sltu $at,$s0,$s1 +/* f10a8a4: 5420fffa */ bnezl $at,.NB0f10a890 +/* f10a8a8: 02802025 */ or $a0,$s4,$zero +/* f10a8ac: 02802025 */ or $a0,$s4,$zero +/* f10a8b0: 9645001e */ lhu $a1,0x1e($s2) +/* f10a8b4: 0fc34a9e */ jal savebufferOr +/* f10a8b8: 24060010 */ addiu $a2,$zero,0x10 +/* f10a8bc: 3c15800a */ lui $s5,0x800a +/* f10a8c0: 26b566f0 */ addiu $s5,$s5,0x66f0 +/* f10a8c4: 24130006 */ addiu $s3,$zero,0x6 +/* f10a8c8: 00008825 */ or $s1,$zero,$zero +.NB0f10a8cc: +/* f10a8cc: 02a09025 */ or $s2,$s5,$zero +.NB0f10a8d0: +/* f10a8d0: 02802025 */ or $a0,$s4,$zero +/* f10a8d4: 96450020 */ lhu $a1,0x20($s2) +/* f10a8d8: 0fc34a9e */ jal savebufferOr +/* f10a8dc: 2406000c */ addiu $a2,$zero,0xc +/* f10a8e0: 26310002 */ addiu $s1,$s1,0x2 +/* f10a8e4: 1633fffa */ bne $s1,$s3,.NB0f10a8d0 +/* f10a8e8: 26520002 */ addiu $s2,$s2,0x2 +/* f10a8ec: 3c18800a */ lui $t8,0x800a +/* f10a8f0: 2718676e */ addiu $t8,$t8,0x676e +/* f10a8f4: 26b50006 */ addiu $s5,$s5,0x6 +/* f10a8f8: 02b8082b */ sltu $at,$s5,$t8 +/* f10a8fc: 5420fff3 */ bnezl $at,.NB0f10a8cc +/* f10a900: 00008825 */ or $s1,$zero,$zero +/* f10a904: 00008825 */ or $s1,$zero,$zero +/* f10a908: 24120005 */ addiu $s2,$zero,0x5 +/* f10a90c: 24100001 */ addiu $s0,$zero,0x1 +.NB0f10a910: +/* f10a910: 02202025 */ or $a0,$s1,$zero +.NB0f10a914: +/* f10a914: 0fc65912 */ jal mpIsChallengeCompletedByAnyPlayerWithNumPlayers +/* f10a918: 02002825 */ or $a1,$s0,$zero +/* f10a91c: 02802025 */ or $a0,$s4,$zero +/* f10a920: 00402825 */ or $a1,$v0,$zero +/* f10a924: 0fc34a9e */ jal savebufferOr +/* f10a928: 24060001 */ addiu $a2,$zero,0x1 +/* f10a92c: 26100001 */ addiu $s0,$s0,0x1 +/* f10a930: 5612fff8 */ bnel $s0,$s2,.NB0f10a914 +/* f10a934: 02202025 */ or $a0,$s1,$zero +/* f10a938: 26310001 */ addiu $s1,$s1,0x1 +/* f10a93c: 2a21001e */ slti $at,$s1,0x1e +/* f10a940: 5420fff3 */ bnezl $at,.NB0f10a910 +/* f10a944: 24100001 */ addiu $s0,$zero,0x1 +/* f10a948: 3c10800a */ lui $s0,0x800a +/* f10a94c: 3c11800a */ lui $s1,0x800a +/* f10a950: 263166fc */ addiu $s1,$s1,0x66fc +/* f10a954: 261066f0 */ addiu $s0,$s0,0x66f0 +/* f10a958: 02802025 */ or $a0,$s4,$zero +.NB0f10a95c: +/* f10a95c: 8e0500a0 */ lw $a1,0xa0($s0) +/* f10a960: 0fc34a9e */ jal savebufferOr +/* f10a964: 24060015 */ addiu $a2,$zero,0x15 +/* f10a968: 26100004 */ addiu $s0,$s0,0x4 +/* f10a96c: 0211082b */ sltu $at,$s0,$s1 +/* f10a970: 5420fffa */ bnezl $at,.NB0f10a95c +/* f10a974: 02802025 */ or $a0,$s4,$zero +/* f10a978: 3c10800a */ lui $s0,0x800a +/* f10a97c: 3c12800a */ lui $s2,0x800a +/* f10a980: 3c11800a */ lui $s1,0x800a +/* f10a984: 263166f8 */ addiu $s1,$s1,0x66f8 +/* f10a988: 265266f9 */ addiu $s2,$s2,0x66f9 +/* f10a98c: 261066f0 */ addiu $s0,$s0,0x66f0 +.NB0f10a990: +/* f10a990: 16110003 */ bne $s0,$s1,.NB0f10a9a0 +/* f10a994: 02802025 */ or $a0,$s4,$zero +/* f10a998: 10000002 */ beqz $zero,.NB0f10a9a4 +/* f10a99c: 24060002 */ addiu $a2,$zero,0x2 +.NB0f10a9a0: +/* f10a9a0: 24060008 */ addiu $a2,$zero,0x8 +.NB0f10a9a4: +/* f10a9a4: 0fc34a9e */ jal savebufferOr +/* f10a9a8: 920500ac */ lbu $a1,0xac($s0) +/* f10a9ac: 26100001 */ addiu $s0,$s0,0x1 +/* f10a9b0: 0212082b */ sltu $at,$s0,$s2 +/* f10a9b4: 1420fff6 */ bnez $at,.NB0f10a990 +/* f10a9b8: 00000000 */ sll $zero,$zero,0x0 +/* f10a9bc: 3c10800a */ lui $s0,0x800a +/* f10a9c0: 3c11800a */ lui $s1,0x800a +/* f10a9c4: 263166f4 */ addiu $s1,$s1,0x66f4 +/* f10a9c8: 261066f0 */ addiu $s0,$s0,0x66f0 +/* f10a9cc: 02802025 */ or $a0,$s4,$zero +.NB0f10a9d0: +/* f10a9d0: 920500b5 */ lbu $a1,0xb5($s0) +/* f10a9d4: 0fc34a9e */ jal savebufferOr +/* f10a9d8: 24060008 */ addiu $a2,$zero,0x8 +/* f10a9dc: 26100001 */ addiu $s0,$s0,0x1 +/* f10a9e0: 5611fffb */ bnel $s0,$s1,.NB0f10a9d0 +/* f10a9e4: 02802025 */ or $a0,$s4,$zero +/* f10a9e8: 0fc34aeb */ jal func0f0d54c4 +/* f10a9ec: 02802025 */ or $a0,$s4,$zero +/* f10a9f0: 27b90140 */ addiu $t9,$sp,0x140 +/* f10a9f4: afb90010 */ sw $t9,0x10($sp) +/* f10a9f8: 83a4014b */ lb $a0,0x14b($sp) +/* f10a9fc: 8fa5014c */ lw $a1,0x14c($sp) +/* f10aa00: 24060080 */ addiu $a2,$zero,0x80 +/* f10aa04: 27a70050 */ addiu $a3,$sp,0x50 +/* f10aa08: 0fc442fb */ jal pakSaveAtGuid +/* f10aa0c: afa00014 */ sw $zero,0x14($sp) +/* f10aa10: 3c01800a */ lui $at,0x800a +/* f10aa14: 14400009 */ bnez $v0,.NB0f10aa3c +/* f10aa18: ac2266e8 */ sw $v0,0x66e8($at) +/* f10aa1c: 8fa80140 */ lw $t0,0x140($sp) +/* f10aa20: 97a90152 */ lhu $t1,0x152($sp) +/* f10aa24: 3c03800a */ lui $v1,0x800a +/* f10aa28: 246367b0 */ addiu $v1,$v1,0x67b0 +/* f10aa2c: 00001025 */ or $v0,$zero,$zero +/* f10aa30: ac680000 */ sw $t0,0x0($v1) +/* f10aa34: 10000003 */ beqz $zero,.NB0f10aa44 +/* f10aa38: a4690004 */ sh $t1,0x4($v1) +.NB0f10aa3c: +/* f10aa3c: 10000001 */ beqz $zero,.NB0f10aa44 +/* f10aa40: 2402ffff */ addiu $v0,$zero,-1 +.NB0f10aa44: +/* f10aa44: 8fbf0034 */ lw $ra,0x34($sp) +/* f10aa48: 8fb0001c */ lw $s0,0x1c($sp) +/* f10aa4c: 8fb10020 */ lw $s1,0x20($sp) +/* f10aa50: 8fb20024 */ lw $s2,0x24($sp) +/* f10aa54: 8fb30028 */ lw $s3,0x28($sp) +/* f10aa58: 8fb4002c */ lw $s4,0x2c($sp) +/* f10aa5c: 8fb50030 */ lw $s5,0x30($sp) +/* f10aa60: 03e00008 */ jr $ra +/* f10aa64: 27bd0148 */ addiu $sp,$sp,0x148 +); +#endif void gamefileGetOverview(char *arg0, char *name, u8 *stage, u8 *difficulty, u32 *time) { diff --git a/src/game/hudmsg.c b/src/game/hudmsg.c index 0084c5711..50bfbc660 100644 --- a/src/game/hudmsg.c +++ b/src/game/hudmsg.c @@ -21,14 +21,6 @@ #include "data.h" #include "types.h" -const char var7f1ade80[] = "%s%s%4.2fX"; -const char var7f1ade8c[] = ""; -const char var7f1ade90[] = ""; -const char var7f1ade94[] = "/"; -const char var7f1ade98[] = "%s%s%4.2fX"; -const char var7f1adea4[] = ""; -const char var7f1adea8[] = ""; - u32 g_NextHudMessageId; u8 g_HudmsgsActive = 0; @@ -439,6 +431,14 @@ glabel hudmsgRenderMissionTimer // return textRender(gdl, &sp8c, &sp88, buffer, g_CharsNumeric, g_FontNumeric, textcolour, 0x000000a0, viGetWidth(), viGetHeight(), 0, 0); //} +const char var7f1ade80[] = "%s%s%4.2fX"; +const char var7f1ade8c[] = ""; +const char var7f1ade90[] = ""; +const char var7f1ade94[] = "/"; +const char var7f1ade98[] = "%s%s%4.2fX"; +const char var7f1adea4[] = ""; +const char var7f1adea8[] = ""; + #if VERSION >= VERSION_NTSC_FINAL GLOBAL_ASM( glabel hudmsgRenderZoomRange @@ -1007,12 +1007,12 @@ glabel hudmsgRenderZoomRange /* f0dd508: 46062300 */ add.s $f12,$f4,$f6 /* f0dd50c: 46006221 */ cvt.d.s $f8,$f12 .L0f0dd510_2: -/* f0dd510: 3c057f1b */ lui $a1,0x7f1b -/* f0dd514: 3c067f1b */ lui $a2,0x7f1b -/* f0dd518: 3c077f1b */ lui $a3,0x7f1b -/* f0dd51c: 24e7dc50 */ addiu $a3,$a3,-9136 -/* f0dd520: 24c6dc4c */ addiu $a2,$a2,-9140 -/* f0dd524: 24a5dc40 */ addiu $a1,$a1,-9152 +/* f0dd510: 3c057f1b */ lui $a1,%hi(var7f1ade80) +/* f0dd514: 3c067f1b */ lui $a2,%hi(var7f1ade8c) +/* f0dd518: 3c077f1b */ lui $a3,%hi(var7f1ade90) +/* f0dd51c: 24e7dc50 */ addiu $a3,$a3,%lo(var7f1ade90) +/* f0dd520: 24c6dc4c */ addiu $a2,$a2,%lo(var7f1ade8c) +/* f0dd524: 24a5dc40 */ addiu $a1,$a1,%lo(var7f1ade80) /* f0dd528: f7a80010 */ sdc1 $f8,0x10($sp) /* f0dd52c: 0c004dad */ jal sprintf /* f0dd530: 27a40084 */ addiu $a0,$sp,0x84 @@ -1080,9 +1080,9 @@ glabel hudmsgRenderZoomRange /* f0dd628: afad0010 */ sw $t5,0x10($sp) /* f0dd62c: 0fc55b06 */ jal textRender /* f0dd630: afaa0020 */ sw $t2,0x20($sp) -/* f0dd634: 3c057f1b */ lui $a1,0x7f1b +/* f0dd634: 3c057f1b */ lui $a1,%hi(var7f1ade94) /* f0dd638: afa200c0 */ sw $v0,0xc0($sp) -/* f0dd63c: 24a5dc54 */ addiu $a1,$a1,-9132 +/* f0dd63c: 24a5dc54 */ addiu $a1,$a1,%lo(var7f1ade94) /* f0dd640: 0c004dad */ jal sprintf /* f0dd644: 27a40084 */ addiu $a0,$sp,0x84 /* f0dd648: 3c0b8008 */ lui $t3,%hi(g_FontNumeric) @@ -1138,15 +1138,15 @@ glabel hudmsgRenderZoomRange /* f0dd710: 0fc55b06 */ jal textRender /* f0dd714: afad0020 */ sw $t5,0x20($sp) /* f0dd718: c7aa009c */ lwc1 $f10,0x9c($sp) -/* f0dd71c: 3c057f1b */ lui $a1,0x7f1b -/* f0dd720: 3c067f1b */ lui $a2,0x7f1b +/* f0dd71c: 3c057f1b */ lui $a1,%hi(var7f1ade98) +/* f0dd720: 3c067f1b */ lui $a2,%hi(var7f1adea4) /* f0dd724: 460054a1 */ cvt.d.s $f18,$f10 -/* f0dd728: 3c077f1b */ lui $a3,0x7f1b +/* f0dd728: 3c077f1b */ lui $a3,%hi(var7f1adea8) /* f0dd72c: afa200c0 */ sw $v0,0xc0($sp) -/* f0dd730: 24e7dc68 */ addiu $a3,$a3,-9112 +/* f0dd730: 24e7dc68 */ addiu $a3,$a3,%lo(var7f1adea8) /* f0dd734: f7b20010 */ sdc1 $f18,0x10($sp) -/* f0dd738: 24c6dc64 */ addiu $a2,$a2,-9116 -/* f0dd73c: 24a5dc58 */ addiu $a1,$a1,-9128 +/* f0dd738: 24c6dc64 */ addiu $a2,$a2,%lo(var7f1adea4) +/* f0dd73c: 24a5dc58 */ addiu $a1,$a1,%lo(var7f1ade98) /* f0dd740: 0c004dad */ jal sprintf /* f0dd744: 27a40084 */ addiu $a0,$sp,0x84 /* f0dd748: 3c0e8008 */ lui $t6,%hi(g_FontNumeric) diff --git a/src/game/lv.c b/src/game/lv.c index 3d17befac..325ee8562 100644 --- a/src/game/lv.c +++ b/src/game/lv.c @@ -4377,11 +4377,6 @@ Gfx *lvRender(Gfx *gdl) return gdl; } #else -u32 var80086910nb[] = { - 0x00000000, 0x00000000, 0x00000000, 0x1e000000, - 0x00000000, 0x00000064, 0x00000000, 0x00000000, -}; - GLOBAL_ASM( glabel lvRender .late_rodata @@ -6516,11 +6511,24 @@ u32 var800840a4 = 0; u32 var800840a8 = 100; u32 var800840ac = 0; u32 g_CutsceneTime240_60 = 0; -#else +#elif VERSION >= VERSION_NTSC_1_0 u32 g_CutsceneTime240_60 = 0; u32 var800840a8 = 0; u32 var800840ac = 0; u32 var800840b0 = 0; +#else +u32 var80086910nb = 0; +u32 var80086914nb = 0; +u32 var80086918nb = 0; +u32 var8008691cnb = 0x1e000000; +u32 var80086920nb = 0; +u32 var80086924nb = 100; +u32 var80086928nb = 0; +u32 g_CutsceneTime240_60 = 0; +u32 var80086930nb = 0; +u32 var800840a8 = 0; +u32 var800840ac = 0; +u32 var800840b0 = 0; #endif u32 var800840b4 = 0; diff --git a/src/game/mainmenu.c b/src/game/mainmenu.c index f44c5de5a..ac29f27f3 100644 --- a/src/game/mainmenu.c +++ b/src/game/mainmenu.c @@ -2113,10 +2113,10 @@ struct stageoverviewentry g_StageNames[NUM_SOLOSTAGES] = { { STAGE_DEFENSE, 0x1a, L_OPTIONS_161, L_OPTIONS_162, L_OPTIONS_161 }, { STAGE_ATTACKSHIP, 0x1b, L_OPTIONS_163, L_OPTIONS_164, L_OPTIONS_163 }, { STAGE_SKEDARRUINS, 0x1c, L_OPTIONS_165, L_OPTIONS_166, L_OPTIONS_165 }, - { STAGE_MBR, 0x1c, L_OPTIONS_167, L_OPTIONS_003, L_OPTIONS_167 }, - { STAGE_MAIANSOS, 0x1c, L_OPTIONS_168, L_OPTIONS_003, L_OPTIONS_168 }, - { STAGE_WAR, 0x1c, L_OPTIONS_170, L_OPTIONS_003, L_OPTIONS_170 }, - { STAGE_DUEL, 0x1c, L_OPTIONS_171, L_OPTIONS_003, L_OPTIONS_171 }, + { STAGE_MBR, 0x1c, L_OPTIONS_167, L_OPTIONS_003, L_OPTIONS_167 }, + { STAGE_MAIANSOS, 0x1c, L_OPTIONS_168, L_OPTIONS_003, L_OPTIONS_168 }, + { STAGE_WAR, 0x1c, L_OPTIONS_170, L_OPTIONS_003, L_OPTIONS_170 }, + { STAGE_DUEL, 0x1c, L_OPTIONS_171, L_OPTIONS_003, L_OPTIONS_171 }, }; s32 getNumUnlockedSpecialStages(void) @@ -2134,7 +2134,7 @@ s32 getNumUnlockedSpecialStages(void) if (g_MissionConfig.iscoop || g_MissionConfig.isanti) { offsetforduel = 0; } else { - for (i = 0; i != 32; i++) { + for (i = 0; i < (VERSION >= VERSION_NTSC_1_0 ? 32 : 33); i++) { if (ciGetFiringRangeScore(i) <= 0) { offsetforduel = 0; } @@ -4978,7 +4978,7 @@ char *invMenuTextWeaponDescription(struct menuitem *item) } if (g_InventoryWeapon == WEAPON_NECKLACE - && g_Vars.stagenum == STAGE_ATTACKSHIP + && g_Vars.stagenum == (VERSION >= VERSION_NTSC_1_0 ? STAGE_ATTACKSHIP : STAGE_SKEDARRUINS) && lvGetDifficulty() >= DIFF_PA) { #if VERSION >= VERSION_NTSC_1_0 // Phrases included here to assist people searching the code for them: @@ -5040,6 +5040,7 @@ char *invMenuTextWeaponDescription(struct menuitem *item) return langGet(L_OPTIONS_003); // "\n" } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuhandler00106028 .late_rodata @@ -5164,7 +5165,134 @@ glabel var7f1b2e44 /* f106170: 03e00008 */ jr $ra /* f106174: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel menuhandler00106028 +.late_rodata +glabel var7f1b2e08 +.word menuhandler00106028+0x48 # f106070 +glabel var7f1b2e0c +.word menuhandler00106028+0x30 # f106058 +glabel var7f1b2e10 +.word menuhandler00106028+0x5c # f106084 +glabel var7f1b2e14 +.word menuhandler00106028+0x38 # f106060 +glabel var7f1b2e18 +.word menuhandler00106028+0x40 # f106068 +glabel var7f1b2e1c +.word menuhandler00106028+0x7c # f1060a4 +glabel var7f1b2e20 +.word menuhandler00106028+0x90 # f1060b8 +glabel var7f1b2e24 +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e28 +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e2c +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e30 +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e34 +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e38 +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e3c +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e40 +.word menuhandler00106028+0x13c # f106164 +glabel var7f1b2e44 +.word menuhandler00106028+0xa0 # f1060c8 +.text +/* f101cac: 248effff */ addiu $t6,$a0,-1 +/* f101cb0: 27bdffe8 */ addiu $sp,$sp,-24 +/* f101cb4: 2dc10010 */ sltiu $at,$t6,0x10 +/* f101cb8: afbf0014 */ sw $ra,0x14($sp) +/* f101cbc: 1020004a */ beqz $at,.NB0f101de8 +/* f101cc0: afa5001c */ sw $a1,0x1c($sp) +/* f101cc4: 000e7080 */ sll $t6,$t6,0x2 +/* f101cc8: 3c017f1b */ lui $at,0x7f1b +/* f101ccc: 002e0821 */ addu $at,$at,$t6 +/* f101cd0: 8c2ed108 */ lw $t6,-0x2ef8($at) +/* f101cd4: 01c00008 */ jr $t6 +/* f101cd8: 00000000 */ sll $zero,$zero,0x0 +/* f101cdc: 10000042 */ beqz $zero,.NB0f101de8 +/* f101ce0: acc00000 */ sw $zero,0x0($a2) +/* f101ce4: 10000041 */ beqz $zero,.NB0f101dec +/* f101ce8: 00001025 */ or $v0,$zero,$zero +/* f101cec: 1000003e */ beqz $zero,.NB0f101de8 +/* f101cf0: acc00008 */ sw $zero,0x8($a2) +/* f101cf4: 0fc65ce0 */ jal frGetNumWeaponsAvailable +/* f101cf8: afa60020 */ sw $a2,0x20($sp) +/* f101cfc: 8fa60020 */ lw $a2,0x20($sp) +/* f101d00: 10000039 */ beqz $zero,.NB0f101de8 +/* f101d04: acc20000 */ sw $v0,0x0($a2) +/* f101d08: 8cc40000 */ lw $a0,0x0($a2) +/* f101d0c: 3c018007 */ lui $at,0x8007 +/* f101d10: 0fc65cc2 */ jal frGetWeaponBySlot +/* f101d14: a0245aa4 */ sb $a0,0x5aa4($at) +/* f101d18: 0fc27fb6 */ jal bgunGetName +/* f101d1c: 00402025 */ or $a0,$v0,$zero +/* f101d20: 10000033 */ beqz $zero,.NB0f101df0 +/* f101d24: 8fbf0014 */ lw $ra,0x14($sp) +/* f101d28: 8ccf0000 */ lw $t7,0x0($a2) +/* f101d2c: 3c018007 */ lui $at,0x8007 +/* f101d30: 00001025 */ or $v0,$zero,$zero +/* f101d34: 1000002d */ beqz $zero,.NB0f101dec +/* f101d38: a02f5aa4 */ sb $t7,0x5aa4($at) +/* f101d3c: 3c188007 */ lui $t8,0x8007 +/* f101d40: 93185aa4 */ lbu $t8,0x5aa4($t8) +/* f101d44: 10000028 */ beqz $zero,.NB0f101de8 +/* f101d48: acd80000 */ sw $t8,0x0($a2) +/* f101d4c: 8cc40000 */ lw $a0,0x0($a2) +/* f101d50: 0fc65cc2 */ jal frGetWeaponBySlot +/* f101d54: afa60020 */ sw $a2,0x20($sp) +/* f101d58: 3c03800a */ lui $v1,0x800a +/* f101d5c: 246366b0 */ addiu $v1,$v1,0x66b0 +/* f101d60: a0620000 */ sb $v0,0x0($v1) +/* f101d64: 3c088007 */ lui $t0,0x8007 +/* f101d68: 8d083af0 */ lw $t0,0x3af0($t0) +/* f101d6c: 8fa60020 */ lw $a2,0x20($sp) +/* f101d70: 3c01800a */ lui $at,0x800a +/* f101d74: 000848c0 */ sll $t1,$t0,0x3 +/* f101d78: 01284823 */ subu $t1,$t1,$t0 +/* f101d7c: 000948c0 */ sll $t1,$t1,0x3 +/* f101d80: 01284823 */ subu $t1,$t1,$t0 +/* f101d84: 00094900 */ sll $t1,$t1,0x4 +/* f101d88: 01284823 */ subu $t1,$t1,$t0 +/* f101d8c: 00094880 */ sll $t1,$t1,0x2 +/* f101d90: 00290821 */ addu $at,$at,$t1 +/* f101d94: 305900ff */ andi $t9,$v0,0xff +/* f101d98: ac393544 */ sw $t9,0x3544($at) +/* f101d9c: 8cca0000 */ lw $t2,0x0($a2) +/* f101da0: 3c018007 */ lui $at,0x8007 +/* f101da4: 3c048007 */ lui $a0,0x8007 +/* f101da8: 24845948 */ addiu $a0,$a0,0x5948 +/* f101dac: 3c05bf80 */ lui $a1,0xbf80 +/* f101db0: 0fc3b7ea */ jal func0f0f139c +/* f101db4: a02a5aa4 */ sb $t2,0x5aa4($at) +/* f101db8: 3c048007 */ lui $a0,0x8007 +/* f101dbc: 2484595c */ addiu $a0,$a0,0x595c +/* f101dc0: 0fc3b7ea */ jal func0f0f139c +/* f101dc4: 3c05bf80 */ lui $a1,0xbf80 +/* f101dc8: 3c048007 */ lui $a0,0x8007 +/* f101dcc: 24845984 */ addiu $a0,$a0,0x5984 +/* f101dd0: 0fc3b7ea */ jal func0f0f139c +/* f101dd4: 3c05bf80 */ lui $a1,0xbf80 +/* f101dd8: 3c048007 */ lui $a0,0x8007 +/* f101ddc: 24845998 */ addiu $a0,$a0,0x5998 +/* f101de0: 0fc3b7ea */ jal func0f0f139c +/* f101de4: 3c05bf80 */ lui $a1,0xbf80 +.NB0f101de8: +/* f101de8: 00001025 */ or $v0,$zero,$zero +.NB0f101dec: +/* f101dec: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f101df0: +/* f101df0: 27bd0018 */ addiu $sp,$sp,0x18 +/* f101df4: 03e00008 */ jr $ra +/* f101df8: 00000000 */ sll $zero,$zero,0x0 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuhandler00106178 .late_rodata @@ -5344,6 +5472,187 @@ glabel var7f1b2e84 /* f10638c: 03e00008 */ jr $ra /* f106390: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel menuhandler00106178 +.late_rodata +glabel var7f1b2e48 +.word menuhandler00106178+0x34 # f1061ac +glabel var7f1b2e4c +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e50 +.word menuhandler00106178+0x48 # f1061c0 +glabel var7f1b2e54 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e58 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e5c +.word menuhandler00106178+0x5c # f1061d4 +glabel var7f1b2e60 +.word menuhandler00106178+0x138 # f1062b0 +glabel var7f1b2e64 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e68 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e6c +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e70 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e74 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e78 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e7c +.word menuhandler00106178+0x14c # f1062c4 +glabel var7f1b2e80 +.word menuhandler00106178+0x208 # f106380 +glabel var7f1b2e84 +.word menuhandler00106178+0x17c # f1062f4 +.text +/* f101dfc: 27bdffe0 */ addiu $sp,$sp,-32 +/* f101e00: 248effff */ addiu $t6,$a0,-1 +/* f101e04: 2dc10010 */ sltiu $at,$t6,0x10 +/* f101e08: afbf0014 */ sw $ra,0x14($sp) +/* f101e0c: afa50024 */ sw $a1,0x24($sp) +/* f101e10: 1020007c */ beqz $at,.NB0f102004 +/* f101e14: afa60028 */ sw $a2,0x28($sp) +/* f101e18: 000e7080 */ sll $t6,$t6,0x2 +/* f101e1c: 3c017f1b */ lui $at,0x7f1b +/* f101e20: 002e0821 */ addu $at,$at,$t6 +/* f101e24: 8c2ed148 */ lw $t6,-0x2eb8($at) +/* f101e28: 01c00008 */ jr $t6 +/* f101e2c: 00000000 */ sll $zero,$zero,0x0 +/* f101e30: 0fc4336c */ jal invGetCount +/* f101e34: 00000000 */ sll $zero,$zero,0x0 +/* f101e38: 8faf0028 */ lw $t7,0x28($sp) +/* f101e3c: 10000071 */ beqz $zero,.NB0f102004 +/* f101e40: ade20000 */ sw $v0,0x0($t7) +/* f101e44: 8fb80028 */ lw $t8,0x28($sp) +/* f101e48: 0fc43497 */ jal invGetNameByIndex +/* f101e4c: 8f040000 */ lw $a0,0x0($t8) +/* f101e50: 1000006e */ beqz $zero,.NB0f10200c +/* f101e54: 8fbf0014 */ lw $ra,0x14($sp) +/* f101e58: 8fb90028 */ lw $t9,0x28($sp) +/* f101e5c: 0fc43429 */ jal invGetWeaponNumByIndex +/* f101e60: 8f240000 */ lw $a0,0x0($t9) +/* f101e64: 24080001 */ addiu $t0,$zero,0x1 +/* f101e68: afa2001c */ sw $v0,0x1c($sp) +/* f101e6c: 10400014 */ beqz $v0,.NB0f101ec0 +/* f101e70: afa80018 */ sw $t0,0x18($sp) +/* f101e74: 0fc2bd87 */ jal currentPlayerGetDeviceState +/* f101e78: 00402025 */ or $a0,$v0,$zero +/* f101e7c: 2401ffff */ addiu $at,$zero,-1 +/* f101e80: 50410010 */ beql $v0,$at,.NB0f101ec4 +/* f101e84: 8fab0018 */ lw $t3,0x18($sp) +/* f101e88: 8fa90028 */ lw $t1,0x28($sp) +/* f101e8c: afa00018 */ sw $zero,0x18($sp) +/* f101e90: 8d2a0004 */ lw $t2,0x4($t1) +/* f101e94: 5540000b */ bnezl $t2,.NB0f101ec4 +/* f101e98: 8fab0018 */ lw $t3,0x18($sp) +/* f101e9c: 14400006 */ bnez $v0,.NB0f101eb8 +/* f101ea0: 8fa4001c */ lw $a0,0x1c($sp) +/* f101ea4: 8fa4001c */ lw $a0,0x1c($sp) +/* f101ea8: 0fc2bdaa */ jal currentPlayerSetDeviceActive +/* f101eac: 24050001 */ addiu $a1,$zero,0x1 +/* f101eb0: 10000004 */ beqz $zero,.NB0f101ec4 +/* f101eb4: 8fab0018 */ lw $t3,0x18($sp) +.NB0f101eb8: +/* f101eb8: 0fc2bdaa */ jal currentPlayerSetDeviceActive +/* f101ebc: 00002825 */ or $a1,$zero,$zero +.NB0f101ec0: +/* f101ec0: 8fab0018 */ lw $t3,0x18($sp) +.NB0f101ec4: +/* f101ec4: 8fac0028 */ lw $t4,0x28($sp) +/* f101ec8: 51600016 */ beqzl $t3,.NB0f101f24 +/* f101ecc: 8fad0028 */ lw $t5,0x28($sp) +/* f101ed0: 0fc434f0 */ jal invSetCurrentIndex +/* f101ed4: 8d840000 */ lw $a0,0x0($t4) +/* f101ed8: 8fa4001c */ lw $a0,0x1c($sp) +/* f101edc: 0fc43056 */ jal invHasDoubleWeaponIncAllGuns +/* f101ee0: 00802825 */ or $a1,$a0,$zero +/* f101ee4: 10400009 */ beqz $v0,.NB0f101f0c +/* f101ee8: 00002025 */ or $a0,$zero,$zero +/* f101eec: 00002025 */ or $a0,$zero,$zero +/* f101ef0: 0fc27f83 */ jal bgunEquipWeapon2 +/* f101ef4: 8fa5001c */ lw $a1,0x1c($sp) +/* f101ef8: 24040001 */ addiu $a0,$zero,0x1 +/* f101efc: 0fc27f83 */ jal bgunEquipWeapon2 +/* f101f00: 8fa5001c */ lw $a1,0x1c($sp) +/* f101f04: 10000007 */ beqz $zero,.NB0f101f24 +/* f101f08: 8fad0028 */ lw $t5,0x28($sp) +.NB0f101f0c: +/* f101f0c: 0fc27f83 */ jal bgunEquipWeapon2 +/* f101f10: 8fa5001c */ lw $a1,0x1c($sp) +/* f101f14: 24040001 */ addiu $a0,$zero,0x1 +/* f101f18: 0fc27f83 */ jal bgunEquipWeapon2 +/* f101f1c: 00002825 */ or $a1,$zero,$zero +/* f101f20: 8fad0028 */ lw $t5,0x28($sp) +.NB0f101f24: +/* f101f24: 3c018007 */ lui $at,0x8007 +/* f101f28: 8dae0000 */ lw $t6,0x0($t5) +/* f101f2c: 10000035 */ beqz $zero,.NB0f102004 +/* f101f30: ac2e38a0 */ sw $t6,0x38a0($at) +/* f101f34: 0fc434ec */ jal invGetCurrentIndex +/* f101f38: 00000000 */ sll $zero,$zero,0x0 +/* f101f3c: 8faf0028 */ lw $t7,0x28($sp) +/* f101f40: 10000030 */ beqz $zero,.NB0f102004 +/* f101f44: ade20000 */ sw $v0,0x0($t7) +/* f101f48: 8fb80028 */ lw $t8,0x28($sp) +/* f101f4c: 0fc43429 */ jal invGetWeaponNumByIndex +/* f101f50: 8f040000 */ lw $a0,0x0($t8) +/* f101f54: 1040002b */ beqz $v0,.NB0f102004 +/* f101f58: 00402025 */ or $a0,$v0,$zero +/* f101f5c: 0fc2bd87 */ jal currentPlayerGetDeviceState +/* f101f60: 00000000 */ sll $zero,$zero,0x0 +/* f101f64: 2401ffff */ addiu $at,$zero,-1 +/* f101f68: 10410026 */ beq $v0,$at,.NB0f102004 +/* f101f6c: 8fb90028 */ lw $t9,0x28($sp) +/* f101f70: 10000024 */ beqz $zero,.NB0f102004 +/* f101f74: af220004 */ sw $v0,0x4($t9) +/* f101f78: 8fa80028 */ lw $t0,0x28($sp) +/* f101f7c: 0fc43429 */ jal invGetWeaponNumByIndex +/* f101f80: 8d040000 */ lw $a0,0x0($t0) +/* f101f84: 3c03800a */ lui $v1,0x800a +/* f101f88: 246366b0 */ addiu $v1,$v1,0x66b0 +/* f101f8c: a0620000 */ sb $v0,0x0($v1) +/* f101f90: 3c0a8007 */ lui $t2,0x8007 +/* f101f94: 8d4a3af0 */ lw $t2,0x3af0($t2) +/* f101f98: 3c01800a */ lui $at,0x800a +/* f101f9c: 304900ff */ andi $t1,$v0,0xff +/* f101fa0: 000a58c0 */ sll $t3,$t2,0x3 +/* f101fa4: 016a5823 */ subu $t3,$t3,$t2 +/* f101fa8: 000b58c0 */ sll $t3,$t3,0x3 +/* f101fac: 016a5823 */ subu $t3,$t3,$t2 +/* f101fb0: 000b5900 */ sll $t3,$t3,0x4 +/* f101fb4: 016a5823 */ subu $t3,$t3,$t2 +/* f101fb8: 000b5880 */ sll $t3,$t3,0x2 +/* f101fbc: 002b0821 */ addu $at,$at,$t3 +/* f101fc0: 3c048007 */ lui $a0,0x8007 +/* f101fc4: ac293544 */ sw $t1,0x3544($at) +/* f101fc8: 24845948 */ addiu $a0,$a0,0x5948 +/* f101fcc: 0fc3b7ea */ jal func0f0f139c +/* f101fd0: 3c05bf80 */ lui $a1,0xbf80 +/* f101fd4: 3c048007 */ lui $a0,0x8007 +/* f101fd8: 2484595c */ addiu $a0,$a0,0x595c +/* f101fdc: 0fc3b7ea */ jal func0f0f139c +/* f101fe0: 3c05bf80 */ lui $a1,0xbf80 +/* f101fe4: 3c048007 */ lui $a0,0x8007 +/* f101fe8: 24845984 */ addiu $a0,$a0,0x5984 +/* f101fec: 0fc3b7ea */ jal func0f0f139c +/* f101ff0: 3c05bf80 */ lui $a1,0xbf80 +/* f101ff4: 3c048007 */ lui $a0,0x8007 +/* f101ff8: 24845998 */ addiu $a0,$a0,0x5998 +/* f101ffc: 0fc3b7ea */ jal func0f0f139c +/* f102000: 3c05bf80 */ lui $a1,0xbf80 +.NB0f102004: +/* f102004: 00001025 */ or $v0,$zero,$zero +/* f102008: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f10200c: +/* f10200c: 27bd0020 */ addiu $sp,$sp,0x20 +/* f102010: 03e00008 */ jr $ra +/* f102014: 00000000 */ sll $zero,$zero,0x0 +); +#endif struct menuitem g_SoloMissionInventoryMenuItems[] = { { MENUITEMTYPE_LIST, 0, 0x00000000, 0x0000006e, 0x00000063, menuhandler00106178 }, diff --git a/src/game/menu/items.c b/src/game/menu/items.c index a5476b98f..d69d28b45 100644 --- a/src/game/menu/items.c +++ b/src/game/menu/items.c @@ -5299,7 +5299,7 @@ glabel menuRenderObjective /* f0ea288: 03e00008 */ jr $ra /* f0ea28c: 27bd0130 */ addiu $sp,$sp,0x130 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuRenderObjective /* f0e98ac: 27bdfed0 */ addiu $sp,$sp,-304 @@ -5952,6 +5952,659 @@ glabel menuRenderObjective /* f0ea288: 03e00008 */ jr $ra /* f0ea28c: 27bd0130 */ addiu $sp,$sp,0x130 ); +#else +GLOBAL_ASM( +glabel menuRenderObjective +/* f0e6a20: 27bdfed0 */ addiu $sp,$sp,-304 +/* f0e6a24: 8fae0154 */ lw $t6,0x154($sp) +/* f0e6a28: afbf003c */ sw $ra,0x3c($sp) +/* f0e6a2c: afb00038 */ sw $s0,0x38($sp) +/* f0e6a30: afa40130 */ sw $a0,0x130($sp) +/* f0e6a34: afa50134 */ sw $a1,0x134($sp) +/* f0e6a38: afa60138 */ sw $a2,0x138($sp) +/* f0e6a3c: afa7013c */ sw $a3,0x13c($sp) +/* f0e6a40: 11c00002 */ beqz $t6,.NB0f0e6a4c +/* f0e6a44: 00001025 */ or $v0,$zero,$zero +/* f0e6a48: 2402000c */ addiu $v0,$zero,0xc +.NB0f0e6a4c: +/* f0e6a4c: 3c047f1b */ lui $a0,0x7f1b +/* f0e6a50: 3c058007 */ lui $a1,0x8007 +/* f0e6a54: 24a53898 */ addiu $a1,$a1,0x3898 +/* f0e6a58: 248482d0 */ addiu $a0,$a0,-32048 +/* f0e6a5c: 0c00381c */ jal mainOverrideVariable +/* f0e6a60: afa200bc */ sw $v0,0xbc($sp) +/* f0e6a64: 8faf0138 */ lw $t7,0x138($sp) +/* f0e6a68: 3c04800a */ lui $a0,0x800a +/* f0e6a6c: 000fc040 */ sll $t8,$t7,0x1 +/* f0e6a70: 00982021 */ addu $a0,$a0,$t8 +/* f0e6a74: 0fc5a4dd */ jal langGet +/* f0e6a78: 9484278a */ lhu $a0,0x278a($a0) +/* f0e6a7c: 87b90146 */ lh $t9,0x146($sp) +/* f0e6a80: 8fa30134 */ lw $v1,0x134($sp) +/* f0e6a84: afa20120 */ sw $v0,0x120($sp) +/* f0e6a88: afb90124 */ sw $t9,0x124($sp) +/* f0e6a8c: 44803000 */ mtc1 $zero,$f6 +/* f0e6a90: c4640040 */ lwc1 $f4,0x40($v1) +/* f0e6a94: 4606203c */ c.lt.s $f4,$f6 +/* f0e6a98: 00000000 */ sll $zero,$zero,0x0 +/* f0e6a9c: 4502000b */ bc1fl .NB0f0e6acc +/* f0e6aa0: 906c003d */ lbu $t4,0x3d($v1) +/* f0e6aa4: 9069003c */ lbu $t1,0x3c($v1) +/* f0e6aa8: 2410003c */ addiu $s0,$zero,0x3c +/* f0e6aac: 3c0b7f1b */ lui $t3,0x7f1b +/* f0e6ab0: 01300019 */ multu $t1,$s0 +/* f0e6ab4: 00005012 */ mflo $t2 +/* f0e6ab8: 016a5821 */ addu $t3,$t3,$t2 +/* f0e6abc: 8d6bc2f8 */ lw $t3,-0x3d08($t3) +/* f0e6ac0: 10000012 */ beqz $zero,.NB0f0e6b0c +/* f0e6ac4: afab012c */ sw $t3,0x12c($sp) +/* f0e6ac8: 906c003d */ lbu $t4,0x3d($v1) +.NB0f0e6acc: +/* f0e6acc: 2410003c */ addiu $s0,$zero,0x3c +/* f0e6ad0: 9078003c */ lbu $t8,0x3c($v1) +/* f0e6ad4: 01900019 */ multu $t4,$s0 +/* f0e6ad8: 3c0e7f1b */ lui $t6,0x7f1b +/* f0e6adc: 25cec2e0 */ addiu $t6,$t6,-15648 +/* f0e6ae0: 8c660044 */ lw $a2,0x44($v1) +/* f0e6ae4: 00006812 */ mflo $t5 +/* f0e6ae8: 01ae7821 */ addu $t7,$t5,$t6 +/* f0e6aec: 8de40018 */ lw $a0,0x18($t7) +/* f0e6af0: 03100019 */ multu $t8,$s0 +/* f0e6af4: 0000c812 */ mflo $t9 +/* f0e6af8: 032e4821 */ addu $t1,$t9,$t6 +/* f0e6afc: 0fc01990 */ jal colourBlend +/* f0e6b00: 8d250018 */ lw $a1,0x18($t1) +/* f0e6b04: afa2012c */ sw $v0,0x12c($sp) +/* f0e6b08: 8fa30134 */ lw $v1,0x134($sp) +.NB0f0e6b0c: +/* f0e6b0c: 8c6a000c */ lw $t2,0xc($v1) +/* f0e6b10: 8fa4012c */ lw $a0,0x12c($sp) +/* f0e6b14: 00002825 */ or $a1,$zero,$zero +/* f0e6b18: 5140000b */ beqzl $t2,.NB0f0e6b48 +/* f0e6b1c: 9078003c */ lbu $t8,0x3c($v1) +/* f0e6b20: 0fc01990 */ jal colourBlend +/* f0e6b24: 2406002c */ addiu $a2,$zero,0x2c +/* f0e6b28: 8fac012c */ lw $t4,0x12c($sp) +/* f0e6b2c: 2401ff00 */ addiu $at,$zero,-256 +/* f0e6b30: 00415824 */ and $t3,$v0,$at +/* f0e6b34: 318d00ff */ andi $t5,$t4,0xff +/* f0e6b38: 016d7825 */ or $t7,$t3,$t5 +/* f0e6b3c: afaf012c */ sw $t7,0x12c($sp) +/* f0e6b40: 8fa30134 */ lw $v1,0x134($sp) +/* f0e6b44: 9078003c */ lbu $t8,0x3c($v1) +.NB0f0e6b48: +/* f0e6b48: 3c047f1b */ lui $a0,0x7f1b +/* f0e6b4c: 3c057f1b */ lui $a1,0x7f1b +/* f0e6b50: 03100019 */ multu $t8,$s0 +/* f0e6b54: 00001012 */ mflo $v0 +/* f0e6b58: 00822021 */ addu $a0,$a0,$v0 +/* f0e6b5c: 00a22821 */ addu $a1,$a1,$v0 +/* f0e6b60: 8ca5c460 */ lw $a1,-0x3ba0($a1) +/* f0e6b64: 0fc53925 */ jal func0f153e38 +/* f0e6b68: 8c84c5c8 */ lw $a0,-0x3a38($a0) +/* f0e6b6c: a3a000d0 */ sb $zero,0xd0($sp) +/* f0e6b70: 0fc5374a */ jal func0f153628 +/* f0e6b74: 8fa40130 */ lw $a0,0x130($sp) +/* f0e6b78: 27b000d0 */ addiu $s0,$sp,0xd0 +/* f0e6b7c: 3c057f1b */ lui $a1,0x7f1b +/* f0e6b80: afa20130 */ sw $v0,0x130($sp) +/* f0e6b84: 24a582d8 */ addiu $a1,$a1,-32040 +/* f0e6b88: 02002025 */ or $a0,$s0,$zero +/* f0e6b8c: 0c004fc1 */ jal sprintf +/* f0e6b90: 8fa6013c */ lw $a2,0x13c($sp) +/* f0e6b94: 3c198008 */ lui $t9,0x8008 +/* f0e6b98: 8f39236c */ lw $t9,0x236c($t9) +/* f0e6b9c: 3c078008 */ lui $a3,0x8008 +/* f0e6ba0: 8ce72370 */ lw $a3,0x2370($a3) +/* f0e6ba4: 27a400c0 */ addiu $a0,$sp,0xc0 +/* f0e6ba8: 27a500c4 */ addiu $a1,$sp,0xc4 +/* f0e6bac: 02003025 */ or $a2,$s0,$zero +/* f0e6bb0: afa00014 */ sw $zero,0x14($sp) +/* f0e6bb4: 0fc54655 */ jal textMeasure +/* f0e6bb8: afb90010 */ sw $t9,0x10($sp) +/* f0e6bbc: 87ae0142 */ lh $t6,0x142($sp) +/* f0e6bc0: 8fa900c4 */ lw $t1,0xc4($sp) +/* f0e6bc4: 3c0b8008 */ lui $t3,0x8008 +/* f0e6bc8: 3c0d8008 */ lui $t5,0x8008 +/* f0e6bcc: 8dad236c */ lw $t5,0x236c($t5) +/* f0e6bd0: 8d6b2370 */ lw $t3,0x2370($t3) +/* f0e6bd4: 8faf012c */ lw $t7,0x12c($sp) +/* f0e6bd8: 87b8014a */ lh $t8,0x14a($sp) +/* f0e6bdc: 87b9014e */ lh $t9,0x14e($sp) +/* f0e6be0: 01c95023 */ subu $t2,$t6,$t1 +/* f0e6be4: 254c0019 */ addiu $t4,$t2,0x19 +/* f0e6be8: afac0128 */ sw $t4,0x128($sp) +/* f0e6bec: 8fa40130 */ lw $a0,0x130($sp) +/* f0e6bf0: 27a50128 */ addiu $a1,$sp,0x128 +/* f0e6bf4: 27a60124 */ addiu $a2,$sp,0x124 +/* f0e6bf8: 02003825 */ or $a3,$s0,$zero +/* f0e6bfc: afa00024 */ sw $zero,0x24($sp) +/* f0e6c00: afa00028 */ sw $zero,0x28($sp) +/* f0e6c04: afad0014 */ sw $t5,0x14($sp) +/* f0e6c08: afab0010 */ sw $t3,0x10($sp) +/* f0e6c0c: afaf0018 */ sw $t7,0x18($sp) +/* f0e6c10: afb8001c */ sw $t8,0x1c($sp) +/* f0e6c14: 0fc541a6 */ jal textRenderProjected +/* f0e6c18: afb90020 */ sw $t9,0x20($sp) +/* f0e6c1c: 87ae0142 */ lh $t6,0x142($sp) +/* f0e6c20: 8faa0154 */ lw $t2,0x154($sp) +/* f0e6c24: afa20130 */ sw $v0,0x130($sp) +/* f0e6c28: 25c90019 */ addiu $t1,$t6,0x19 +/* f0e6c2c: 1140001f */ beqz $t2,.NB0f0e6cac +/* f0e6c30: afa90128 */ sw $t1,0x128($sp) +/* f0e6c34: 3c0c8008 */ lui $t4,0x8008 +/* f0e6c38: 8d8c2364 */ lw $t4,0x2364($t4) +/* f0e6c3c: 3c078008 */ lui $a3,0x8008 +/* f0e6c40: 8ce72368 */ lw $a3,0x2368($a3) +/* f0e6c44: 24040055 */ addiu $a0,$zero,0x55 +/* f0e6c48: 8fa50120 */ lw $a1,0x120($sp) +/* f0e6c4c: 02003025 */ or $a2,$s0,$zero +/* f0e6c50: 0fc546df */ jal textWrap +/* f0e6c54: afac0010 */ sw $t4,0x10($sp) +/* f0e6c58: 3c0b8008 */ lui $t3,0x8008 +/* f0e6c5c: 3c0d8008 */ lui $t5,0x8008 +/* f0e6c60: 8dad2364 */ lw $t5,0x2364($t5) +/* f0e6c64: 8d6b2368 */ lw $t3,0x2368($t3) +/* f0e6c68: 8faf012c */ lw $t7,0x12c($sp) +/* f0e6c6c: 87b8014a */ lh $t8,0x14a($sp) +/* f0e6c70: 87b9014e */ lh $t9,0x14e($sp) +/* f0e6c74: 8fa40130 */ lw $a0,0x130($sp) +/* f0e6c78: 27a50128 */ addiu $a1,$sp,0x128 +/* f0e6c7c: 27a60124 */ addiu $a2,$sp,0x124 +/* f0e6c80: 02003825 */ or $a3,$s0,$zero +/* f0e6c84: afa00024 */ sw $zero,0x24($sp) +/* f0e6c88: afa00028 */ sw $zero,0x28($sp) +/* f0e6c8c: afad0014 */ sw $t5,0x14($sp) +/* f0e6c90: afab0010 */ sw $t3,0x10($sp) +/* f0e6c94: afaf0018 */ sw $t7,0x18($sp) +/* f0e6c98: afb8001c */ sw $t8,0x1c($sp) +/* f0e6c9c: 0fc541a6 */ jal textRenderProjected +/* f0e6ca0: afb90020 */ sw $t9,0x20($sp) +/* f0e6ca4: 1000001a */ beqz $zero,.NB0f0e6d10 +/* f0e6ca8: afa20130 */ sw $v0,0x130($sp) +.NB0f0e6cac: +/* f0e6cac: 3c057f1b */ lui $a1,0x7f1b +/* f0e6cb0: 24a582e0 */ addiu $a1,$a1,-32032 +/* f0e6cb4: 02002025 */ or $a0,$s0,$zero +/* f0e6cb8: 0c004fc1 */ jal sprintf +/* f0e6cbc: 8fa60120 */ lw $a2,0x120($sp) +/* f0e6cc0: 3c0e8008 */ lui $t6,0x8008 +/* f0e6cc4: 3c098008 */ lui $t1,0x8008 +/* f0e6cc8: 8d29236c */ lw $t1,0x236c($t1) +/* f0e6ccc: 8dce2370 */ lw $t6,0x2370($t6) +/* f0e6cd0: 8faa012c */ lw $t2,0x12c($sp) +/* f0e6cd4: 87ac014a */ lh $t4,0x14a($sp) +/* f0e6cd8: 87ab014e */ lh $t3,0x14e($sp) +/* f0e6cdc: 8fa40130 */ lw $a0,0x130($sp) +/* f0e6ce0: 27a50128 */ addiu $a1,$sp,0x128 +/* f0e6ce4: 27a60124 */ addiu $a2,$sp,0x124 +/* f0e6ce8: 02003825 */ or $a3,$s0,$zero +/* f0e6cec: afa00024 */ sw $zero,0x24($sp) +/* f0e6cf0: afa00028 */ sw $zero,0x28($sp) +/* f0e6cf4: afa90014 */ sw $t1,0x14($sp) +/* f0e6cf8: afae0010 */ sw $t6,0x10($sp) +/* f0e6cfc: afaa0018 */ sw $t2,0x18($sp) +/* f0e6d00: afac001c */ sw $t4,0x1c($sp) +/* f0e6d04: 0fc541a6 */ jal textRenderProjected +/* f0e6d08: afab0020 */ sw $t3,0x20($sp) +/* f0e6d0c: afa20130 */ sw $v0,0x130($sp) +.NB0f0e6d10: +/* f0e6d10: 8fad0150 */ lw $t5,0x150($sp) +/* f0e6d14: 27a400c0 */ addiu $a0,$sp,0xc0 +/* f0e6d18: 27a500c4 */ addiu $a1,$sp,0xc4 +/* f0e6d1c: 11a00141 */ beqz $t5,.NB0f0e7224 +/* f0e6d20: 3c078008 */ lui $a3,0x8008 +/* f0e6d24: 0fc24dd9 */ jal objectiveCheck +/* f0e6d28: 8fa40138 */ lw $a0,0x138($sp) +/* f0e6d2c: 10400007 */ beqz $v0,.NB0f0e6d4c +/* f0e6d30: 24010001 */ addiu $at,$zero,0x1 +/* f0e6d34: 1041000c */ beq $v0,$at,.NB0f0e6d68 +/* f0e6d38: 24010002 */ addiu $at,$zero,0x2 +/* f0e6d3c: 10410011 */ beq $v0,$at,.NB0f0e6d84 +/* f0e6d40: 00000000 */ sll $zero,$zero,0x0 +/* f0e6d44: 10000015 */ beqz $zero,.NB0f0e6d9c +/* f0e6d48: 00000000 */ sll $zero,$zero,0x0 +.NB0f0e6d4c: +/* f0e6d4c: 0fc5a4dd */ jal langGet +/* f0e6d50: 24045601 */ addiu $a0,$zero,0x5601 +/* f0e6d54: 3c0fffff */ lui $t7,0xffff +/* f0e6d58: 35ef00ff */ ori $t7,$t7,0xff +/* f0e6d5c: afa200cc */ sw $v0,0xcc($sp) +/* f0e6d60: 1000000e */ beqz $zero,.NB0f0e6d9c +/* f0e6d64: afaf00c8 */ sw $t7,0xc8($sp) +.NB0f0e6d68: +/* f0e6d68: 0fc5a4dd */ jal langGet +/* f0e6d6c: 24045600 */ addiu $a0,$zero,0x5600 +/* f0e6d70: 3c1800ff */ lui $t8,0xff +/* f0e6d74: 371800ff */ ori $t8,$t8,0xff +/* f0e6d78: afa200cc */ sw $v0,0xcc($sp) +/* f0e6d7c: 10000007 */ beqz $zero,.NB0f0e6d9c +/* f0e6d80: afb800c8 */ sw $t8,0xc8($sp) +.NB0f0e6d84: +/* f0e6d84: 0fc5a4dd */ jal langGet +/* f0e6d88: 24045602 */ addiu $a0,$zero,0x5602 +/* f0e6d8c: 3c19ff40 */ lui $t9,0xff40 +/* f0e6d90: 373940ff */ ori $t9,$t9,0x40ff +/* f0e6d94: afa200cc */ sw $v0,0xcc($sp) +/* f0e6d98: afb900c8 */ sw $t9,0xc8($sp) +.NB0f0e6d9c: +/* f0e6d9c: 3c098007 */ lui $t1,0x8007 +/* f0e6da0: 8d293af0 */ lw $t1,0x3af0($t1) +/* f0e6da4: 3c0c800a */ lui $t4,0x800a +/* f0e6da8: 8fae0134 */ lw $t6,0x134($sp) +/* f0e6dac: 000950c0 */ sll $t2,$t1,0x3 +/* f0e6db0: 01495023 */ subu $t2,$t2,$t1 +/* f0e6db4: 000a50c0 */ sll $t2,$t2,0x3 +/* f0e6db8: 01495023 */ subu $t2,$t2,$t1 +/* f0e6dbc: 000a5100 */ sll $t2,$t2,0x4 +/* f0e6dc0: 01495023 */ subu $t2,$t2,$t1 +/* f0e6dc4: 000a5080 */ sll $t2,$t2,0x2 +/* f0e6dc8: 018a6021 */ addu $t4,$t4,$t2 +/* f0e6dcc: 8d8c2c48 */ lw $t4,0x2c48($t4) +/* f0e6dd0: 27a400c0 */ addiu $a0,$sp,0xc0 +/* f0e6dd4: 27a500c4 */ addiu $a1,$sp,0xc4 +/* f0e6dd8: 11cc0004 */ beq $t6,$t4,.NB0f0e6dec +/* f0e6ddc: 3c078008 */ lui $a3,0x8008 +/* f0e6de0: 3c0b7f1b */ lui $t3,0x7f1b +/* f0e6de4: 8d6bc2f8 */ lw $t3,-0x3d08($t3) +/* f0e6de8: afab00c8 */ sw $t3,0xc8($sp) +.NB0f0e6dec: +/* f0e6dec: 3c0d8008 */ lui $t5,0x8008 +/* f0e6df0: 8dad2364 */ lw $t5,0x2364($t5) +/* f0e6df4: 8fa600cc */ lw $a2,0xcc($sp) +/* f0e6df8: 8ce72368 */ lw $a3,0x2368($a3) +/* f0e6dfc: afa00014 */ sw $zero,0x14($sp) +/* f0e6e00: 0fc54655 */ jal textMeasure +/* f0e6e04: afad0010 */ sw $t5,0x10($sp) +/* f0e6e08: 3c028007 */ lui $v0,0x8007 +/* f0e6e0c: 8c423898 */ lw $v0,0x3898($v0) +/* f0e6e10: 27a50128 */ addiu $a1,$sp,0x128 +/* f0e6e14: 27a60124 */ addiu $a2,$sp,0x124 +/* f0e6e18: 10400002 */ beqz $v0,.NB0f0e6e24 +/* f0e6e1c: 3c0c8008 */ lui $t4,0x8008 +/* f0e6e20: afa200c8 */ sw $v0,0xc8($sp) +.NB0f0e6e24: +/* f0e6e24: 87a2014a */ lh $v0,0x14a($sp) +/* f0e6e28: 87af0142 */ lh $t7,0x142($sp) +/* f0e6e2c: 8fb800c4 */ lw $t8,0xc4($sp) +/* f0e6e30: 87aa0146 */ lh $t2,0x146($sp) +/* f0e6e34: 8fae00bc */ lw $t6,0xbc($sp) +/* f0e6e38: 01e28021 */ addu $s0,$t7,$v0 +/* f0e6e3c: 3c0b8008 */ lui $t3,0x8008 +/* f0e6e40: 8d6b2364 */ lw $t3,0x2364($t3) +/* f0e6e44: 87af014e */ lh $t7,0x14e($sp) +/* f0e6e48: 8d8c2368 */ lw $t4,0x2368($t4) +/* f0e6e4c: 8fad00c8 */ lw $t5,0xc8($sp) +/* f0e6e50: 0218c823 */ subu $t9,$s0,$t8 +/* f0e6e54: 014e1821 */ addu $v1,$t2,$t6 +/* f0e6e58: 2729fff6 */ addiu $t1,$t9,-10 +/* f0e6e5c: 24630009 */ addiu $v1,$v1,0x9 +/* f0e6e60: afa90128 */ sw $t1,0x128($sp) +/* f0e6e64: afa30124 */ sw $v1,0x124($sp) +/* f0e6e68: afa30058 */ sw $v1,0x58($sp) +/* f0e6e6c: 8fa40130 */ lw $a0,0x130($sp) +/* f0e6e70: 8fa700cc */ lw $a3,0xcc($sp) +/* f0e6e74: afa00024 */ sw $zero,0x24($sp) +/* f0e6e78: afa00028 */ sw $zero,0x28($sp) +/* f0e6e7c: afa2001c */ sw $v0,0x1c($sp) +/* f0e6e80: afab0014 */ sw $t3,0x14($sp) +/* f0e6e84: afaf0020 */ sw $t7,0x20($sp) +/* f0e6e88: afac0010 */ sw $t4,0x10($sp) +/* f0e6e8c: 0fc541a6 */ jal textRenderProjected +/* f0e6e90: afad0018 */ sw $t5,0x18($sp) +/* f0e6e94: 8fb800c4 */ lw $t8,0xc4($sp) +/* f0e6e98: 8fac00c8 */ lw $t4,0xc8($sp) +/* f0e6e9c: 3c0a8008 */ lui $t2,0x8008 +/* f0e6ea0: 3c0e8008 */ lui $t6,0x8008 +/* f0e6ea4: 8fa30058 */ lw $v1,0x58($sp) +/* f0e6ea8: 8dce2364 */ lw $t6,0x2364($t6) +/* f0e6eac: 8d4a2368 */ lw $t2,0x2368($t2) +/* f0e6eb0: 87ad014a */ lh $t5,0x14a($sp) +/* f0e6eb4: 87af014e */ lh $t7,0x14e($sp) +/* f0e6eb8: 2401ff7f */ addiu $at,$zero,-129 +/* f0e6ebc: 0218c823 */ subu $t9,$s0,$t8 +/* f0e6ec0: 2729fff6 */ addiu $t1,$t9,-10 +/* f0e6ec4: 01815824 */ and $t3,$t4,$at +/* f0e6ec8: afa90128 */ sw $t1,0x128($sp) +/* f0e6ecc: afab0018 */ sw $t3,0x18($sp) +/* f0e6ed0: 00402025 */ or $a0,$v0,$zero +/* f0e6ed4: 27a50128 */ addiu $a1,$sp,0x128 +/* f0e6ed8: 27a60124 */ addiu $a2,$sp,0x124 +/* f0e6edc: 8fa700cc */ lw $a3,0xcc($sp) +/* f0e6ee0: afa00024 */ sw $zero,0x24($sp) +/* f0e6ee4: afa00028 */ sw $zero,0x28($sp) +/* f0e6ee8: afa30124 */ sw $v1,0x124($sp) +/* f0e6eec: afae0014 */ sw $t6,0x14($sp) +/* f0e6ef0: afaa0010 */ sw $t2,0x10($sp) +/* f0e6ef4: afad001c */ sw $t5,0x1c($sp) +/* f0e6ef8: 0fc541a6 */ jal textRenderProjected +/* f0e6efc: afaf0020 */ sw $t7,0x20($sp) +/* f0e6f00: 8fb800c4 */ lw $t8,0xc4($sp) +/* f0e6f04: 87b90146 */ lh $t9,0x146($sp) +/* f0e6f08: 00402025 */ or $a0,$v0,$zero +/* f0e6f0c: 02183023 */ subu $a2,$s0,$t8 +/* f0e6f10: 24c6fff3 */ addiu $a2,$a2,-13 +/* f0e6f14: 27290009 */ addiu $t1,$t9,0x9 +/* f0e6f18: afa90124 */ sw $t1,0x124($sp) +/* f0e6f1c: 0fc537a0 */ jal func0f153780 +/* f0e6f20: afa60128 */ sw $a2,0x128($sp) +/* f0e6f24: 87a50142 */ lh $a1,0x142($sp) +/* f0e6f28: 87ae0146 */ lh $t6,0x146($sp) +/* f0e6f2c: 8fa60128 */ lw $a2,0x128($sp) +/* f0e6f30: 00054880 */ sll $t1,$a1,0x2 +/* f0e6f34: 01254823 */ subu $t1,$t1,$a1 +/* f0e6f38: 25cb0008 */ addiu $t3,$t6,0x8 +/* f0e6f3c: 8fad0124 */ lw $t5,0x124($sp) +/* f0e6f40: 8faf00bc */ lw $t7,0xbc($sp) +/* f0e6f44: afab00ac */ sw $t3,0xac($sp) +/* f0e6f48: 24aa0016 */ addiu $t2,$a1,0x16 +/* f0e6f4c: 01251821 */ addu $v1,$t1,$a1 +/* f0e6f50: 8fab013c */ lw $t3,0x13c($sp) +/* f0e6f54: afaa00b4 */ sw $t2,0xb4($sp) +/* f0e6f58: 24630042 */ addiu $v1,$v1,0x42 +/* f0e6f5c: 25ccfffe */ addiu $t4,$t6,-2 +/* f0e6f60: afac00b0 */ sw $t4,0xb0($sp) +/* f0e6f64: 01afc021 */ addu $t8,$t5,$t7 +/* f0e6f68: 256dffff */ addiu $t5,$t3,-1 +/* f0e6f6c: 27190002 */ addiu $t9,$t8,0x2 +/* f0e6f70: afb900a8 */ sw $t9,0xa8($sp) +/* f0e6f74: 00402025 */ or $a0,$v0,$zero +/* f0e6f78: afa6009c */ sw $a2,0x9c($sp) +/* f0e6f7c: 04610003 */ bgez $v1,.NB0f0e6f8c +/* f0e6f80: 00035083 */ sra $t2,$v1,0x2 +/* f0e6f84: 24610003 */ addiu $at,$v1,0x3 +/* f0e6f88: 00015083 */ sra $t2,$at,0x2 +.NB0f0e6f8c: +/* f0e6f8c: 00ca6023 */ subu $t4,$a2,$t2 +/* f0e6f90: 258effe8 */ addiu $t6,$t4,-24 +/* f0e6f94: 01cd0019 */ multu $t6,$t5 +/* f0e6f98: 24010005 */ addiu $at,$zero,0x5 +/* f0e6f9c: afaa005c */ sw $t2,0x5c($sp) +/* f0e6fa0: 00007812 */ mflo $t7 +/* f0e6fa4: 00000000 */ sll $zero,$zero,0x0 +/* f0e6fa8: 00000000 */ sll $zero,$zero,0x0 +/* f0e6fac: 01e1001a */ div $zero,$t7,$at +/* f0e6fb0: 0000c012 */ mflo $t8 +/* f0e6fb4: 0158c821 */ addu $t9,$t2,$t8 +/* f0e6fb8: 27290013 */ addiu $t1,$t9,0x13 +/* f0e6fbc: 0fc37e4b */ jal func0f0e2498 +/* f0e6fc0: afa90098 */ sw $t1,0x98($sp) +/* f0e6fc4: 8fa3012c */ lw $v1,0x12c($sp) +/* f0e6fc8: 8fa600b0 */ lw $a2,0xb0($sp) +/* f0e6fcc: 2401ff00 */ addiu $at,$zero,-256 +/* f0e6fd0: 00616024 */ and $t4,$v1,$at +/* f0e6fd4: 3590003f */ ori $s0,$t4,0x3f +/* f0e6fd8: 24ca0001 */ addiu $t2,$a2,0x1 +/* f0e6fdc: afaa0010 */ sw $t2,0x10($sp) +/* f0e6fe0: afb00018 */ sw $s0,0x18($sp) +/* f0e6fe4: 01801825 */ or $v1,$t4,$zero +/* f0e6fe8: afac0014 */ sw $t4,0x14($sp) +/* f0e6fec: afac0054 */ sw $t4,0x54($sp) +/* f0e6ff0: 00402025 */ or $a0,$v0,$zero +/* f0e6ff4: 87a50142 */ lh $a1,0x142($sp) +/* f0e6ff8: 0fc37ef6 */ jal func0f0e2744 +/* f0e6ffc: 8fa700b4 */ lw $a3,0xb4($sp) +/* f0e7000: 8fa500b4 */ lw $a1,0xb4($sp) +/* f0e7004: 8fab00ac */ lw $t3,0xac($sp) +/* f0e7008: 00402025 */ or $a0,$v0,$zero +/* f0e700c: 24a70001 */ addiu $a3,$a1,0x1 +/* f0e7010: afa7004c */ sw $a3,0x4c($sp) +/* f0e7014: 8fa600b0 */ lw $a2,0xb0($sp) +/* f0e7018: afb00014 */ sw $s0,0x14($sp) +/* f0e701c: afb00018 */ sw $s0,0x18($sp) +/* f0e7020: 0fc37ef6 */ jal func0f0e2744 +/* f0e7024: afab0010 */ sw $t3,0x10($sp) +/* f0e7028: 8fa600ac */ lw $a2,0xac($sp) +/* f0e702c: 8fa7005c */ lw $a3,0x5c($sp) +/* f0e7030: 8fa30054 */ lw $v1,0x54($sp) +/* f0e7034: 24c80001 */ addiu $t0,$a2,0x1 +/* f0e7038: 24e7ffff */ addiu $a3,$a3,-1 +/* f0e703c: afa70058 */ sw $a3,0x58($sp) +/* f0e7040: afa80010 */ sw $t0,0x10($sp) +/* f0e7044: afa80048 */ sw $t0,0x48($sp) +/* f0e7048: 00402025 */ or $a0,$v0,$zero +/* f0e704c: 87a50142 */ lh $a1,0x142($sp) +/* f0e7050: afb00018 */ sw $s0,0x18($sp) +/* f0e7054: 0fc37ef6 */ jal func0f0e2744 +/* f0e7058: afa30014 */ sw $v1,0x14($sp) +/* f0e705c: 8fa50058 */ lw $a1,0x58($sp) +/* f0e7060: 8fa80048 */ lw $t0,0x48($sp) +/* f0e7064: 00402025 */ or $a0,$v0,$zero +/* f0e7068: 24a50003 */ addiu $a1,$a1,0x3 +/* f0e706c: afa50054 */ sw $a1,0x54($sp) +/* f0e7070: 8fa600ac */ lw $a2,0xac($sp) +/* f0e7074: 8fa7004c */ lw $a3,0x4c($sp) +/* f0e7078: afb00014 */ sw $s0,0x14($sp) +/* f0e707c: afb00018 */ sw $s0,0x18($sp) +/* f0e7080: 0fc37ef6 */ jal func0f0e2744 +/* f0e7084: afa80010 */ sw $t0,0x10($sp) +/* f0e7088: 8fa300a8 */ lw $v1,0xa8($sp) +/* f0e708c: 8fa50058 */ lw $a1,0x58($sp) +/* f0e7090: 00402025 */ or $a0,$v0,$zero +/* f0e7094: 24630002 */ addiu $v1,$v1,0x2 +/* f0e7098: afa30010 */ sw $v1,0x10($sp) +/* f0e709c: afa3004c */ sw $v1,0x4c($sp) +/* f0e70a0: 8fa600ac */ lw $a2,0xac($sp) +/* f0e70a4: afb00014 */ sw $s0,0x14($sp) +/* f0e70a8: afb00018 */ sw $s0,0x18($sp) +/* f0e70ac: 0fc37ef6 */ jal func0f0e2744 +/* f0e70b0: 24a70001 */ addiu $a3,$a1,0x1 +/* f0e70b4: 8fa50058 */ lw $a1,0x58($sp) +/* f0e70b8: 8fae00a8 */ lw $t6,0xa8($sp) +/* f0e70bc: 00402025 */ or $a0,$v0,$zero +/* f0e70c0: 24a50002 */ addiu $a1,$a1,0x2 +/* f0e70c4: afa50044 */ sw $a1,0x44($sp) +/* f0e70c8: 8fa600ac */ lw $a2,0xac($sp) +/* f0e70cc: 8fa70054 */ lw $a3,0x54($sp) +/* f0e70d0: afb00014 */ sw $s0,0x14($sp) +/* f0e70d4: afb00018 */ sw $s0,0x18($sp) +/* f0e70d8: 0fc37ef6 */ jal func0f0e2744 +/* f0e70dc: afae0010 */ sw $t6,0x10($sp) +/* f0e70e0: 8fa600a8 */ lw $a2,0xa8($sp) +/* f0e70e4: 8fa7005c */ lw $a3,0x5c($sp) +/* f0e70e8: 8fa50044 */ lw $a1,0x44($sp) +/* f0e70ec: 24c30001 */ addiu $v1,$a2,0x1 +/* f0e70f0: 24e7000e */ addiu $a3,$a3,0xe +/* f0e70f4: afa70054 */ sw $a3,0x54($sp) +/* f0e70f8: afa30010 */ sw $v1,0x10($sp) +/* f0e70fc: afa30048 */ sw $v1,0x48($sp) +/* f0e7100: 00402025 */ or $a0,$v0,$zero +/* f0e7104: afb00014 */ sw $s0,0x14($sp) +/* f0e7108: 0fc37ef6 */ jal func0f0e2744 +/* f0e710c: afb00018 */ sw $s0,0x18($sp) +/* f0e7110: 8fa300a8 */ lw $v1,0xa8($sp) +/* f0e7114: 00402025 */ or $a0,$v0,$zero +/* f0e7118: 8fa50058 */ lw $a1,0x58($sp) +/* f0e711c: 24630003 */ addiu $v1,$v1,0x3 +/* f0e7120: afa30010 */ sw $v1,0x10($sp) +/* f0e7124: afa30044 */ sw $v1,0x44($sp) +/* f0e7128: 8fa6004c */ lw $a2,0x4c($sp) +/* f0e712c: 8fa70054 */ lw $a3,0x54($sp) +/* f0e7130: afb00014 */ sw $s0,0x14($sp) +/* f0e7134: 0fc37ef6 */ jal func0f0e2744 +/* f0e7138: afb00018 */ sw $s0,0x18($sp) +/* f0e713c: 8fad0048 */ lw $t5,0x48($sp) +/* f0e7140: 00402025 */ or $a0,$v0,$zero +/* f0e7144: 8fa50054 */ lw $a1,0x54($sp) +/* f0e7148: 8fa600a8 */ lw $a2,0xa8($sp) +/* f0e714c: 8fa70098 */ lw $a3,0x98($sp) +/* f0e7150: afb00014 */ sw $s0,0x14($sp) +/* f0e7154: afb00018 */ sw $s0,0x18($sp) +/* f0e7158: 0fc37ef6 */ jal func0f0e2744 +/* f0e715c: afad0010 */ sw $t5,0x10($sp) +/* f0e7160: 8faf0044 */ lw $t7,0x44($sp) +/* f0e7164: 00402025 */ or $a0,$v0,$zero +/* f0e7168: 8fa50054 */ lw $a1,0x54($sp) +/* f0e716c: 8fa6004c */ lw $a2,0x4c($sp) +/* f0e7170: 8fa70098 */ lw $a3,0x98($sp) +/* f0e7174: afb00014 */ sw $s0,0x14($sp) +/* f0e7178: afb00018 */ sw $s0,0x18($sp) +/* f0e717c: 0fc37ef6 */ jal func0f0e2744 +/* f0e7180: afaf0010 */ sw $t7,0x10($sp) +/* f0e7184: 8fa300c8 */ lw $v1,0xc8($sp) +/* f0e7188: 8fa50098 */ lw $a1,0x98($sp) +/* f0e718c: 2401ff00 */ addiu $at,$zero,-256 +/* f0e7190: 8fb90044 */ lw $t9,0x44($sp) +/* f0e7194: 00614824 */ and $t1,$v1,$at +/* f0e7198: 3530003f */ ori $s0,$t1,0x3f +/* f0e719c: 24a70001 */ addiu $a3,$a1,0x1 +/* f0e71a0: afa70054 */ sw $a3,0x54($sp) +/* f0e71a4: afb00014 */ sw $s0,0x14($sp) +/* f0e71a8: afb00018 */ sw $s0,0x18($sp) +/* f0e71ac: 01201825 */ or $v1,$t1,$zero +/* f0e71b0: afa9005c */ sw $t1,0x5c($sp) +/* f0e71b4: 00402025 */ or $a0,$v0,$zero +/* f0e71b8: 8fa600a8 */ lw $a2,0xa8($sp) +/* f0e71bc: 0fc37ef6 */ jal func0f0e2744 +/* f0e71c0: afb90010 */ sw $t9,0x10($sp) +/* f0e71c4: 8fa7009c */ lw $a3,0x9c($sp) +/* f0e71c8: 8faa004c */ lw $t2,0x4c($sp) +/* f0e71cc: 00402025 */ or $a0,$v0,$zero +/* f0e71d0: 24e7fffc */ addiu $a3,$a3,-4 +/* f0e71d4: afa70050 */ sw $a3,0x50($sp) +/* f0e71d8: 8fa50054 */ lw $a1,0x54($sp) +/* f0e71dc: 8fa60048 */ lw $a2,0x48($sp) +/* f0e71e0: afb00014 */ sw $s0,0x14($sp) +/* f0e71e4: afb00018 */ sw $s0,0x18($sp) +/* f0e71e8: 0fc37ef6 */ jal func0f0e2744 +/* f0e71ec: afaa0010 */ sw $t2,0x10($sp) +/* f0e71f0: 8fab005c */ lw $t3,0x5c($sp) +/* f0e71f4: 8fac004c */ lw $t4,0x4c($sp) +/* f0e71f8: 00402025 */ or $a0,$v0,$zero +/* f0e71fc: 356e00cf */ ori $t6,$t3,0xcf +/* f0e7200: afae0018 */ sw $t6,0x18($sp) +/* f0e7204: 8fa50050 */ lw $a1,0x50($sp) +/* f0e7208: 8fa60048 */ lw $a2,0x48($sp) +/* f0e720c: 8fa7009c */ lw $a3,0x9c($sp) +/* f0e7210: afb00014 */ sw $s0,0x14($sp) +/* f0e7214: 0fc37ef6 */ jal func0f0e2744 +/* f0e7218: afac0010 */ sw $t4,0x10($sp) +/* f0e721c: 10000074 */ beqz $zero,.NB0f0e73f0 +/* f0e7220: afa20130 */ sw $v0,0x130($sp) +.NB0f0e7224: +/* f0e7224: 87b80146 */ lh $t8,0x146($sp) +/* f0e7228: 87ad0142 */ lh $t5,0x142($sp) +/* f0e722c: 8faa0124 */ lw $t2,0x124($sp) +/* f0e7230: 3c0b8008 */ lui $t3,0x8008 +/* f0e7234: 8d6b236c */ lw $t3,0x236c($t3) +/* f0e7238: 2719fffe */ addiu $t9,$t8,-2 +/* f0e723c: 27090008 */ addiu $t1,$t8,0x8 +/* f0e7240: 25af0016 */ addiu $t7,$t5,0x16 +/* f0e7244: 254c0001 */ addiu $t4,$t2,0x1 +/* f0e7248: afaf0080 */ sw $t7,0x80($sp) +/* f0e724c: afb9007c */ sw $t9,0x7c($sp) +/* f0e7250: afa90078 */ sw $t1,0x78($sp) +/* f0e7254: afac0074 */ sw $t4,0x74($sp) +/* f0e7258: 8fa60120 */ lw $a2,0x120($sp) +/* f0e725c: 8ce72370 */ lw $a3,0x2370($a3) +/* f0e7260: afa00014 */ sw $zero,0x14($sp) +/* f0e7264: 0fc54655 */ jal textMeasure +/* f0e7268: afab0010 */ sw $t3,0x10($sp) +/* f0e726c: 87ae0142 */ lh $t6,0x142($sp) +/* f0e7270: 8fad00c4 */ lw $t5,0xc4($sp) +/* f0e7274: 8fa40130 */ lw $a0,0x130($sp) +/* f0e7278: 01cd7821 */ addu $t7,$t6,$t5 +/* f0e727c: 25f90019 */ addiu $t9,$t7,0x19 +/* f0e7280: 0fc537a0 */ jal func0f153780 +/* f0e7284: afb9006c */ sw $t9,0x6c($sp) +/* f0e7288: 0fc37e4b */ jal func0f0e2498 +/* f0e728c: 00402025 */ or $a0,$v0,$zero +/* f0e7290: 8fa3012c */ lw $v1,0x12c($sp) +/* f0e7294: 8fa6007c */ lw $a2,0x7c($sp) +/* f0e7298: 2401ff00 */ addiu $at,$zero,-256 +/* f0e729c: 00614824 */ and $t1,$v1,$at +/* f0e72a0: 3530003f */ ori $s0,$t1,0x3f +/* f0e72a4: 24d80001 */ addiu $t8,$a2,0x1 +/* f0e72a8: afb80010 */ sw $t8,0x10($sp) +/* f0e72ac: afb00018 */ sw $s0,0x18($sp) +/* f0e72b0: 01201825 */ or $v1,$t1,$zero +/* f0e72b4: afa90014 */ sw $t1,0x14($sp) +/* f0e72b8: afa90054 */ sw $t1,0x54($sp) +/* f0e72bc: 00402025 */ or $a0,$v0,$zero +/* f0e72c0: 87a50142 */ lh $a1,0x142($sp) +/* f0e72c4: 0fc37ef6 */ jal func0f0e2744 +/* f0e72c8: 8fa70080 */ lw $a3,0x80($sp) +/* f0e72cc: 8fa50080 */ lw $a1,0x80($sp) +/* f0e72d0: 8fac0078 */ lw $t4,0x78($sp) +/* f0e72d4: 00402025 */ or $a0,$v0,$zero +/* f0e72d8: 24a70001 */ addiu $a3,$a1,0x1 +/* f0e72dc: afa7005c */ sw $a3,0x5c($sp) +/* f0e72e0: 8fa6007c */ lw $a2,0x7c($sp) +/* f0e72e4: afb00014 */ sw $s0,0x14($sp) +/* f0e72e8: afb00018 */ sw $s0,0x18($sp) +/* f0e72ec: 0fc37ef6 */ jal func0f0e2744 +/* f0e72f0: afac0010 */ sw $t4,0x10($sp) +/* f0e72f4: 87ab0142 */ lh $t3,0x142($sp) +/* f0e72f8: 8fa60078 */ lw $a2,0x78($sp) +/* f0e72fc: 8fa30054 */ lw $v1,0x54($sp) +/* f0e7300: 000b7080 */ sll $t6,$t3,0x2 +/* f0e7304: 01cb7023 */ subu $t6,$t6,$t3 +/* f0e7308: 01cb3821 */ addu $a3,$t6,$t3 +/* f0e730c: 24e70042 */ addiu $a3,$a3,0x42 +/* f0e7310: 24c80001 */ addiu $t0,$a2,0x1 +/* f0e7314: afa80010 */ sw $t0,0x10($sp) +/* f0e7318: afa8004c */ sw $t0,0x4c($sp) +/* f0e731c: 00402025 */ or $a0,$v0,$zero +/* f0e7320: afb00018 */ sw $s0,0x18($sp) +/* f0e7324: 01602825 */ or $a1,$t3,$zero +/* f0e7328: 04e10003 */ bgez $a3,.NB0f0e7338 +/* f0e732c: 00076883 */ sra $t5,$a3,0x2 +/* f0e7330: 24e10003 */ addiu $at,$a3,0x3 +/* f0e7334: 00016883 */ sra $t5,$at,0x2 +.NB0f0e7338: +/* f0e7338: 25a7ffff */ addiu $a3,$t5,-1 +/* f0e733c: afa70058 */ sw $a3,0x58($sp) +/* f0e7340: 0fc37ef6 */ jal func0f0e2744 +/* f0e7344: afa30014 */ sw $v1,0x14($sp) +/* f0e7348: 8fa50058 */ lw $a1,0x58($sp) +/* f0e734c: 8fa8004c */ lw $t0,0x4c($sp) +/* f0e7350: 00402025 */ or $a0,$v0,$zero +/* f0e7354: 24a50003 */ addiu $a1,$a1,0x3 +/* f0e7358: afa50054 */ sw $a1,0x54($sp) +/* f0e735c: 8fa60078 */ lw $a2,0x78($sp) +/* f0e7360: 8fa7005c */ lw $a3,0x5c($sp) +/* f0e7364: afb00014 */ sw $s0,0x14($sp) +/* f0e7368: afb00018 */ sw $s0,0x18($sp) +/* f0e736c: 0fc37ef6 */ jal func0f0e2744 +/* f0e7370: afa80010 */ sw $t0,0x10($sp) +/* f0e7374: 8faf0074 */ lw $t7,0x74($sp) +/* f0e7378: 8fa50058 */ lw $a1,0x58($sp) +/* f0e737c: 00402025 */ or $a0,$v0,$zero +/* f0e7380: 25f90002 */ addiu $t9,$t7,0x2 +/* f0e7384: afb90010 */ sw $t9,0x10($sp) +/* f0e7388: 8fa60078 */ lw $a2,0x78($sp) +/* f0e738c: afb00014 */ sw $s0,0x14($sp) +/* f0e7390: afb00018 */ sw $s0,0x18($sp) +/* f0e7394: 0fc37ef6 */ jal func0f0e2744 +/* f0e7398: 24a70001 */ addiu $a3,$a1,0x1 +/* f0e739c: 8fa50058 */ lw $a1,0x58($sp) +/* f0e73a0: 8fb80074 */ lw $t8,0x74($sp) +/* f0e73a4: 00402025 */ or $a0,$v0,$zero +/* f0e73a8: 24a50002 */ addiu $a1,$a1,0x2 +/* f0e73ac: afa50044 */ sw $a1,0x44($sp) +/* f0e73b0: 8fa60078 */ lw $a2,0x78($sp) +/* f0e73b4: 8fa70054 */ lw $a3,0x54($sp) +/* f0e73b8: afb00014 */ sw $s0,0x14($sp) +/* f0e73bc: afb00018 */ sw $s0,0x18($sp) +/* f0e73c0: 0fc37ef6 */ jal func0f0e2744 +/* f0e73c4: afb80010 */ sw $t8,0x10($sp) +/* f0e73c8: 8fa60074 */ lw $a2,0x74($sp) +/* f0e73cc: 8fa50044 */ lw $a1,0x44($sp) +/* f0e73d0: 00402025 */ or $a0,$v0,$zero +/* f0e73d4: 24ca0001 */ addiu $t2,$a2,0x1 +/* f0e73d8: afaa0010 */ sw $t2,0x10($sp) +/* f0e73dc: 8fa7006c */ lw $a3,0x6c($sp) +/* f0e73e0: afb00014 */ sw $s0,0x14($sp) +/* f0e73e4: 0fc37ef6 */ jal func0f0e2744 +/* f0e73e8: afb00018 */ sw $s0,0x18($sp) +/* f0e73ec: afa20130 */ sw $v0,0x130($sp) +.NB0f0e73f0: +/* f0e73f0: 8fbf003c */ lw $ra,0x3c($sp) +/* f0e73f4: 8fa20130 */ lw $v0,0x130($sp) +/* f0e73f8: 8fb00038 */ lw $s0,0x38($sp) +/* f0e73fc: 03e00008 */ jr $ra +/* f0e7400: 27bd0130 */ addiu $sp,$sp,0x130 +); #endif Gfx *menuRenderItemObjectives(Gfx *gdl, struct menurendercontext *context) @@ -7610,7 +8263,7 @@ Gfx *menuRenderItemCarousel(Gfx *gdl, struct menurendercontext *context) // This part of the function is unused because param2 is always zero. // Setting it to 0x7b causes a crash. - // 0x7c and 0x7d don't do anycontext with the option value, so it's probable + // 0x7c and 0x7d don't do anything with the option value, so it's probable // that the original source has a commented function call in that block. if (context->item->param2 == 0x7b && context->item->handler) { union handlerdata data; @@ -8249,7 +8902,7 @@ char *menuItemScrollableGetText(u32 type) * * headings - which are started with the pipe character and ended with a * double line break - * body text - which is anycontext else + * body text - which is anything else * * Headings are rendered in red, with a dropshadow and are outdented. */ diff --git a/src/game/mplayer/ingame.c b/src/game/mplayer/ingame.c index dde9a2219..8508bfe88 100644 --- a/src/game/mplayer/ingame.c +++ b/src/game/mplayer/ingame.c @@ -22,9 +22,12 @@ struct menudialog g_MpEndscreenChallengeCompletedMenuDialog; struct menudialog g_MpEndscreenIndGameOverMenuDialog; -struct menudialog g_MpEndscreenSavePlayerMenuDialog; struct menudialog g_MpEndscreenTeamGameOverMenuDialog; +#if VERSION >= VERSION_NTSC_1_0 +struct menudialog g_MpEndscreenSavePlayerMenuDialog; +#endif + s32 mpStatsForPlayerDropdownHandler(s32 operation, struct menuitem *item, union handlerdata *data) { char *name; diff --git a/src/game/mplayer/mplayer.c b/src/game/mplayer/mplayer.c index 2f9d23b1f..5a606e331 100644 --- a/src/game/mplayer/mplayer.c +++ b/src/game/mplayer/mplayer.c @@ -1378,6 +1378,7 @@ s32 mpGetWeaponSlot(s32 slot) return count; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f188e24 /* f188e24: 24860001 */ addiu $a2,$a0,0x1 @@ -1430,6 +1431,60 @@ glabel func0f188e24 /* f188ecc: 03e00008 */ jr $ra /* f188ed0: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f188e24 +/* f188e24: 24860001 */ addiu $a2,$a0,0x1 +/* f188e28: 27bdfff0 */ addiu $sp,$sp,-16 +/* f188e2c: 00c01025 */ or $v0,$a2,$zero +/* f188e30: 18c0001e */ blez $a2,.L0f188eac +/* f188e34: 00002825 */ or $a1,$zero,$zero +/* f188e38: 3c088008 */ lui $t0,%hi(g_MpWeapons) +/* f188e3c: 3c04800b */ lui $a0,%hi(g_MpSetup) +/* f188e40: 2484cb88 */ addiu $a0,$a0,%lo(g_MpSetup) +/* f188e44: 25087268 */ addiu $t0,$t0,%lo(g_MpWeapons) +/* f188e48: 2409000a */ addiu $t1,$zero,0xa +/* f188e4c: 2407005c */ addiu $a3,$zero,0x5b +/* f188e50: 00857021 */ addu $t6,$a0,$a1 +.L0f188e54: +/* f188e54: 91c30018 */ lbu $v1,0x18($t6) +/* f188e58: 00690019 */ multu $v1,$t1 +/* f188e5c: 00007812 */ mflo $t7 +/* f188e60: 010fc021 */ addu $t8,$t0,$t7 +/* f188e64: 93190000 */ lbu $t9,0x0($t8) +/* f188e68: 10f90002 */ beq $a3,$t9,.L0f188e74 +/* f188e6c: 00000000 */ nop +/* f188e70: 2442ffff */ addiu $v0,$v0,-1 +.L0f188e74: +/* f188e74: 1840000a */ blez $v0,.L0f188ea0 +/* f188e78: 00000000 */ nop +/* f188e7c: 24a50001 */ addiu $a1,$a1,0x1 +/* f188e80: 28a10006 */ slti $at,$a1,0x6 +/* f188e84: 14200006 */ bnez $at,.L0f188ea0 +/* f188e88: 00000000 */ nop +/* f188e8c: 14c20003 */ bne $a2,$v0,.L0f188e9c +/* f188e90: 00002825 */ or $a1,$zero,$zero +/* f188e94: 00001825 */ or $v1,$zero,$zero +/* f188e98: 00001025 */ or $v0,$zero,$zero +.L0f188e9c: +/* f188e9c: 00403025 */ or $a2,$v0,$zero +.L0f188ea0: +/* f188ea0: 5c40ffec */ bgtzl $v0,.L0f188e54 +/* f188ea4: 00857021 */ addu $t6,$a0,$a1 +/* f188ea8: a3a30003 */ sb $v1,0x3($sp) +.L0f188eac: +/* f188eac: 93a30003 */ lbu $v1,0x3($sp) +/* f188eb0: 2409000a */ addiu $t1,$zero,0xa +/* f188eb4: 3c088008 */ lui $t0,%hi(g_MpWeapons) +/* f188eb8: 00690019 */ multu $v1,$t1 +/* f188ebc: 25087268 */ addiu $t0,$t0,%lo(g_MpWeapons) +/* f188ec0: 27bd0010 */ addiu $sp,$sp,0x10 +/* f188ec4: 00005012 */ mflo $t2 +/* f188ec8: 010a1021 */ addu $v0,$t0,$t2 +/* f188ecc: 03e00008 */ jr $ra +/* f188ed0: 00000000 */ nop +); +#endif s32 mpCountWeaponSetThing(s32 weaponsetindex) { @@ -1445,7 +1500,7 @@ s32 mpCountWeaponSetThing(s32 weaponsetindex) if ((mpIsFeatureUnlocked(g_MpWeaponSets[i].requirefeatures[0]) && mpIsFeatureUnlocked(g_MpWeaponSets[i].requirefeatures[1]) && mpIsFeatureUnlocked(g_MpWeaponSets[i].requirefeatures[2]) - && mpIsFeatureUnlocked(g_MpWeaponSets[i].requirefeatures[3])) || g_MpWeaponSets[i].unk0c != 0x5c) { + && mpIsFeatureUnlocked(g_MpWeaponSets[i].requirefeatures[3])) || g_MpWeaponSets[i].unk0c != WEAPON_DISABLED) { count++; } } @@ -1504,6 +1559,7 @@ char *mpGetWeaponSetName(s32 index) return langGet(g_MpWeaponSets[index].name); } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f18913c /* f18913c: 27bdffb8 */ addiu $sp,$sp,-72 @@ -1620,7 +1676,126 @@ glabel func0f18913c /* f1892d4: 03e00008 */ jr $ra /* f1892d8: 27bd0048 */ addiu $sp,$sp,0x48 ); +#else +GLOBAL_ASM( +glabel func0f18913c +/* f18913c: 27bdffb8 */ addiu $sp,$sp,-72 +/* f189140: afb70034 */ sw $s7,0x34($sp) +/* f189144: afb5002c */ sw $s5,0x2c($sp) +/* f189148: 3c0f8008 */ lui $t7,%hi(g_MpWeaponSets) +/* f18914c: afbe0038 */ sw $s8,0x38($sp) +/* f189150: afb60030 */ sw $s6,0x30($sp) +/* f189154: afb40028 */ sw $s4,0x28($sp) +/* f189158: 25ef73f0 */ addiu $t7,$t7,%lo(g_MpWeaponSets) +/* f18915c: 3c158008 */ lui $s5,%hi(g_MpWeapons) +/* f189160: 3c17800b */ lui $s7,%hi(g_MpSetup+0x6) +/* f189164: 00007100 */ sll $t6,$zero,0x4 +/* f189168: afbf003c */ sw $ra,0x3c($sp) +/* f18916c: afb30024 */ sw $s3,0x24($sp) +/* f189170: afb20020 */ sw $s2,0x20($sp) +/* f189174: afb1001c */ sw $s1,0x1c($sp) +/* f189178: afb00018 */ sw $s0,0x18($sp) +/* f18917c: afa00040 */ sw $zero,0x40($sp) +/* f189180: 01cff021 */ addu $s8,$t6,$t7 +/* f189184: 26f7cb8e */ addiu $s7,$s7,%lo(g_MpSetup+0x6) +/* f189188: 26b57268 */ addiu $s5,$s5,%lo(g_MpWeapons) +/* f18918c: 2414005b */ addiu $s4,$zero,0x5a +/* f189190: 2416000a */ addiu $s6,$zero,0xa +/* f189194: afa00044 */ sw $zero,0x44($sp) +.L0f189198: +/* f189198: 0fc67244 */ jal mpIsFeatureUnlocked +/* f18919c: 93c40008 */ lbu $a0,0x8($s8) +/* f1891a0: 50400010 */ beqzl $v0,.L0f1891e4 +/* f1891a4: 93d8000c */ lbu $t8,0xc($s8) +/* f1891a8: 0fc67244 */ jal mpIsFeatureUnlocked +/* f1891ac: 93c40009 */ lbu $a0,0x9($s8) +/* f1891b0: 5040000c */ beqzl $v0,.L0f1891e4 +/* f1891b4: 93d8000c */ lbu $t8,0xc($s8) +/* f1891b8: 0fc67244 */ jal mpIsFeatureUnlocked +/* f1891bc: 93c4000a */ lbu $a0,0xa($s8) +/* f1891c0: 50400008 */ beqzl $v0,.L0f1891e4 +/* f1891c4: 93d8000c */ lbu $t8,0xc($s8) +/* f1891c8: 0fc67244 */ jal mpIsFeatureUnlocked +/* f1891cc: 93c4000b */ lbu $a0,0xb($s8) +/* f1891d0: 50400004 */ beqzl $v0,.L0f1891e4 +/* f1891d4: 93d8000c */ lbu $t8,0xc($s8) +/* f1891d8: 10000008 */ b .L0f1891fc +/* f1891dc: 27c20002 */ addiu $v0,$s8,0x2 +/* f1891e0: 93d8000c */ lbu $t8,0xc($s8) +.L0f1891e4: +/* f1891e4: 2401005c */ addiu $at,$zero,0x5b +/* f1891e8: 00001025 */ or $v0,$zero,$zero +/* f1891ec: 13010003 */ beq $t8,$at,.L0f1891fc +/* f1891f0: 00000000 */ nop +/* f1891f4: 10000001 */ b .L0f1891fc +/* f1891f8: 27c2000c */ addiu $v0,$s8,0xc +.L0f1891fc: +/* f1891fc: 1040001d */ beqz $v0,.L0f189274 +/* f189200: 24130001 */ addiu $s3,$zero,0x1 +/* f189204: 3c11800b */ lui $s1,%hi(g_MpSetup) +/* f189208: 2631cb88 */ addiu $s1,$s1,%lo(g_MpSetup) +/* f18920c: 00409025 */ or $s2,$v0,$zero +.L0f189210: +/* f189210: 92500000 */ lbu $s0,0x0($s2) +/* f189214: 56140007 */ bnel $s0,$s4,.L0f189234 +/* f189218: 92390018 */ lbu $t9,0x18($s1) +/* f18921c: 0fc67244 */ jal mpIsFeatureUnlocked +/* f189220: 24040016 */ addiu $a0,$zero,0x16 +/* f189224: 54400003 */ bnezl $v0,.L0f189234 +/* f189228: 92390018 */ lbu $t9,0x18($s1) +/* f18922c: 00008025 */ or $s0,$zero,$zero +/* f189230: 92390018 */ lbu $t9,0x18($s1) +.L0f189234: +/* f189234: 26310001 */ addiu $s1,$s1,0x1 +/* f189238: 03360019 */ multu $t9,$s6 +/* f18923c: 00004012 */ mflo $t0 +/* f189240: 02a84821 */ addu $t1,$s5,$t0 +/* f189244: 912a0000 */ lbu $t2,0x0($t1) +/* f189248: 120a0002 */ beq $s0,$t2,.L0f189254 +/* f18924c: 00000000 */ nop +/* f189250: 00009825 */ or $s3,$zero,$zero +.L0f189254: +/* f189254: 1637ffee */ bne $s1,$s7,.L0f189210 +/* f189258: 26520001 */ addiu $s2,$s2,0x1 +/* f18925c: 12600005 */ beqz $s3,.L0f189274 +/* f189260: 8fa20044 */ lw $v0,0x44($sp) +/* f189264: 240b0001 */ addiu $t3,$zero,0x1 +/* f189268: 3c018008 */ lui $at,%hi(var800874c8) +/* f18926c: afab0040 */ sw $t3,0x40($sp) +/* f189270: ac2274c8 */ sw $v0,%lo(var800874c8)($at) +.L0f189274: +/* f189274: 8fac0040 */ lw $t4,0x40($sp) +/* f189278: 8fa20044 */ lw $v0,0x44($sp) +/* f18927c: 27de0012 */ addiu $s8,$s8,0x12 +/* f189280: 15800004 */ bnez $t4,.L0f189294 +/* f189284: 24420001 */ addiu $v0,$v0,0x1 +/* f189288: 2401000c */ addiu $at,$zero,0xc +/* f18928c: 1441ffc2 */ bne $v0,$at,.L0f189198 +/* f189290: afa20044 */ sw $v0,0x44($sp) +.L0f189294: +/* f189294: 8fad0040 */ lw $t5,0x40($sp) +/* f189298: 240e000e */ addiu $t6,$zero,0xe +/* f18929c: 3c018008 */ lui $at,%hi(var800874c8) +/* f1892a0: 55a00003 */ bnezl $t5,.L0f1892b0 +/* f1892a4: 8fbf003c */ lw $ra,0x3c($sp) +/* f1892a8: ac2e74c8 */ sw $t6,%lo(var800874c8)($at) +/* f1892ac: 8fbf003c */ lw $ra,0x3c($sp) +.L0f1892b0: +/* f1892b0: 8fb00018 */ lw $s0,0x18($sp) +/* f1892b4: 8fb1001c */ lw $s1,0x1c($sp) +/* f1892b8: 8fb20020 */ lw $s2,0x20($sp) +/* f1892bc: 8fb30024 */ lw $s3,0x24($sp) +/* f1892c0: 8fb40028 */ lw $s4,0x28($sp) +/* f1892c4: 8fb5002c */ lw $s5,0x2c($sp) +/* f1892c8: 8fb60030 */ lw $s6,0x30($sp) +/* f1892cc: 8fb70034 */ lw $s7,0x34($sp) +/* f1892d0: 8fbe0038 */ lw $s8,0x38($sp) +/* f1892d4: 03e00008 */ jr $ra +/* f1892d8: 27bd0048 */ addiu $sp,$sp,0x48 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f1892dc /* f1892dc: 27bdffb0 */ addiu $sp,$sp,-80 @@ -1822,6 +1997,209 @@ glabel func0f1892dc /* f1895b4: 03e00008 */ jr $ra /* f1895b8: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f1892dc +/* f1892dc: 27bdffb0 */ addiu $sp,$sp,-80 +/* f1892e0: afb00018 */ sw $s0,0x18($sp) +/* f1892e4: 3c108008 */ lui $s0,%hi(var800874c8) +/* f1892e8: 261074c8 */ addiu $s0,$s0,%lo(var800874c8) +/* f1892ec: 8e020000 */ lw $v0,0x0($s0) +/* f1892f0: afbf001c */ sw $ra,0x1c($sp) +/* f1892f4: 04400077 */ bltz $v0,.L0f1894d4 +/* f1892f8: 2841000c */ slti $at,$v0,0xc +/* f1892fc: 10200075 */ beqz $at,.L0f1894d4 +/* f189300: 000270c0 */ sll $t6,$v0,0x3 +/* f189304: 01c27021 */ addu $t6,$t6,$v0 +/* f189308: 000e7040 */ sll $t6,$t6,0x1 +/* f18930c: 3c048008 */ lui $a0,%hi(g_MpWeaponSets+0x8) +/* f189310: 008e2021 */ addu $a0,$a0,$t6 +/* f189314: 0fc67244 */ jal mpIsFeatureUnlocked +/* f189318: 908473f8 */ lbu $a0,%lo(g_MpWeaponSets+0x8)($a0) +/* f18931c: 50400029 */ beqzl $v0,.L0f1893c4 +/* f189320: 8e0d0000 */ lw $t5,0x0($s0) +/* f189324: 8e0f0000 */ lw $t7,0x0($s0) +/* f189328: 3c048008 */ lui $a0,%hi(g_MpWeaponSets+0x9) +/* f18932c: 000fc0c0 */ sll $t8,$t7,0x3 +/* f189330: 030fc021 */ addu $t8,$t8,$t7 +/* f189334: 0018c040 */ sll $t8,$t8,0x1 +/* f189338: 00982021 */ addu $a0,$a0,$t8 +/* f18933c: 0fc67244 */ jal mpIsFeatureUnlocked +/* f189340: 908473f9 */ lbu $a0,%lo(g_MpWeaponSets+0x9)($a0) +/* f189344: 5040001f */ beqzl $v0,.L0f1893c4 +/* f189348: 8e0d0000 */ lw $t5,0x0($s0) +/* f18934c: 8e190000 */ lw $t9,0x0($s0) +/* f189350: 3c048008 */ lui $a0,%hi(g_MpWeaponSets+0xa) +/* f189354: 001960c0 */ sll $t4,$t9,0x3 +/* f189358: 01996021 */ addu $t4,$t4,$t9 +/* f18935c: 000c6040 */ sll $t4,$t4,0x1 +/* f189360: 008c2021 */ addu $a0,$a0,$t4 +/* f189364: 0fc67244 */ jal mpIsFeatureUnlocked +/* f189368: 908473fa */ lbu $a0,%lo(g_MpWeaponSets+0xa)($a0) +/* f18936c: 50400015 */ beqzl $v0,.L0f1893c4 +/* f189370: 8e0d0000 */ lw $t5,0x0($s0) +/* f189374: 8e0d0000 */ lw $t5,0x0($s0) +/* f189378: 3c048008 */ lui $a0,%hi(g_MpWeaponSets+0xb) +/* f18937c: 000d70c0 */ sll $t6,$t5,0x3 +/* f189380: 01cd7021 */ addu $t6,$t6,$t5 +/* f189384: 000e7040 */ sll $t6,$t6,0x1 +/* f189388: 008e2021 */ addu $a0,$a0,$t6 +/* f18938c: 0fc67244 */ jal mpIsFeatureUnlocked +/* f189390: 908473fb */ lbu $a0,%lo(g_MpWeaponSets+0xb)($a0) +/* f189394: 5040000b */ beqzl $v0,.L0f1893c4 +/* f189398: 8e0d0000 */ lw $t5,0x0($s0) +/* f18939c: 8e0f0000 */ lw $t7,0x0($s0) +/* f1893a0: 3c0c8008 */ lui $t4,%hi(g_MpWeaponSets) +/* f1893a4: 258c73f0 */ addiu $t4,$t4,%lo(g_MpWeaponSets) +/* f1893a8: 000fc0c0 */ sll $t8,$t7,0x3 +/* f1893ac: 030fc021 */ addu $t8,$t8,$t7 +/* f1893b0: 0018c040 */ sll $t8,$t8,0x1 +/* f1893b4: 27190002 */ addiu $t9,$t8,0x2 +/* f1893b8: 1000000f */ b .L0f1893f8 +/* f1893bc: 032c1021 */ addu $v0,$t9,$t4 +/* f1893c0: 8e0d0000 */ lw $t5,0x0($s0) +.L0f1893c4: +/* f1893c4: 3c0f8008 */ lui $t7,%hi(g_MpWeaponSets) +/* f1893c8: 25ef73f0 */ addiu $t7,$t7,%lo(g_MpWeaponSets) +/* f1893cc: 000d70c0 */ sll $t6,$t5,0x3 +/* f1893d0: 01cd7021 */ addu $t6,$t6,$t5 +/* f1893d4: 000e7040 */ sll $t6,$t6,0x1 +/* f1893d8: 01cf1821 */ addu $v1,$t6,$t7 +/* f1893dc: 9078000c */ lbu $t8,0xc($v1) +/* f1893e0: 2401005c */ addiu $at,$zero,0x5b +/* f1893e4: 53010004 */ beql $t8,$at,.L0f1893f8 +/* f1893e8: 00001025 */ or $v0,$zero,$zero +/* f1893ec: 10000002 */ b .L0f1893f8 +/* f1893f0: 2462000c */ addiu $v0,$v1,0xc +/* f1893f4: 00001025 */ or $v0,$zero,$zero +.L0f1893f8: +/* f1893f8: 1040006b */ beqz $v0,.L0f1895a8 +/* f1893fc: 00405825 */ or $t3,$v0,$zero +/* f189400: 3c0a800b */ lui $t2,%hi(g_MpSetup) +/* f189404: 3c088008 */ lui $t0,%hi(g_MpWeapons) +/* f189408: 25087268 */ addiu $t0,$t0,%lo(g_MpWeapons) +/* f18940c: 254acb88 */ addiu $t2,$t2,%lo(g_MpSetup) +/* f189410: 2410005b */ addiu $s0,$zero,0x5a +/* f189414: 2409000a */ addiu $t1,$zero,0xa +.L0f189418: +/* f189418: 91660000 */ lbu $a2,0x0($t3) +/* f18941c: 00002825 */ or $a1,$zero,$zero +/* f189420: 00003825 */ or $a3,$zero,$zero +/* f189424: 14d00014 */ bne $a2,$s0,.L0f189478 +/* f189428: 00001825 */ or $v1,$zero,$zero +/* f18942c: 24040016 */ addiu $a0,$zero,0x16 +/* f189430: afa00044 */ sw $zero,0x44($sp) +/* f189434: afa00040 */ sw $zero,0x40($sp) +/* f189438: afa60038 */ sw $a2,0x38($sp) +/* f18943c: afa0003c */ sw $zero,0x3c($sp) +/* f189440: afaa0024 */ sw $t2,0x24($sp) +/* f189444: 0fc67244 */ jal mpIsFeatureUnlocked +/* f189448: afab0028 */ sw $t3,0x28($sp) +/* f18944c: 3c088008 */ lui $t0,%hi(g_MpWeapons) +/* f189450: 25087268 */ addiu $t0,$t0,%lo(g_MpWeapons) +/* f189454: 8fa30044 */ lw $v1,0x44($sp) +/* f189458: 8fa50040 */ lw $a1,0x40($sp) +/* f18945c: 8fa60038 */ lw $a2,0x38($sp) +/* f189460: 8fa7003c */ lw $a3,0x3c($sp) +/* f189464: 2409000a */ addiu $t1,$zero,0xa +/* f189468: 8faa0024 */ lw $t2,0x24($sp) +/* f18946c: 14400002 */ bnez $v0,.L0f189478 +/* f189470: 8fab0028 */ lw $t3,0x28($sp) +/* f189474: 00003025 */ or $a2,$zero,$zero +.L0f189478: +/* f189478: 2c610027 */ sltiu $at,$v1,0x27 +/* f18947c: 14200003 */ bnez $at,.L0f18948c +/* f189480: 00000000 */ nop +/* f189484: 10000009 */ b .L0f1894ac +/* f189488: 24050001 */ addiu $a1,$zero,0x1 +.L0f18948c: +/* f18948c: 00690019 */ multu $v1,$t1 +/* f189490: 0000c812 */ mflo $t9 +/* f189494: 01196021 */ addu $t4,$t0,$t9 +/* f189498: 918d0000 */ lbu $t5,0x0($t4) +/* f18949c: 14cd0003 */ bne $a2,$t5,.L0f1894ac +/* f1894a0: 00000000 */ nop +/* f1894a4: 00603825 */ or $a3,$v1,$zero +/* f1894a8: 24050001 */ addiu $a1,$zero,0x1 +.L0f1894ac: +/* f1894ac: 10a0fff2 */ beqz $a1,.L0f189478 +/* f1894b0: 24630001 */ addiu $v1,$v1,0x1 +/* f1894b4: 3c0e800b */ lui $t6,%hi(g_MpSetup+0x6) +/* f1894b8: 25cecb8e */ addiu $t6,$t6,%lo(g_MpSetup+0x6) +/* f1894bc: 254a0001 */ addiu $t2,$t2,0x1 +/* f1894c0: 256b0001 */ addiu $t3,$t3,0x1 +/* f1894c4: 154effd4 */ bne $t2,$t6,.L0f189418 +/* f1894c8: a1470017 */ sb $a3,0x17($t2) +/* f1894cc: 10000037 */ b .L0f1895ac +/* f1894d0: 8fbf001c */ lw $ra,0x1c($sp) +.L0f1894d4: +/* f1894d4: 2401000d */ addiu $at,$zero,0xd +/* f1894d8: 54410017 */ bnel $v0,$at,.L0f189538 +/* f1894dc: 2401000c */ addiu $at,$zero,0xc +/* f1894e0: 0fc622f5 */ jal mpGetNumWeaponOptions +/* f1894e4: 00000000 */ nop +/* f1894e8: afa20034 */ sw $v0,0x34($sp) +/* f1894ec: 00008025 */ or $s0,$zero,$zero +.L0f1894f0: +/* f1894f0: 0c004b70 */ jal random +/* f1894f4: 00000000 */ nop +/* f1894f8: 8faf0034 */ lw $t7,0x34($sp) +/* f1894fc: 02002025 */ or $a0,$s0,$zero +/* f189500: 004f001b */ divu $zero,$v0,$t7 +/* f189504: 00002810 */ mfhi $a1 +/* f189508: 15e00002 */ bnez $t7,.L0f189514 +/* f18950c: 00000000 */ nop +/* f189510: 0007000d */ break 0x7 +.L0f189514: +/* f189514: 0fc62346 */ jal mpSetWeaponSlot +/* f189518: 00000000 */ nop +/* f18951c: 26100001 */ addiu $s0,$s0,0x1 +/* f189520: 24010006 */ addiu $at,$zero,0x6 +/* f189524: 1601fff2 */ bne $s0,$at,.L0f1894f0 +/* f189528: 00000000 */ nop +/* f18952c: 1000001f */ b .L0f1895ac +/* f189530: 8fbf001c */ lw $ra,0x1c($sp) +/* f189534: 2401000c */ addiu $at,$zero,0xc +.L0f189538: +/* f189538: 5441001c */ bnel $v0,$at,.L0f1895ac +/* f18953c: 8fbf001c */ lw $ra,0x1c($sp) +/* f189540: 0fc622f5 */ jal mpGetNumWeaponOptions +/* f189544: 00000000 */ nop +/* f189548: 2458fffe */ addiu $t8,$v0,-2 +/* f18954c: afb80030 */ sw $t8,0x30($sp) +/* f189550: 00008025 */ or $s0,$zero,$zero +.L0f189554: +/* f189554: 0c004b70 */ jal random +/* f189558: 00000000 */ nop +/* f18955c: 8fb90030 */ lw $t9,0x30($sp) +/* f189560: 02002025 */ or $a0,$s0,$zero +/* f189564: 0059001b */ divu $zero,$v0,$t9 +/* f189568: 00002810 */ mfhi $a1 +/* f18956c: 24a50001 */ addiu $a1,$a1,0x1 +/* f189570: 17200002 */ bnez $t9,.L0f18957c +/* f189574: 00000000 */ nop +/* f189578: 0007000d */ break 0x7 +.L0f18957c: +/* f18957c: 0fc62346 */ jal mpSetWeaponSlot +/* f189580: 00000000 */ nop +/* f189584: 26100001 */ addiu $s0,$s0,0x1 +/* f189588: 24010005 */ addiu $at,$zero,0x5 +/* f18958c: 1601fff1 */ bne $s0,$at,.L0f189554 +/* f189590: 00000000 */ nop +/* f189594: 0fc622f5 */ jal mpGetNumWeaponOptions +/* f189598: 00000000 */ nop +/* f18959c: 02002025 */ or $a0,$s0,$zero +/* f1895a0: 0fc62346 */ jal mpSetWeaponSlot +/* f1895a4: 2445ffff */ addiu $a1,$v0,-1 +.L0f1895a8: +/* f1895a8: 8fbf001c */ lw $ra,0x1c($sp) +.L0f1895ac: +/* f1895ac: 8fb00018 */ lw $s0,0x18($sp) +/* f1895b0: 27bd0050 */ addiu $sp,$sp,0x50 +/* f1895b4: 03e00008 */ jr $ra +/* f1895b8: 00000000 */ nop +); +#endif void mpSetWeaponSet(s32 weaponsetnum) { diff --git a/src/game/mplayer/scenarios.c b/src/game/mplayer/scenarios.c index 49c09911f..b1d99231f 100644 --- a/src/game/mplayer/scenarios.c +++ b/src/game/mplayer/scenarios.c @@ -2381,6 +2381,7 @@ bool scenarioCtcRadar2(Gfx **gdl, struct prop *prop) return false; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel scenarioCtcHighlight /* f181764: 90860000 */ lbu $a2,0x0($a0) @@ -2425,6 +2426,52 @@ glabel scenarioCtcHighlight /* f1817f8: 03e00008 */ jr $ra /* f1817fc: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel scenarioCtcHighlight +/* f181764: 90860000 */ lbu $a2,0x0($a0) +/* f181768: 8c830004 */ lw $v1,0x4($a0) +/* f18176c: 24010001 */ addiu $at,$zero,0x1 +/* f181770: 10c10006 */ beq $a2,$at,.L0f18178c +/* f181774: 00601025 */ or $v0,$v1,$zero +/* f181778: 24010004 */ addiu $at,$zero,0x4 +/* f18177c: 10c10003 */ beq $a2,$at,.L0f18178c +/* f181780: 24010002 */ addiu $at,$zero,0x2 +/* f181784: 54c1001c */ bnel $a2,$at,.L0f1817f8 +/* f181788: 00001025 */ or $v0,$zero,$zero +.L0f18178c: +/* f18178c: 904e0003 */ lbu $t6,0x3($v0) +/* f181790: 24010008 */ addiu $at,$zero,0x8 +/* f181794: 55c10018 */ bnel $t6,$at,.L0f1817f8 +/* f181798: 00001025 */ or $v0,$zero,$zero +/* f18179c: 906f005c */ lbu $t7,0x5c($v1) +/* f1817a0: 24010057 */ addiu $at,$zero,0x56 +/* f1817a4: 55e10014 */ bnel $t7,$at,.L0f1817f8 +/* f1817a8: 00001025 */ or $v0,$zero,$zero +/* f1817ac: 84780062 */ lh $t8,0x62($v1) +/* f1817b0: 3c038008 */ lui $v1,%hi(g_TeamColours) +/* f1817b4: 240e004b */ addiu $t6,$zero,0x4b +/* f1817b8: 0018c880 */ sll $t9,$t8,0x2 +/* f1817bc: 00791821 */ addu $v1,$v1,$t9 +/* f1817c0: 8c637cc4 */ lw $v1,%lo(g_TeamColours)($v1) +/* f1817c4: acae000c */ sw $t6,0xc($a1) +/* f1817c8: 24020001 */ addiu $v0,$zero,0x1 +/* f1817cc: 00034602 */ srl $t0,$v1,0x18 +/* f1817d0: 00035402 */ srl $t2,$v1,0x10 +/* f1817d4: 00036202 */ srl $t4,$v1,0x8 +/* f1817d8: 310900ff */ andi $t1,$t0,0xff +/* f1817dc: 314b00ff */ andi $t3,$t2,0xff +/* f1817e0: 318d00ff */ andi $t5,$t4,0xff +/* f1817e4: aca90000 */ sw $t1,0x0($a1) +/* f1817e8: acab0004 */ sw $t3,0x4($a1) +/* f1817ec: 03e00008 */ jr $ra +/* f1817f0: acad0008 */ sw $t5,0x8($a1) +/* f1817f4: 00001025 */ or $v0,$zero,$zero +.L0f1817f8: +/* f1817f8: 03e00008 */ jr $ra +/* f1817fc: 00000000 */ nop +); +#endif //bool scenarioCtcHighlight(struct prop *prop, u32 *colour) //{ diff --git a/src/game/mplayer/setup.c b/src/game/mplayer/setup.c index 450633327..37bd13580 100644 --- a/src/game/mplayer/setup.c +++ b/src/game/mplayer/setup.c @@ -1806,7 +1806,7 @@ const char var7f1b7f68[] = "%d:%02d:%02d"; char *mpMenuTextAccuracy(struct menuitem *item) { #if VERSION < VERSION_NTSC_1_0 - if (g_MpPlayers[g_MpPlayerNum].ammoused < 8) { + if (g_MpPlayers[g_MpPlayerNum].gamesplayed < 8) { return "-\n"; } #endif @@ -4691,6 +4691,7 @@ u32 var800857d4 = 0x50670000; // "Normal Simulants" u32 var800857d8 = 0x00000006; u32 var800857dc = 0x50680000; // "Special Simulants" +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuhandler0017c6a4 .late_rodata @@ -4979,6 +4980,296 @@ glabel var7f1b81e8 /* f17ca38: 03e00008 */ jr $ra /* f17ca3c: 27bd0058 */ addiu $sp,$sp,0x58 ); +#else +GLOBAL_ASM( +glabel menuhandler0017c6a4 +.late_rodata +glabel var7f1b81ac +.word menuhandler0017c6a4+0x78 # f17c71c +glabel var7f1b81b0 +.word menuhandler0017c6a4+0x2f0 # f17c994 +glabel var7f1b81b4 +.word menuhandler0017c6a4+0xac # f17c750 +glabel var7f1b81b8 +.word menuhandler0017c6a4+0x2fc # f17c9a0 +glabel var7f1b81bc +.word menuhandler0017c6a4+0x318 # f17c9bc +glabel var7f1b81c0 +.word menuhandler0017c6a4+0x100 # f17c7a4 +glabel var7f1b81c4 +.word menuhandler0017c6a4+0x2b8 # f17c95c +glabel var7f1b81c8 +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81cc +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81d0 +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81d4 +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81d8 +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81dc +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81e0 +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81e4 +.word menuhandler0017c6a4+0x378 # f17ca1c +glabel var7f1b81e8 +.word menuhandler0017c6a4+0x250 # f17c8f4 +.text +/* f176dc4: 27bdffa8 */ addiu $sp,$sp,-88 +/* f176dc8: 3c0e8008 */ lui $t6,0x8008 +/* f176dcc: afbf002c */ sw $ra,0x2c($sp) +/* f176dd0: afb40028 */ sw $s4,0x28($sp) +/* f176dd4: afb30024 */ sw $s3,0x24($sp) +/* f176dd8: afb20020 */ sw $s2,0x20($sp) +/* f176ddc: afb1001c */ sw $s1,0x1c($sp) +/* f176de0: afb00018 */ sw $s0,0x18($sp) +/* f176de4: afa5005c */ sw $a1,0x5c($sp) +/* f176de8: 25ce7f4c */ addiu $t6,$t6,0x7f4c +/* f176dec: 8dc10000 */ lw $at,0x0($t6) +/* f176df0: 27b30040 */ addiu $s3,$sp,0x40 +/* f176df4: 2488ffff */ addiu $t0,$a0,-1 +/* f176df8: ae610000 */ sw $at,0x0($s3) +/* f176dfc: 8dd90004 */ lw $t9,0x4($t6) +/* f176e00: 00c0a025 */ or $s4,$a2,$zero +/* f176e04: 00009025 */ or $s2,$zero,$zero +/* f176e08: ae790004 */ sw $t9,0x4($s3) +/* f176e0c: 8dc10008 */ lw $at,0x8($t6) +/* f176e10: ae610008 */ sw $at,0x8($s3) +/* f176e14: 8dd9000c */ lw $t9,0xc($t6) +/* f176e18: 2d010010 */ sltiu $at,$t0,0x10 +/* f176e1c: 102000c7 */ beqz $at,.NB0f17713c +/* f176e20: ae79000c */ sw $t9,0xc($s3) +/* f176e24: 00084080 */ sll $t0,$t0,0x2 +/* f176e28: 3c017f1b */ lui $at,0x7f1b +/* f176e2c: 00280821 */ addu $at,$at,$t0 +/* f176e30: 8c282aa0 */ lw $t0,0x2aa0($at) +/* f176e34: 01000008 */ jr $t0 +/* f176e38: 00000000 */ sll $zero,$zero,0x0 +/* f176e3c: 3c108009 */ lui $s0,0x8009 +/* f176e40: 3c118009 */ lui $s1,0x8009 +/* f176e44: 26319f3c */ addiu $s1,$s1,-24772 +/* f176e48: 26109eac */ addiu $s0,$s0,-24916 +.NB0f176e4c: +/* f176e4c: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f176e50: 92040006 */ lbu $a0,0x6($s0) +/* f176e54: 10400002 */ beqz $v0,.NB0f176e60 +/* f176e58: 26100008 */ addiu $s0,$s0,0x8 +/* f176e5c: 26520001 */ addiu $s2,$s2,0x1 +.NB0f176e60: +/* f176e60: 1611fffa */ bne $s0,$s1,.NB0f176e4c +/* f176e64: 00000000 */ sll $zero,$zero,0x0 +/* f176e68: 100000b4 */ beqz $zero,.NB0f17713c +/* f176e6c: ae920000 */ sw $s2,0x0($s4) +/* f176e70: 3c108009 */ lui $s0,0x8009 +/* f176e74: 3c118009 */ lui $s1,0x8009 +/* f176e78: 26319f3c */ addiu $s1,$s1,-24772 +/* f176e7c: 26109eac */ addiu $s0,$s0,-24916 +.NB0f176e80: +/* f176e80: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f176e84: 92040006 */ lbu $a0,0x6($s0) +/* f176e88: 5040000a */ beqzl $v0,.NB0f176eb4 +/* f176e8c: 26100008 */ addiu $s0,$s0,0x8 +/* f176e90: 8e890000 */ lw $t1,0x0($s4) +/* f176e94: 56490006 */ bnel $s2,$t1,.NB0f176eb0 +/* f176e98: 26520001 */ addiu $s2,$s2,0x1 +/* f176e9c: 0fc5a4dd */ jal langGet +/* f176ea0: 86040002 */ lh $a0,0x2($s0) +/* f176ea4: 100000a7 */ beqz $zero,.NB0f177144 +/* f176ea8: 8fbf002c */ lw $ra,0x2c($sp) +/* f176eac: 26520001 */ addiu $s2,$s2,0x1 +.NB0f176eb0: +/* f176eb0: 26100008 */ addiu $s0,$s0,0x8 +.NB0f176eb4: +/* f176eb4: 1611fff2 */ bne $s0,$s1,.NB0f176e80 +/* f176eb8: 00000000 */ sll $zero,$zero,0x0 +/* f176ebc: 100000a0 */ beqz $zero,.NB0f177140 +/* f176ec0: 00001025 */ or $v0,$zero,$zero +/* f176ec4: 3c0a8007 */ lui $t2,0x8007 +/* f176ec8: 8d4a3af0 */ lw $t2,0x3af0($t2) +/* f176ecc: 3c0c800a */ lui $t4,0x800a +/* f176ed0: afa00038 */ sw $zero,0x38($sp) +/* f176ed4: 000a58c0 */ sll $t3,$t2,0x3 +/* f176ed8: 016a5823 */ subu $t3,$t3,$t2 +/* f176edc: 000b58c0 */ sll $t3,$t3,0x3 +/* f176ee0: 016a5823 */ subu $t3,$t3,$t2 +/* f176ee4: 000b5900 */ sll $t3,$t3,0x4 +/* f176ee8: 016a5823 */ subu $t3,$t3,$t2 +/* f176eec: 000b5880 */ sll $t3,$t3,0x2 +/* f176ef0: 018b6021 */ addu $t4,$t4,$t3 +/* f176ef4: 8d8c3538 */ lw $t4,0x3538($t4) +/* f176ef8: 3c18800b */ lui $t8,0x800b +/* f176efc: 05810007 */ bgez $t4,.NB0f176f1c +/* f176f00: afac003c */ sw $t4,0x3c($sp) +/* f176f04: 0fc61b6f */ jal mpGetNumSimulants +/* f176f08: 00000000 */ sll $zero,$zero,0x0 +/* f176f0c: 240d0001 */ addiu $t5,$zero,0x1 +/* f176f10: afa2003c */ sw $v0,0x3c($sp) +/* f176f14: 1000000a */ beqz $zero,.NB0f176f40 +/* f176f18: afad0038 */ sw $t5,0x38($sp) +.NB0f176f1c: +/* f176f1c: 8faf003c */ lw $t7,0x3c($sp) +/* f176f20: 9718144e */ lhu $t8,0x144e($t8) +/* f176f24: 24190001 */ addiu $t9,$zero,0x1 +/* f176f28: 25ee0004 */ addiu $t6,$t7,0x4 +/* f176f2c: 01d94004 */ sllv $t0,$t9,$t6 +/* f176f30: 03084824 */ and $t1,$t8,$t0 +/* f176f34: 15200002 */ bnez $t1,.NB0f176f40 +/* f176f38: 240a0001 */ addiu $t2,$zero,0x1 +/* f176f3c: afaa0038 */ sw $t2,0x38($sp) +.NB0f176f40: +/* f176f40: 3c108009 */ lui $s0,0x8009 +/* f176f44: 26109eac */ addiu $s0,$s0,-24916 +/* f176f48: 00008825 */ or $s1,$zero,$zero +/* f176f4c: 24130012 */ addiu $s3,$zero,0x12 +.NB0f176f50: +/* f176f50: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f176f54: 92040006 */ lbu $a0,0x6($s0) +/* f176f58: 50400005 */ beqzl $v0,.NB0f176f70 +/* f176f5c: 26310001 */ addiu $s1,$s1,0x1 +/* f176f60: 8e8b0000 */ lw $t3,0x0($s4) +/* f176f64: 124b0004 */ beq $s2,$t3,.NB0f176f78 +/* f176f68: 26520001 */ addiu $s2,$s2,0x1 +/* f176f6c: 26310001 */ addiu $s1,$s1,0x1 +.NB0f176f70: +/* f176f70: 1633fff7 */ bne $s1,$s3,.NB0f176f50 +/* f176f74: 26100008 */ addiu $s0,$s0,0x8 +.NB0f176f78: +/* f176f78: 8fac0038 */ lw $t4,0x38($sp) +/* f176f7c: 8fad003c */ lw $t5,0x3c($sp) +/* f176f80: 3c19800b */ lui $t9,0x800b +/* f176f84: 11800006 */ beqz $t4,.NB0f176fa0 +/* f176f88: 000d7880 */ sll $t7,$t5,0x2 +/* f176f8c: 8fa4003c */ lw $a0,0x3c($sp) +/* f176f90: 0fc61ae2 */ jal func0f18c984 +/* f176f94: 322500ff */ andi $a1,$s1,0xff +/* f176f98: 1000000e */ beqz $zero,.NB0f176fd4 +/* f176f9c: 00000000 */ sll $zero,$zero,0x0 +.NB0f176fa0: +/* f176fa0: 01ed7821 */ addu $t7,$t7,$t5 +/* f176fa4: 920e0000 */ lbu $t6,0x0($s0) +/* f176fa8: 000f7880 */ sll $t7,$t7,0x2 +/* f176fac: 01ed7823 */ subu $t7,$t7,$t5 +/* f176fb0: 000f7880 */ sll $t7,$t7,0x2 +/* f176fb4: 27390de8 */ addiu $t9,$t9,0xde8 +/* f176fb8: 01f91021 */ addu $v0,$t7,$t9 +/* f176fbc: 31d800ff */ andi $t8,$t6,0xff +/* f176fc0: 17000004 */ bnez $t8,.NB0f176fd4 +/* f176fc4: a04e0047 */ sb $t6,0x47($v0) +/* f176fc8: 8fa4003c */ lw $a0,0x3c($sp) +/* f176fcc: 0fc61b59 */ jal func0f18cb60 +/* f176fd0: 92050001 */ lbu $a1,0x1($s0) +.NB0f176fd4: +/* f176fd4: 0fc61bf8 */ jal func0f18cddc +/* f176fd8: 00000000 */ sll $zero,$zero,0x0 +/* f176fdc: 3c098007 */ lui $t1,0x8007 +/* f176fe0: 8d293af0 */ lw $t1,0x3af0($t1) +/* f176fe4: 8e880000 */ lw $t0,0x0($s4) +/* f176fe8: 3c01800a */ lui $at,0x800a +/* f176fec: 000950c0 */ sll $t2,$t1,0x3 +/* f176ff0: 01495023 */ subu $t2,$t2,$t1 +/* f176ff4: 000a50c0 */ sll $t2,$t2,0x3 +/* f176ff8: 01495023 */ subu $t2,$t2,$t1 +/* f176ffc: 000a5100 */ sll $t2,$t2,0x4 +/* f177000: 01495023 */ subu $t2,$t2,$t1 +/* f177004: 000a5080 */ sll $t2,$t2,0x2 +/* f177008: 002a0821 */ addu $at,$at,$t2 +/* f17700c: 1000004b */ beqz $zero,.NB0f17713c +/* f177010: ac28353c */ sw $t0,0x353c($at) +/* f177014: 3c108009 */ lui $s0,0x8009 +/* f177018: 26109eac */ addiu $s0,$s0,-24916 +/* f17701c: 00008825 */ or $s1,$zero,$zero +/* f177020: 24130012 */ addiu $s3,$zero,0x12 +.NB0f177024: +/* f177024: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f177028: 92040006 */ lbu $a0,0x6($s0) +/* f17702c: 50400005 */ beqzl $v0,.NB0f177044 +/* f177030: 26310001 */ addiu $s1,$s1,0x1 +/* f177034: 8e8b0000 */ lw $t3,0x0($s4) +/* f177038: 124b0004 */ beq $s2,$t3,.NB0f17704c +/* f17703c: 26520001 */ addiu $s2,$s2,0x1 +/* f177040: 26310001 */ addiu $s1,$s1,0x1 +.NB0f177044: +/* f177044: 1633fff7 */ bne $s1,$s3,.NB0f177024 +/* f177048: 26100008 */ addiu $s0,$s0,0x8 +.NB0f17704c: +/* f17704c: 3c0c8007 */ lui $t4,0x8007 +/* f177050: 8d8c3af0 */ lw $t4,0x3af0($t4) +/* f177054: 3c01800a */ lui $at,0x800a +/* f177058: 000c68c0 */ sll $t5,$t4,0x3 +/* f17705c: 01ac6823 */ subu $t5,$t5,$t4 +/* f177060: 000d68c0 */ sll $t5,$t5,0x3 +/* f177064: 01ac6823 */ subu $t5,$t5,$t4 +/* f177068: 000d6900 */ sll $t5,$t5,0x4 +/* f17706c: 01ac6823 */ subu $t5,$t5,$t4 +/* f177070: 000d6880 */ sll $t5,$t5,0x2 +/* f177074: 002d0821 */ addu $at,$at,$t5 +/* f177078: ac313540 */ sw $s1,0x3540($at) +/* f17707c: 3c0f8007 */ lui $t7,0x8007 +/* f177080: 8def3af0 */ lw $t7,0x3af0($t7) +/* f177084: 3c0e800a */ lui $t6,0x800a +/* f177088: 000fc8c0 */ sll $t9,$t7,0x3 +/* f17708c: 032fc823 */ subu $t9,$t9,$t7 +/* f177090: 0019c8c0 */ sll $t9,$t9,0x3 +/* f177094: 032fc823 */ subu $t9,$t9,$t7 +/* f177098: 0019c900 */ sll $t9,$t9,0x4 +/* f17709c: 032fc823 */ subu $t9,$t9,$t7 +/* f1770a0: 0019c880 */ sll $t9,$t9,0x2 +/* f1770a4: 01d97021 */ addu $t6,$t6,$t9 +/* f1770a8: 8dce353c */ lw $t6,0x353c($t6) +/* f1770ac: 10000023 */ beqz $zero,.NB0f17713c +/* f1770b0: ae8e0000 */ sw $t6,0x0($s4) +/* f1770b4: 24180002 */ addiu $t8,$zero,0x2 +/* f1770b8: 10000020 */ beqz $zero,.NB0f17713c +/* f1770bc: ae980000 */ sw $t8,0x0($s4) +/* f1770c0: 8e890000 */ lw $t1,0x0($s4) +/* f1770c4: 000940c0 */ sll $t0,$t1,0x3 +/* f1770c8: 02685021 */ addu $t2,$s3,$t0 +/* f1770cc: 0fc5a4dd */ jal langGet +/* f1770d0: 95440004 */ lhu $a0,0x4($t2) +/* f1770d4: 1000001b */ beqz $zero,.NB0f177144 +/* f1770d8: 8fbf002c */ lw $ra,0x2c($sp) +/* f1770dc: 8e8b0000 */ lw $t3,0x0($s4) +/* f1770e0: 3c108009 */ lui $s0,0x8009 +/* f1770e4: 26109eac */ addiu $s0,$s0,-24916 +/* f1770e8: 000b60c0 */ sll $t4,$t3,0x3 +/* f1770ec: 026c6821 */ addu $t5,$s3,$t4 +/* f1770f0: 8daf0000 */ lw $t7,0x0($t5) +/* f1770f4: 00008825 */ or $s1,$zero,$zero +/* f1770f8: 59e00010 */ blezl $t7,.NB0f17713c +/* f1770fc: ae920008 */ sw $s2,0x8($s4) +.NB0f177100: +/* f177100: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f177104: 92040006 */ lbu $a0,0x6($s0) +/* f177108: 50400003 */ beqzl $v0,.NB0f177118 +/* f17710c: 8e990000 */ lw $t9,0x0($s4) +/* f177110: 26520001 */ addiu $s2,$s2,0x1 +/* f177114: 8e990000 */ lw $t9,0x0($s4) +.NB0f177118: +/* f177118: 26310001 */ addiu $s1,$s1,0x1 +/* f17711c: 26100008 */ addiu $s0,$s0,0x8 +/* f177120: 001970c0 */ sll $t6,$t9,0x3 +/* f177124: 026ec021 */ addu $t8,$s3,$t6 +/* f177128: 8f090000 */ lw $t1,0x0($t8) +/* f17712c: 0229082a */ slt $at,$s1,$t1 +/* f177130: 1420fff3 */ bnez $at,.NB0f177100 +/* f177134: 00000000 */ sll $zero,$zero,0x0 +/* f177138: ae920008 */ sw $s2,0x8($s4) +.NB0f17713c: +/* f17713c: 00001025 */ or $v0,$zero,$zero +.NB0f177140: +/* f177140: 8fbf002c */ lw $ra,0x2c($sp) +.NB0f177144: +/* f177144: 8fb00018 */ lw $s0,0x18($sp) +/* f177148: 8fb1001c */ lw $s1,0x1c($sp) +/* f17714c: 8fb20020 */ lw $s2,0x20($sp) +/* f177150: 8fb30024 */ lw $s3,0x24($sp) +/* f177154: 8fb40028 */ lw $s4,0x28($sp) +/* f177158: 03e00008 */ jr $ra +/* f17715c: 27bd0058 */ addiu $sp,$sp,0x58 +); +#endif char *mpMenuTextSimulantDescription(struct menuitem *item) { @@ -5167,7 +5458,7 @@ glabel menuhandlerMpSimulantDifficulty /* f17cf50: 03e00008 */ jr $ra /* f17cf54: 27bd0030 */ addiu $sp,$sp,0x30 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuhandlerMpSimulantDifficulty /* f17cda0: 27bdffd0 */ addiu $sp,$sp,-48 @@ -5294,6 +5585,133 @@ glabel menuhandlerMpSimulantDifficulty /* f17cf50: 03e00008 */ jr $ra /* f17cf54: 27bd0030 */ addiu $sp,$sp,0x30 ); +#else +GLOBAL_ASM( +glabel menuhandlerMpSimulantDifficulty +/* f1774c0: 27bdffd0 */ addiu $sp,$sp,-48 +/* f1774c4: afb40028 */ sw $s4,0x28($sp) +/* f1774c8: afb20020 */ sw $s2,0x20($sp) +/* f1774cc: 24010001 */ addiu $at,$zero,0x1 +/* f1774d0: 00c0a025 */ or $s4,$a2,$zero +/* f1774d4: afbf002c */ sw $ra,0x2c($sp) +/* f1774d8: afb30024 */ sw $s3,0x24($sp) +/* f1774dc: afb1001c */ sw $s1,0x1c($sp) +/* f1774e0: afb00018 */ sw $s0,0x18($sp) +/* f1774e4: afa50034 */ sw $a1,0x34($sp) +/* f1774e8: 10810038 */ beq $a0,$at,.NB0f1775cc +/* f1774ec: 00009025 */ or $s2,$zero,$zero +/* f1774f0: 24010003 */ addiu $at,$zero,0x3 +/* f1774f4: 10810042 */ beq $a0,$at,.NB0f177600 +/* f1774f8: 00008825 */ or $s1,$zero,$zero +/* f1774fc: 24130006 */ addiu $s3,$zero,0x6 +/* f177500: 10930006 */ beq $a0,$s3,.NB0f17751c +/* f177504: 3c0e8007 */ lui $t6,0x8007 +/* f177508: 24010007 */ addiu $at,$zero,0x7 +/* f17750c: 10810014 */ beq $a0,$at,.NB0f177560 +/* f177510: 3c188007 */ lui $t8,0x8007 +/* f177514: 10000050 */ beqz $zero,.NB0f177658 +/* f177518: 00001025 */ or $v0,$zero,$zero +.NB0f17751c: +/* f17751c: 8dce3af0 */ lw $t6,0x3af0($t6) +/* f177520: 3c04800a */ lui $a0,0x800a +/* f177524: 8e850000 */ lw $a1,0x0($s4) +/* f177528: 000e78c0 */ sll $t7,$t6,0x3 +/* f17752c: 01ee7823 */ subu $t7,$t7,$t6 +/* f177530: 000f78c0 */ sll $t7,$t7,0x3 +/* f177534: 01ee7823 */ subu $t7,$t7,$t6 +/* f177538: 000f7900 */ sll $t7,$t7,0x4 +/* f17753c: 01ee7823 */ subu $t7,$t7,$t6 +/* f177540: 000f7880 */ sll $t7,$t7,0x2 +/* f177544: 008f2021 */ addu $a0,$a0,$t7 +/* f177548: 0fc61b59 */ jal func0f18cb60 +/* f17754c: 8c843538 */ lw $a0,0x3538($a0) +/* f177550: 0fc61bf8 */ jal func0f18cddc +/* f177554: 00000000 */ sll $zero,$zero,0x0 +/* f177558: 1000003f */ beqz $zero,.NB0f177658 +/* f17755c: 00001025 */ or $v0,$zero,$zero +.NB0f177560: +/* f177560: 8f183af0 */ lw $t8,0x3af0($t8) +/* f177564: 3c08800a */ lui $t0,0x800a +/* f177568: 3c02800b */ lui $v0,0x800b +/* f17756c: 0018c8c0 */ sll $t9,$t8,0x3 +/* f177570: 0338c823 */ subu $t9,$t9,$t8 +/* f177574: 0019c8c0 */ sll $t9,$t9,0x3 +/* f177578: 0338c823 */ subu $t9,$t9,$t8 +/* f17757c: 0019c900 */ sll $t9,$t9,0x4 +/* f177580: 0338c823 */ subu $t9,$t9,$t8 +/* f177584: 0019c880 */ sll $t9,$t9,0x2 +/* f177588: 01194021 */ addu $t0,$t0,$t9 +/* f17758c: 8d083538 */ lw $t0,0x3538($t0) +/* f177590: 00084880 */ sll $t1,$t0,0x2 +/* f177594: 01284821 */ addu $t1,$t1,$t0 +/* f177598: 00094880 */ sll $t1,$t1,0x2 +/* f17759c: 01284823 */ subu $t1,$t1,$t0 +/* f1775a0: 00094880 */ sll $t1,$t1,0x2 +/* f1775a4: 00491021 */ addu $v0,$v0,$t1 +/* f1775a8: 90420e30 */ lbu $v0,0xe30($v0) +/* f1775ac: 04400005 */ bltz $v0,.NB0f1775c4 +/* f1775b0: 28410006 */ slti $at,$v0,0x6 +/* f1775b4: 10200003 */ beqz $at,.NB0f1775c4 +/* f1775b8: 00000000 */ sll $zero,$zero,0x0 +/* f1775bc: 10000025 */ beqz $zero,.NB0f177654 +/* f1775c0: ae820000 */ sw $v0,0x0($s4) +.NB0f1775c4: +/* f1775c4: 10000023 */ beqz $zero,.NB0f177654 +/* f1775c8: ae800000 */ sw $zero,0x0($s4) +.NB0f1775cc: +/* f1775cc: 3c108009 */ lui $s0,0x8009 +/* f1775d0: 3c118009 */ lui $s1,0x8009 +/* f1775d4: 26319edc */ addiu $s1,$s1,-24868 +/* f1775d8: 26109eac */ addiu $s0,$s0,-24916 +.NB0f1775dc: +/* f1775dc: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f1775e0: 92040006 */ lbu $a0,0x6($s0) +/* f1775e4: 10400002 */ beqz $v0,.NB0f1775f0 +/* f1775e8: 26100008 */ addiu $s0,$s0,0x8 +/* f1775ec: 26520001 */ addiu $s2,$s2,0x1 +.NB0f1775f0: +/* f1775f0: 1611fffa */ bne $s0,$s1,.NB0f1775dc +/* f1775f4: 00000000 */ sll $zero,$zero,0x0 +/* f1775f8: 10000016 */ beqz $zero,.NB0f177654 +/* f1775fc: ae920000 */ sw $s2,0x0($s4) +.NB0f177600: +/* f177600: 3c108009 */ lui $s0,0x8009 +/* f177604: 26109eac */ addiu $s0,$s0,-24916 +/* f177608: 24130006 */ addiu $s3,$zero,0x6 +.NB0f17760c: +/* f17760c: 0fc65a5e */ jal mpIsFeatureUnlocked +/* f177610: 92040006 */ lbu $a0,0x6($s0) +/* f177614: 5040000a */ beqzl $v0,.NB0f177640 +/* f177618: 26310001 */ addiu $s1,$s1,0x1 +/* f17761c: 8e8a0000 */ lw $t2,0x0($s4) +/* f177620: 564a0006 */ bnel $s2,$t2,.NB0f17763c +/* f177624: 26520001 */ addiu $s2,$s2,0x1 +/* f177628: 0fc5a4dd */ jal langGet +/* f17762c: 26245852 */ addiu $a0,$s1,0x5852 +/* f177630: 1000000a */ beqz $zero,.NB0f17765c +/* f177634: 8fbf002c */ lw $ra,0x2c($sp) +/* f177638: 26520001 */ addiu $s2,$s2,0x1 +.NB0f17763c: +/* f17763c: 26310001 */ addiu $s1,$s1,0x1 +.NB0f177640: +/* f177640: 1633fff2 */ bne $s1,$s3,.NB0f17760c +/* f177644: 26100008 */ addiu $s0,$s0,0x8 +/* f177648: 3c027f1b */ lui $v0,0x7f1b +/* f17764c: 10000002 */ beqz $zero,.NB0f177658 +/* f177650: 24422928 */ addiu $v0,$v0,0x2928 +.NB0f177654: +/* f177654: 00001025 */ or $v0,$zero,$zero +.NB0f177658: +/* f177658: 8fbf002c */ lw $ra,0x2c($sp) +.NB0f17765c: +/* f17765c: 8fb00018 */ lw $s0,0x18($sp) +/* f177660: 8fb1001c */ lw $s1,0x1c($sp) +/* f177664: 8fb20020 */ lw $s2,0x20($sp) +/* f177668: 8fb30024 */ lw $s3,0x24($sp) +/* f17766c: 8fb40028 */ lw $s4,0x28($sp) +/* f177670: 03e00008 */ jr $ra +/* f177674: 27bd0030 */ addiu $sp,$sp,0x30 +); #endif s32 menuhandlerMpDeleteSimulant(s32 operation, struct menuitem *item, union handlerdata *data) @@ -6154,6 +6572,7 @@ s32 menuhandlerMpMultipleTunes(s32 operation, struct menuitem *item, union handl return 0; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel menuhandler0017e06c /* f17e06c: afa50004 */ sw $a1,0x4($sp) @@ -6303,6 +6722,157 @@ glabel menuhandler0017e06c /* f17e280: 03e00008 */ jr $ra /* f17e284: 00001025 */ or $v0,$zero,$zero ); +#else +GLOBAL_ASM( +glabel menuhandler0017e06c +/* f17877c: afa50004 */ sw $a1,0x4($sp) +/* f178780: 24010011 */ addiu $at,$zero,0x11 +/* f178784: 10810006 */ beq $a0,$at,.NB0f1787a0 +/* f178788: 8cc20000 */ lw $v0,0x0($a2) +/* f17878c: 24010012 */ addiu $at,$zero,0x12 +/* f178790: 1081003f */ beq $a0,$at,.NB0f178890 +/* f178794: 3c098007 */ lui $t1,0x8007 +/* f178798: 03e00008 */ jr $ra +/* f17879c: 00001025 */ or $v0,$zero,$zero +.NB0f1787a0: +/* f1787a0: 3c098007 */ lui $t1,0x8007 +/* f1787a4: 25293af0 */ addiu $t1,$t1,0x3af0 +/* f1787a8: 8d2e0000 */ lw $t6,0x0($t1) +/* f1787ac: 240a0dbc */ addiu $t2,$zero,0xdbc +/* f1787b0: 3c08800a */ lui $t0,0x800a +/* f1787b4: 01ca0019 */ multu $t6,$t2 +/* f1787b8: 250827c0 */ addiu $t0,$t0,0x27c0 +/* f1787bc: 3c07800b */ lui $a3,0x800b +/* f1787c0: 24e71460 */ addiu $a3,$a3,0x1460 +/* f1787c4: 240b000a */ addiu $t3,$zero,0xa +/* f1787c8: 00001825 */ or $v1,$zero,$zero +/* f1787cc: 00007812 */ mflo $t7 +/* f1787d0: 010fc021 */ addu $t8,$t0,$t7 +/* f1787d4: 8f040d78 */ lw $a0,0xd78($t8) +/* f1787d8: 0004c880 */ sll $t9,$a0,0x2 +/* f1787dc: 0324c823 */ subu $t9,$t9,$a0 +/* f1787e0: 0019c880 */ sll $t9,$t9,0x2 +/* f1787e4: 00f96821 */ addu $t5,$a3,$t9 +/* f1787e8: 91ae0000 */ lbu $t6,0x0($t5) +/* f1787ec: 00047880 */ sll $t7,$a0,0x2 +/* f1787f0: 01e47823 */ subu $t7,$t7,$a0 +/* f1787f4: 116e001c */ beq $t3,$t6,.NB0f178868 +/* f1787f8: 000f7880 */ sll $t7,$t7,0x2 +/* f1787fc: 00ef2821 */ addu $a1,$a3,$t7 +/* f178800: 90b80000 */ lbu $t8,0x0($a1) +/* f178804: 00403021 */ addu $a2,$v0,$zero +/* f178808: 240c000b */ addiu $t4,$zero,0xb +/* f17880c: 53000017 */ beqzl $t8,.NB0f17886c +/* f178810: 2861000b */ slti $at,$v1,0xb +/* f178814: 90a40000 */ lbu $a0,0x0($a1) +/* f178818: a0c40000 */ sb $a0,0x0($a2) +.NB0f17881c: +/* f17881c: 8d2d0000 */ lw $t5,0x0($t1) +/* f178820: 24630001 */ addiu $v1,$v1,0x1 +/* f178824: 24c60001 */ addiu $a2,$a2,0x1 +/* f178828: 01aa0019 */ multu $t5,$t2 +/* f17882c: 00007012 */ mflo $t6 +/* f178830: 010e7821 */ addu $t7,$t0,$t6 +/* f178834: 8df80d78 */ lw $t8,0xd78($t7) +/* f178838: 0018c880 */ sll $t9,$t8,0x2 +/* f17883c: 0338c823 */ subu $t9,$t9,$t8 +/* f178840: 0019c880 */ sll $t9,$t9,0x2 +/* f178844: 00f96821 */ addu $t5,$a3,$t9 +/* f178848: 01a37021 */ addu $t6,$t5,$v1 +/* f17884c: 91c40000 */ lbu $a0,0x0($t6) +/* f178850: 51640006 */ beql $t3,$a0,.NB0f17886c +/* f178854: 2861000b */ slti $at,$v1,0xb +/* f178858: 50800004 */ beqzl $a0,.NB0f17886c +/* f17885c: 2861000b */ slti $at,$v1,0xb +/* f178860: 546cffee */ bnel $v1,$t4,.NB0f17881c +/* f178864: a0c40000 */ sb $a0,0x0($a2) +.NB0f178868: +/* f178868: 2861000b */ slti $at,$v1,0xb +.NB0f17886c: +/* f17886c: 10200048 */ beqz $at,.NB0f178990 +/* f178870: 00433021 */ addu $a2,$v0,$v1 +.NB0f178874: +/* f178874: 24630001 */ addiu $v1,$v1,0x1 +/* f178878: 2861000b */ slti $at,$v1,0xb +/* f17887c: a0c00000 */ sb $zero,0x0($a2) +/* f178880: 1420fffc */ bnez $at,.NB0f178874 +/* f178884: 24c60001 */ addiu $a2,$a2,0x1 +/* f178888: 03e00008 */ jr $ra +/* f17888c: 00001025 */ or $v0,$zero,$zero +.NB0f178890: +/* f178890: 904f0000 */ lbu $t7,0x0($v0) +/* f178894: 00001825 */ or $v1,$zero,$zero +/* f178898: 3c188007 */ lui $t8,0x8007 +/* f17889c: 11e0001d */ beqz $t7,.NB0f178914 +/* f1788a0: 25293af0 */ addiu $t1,$t1,0x3af0 +/* f1788a4: 8f183af0 */ lw $t8,0x3af0($t8) +/* f1788a8: 3c0d800a */ lui $t5,0x800a +/* f1788ac: 00403021 */ addu $a2,$v0,$zero +/* f1788b0: 0018c8c0 */ sll $t9,$t8,0x3 +/* f1788b4: 0338c823 */ subu $t9,$t9,$t8 +/* f1788b8: 0019c8c0 */ sll $t9,$t9,0x3 +/* f1788bc: 0338c823 */ subu $t9,$t9,$t8 +/* f1788c0: 0019c900 */ sll $t9,$t9,0x4 +/* f1788c4: 0338c823 */ subu $t9,$t9,$t8 +/* f1788c8: 0019c880 */ sll $t9,$t9,0x2 +/* f1788cc: 01b96821 */ addu $t5,$t5,$t9 +/* f1788d0: 8dad3538 */ lw $t5,0x3538($t5) +/* f1788d4: 3c18800b */ lui $t8,0x800b +/* f1788d8: 27181460 */ addiu $t8,$t8,0x1460 +/* f1788dc: 000d7080 */ sll $t6,$t5,0x2 +/* f1788e0: 01cd7023 */ subu $t6,$t6,$t5 +/* f1788e4: 000e7080 */ sll $t6,$t6,0x2 +/* f1788e8: 01d82021 */ addu $a0,$t6,$t8 +/* f1788ec: 90450000 */ lbu $a1,0x0($v0) +/* f1788f0: 24630001 */ addiu $v1,$v1,0x1 +.NB0f1788f4: +/* f1788f4: 2861000b */ slti $at,$v1,0xb +/* f1788f8: a0850000 */ sb $a1,0x0($a0) +/* f1788fc: 24840001 */ addiu $a0,$a0,0x1 +/* f178900: 10200004 */ beqz $at,.NB0f178914 +/* f178904: 24c60001 */ addiu $a2,$a2,0x1 +/* f178908: 90c50000 */ lbu $a1,0x0($a2) +/* f17890c: 54a0fff9 */ bnezl $a1,.NB0f1788f4 +/* f178910: 24630001 */ addiu $v1,$v1,0x1 +.NB0f178914: +/* f178914: 8d390000 */ lw $t9,0x0($t1) +/* f178918: 240a0dbc */ addiu $t2,$zero,0xdbc +/* f17891c: 3c08800a */ lui $t0,0x800a +/* f178920: 032a0019 */ multu $t9,$t2 +/* f178924: 250827c0 */ addiu $t0,$t0,0x27c0 +/* f178928: 3c07800b */ lui $a3,0x800b +/* f17892c: 24e71460 */ addiu $a3,$a3,0x1460 +/* f178930: 3c02800a */ lui $v0,0x800a +/* f178934: 2442e6c0 */ addiu $v0,$v0,-6464 +/* f178938: 00006812 */ mflo $t5 +/* f17893c: 010d7021 */ addu $t6,$t0,$t5 +/* f178940: 8dcf0d78 */ lw $t7,0xd78($t6) +/* f178944: 240d000a */ addiu $t5,$zero,0xa +/* f178948: 000fc080 */ sll $t8,$t7,0x2 +/* f17894c: 030fc023 */ subu $t8,$t8,$t7 +/* f178950: 0018c080 */ sll $t8,$t8,0x2 +/* f178954: 00f8c821 */ addu $t9,$a3,$t8 +/* f178958: 03232021 */ addu $a0,$t9,$v1 +/* f17895c: 24630001 */ addiu $v1,$v1,0x1 +/* f178960: 2861000b */ slti $at,$v1,0xb +/* f178964: a08d0000 */ sb $t5,0x0($a0) +/* f178968: 10200006 */ beqz $at,.NB0f178984 +/* f17896c: 24840001 */ addiu $a0,$a0,0x1 +.NB0f178970: +/* f178970: 24630001 */ addiu $v1,$v1,0x1 +/* f178974: 2861000b */ slti $at,$v1,0xb +/* f178978: a0800000 */ sb $zero,0x0($a0) +/* f17897c: 1420fffc */ bnez $at,.NB0f178970 +/* f178980: 24840001 */ addiu $a0,$a0,0x1 +.NB0f178984: +/* f178984: 8c4e0458 */ lw $t6,0x458($v0) +/* f178988: 35cf0002 */ ori $t7,$t6,0x2 +/* f17898c: ac4f0458 */ sw $t7,0x458($v0) +.NB0f178990: +/* f178990: 03e00008 */ jr $ra +/* f178994: 00001025 */ or $v0,$zero,$zero +); +#endif /** * item->param2 is a text ID for that team's colour. The text IDs for team @@ -7835,6 +8405,7 @@ s32 menuhandlerMpAdvancedSetup(s32 operation, struct menuitem *item, union handl return 0; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f17fa28 /* f17fa28: 27bdffb8 */ addiu $sp,$sp,-72 @@ -8019,6 +8590,192 @@ glabel func0f17fa28 /* f17fca8: 03e00008 */ jr $ra /* f17fcac: 27bd0048 */ addiu $sp,$sp,0x48 ); +#else +GLOBAL_ASM( +glabel func0f17fa28 +/* f17a0b0: 27bdffb8 */ addiu $sp,$sp,-72 +/* f17a0b4: afbf003c */ sw $ra,0x3c($sp) +/* f17a0b8: 3c1f8007 */ lui $ra,0x8007 +/* f17a0bc: 27ff3af0 */ addiu $ra,$ra,0x3af0 +/* f17a0c0: 8fee0000 */ lw $t6,0x0($ra) +/* f17a0c4: afbe0038 */ sw $s8,0x38($sp) +/* f17a0c8: afb70034 */ sw $s7,0x34($sp) +/* f17a0cc: afb60030 */ sw $s6,0x30($sp) +/* f17a0d0: afb5002c */ sw $s5,0x2c($sp) +/* f17a0d4: afb40028 */ sw $s4,0x28($sp) +/* f17a0d8: afb30024 */ sw $s3,0x24($sp) +/* f17a0dc: afb20020 */ sw $s2,0x20($sp) +/* f17a0e0: afb1001c */ sw $s1,0x1c($sp) +/* f17a0e4: 3c118008 */ lui $s1,0x8008 +/* f17a0e8: 3c128008 */ lui $s2,0x8008 +/* f17a0ec: 3c138008 */ lui $s3,0x8008 +/* f17a0f0: 3c148008 */ lui $s4,0x8008 +/* f17a0f4: 3c158009 */ lui $s5,0x8009 +/* f17a0f8: 3c168009 */ lui $s6,0x8009 +/* f17a0fc: 3c178009 */ lui $s7,0x8009 +/* f17a100: 3c1e8009 */ lui $s8,0x8009 +/* f17a104: 3c098009 */ lui $t1,0x8009 +/* f17a108: 3c088009 */ lui $t0,0x8009 +/* f17a10c: 3c078009 */ lui $a3,0x8009 +/* f17a110: afb00018 */ sw $s0,0x18($sp) +/* f17a114: 24e79460 */ addiu $a3,$a3,-27552 +/* f17a118: 2508957c */ addiu $t0,$t0,-27268 +/* f17a11c: 25299700 */ addiu $t1,$t1,-26880 +/* f17a120: 27de92c8 */ addiu $s8,$s8,-27960 +/* f17a124: 26f79154 */ addiu $s7,$s7,-28332 +/* f17a128: 26d69038 */ addiu $s6,$s6,-28616 +/* f17a12c: 26b580a8 */ addiu $s5,$s5,-32600 +/* f17a130: 26947fb0 */ addiu $s4,$s4,0x7fb0 +/* f17a134: 26737f98 */ addiu $s3,$s3,0x7f98 +/* f17a138: 26527518 */ addiu $s2,$s2,0x7518 +/* f17a13c: 2631749c */ addiu $s1,$s1,0x749c +/* f17a140: 00001025 */ or $v0,$zero,$zero +/* f17a144: afae0040 */ sw $t6,0x40($sp) +/* f17a148: 0002c0c0 */ sll $t8,$v0,0x3 +.NB0f17a14c: +/* f17a14c: 0302c023 */ subu $t8,$t8,$v0 +/* f17a150: 0018c0c0 */ sll $t8,$t8,0x3 +/* f17a154: 0302c023 */ subu $t8,$t8,$v0 +/* f17a158: 0018c100 */ sll $t8,$t8,0x4 +/* f17a15c: 0302c023 */ subu $t8,$t8,$v0 +/* f17a160: 0018c080 */ sll $t8,$t8,0x2 +/* f17a164: 3c19800a */ lui $t9,0x800a +/* f17a168: afe20000 */ sw $v0,0x0($ra) +/* f17a16c: 0338c821 */ addu $t9,$t9,$t8 +/* f17a170: 8f392c48 */ lw $t9,0x2c48($t9) +/* f17a174: 5320005f */ beqzl $t9,.NB0f17a2f4 +/* f17a178: 24420001 */ addiu $v0,$v0,0x1 +/* f17a17c: afa20044 */ sw $v0,0x44($sp) +/* f17a180: 8fe20000 */ lw $v0,0x0($ra) +.NB0f17a184: +/* f17a184: 3c0f800a */ lui $t7,0x800a +/* f17a188: 25ef27c0 */ addiu $t7,$t7,0x27c0 +/* f17a18c: 000270c0 */ sll $t6,$v0,0x3 +/* f17a190: 01c27023 */ subu $t6,$t6,$v0 +/* f17a194: 000e70c0 */ sll $t6,$t6,0x3 +/* f17a198: 01c27023 */ subu $t6,$t6,$v0 +/* f17a19c: 000e7100 */ sll $t6,$t6,0x4 +/* f17a1a0: 01c27023 */ subu $t6,$t6,$v0 +/* f17a1a4: 000e7080 */ sll $t6,$t6,0x2 +/* f17a1a8: 01cfc021 */ addu $t8,$t6,$t7 +/* f17a1ac: 870d0484 */ lh $t5,0x484($t8) +/* f17a1b0: 24100001 */ addiu $s0,$zero,0x1 +/* f17a1b4: 00005025 */ or $t2,$zero,$zero +/* f17a1b8: 19a0003e */ blez $t5,.NB0f17a2b4 +/* f17a1bc: 0002c8c0 */ sll $t9,$v0,0x3 +/* f17a1c0: 0322c823 */ subu $t9,$t9,$v0 +/* f17a1c4: 0019c8c0 */ sll $t9,$t9,0x3 +/* f17a1c8: 0322c823 */ subu $t9,$t9,$v0 +/* f17a1cc: 0019c900 */ sll $t9,$t9,0x4 +/* f17a1d0: 0322c823 */ subu $t9,$t9,$v0 +/* f17a1d4: 0019c880 */ sll $t9,$t9,0x2 +/* f17a1d8: 032f6021 */ addu $t4,$t9,$t7 +/* f17a1dc: 01805825 */ or $t3,$t4,$zero +.NB0f17a1e0: +/* f17a1e0: 81620408 */ lb $v0,0x408($t3) +/* f17a1e4: 000a7080 */ sll $t6,$t2,0x2 +/* f17a1e8: 01ca7023 */ subu $t6,$t6,$t2 +/* f17a1ec: 1840002d */ blez $v0,.NB0f17a2a4 +/* f17a1f0: 00002025 */ or $a0,$zero,$zero +/* f17a1f4: 000e70c0 */ sll $t6,$t6,0x3 +/* f17a1f8: 018e2821 */ addu $a1,$t4,$t6 +/* f17a1fc: 00023080 */ sll $a2,$v0,0x2 +.NB0f17a200: +/* f17a200: 8ca303f4 */ lw $v1,0x3f4($a1) +/* f17a204: 24840004 */ addiu $a0,$a0,0x4 +/* f17a208: 0086082a */ slt $at,$a0,$a2 +/* f17a20c: 10600023 */ beqz $v1,.NB0f17a29c +/* f17a210: 00000000 */ sll $zero,$zero,0x0 +/* f17a214: 8c620000 */ lw $v0,0x0($v1) +/* f17a218: 14510002 */ bne $v0,$s1,.NB0f17a224 +/* f17a21c: 00000000 */ sll $zero,$zero,0x0 +/* f17a220: 00008025 */ or $s0,$zero,$zero +.NB0f17a224: +/* f17a224: 14520002 */ bne $v0,$s2,.NB0f17a230 +/* f17a228: 00000000 */ sll $zero,$zero,0x0 +/* f17a22c: 00008025 */ or $s0,$zero,$zero +.NB0f17a230: +/* f17a230: 14530002 */ bne $v0,$s3,.NB0f17a23c +/* f17a234: 00000000 */ sll $zero,$zero,0x0 +/* f17a238: 00008025 */ or $s0,$zero,$zero +.NB0f17a23c: +/* f17a23c: 14540002 */ bne $v0,$s4,.NB0f17a248 +/* f17a240: 00000000 */ sll $zero,$zero,0x0 +/* f17a244: 00008025 */ or $s0,$zero,$zero +.NB0f17a248: +/* f17a248: 14550002 */ bne $v0,$s5,.NB0f17a254 +/* f17a24c: 00000000 */ sll $zero,$zero,0x0 +/* f17a250: 00008025 */ or $s0,$zero,$zero +.NB0f17a254: +/* f17a254: 14560002 */ bne $v0,$s6,.NB0f17a260 +/* f17a258: 00000000 */ sll $zero,$zero,0x0 +/* f17a25c: 00008025 */ or $s0,$zero,$zero +.NB0f17a260: +/* f17a260: 14570002 */ bne $v0,$s7,.NB0f17a26c +/* f17a264: 00000000 */ sll $zero,$zero,0x0 +/* f17a268: 00008025 */ or $s0,$zero,$zero +.NB0f17a26c: +/* f17a26c: 145e0002 */ bne $v0,$s8,.NB0f17a278 +/* f17a270: 00000000 */ sll $zero,$zero,0x0 +/* f17a274: 00008025 */ or $s0,$zero,$zero +.NB0f17a278: +/* f17a278: 14470002 */ bne $v0,$a3,.NB0f17a284 +/* f17a27c: 00000000 */ sll $zero,$zero,0x0 +/* f17a280: 00008025 */ or $s0,$zero,$zero +.NB0f17a284: +/* f17a284: 14480002 */ bne $v0,$t0,.NB0f17a290 +/* f17a288: 00000000 */ sll $zero,$zero,0x0 +/* f17a28c: 00008025 */ or $s0,$zero,$zero +.NB0f17a290: +/* f17a290: 14490002 */ bne $v0,$t1,.NB0f17a29c +/* f17a294: 00000000 */ sll $zero,$zero,0x0 +/* f17a298: 00008025 */ or $s0,$zero,$zero +.NB0f17a29c: +/* f17a29c: 1420ffd8 */ bnez $at,.NB0f17a200 +/* f17a2a0: 24a50004 */ addiu $a1,$a1,0x4 +.NB0f17a2a4: +/* f17a2a4: 254a0001 */ addiu $t2,$t2,0x1 +/* f17a2a8: 014d082a */ slt $at,$t2,$t5 +/* f17a2ac: 1420ffcc */ bnez $at,.NB0f17a1e0 +/* f17a2b0: 256b0018 */ addiu $t3,$t3,0x18 +.NB0f17a2b4: +/* f17a2b4: 1600000b */ bnez $s0,.NB0f17a2e4 +/* f17a2b8: 00000000 */ sll $zero,$zero,0x0 +/* f17a2bc: 0fc3c088 */ jal menuPopDialog +/* f17a2c0: 00000000 */ sll $zero,$zero,0x0 +/* f17a2c4: 3c078009 */ lui $a3,0x8009 +/* f17a2c8: 3c088009 */ lui $t0,0x8009 +/* f17a2cc: 3c098009 */ lui $t1,0x8009 +/* f17a2d0: 3c1f8007 */ lui $ra,0x8007 +/* f17a2d4: 27ff3af0 */ addiu $ra,$ra,0x3af0 +/* f17a2d8: 25299700 */ addiu $t1,$t1,-26880 +/* f17a2dc: 2508957c */ addiu $t0,$t0,-27268 +/* f17a2e0: 24e79460 */ addiu $a3,$a3,-27552 +.NB0f17a2e4: +/* f17a2e4: 5200ffa7 */ beqzl $s0,.NB0f17a184 +/* f17a2e8: 8fe20000 */ lw $v0,0x0($ra) +/* f17a2ec: 8fa20044 */ lw $v0,0x44($sp) +/* f17a2f0: 24420001 */ addiu $v0,$v0,0x1 +.NB0f17a2f4: +/* f17a2f4: 24010004 */ addiu $at,$zero,0x4 +/* f17a2f8: 5441ff94 */ bnel $v0,$at,.NB0f17a14c +/* f17a2fc: 0002c0c0 */ sll $t8,$v0,0x3 +/* f17a300: 8fb80040 */ lw $t8,0x40($sp) +/* f17a304: 8fb00018 */ lw $s0,0x18($sp) +/* f17a308: 8fb1001c */ lw $s1,0x1c($sp) +/* f17a30c: aff80000 */ sw $t8,0x0($ra) +/* f17a310: 8fbf003c */ lw $ra,0x3c($sp) +/* f17a314: 8fb20020 */ lw $s2,0x20($sp) +/* f17a318: 8fb30024 */ lw $s3,0x24($sp) +/* f17a31c: 8fb40028 */ lw $s4,0x28($sp) +/* f17a320: 8fb5002c */ lw $s5,0x2c($sp) +/* f17a324: 8fb60030 */ lw $s6,0x30($sp) +/* f17a328: 8fb70034 */ lw $s7,0x34($sp) +/* f17a32c: 8fbe0038 */ lw $s8,0x38($sp) +/* f17a330: 03e00008 */ jr $ra +/* f17a334: 27bd0048 */ addiu $sp,$sp,0x48 +); +#endif struct menudialog g_MpAbortMenuDialog; diff --git a/src/game/music.c b/src/game/music.c index ba5fa89ee..2fbe4b234 100644 --- a/src/game/music.c +++ b/src/game/music.c @@ -286,6 +286,7 @@ void musicStartPrimary(f32 arg0) #define AMBIENTTRACK() (g_TemporaryAmbientTrack != -1 ? g_TemporaryAmbientTrack : stageGetAmbientTrack(g_MusicStageNum)) +#if VERSION >= VERSION_NTSC_1_0 void musicStartAmbient(f32 arg0) { s32 pass = false; @@ -312,6 +313,110 @@ void musicStartAmbient(f32 arg0) } } } +#else +GLOBAL_ASM( +glabel musicStartAmbient +/* f16821c: 3c028008 */ lui $v0,0x8008 +/* f168220: 8c42694c */ lw $v0,0x694c($v0) +/* f168224: 27bdffe0 */ addiu $sp,$sp,-32 +/* f168228: 2401ffff */ addiu $at,$zero,-1 +/* f16822c: afbf0014 */ sw $ra,0x14($sp) +/* f168230: e7ac0020 */ swc1 $f12,0x20($sp) +/* f168234: 10410003 */ beq $v0,$at,.NB0f168244 +/* f168238: 00002825 */ or $a1,$zero,$zero +/* f16823c: 10000007 */ beqz $zero,.NB0f16825c +/* f168240: 00401825 */ or $v1,$v0,$zero +.NB0f168244: +/* f168244: 3c04800b */ lui $a0,0x800b +/* f168248: 8c84ee80 */ lw $a0,-0x1180($a0) +/* f16824c: 0fc5c65e */ jal stageGetAmbientTrack +/* f168250: afa5001c */ sw $a1,0x1c($sp) +/* f168254: 8fa5001c */ lw $a1,0x1c($sp) +/* f168258: 00401825 */ or $v1,$v0,$zero +.NB0f16825c: +/* f16825c: 0460002c */ bltz $v1,.NB0f168310 +/* f168260: 3c0e8008 */ lui $t6,0x8008 +/* f168264: 8dce694c */ lw $t6,0x694c($t6) +/* f168268: 2401ffff */ addiu $at,$zero,-1 +/* f16826c: 11c10003 */ beq $t6,$at,.NB0f16827c +/* f168270: 00000000 */ sll $zero,$zero,0x0 +/* f168274: 10000026 */ beqz $zero,.NB0f168310 +/* f168278: 24050001 */ addiu $a1,$zero,0x1 +.NB0f16827c: +/* f16827c: 0fc5a0df */ jal musicIsAnyPlayerInAmbientRoom +/* f168280: afa5001c */ sw $a1,0x1c($sp) +/* f168284: 10400022 */ beqz $v0,.NB0f168310 +/* f168288: 8fa5001c */ lw $a1,0x1c($sp) +/* f16828c: 3c0f800a */ lui $t7,0x800a +/* f168290: 8defe96c */ lw $t7,-0x1694($t7) +/* f168294: 24010006 */ addiu $at,$zero,0x6 +/* f168298: 3c028008 */ lui $v0,0x8008 +/* f16829c: 51e1001c */ beql $t7,$at,.NB0f168310 +/* f1682a0: 24050001 */ addiu $a1,$zero,0x1 +/* f1682a4: 8c42694c */ lw $v0,0x694c($v0) +/* f1682a8: 2401ffff */ addiu $at,$zero,-1 +/* f1682ac: 3c04800b */ lui $a0,0x800b +/* f1682b0: 10410003 */ beq $v0,$at,.NB0f1682c0 +/* f1682b4: 00000000 */ sll $zero,$zero,0x0 +/* f1682b8: 10000004 */ beqz $zero,.NB0f1682cc +/* f1682bc: 00401825 */ or $v1,$v0,$zero +.NB0f1682c0: +/* f1682c0: 0fc5c65e */ jal stageGetAmbientTrack +/* f1682c4: 8c84ee80 */ lw $a0,-0x1180($a0) +/* f1682c8: 00401825 */ or $v1,$v0,$zero +.NB0f1682cc: +/* f1682cc: 3c04800b */ lui $a0,0x800b +/* f1682d0: 8c84ee80 */ lw $a0,-0x1180($a0) +/* f1682d4: 0fc5c65e */ jal stageGetAmbientTrack +/* f1682d8: afa30018 */ sw $v1,0x18($sp) +/* f1682dc: 8fa30018 */ lw $v1,0x18($sp) +/* f1682e0: 5043000b */ beql $v0,$v1,.NB0f168310 +/* f1682e4: 24050001 */ addiu $a1,$zero,0x1 +/* f1682e8: 0fc59fed */ jal musicEnd +/* f1682ec: 24040005 */ addiu $a0,$zero,0x5 +/* f1682f0: 3c04800b */ lui $a0,0x800b +/* f1682f4: 0fc5c65e */ jal stageGetAmbientTrack +/* f1682f8: 8c84ee80 */ lw $a0,-0x1180($a0) +/* f1682fc: 0fc5a2f1 */ jal musicStartTemporary +/* f168300: 00402025 */ or $a0,$v0,$zero +/* f168304: 1000001a */ beqz $zero,.NB0f168370 +/* f168308: 8fbf0014 */ lw $ra,0x14($sp) +/* f16830c: 24050001 */ addiu $a1,$zero,0x1 +.NB0f168310: +/* f168310: 50a00017 */ beqzl $a1,.NB0f168370 +/* f168314: 8fbf0014 */ lw $ra,0x14($sp) +/* f168318: 0fc59fa6 */ jal func0f16d124 +/* f16831c: 24040005 */ addiu $a0,$zero,0x5 +/* f168320: 10400002 */ beqz $v0,.NB0f16832c +/* f168324: 24010002 */ addiu $at,$zero,0x2 +/* f168328: 14410010 */ bne $v0,$at,.NB0f16836c +.NB0f16832c: +/* f16832c: 3c028008 */ lui $v0,0x8008 +/* f168330: 8c42694c */ lw $v0,0x694c($v0) +/* f168334: 2401ffff */ addiu $at,$zero,-1 +/* f168338: 3c04800b */ lui $a0,0x800b +/* f16833c: 10410003 */ beq $v0,$at,.NB0f16834c +/* f168340: 00000000 */ sll $zero,$zero,0x0 +/* f168344: 10000004 */ beqz $zero,.NB0f168358 +/* f168348: 00402825 */ or $a1,$v0,$zero +.NB0f16834c: +/* f16834c: 0fc5c65e */ jal stageGetAmbientTrack +/* f168350: 8c84ee80 */ lw $a0,-0x1180($a0) +/* f168354: 00402825 */ or $a1,$v0,$zero +.NB0f168358: +/* f168358: 3c078006 */ lui $a3,0x8006 +/* f16835c: 94e7f6e8 */ lhu $a3,-0x918($a3) +/* f168360: 24040005 */ addiu $a0,$zero,0x5 +/* f168364: 0fc59fcc */ jal musicStart +/* f168368: 8fa60020 */ lw $a2,0x20($sp) +.NB0f16836c: +/* f16836c: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f168370: +/* f168370: 27bd0020 */ addiu $sp,$sp,0x20 +/* f168374: 03e00008 */ jr $ra +/* f168378: 00000000 */ sll $zero,$zero,0x0 +); +#endif bool musicIsAnyPlayerInAmbientRoom(void) { diff --git a/src/game/objectives/objectives.c b/src/game/objectives/objectives.c index 741e01e84..afa1a7e2c 100644 --- a/src/game/objectives/objectives.c +++ b/src/game/objectives/objectives.c @@ -409,13 +409,13 @@ void objectivesCheckAll(void) #else if (status == OBJECTIVE_COMPLETE) { strcat(buffer, langGet(L_MISC_045)); // "Completed" - hudmsgCreateWithFlags(buffer, HUDMSGTYPE_OBJECTIVECOMPLETE, HUDMSGFLAG_DELAY | HUDMSGFLAG_ALLOWDUPES); + hudmsgCreateWithFlags(buffer, HUDMSGTYPE_OBJECTIVECOMPLETE, HUDMSGFLAG_ALLOWDUPES); } else if (status == OBJECTIVE_INCOMPLETE) { strcat(buffer, langGet(L_MISC_046)); // "Incomplete" - hudmsgCreateWithFlags(buffer, HUDMSGTYPE_OBJECTIVECOMPLETE, HUDMSGFLAG_DELAY | HUDMSGFLAG_ALLOWDUPES); + hudmsgCreateWithFlags(buffer, HUDMSGTYPE_OBJECTIVECOMPLETE, HUDMSGFLAG_ALLOWDUPES); } else if (status == OBJECTIVE_FAILED) { strcat(buffer, langGet(L_MISC_047)); // "Failed" - hudmsgCreateWithFlags(buffer, HUDMSGTYPE_OBJECTIVEFAILED, HUDMSGFLAG_DELAY | HUDMSGFLAG_ALLOWDUPES); + hudmsgCreateWithFlags(buffer, HUDMSGTYPE_OBJECTIVEFAILED, HUDMSGFLAG_ALLOWDUPES); } #endif } diff --git a/src/game/pak/pak.c b/src/game/pak/pak.c index 6d1ce5d61..3ada51222 100644 --- a/src/game/pak/pak.c +++ b/src/game/pak/pak.c @@ -149,18 +149,18 @@ #define LINE_4394 4199 #define LINE_4801 4606 #else -#define LINE_825 822 +#define LINE_825 742 #define LINE_1058 994 -#define LINE_1551 1551 -#define LINE_1802 1788 +#define LINE_1551 1461 +#define LINE_1802 1698 #define LINE_3486 3133 #define LINE_3495 3142 #define LINE_3599 3246 #define LINE_3829 3829 #define LINE_3865 3865 #define LINE_3889 3889 -#define LINE_3948 3753 -#define LINE_4140 3799 +#define LINE_3948 3573 +#define LINE_4140 3779 #define LINE_4394 4029 #define LINE_4801 4436 #endif @@ -182,7 +182,11 @@ const char var7f1b3ad4[] = "Pak %d -> Pak_UpdateAndGetPakNoteInfo - ERROR - ekPa const char var7f1b3b18[] = "Pak %d -> Pak_UpdateAndGetPakNoteInfo - ERROR - ekPakErrorNoPakPresent\n"; struct pak g_Paks[5]; + +#if VERSION >= VERSION_NTSC_1_0 u32 var800a317c; +#endif + OSPfs g_Pfses[4]; u32 var800a3320; u32 var800a3324; @@ -274,6 +278,10 @@ u8 var80075d10 = 0; u32 var80075d14 = 0x00000001; #endif +#if VERSION < VERSION_NTSC_1_0 +u8 var800a7880nb[0xe0]; +#endif + u32 pakGetBlockSize(s8 device) { return device == SAVEDEVICE_GAMEPAK ? 0x10 : 0x20; @@ -540,9 +548,9 @@ s32 _pakDeleteGameNote(s8 device, u16 company_code, u32 game_code, char *game_na s32 result; if (pak0f116b5c(device)) { - joyDisableCyclicPolling(JOYARGS(123)); + joyDisableCyclicPolling(JOYARGS(738)); result = pakDeleteGameNote3(PFS(device), company_code, game_code, game_name, ext_name); - joyEnableCyclicPolling(JOYARGS(123)); + joyEnableCyclicPolling(JOYARGS(740)); if (pakHandleResult(result, device, true, LINE_825)) { g_Paks[device].unk2b8_02 = 1; @@ -1093,6 +1101,7 @@ PakErr1 _pakReadWriteBlock(OSPfs *pfs, s32 file_no, u8 flag, u32 address, u32 le if (newaddress >= 256) { #if VERSION < VERSION_NTSC_1_0 + u32 stack; func0000c1d0nb("ILLEGAL EEPROM ADDRESS (>=256)"); *(u8 *)0 = 69; #endif @@ -6556,33 +6565,6 @@ const char var7f1b45e4[] = "-forceversion"; const char var7f1ae60cnb[] = "pak.c"; const char var7f1ae614nb[] = "pak.c"; const char var7f1ae61cnb[] = "pak.c"; -const char var7f1ae624nb[] = "pak.c"; -const char var7f1ae62cnb[] = "pak.c"; -#endif - -const char var7f1b45f4[] = "PakMac_PaksLive()=%x\n"; - -#if VERSION >= VERSION_NTSC_1_0 -const char var7f1b460c[] = "paksNeedToBeLive4Game=%x\n"; -const char var7f1b4628[] = "paksNeedToBeLive4Menu=%x\n"; -#endif - -const char var7f1b4644[] = "g_LastPackPattern=%x\n"; - -#if VERSION < VERSION_NTSC_1_0 -const char var7f1ae664nb[] = "lvGetPause = %s"; -const char var7f1ae678nb[] = "TRUE"; -const char var7f1ae680nb[] = "FALSE"; -const char var7f1ae688nb[] = "MP_GetPause = %s"; -const char var7f1ae69cnb[] = "TRUE"; -const char var7f1ae6a4nb[] = "FALSE"; -const char var7f1ae6acnb[] = "getnumplayers = %d"; -const char var7f1ae6c0nb[] = "forcecrc"; -const char var7f1ae6ccnb[] = "forcescrub"; -const char var7f1ae6d8nb[] = "dumph"; -const char var7f1ae6e0nb[] = "pakcache"; -const char var7f1ae6ecnb[] = "pakinit"; -const char var7f1ae6f4nb[] = "dumpeeprom"; #endif bool pakRepair(s8 device) @@ -6618,6 +6600,33 @@ bool pakRepair(s8 device) return false; } +const char var7f1b45f4[] = "PakMac_PaksLive()=%x\n"; + +#if VERSION >= VERSION_NTSC_1_0 +const char var7f1b460c[] = "paksNeedToBeLive4Game=%x\n"; +const char var7f1b4628[] = "paksNeedToBeLive4Menu=%x\n"; +#endif + +const char var7f1b4644[] = "g_LastPackPattern=%x\n"; + +#if VERSION < VERSION_NTSC_1_0 +const char var7f1ae664nb[] = "lvGetPause = %s"; +const char var7f1ae678nb[] = "TRUE"; +const char var7f1ae680nb[] = "FALSE"; +const char var7f1ae688nb[] = "MP_GetPause = %s"; +const char var7f1ae69cnb[] = "TRUE"; +const char var7f1ae6a4nb[] = "FALSE"; +const char var7f1ae6acnb[] = "getnumplayers = %d"; +const char var7f1ae6c0nb[] = "forcecrc"; +const char var7f1ae6ccnb[] = "forcescrub"; +const char var7f1ae6d8nb[] = "dumph"; +const char var7f1ae6e0nb[] = "pakcache"; +const char var7f1ae6ecnb[] = "pakinit"; +const char var7f1ae6f4nb[] = "dumpeeprom"; +const char var7f1ae700nb[] = "pak.c"; +const char var7f1ae708nb[] = "pak.c"; +#endif + #if VERSION >= VERSION_NTSC_1_0 bool pakHandleResult(s32 err1, s8 device, bool arg2, u32 line) { @@ -7838,14 +7847,18 @@ void pak0f11d620(s8 device) } } +#if VERSION >= VERSION_NTSC_1_0 void pak0f11d678(void) { // empty } +#endif #if VERSION < VERSION_NTSC_1_0 GLOBAL_ASM( -glabel pak7f1172d0nb +glabel pak7f1172c8nb +/* f1172c8: 00047600 */ sll $t6,$a0,0x18 +/* f1172cc: 000e7e03 */ sra $t7,$t6,0x18 /* f1172d0: 000fc080 */ sll $t8,$t7,0x2 /* f1172d4: 030fc023 */ subu $t8,$t8,$t7 /* f1172d8: 0018c080 */ sll $t8,$t8,0x2 @@ -8370,11 +8383,9 @@ void pakRumble(s32 device, f32 numsecs, s32 onduration, s32 offduration) } } #else -u8 var80009eb9cnb[5]; - void pakRumble(s8 device, f32 numsecs, s32 onduration, s32 offduration) { - u8 index = var80009eb9cnb[device]; + u8 index = g_Vars.playertojoymap[device]; if (g_Paks[index].unk010 == PAK010_11 && g_Paks[index].type == PAKTYPE_RUMBLE @@ -9483,7 +9494,7 @@ glabel pak7f117f94nb /* f118188: 1443fffc */ bne $v0,$v1,.NB0f11817c /* f11818c: a1200000 */ sb $zero,0x0($t1) /* f118190: 8cc50270 */ lw $a1,0x270($a2) -/* f118194: 0fc45cb2 */ jal pak0f11d678 +/* f118194: 0fc45cb2 */ jal pak7f1172c8nb /* f118198: afa60018 */ sw $a2,0x18($sp) /* f11819c: 8fa60018 */ lw $a2,0x18($sp) /* f1181a0: 24030009 */ addiu $v1,$zero,0x9 diff --git a/src/game/prop.c b/src/game/prop.c index 986c091a7..c547d2df2 100644 --- a/src/game/prop.c +++ b/src/game/prop.c @@ -41,10 +41,13 @@ s16 *g_RoomPropListChunkIndexes; struct roomproplistchunk *g_RoomPropListChunks; struct prop *g_InteractProp; u32 var8009cdac; + +#if VERSION >= VERSION_NTSC_1_0 u32 var8009cdb0; u32 var8009cdb4; u32 var8009cdb8; u32 var8009cdbc; +#endif f32 var80069880 = 1; diff --git a/src/game/propobj.c b/src/game/propobj.c index c9ec7d680..bae68672f 100644 --- a/src/game/propobj.c +++ b/src/game/propobj.c @@ -6478,7 +6478,7 @@ glabel func0f06b488 /* f06b608: 03e00008 */ jr $ra /* f06b60c: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f06b488 /* f06b488: 27bdffb8 */ addiu $sp,$sp,-72 @@ -6585,6 +6585,113 @@ glabel func0f06b488 /* f06b608: 03e00008 */ jr $ra /* f06b60c: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f06b488 +/* f06b488: 27bdffb8 */ addiu $sp,$sp,-72 +/* f06b48c: afa40048 */ sw $a0,0x48($sp) +/* f06b490: afa5004c */ sw $a1,0x4c($sp) +/* f06b494: 00a02025 */ or $a0,$a1,$zero +/* f06b498: afbf001c */ sw $ra,0x1c($sp) +/* f06b49c: afb00018 */ sw $s0,0x18($sp) +/* f06b4a0: afa60050 */ sw $a2,0x50($sp) +/* f06b4a4: 00c02825 */ or $a1,$a2,$zero +/* f06b4a8: 00e08025 */ or $s0,$a3,$zero +/* f06b4ac: 0c00b7b6 */ jal cd0002ded8 +/* f06b4b0: 8fa60048 */ lw $a2,0x48($sp) +/* f06b4b4: 14400050 */ bnez $v0,.L0f06b5f8 +/* f06b4b8: 27a4003c */ addiu $a0,$sp,0x3c +/* f06b4bc: 3c077f1b */ lui $a3,%hi(var7f1a9f7c) +/* f06b4c0: 24e79f7c */ addiu $a3,$a3,%lo(var7f1a9f7c) +/* f06b4c4: 27a50030 */ addiu $a1,$sp,0x30 +/* f06b4c8: 0c009393 */ jal cd00024e4c +/* f06b4cc: 24060b5d */ addiu $a2,$zero,0xb52 +/* f06b4d0: 3c067f1b */ lui $a2,%hi(var7f1a9f88) +/* f06b4d4: 24c69f88 */ addiu $a2,$a2,%lo(var7f1a9f88) +/* f06b4d8: 27a40020 */ addiu $a0,$sp,0x20 +/* f06b4dc: 0c0093af */ jal cdGetPos +/* f06b4e0: 24050b5e */ addiu $a1,$zero,0xb53 +/* f06b4e4: 8fa2004c */ lw $v0,0x4c($sp) +/* f06b4e8: c7a40020 */ lwc1 $f4,0x20($sp) +/* f06b4ec: c60a0000 */ lwc1 $f10,0x0($s0) +/* f06b4f0: c4460000 */ lwc1 $f6,0x0($v0) +/* f06b4f4: c7b20024 */ lwc1 $f18,0x24($sp) +/* f06b4f8: 8fa30060 */ lw $v1,0x60($sp) +/* f06b4fc: 46062201 */ sub.s $f8,$f4,$f6 +/* f06b500: c4440004 */ lwc1 $f4,0x4($v0) +/* f06b504: 8fa4005c */ lw $a0,0x5c($sp) +/* f06b508: 460a4402 */ mul.s $f16,$f8,$f10 +/* f06b50c: 46049181 */ sub.s $f6,$f18,$f4 +/* f06b510: c6080004 */ lwc1 $f8,0x4($s0) +/* f06b514: c7a40028 */ lwc1 $f4,0x28($sp) +/* f06b518: 46083282 */ mul.s $f10,$f6,$f8 +/* f06b51c: c4460008 */ lwc1 $f6,0x8($v0) +/* f06b520: 8fa20058 */ lw $v0,0x58($sp) +/* f06b524: 46062201 */ sub.s $f8,$f4,$f6 +/* f06b528: c4640000 */ lwc1 $f4,0x0($v1) +/* f06b52c: 460a8480 */ add.s $f18,$f16,$f10 +/* f06b530: c6100008 */ lwc1 $f16,0x8($s0) +/* f06b534: 46088282 */ mul.s $f10,$f16,$f8 +/* f06b538: 46125000 */ add.s $f0,$f10,$f18 +/* f06b53c: 4604003c */ c.lt.s $f0,$f4 +/* f06b540: 00000000 */ nop +/* f06b544: 4502002d */ bc1fl .L0f06b5fc +/* f06b548: 00001025 */ or $v0,$zero,$zero +/* f06b54c: e4600000 */ swc1 $f0,0x0($v1) +/* f06b550: c7a60020 */ lwc1 $f6,0x20($sp) +/* f06b554: 44801000 */ mtc1 $zero,$f2 +/* f06b558: 24850004 */ addiu $a1,$a0,0x4 +/* f06b55c: e4460000 */ swc1 $f6,0x0($v0) +/* f06b560: c7b00024 */ lwc1 $f16,0x24($sp) +/* f06b564: e4500004 */ swc1 $f16,0x4($v0) +/* f06b568: c7a80028 */ lwc1 $f8,0x28($sp) +/* f06b56c: e4480008 */ swc1 $f8,0x8($v0) +/* f06b570: c60a0000 */ lwc1 $f10,0x0($s0) +/* f06b574: e4820004 */ swc1 $f2,0x4($a0) +/* f06b578: 46005487 */ neg.s $f18,$f10 +/* f06b57c: e4920000 */ swc1 $f18,0x0($a0) +/* f06b580: c4900000 */ lwc1 $f16,0x0($a0) +/* f06b584: c6040008 */ lwc1 $f4,0x8($s0) +/* f06b588: 46101032 */ c.eq.s $f2,$f16 +/* f06b58c: 46002187 */ neg.s $f6,$f4 +/* f06b590: 45000007 */ bc1f .L0f06b5b0 +/* f06b594: e4860008 */ swc1 $f6,0x8($a0) +/* f06b598: c4880008 */ lwc1 $f8,0x8($a0) +/* f06b59c: 3c013f80 */ lui $at,0x3f80 +/* f06b5a0: 46081032 */ c.eq.s $f2,$f8 +/* f06b5a4: 00000000 */ nop +/* f06b5a8: 45030006 */ bc1tl .L0f06b5c4 +/* f06b5ac: 44815000 */ mtc1 $at,$f10 +.L0f06b5b0: +/* f06b5b0: 0c0011e4 */ jal guNormalize +/* f06b5b4: 24860008 */ addiu $a2,$a0,0x8 +/* f06b5b8: 10000005 */ b .L0f06b5d0 +/* f06b5bc: 8fae0048 */ lw $t6,0x48($sp) +/* f06b5c0: 44815000 */ mtc1 $at,$f10 +.L0f06b5c4: +/* f06b5c4: 00000000 */ nop +/* f06b5c8: e48a0008 */ swc1 $f10,0x8($a0) +/* f06b5cc: 8fae0048 */ lw $t6,0x48($sp) +.L0f06b5d0: +/* f06b5d0: 3c018007 */ lui $at,%hi(var80069930) +/* f06b5d4: 24020001 */ addiu $v0,$zero,0x1 +/* f06b5d8: ac2e9930 */ sw $t6,%lo(var80069930)($at) +/* f06b5dc: 3c018007 */ lui $at,%hi(var80069934) +/* f06b5e0: ac209934 */ sw $zero,%lo(var80069934)($at) +/* f06b5e4: 3c01800a */ lui $at,%hi(var8009ce70) +/* f06b5e8: ac20ce70 */ sw $zero,%lo(var8009ce70)($at) +/* f06b5ec: 3c01800a */ lui $at,%hi(var8009ce74) +/* f06b5f0: 10000002 */ b .L0f06b5fc +/* f06b5f4: ac20ce74 */ sw $zero,%lo(var8009ce74)($at) +.L0f06b5f8: +/* f06b5f8: 00001025 */ or $v0,$zero,$zero +.L0f06b5fc: +/* f06b5fc: 8fbf001c */ lw $ra,0x1c($sp) +/* f06b600: 8fb00018 */ lw $s0,0x18($sp) +/* f06b604: 27bd0048 */ addiu $sp,$sp,0x48 +/* f06b608: 03e00008 */ jr $ra +/* f06b60c: 00000000 */ nop +); #endif GLOBAL_ASM( @@ -8653,7 +8760,7 @@ glabel var7f1aa268 /* f06d374: 03e00008 */ jr $ra /* f06d378: 27bd0208 */ addiu $sp,$sp,0x208 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f06cd00 .late_rodata @@ -9100,6 +9207,453 @@ glabel var7f1aa268 /* f06d374: 03e00008 */ jr $ra /* f06d378: 27bd0208 */ addiu $sp,$sp,0x208 ); +#else +GLOBAL_ASM( +glabel func0f06cd00 +.late_rodata +glabel var7f1aa268 +.word 0x3dcccccd +.text +/* f06cd00: 27bdfdf8 */ addiu $sp,$sp,-520 +/* f06cd04: 3c02800a */ lui $v0,%hi(g_Vars) +/* f06cd08: 24429fc0 */ addiu $v0,$v0,%lo(g_Vars) +/* f06cd0c: 8c4f0318 */ lw $t7,0x318($v0) +/* f06cd10: afbf0074 */ sw $ra,0x74($sp) +/* f06cd14: afb70070 */ sw $s7,0x70($sp) +/* f06cd18: afb6006c */ sw $s6,0x6c($sp) +/* f06cd1c: afb50068 */ sw $s5,0x68($sp) +/* f06cd20: afb40064 */ sw $s4,0x64($sp) +/* f06cd24: afb30060 */ sw $s3,0x60($sp) +/* f06cd28: afb2005c */ sw $s2,0x5c($sp) +/* f06cd2c: afb10058 */ sw $s1,0x58($sp) +/* f06cd30: afb00054 */ sw $s0,0x54($sp) +/* f06cd34: f7b60048 */ sdc1 $f22,0x48($sp) +/* f06cd38: f7b40040 */ sdc1 $f20,0x40($sp) +/* f06cd3c: afa60210 */ sw $a2,0x210($sp) +/* f06cd40: 8c920014 */ lw $s2,0x14($a0) +/* f06cd44: 240e0001 */ addiu $t6,$zero,0x1 +/* f06cd48: 00a08025 */ or $s0,$a1,$zero +/* f06cd4c: 00e0a025 */ or $s4,$a3,$zero +/* f06cd50: 0080b825 */ or $s7,$a0,$zero +/* f06cd54: 11e00003 */ beqz $t7,.L0f06cd64 +/* f06cd58: afae0200 */ sw $t6,0x200($sp) +/* f06cd5c: 24180001 */ addiu $t8,$zero,0x1 +/* f06cd60: ac58048c */ sw $t8,0x48c($v0) +.L0f06cd64: +/* f06cd64: 3c018007 */ lui $at,%hi(var80069930) +/* f06cd68: ac209930 */ sw $zero,%lo(var80069930)($at) +/* f06cd6c: 3c018007 */ lui $at,%hi(var80069944) +/* f06cd70: ac209944 */ sw $zero,%lo(var80069944)($at) +/* f06cd74: c6040000 */ lwc1 $f4,0x0($s0) +/* f06cd78: e7a401c4 */ swc1 $f4,0x1c4($sp) +/* f06cd7c: c6060004 */ lwc1 $f6,0x4($s0) +/* f06cd80: e7a601c8 */ swc1 $f6,0x1c8($sp) +/* f06cd84: c6080008 */ lwc1 $f8,0x8($s0) +/* f06cd88: e7a801cc */ swc1 $f8,0x1cc($sp) +/* f06cd8c: c6500008 */ lwc1 $f16,0x8($s2) +/* f06cd90: c60a0000 */ lwc1 $f10,0x0($s0) +/* f06cd94: 46105032 */ c.eq.s $f10,$f16 +/* f06cd98: 00000000 */ nop +/* f06cd9c: 4502000e */ bc1fl .L0f06cdd8 +/* f06cda0: 8ef90040 */ lw $t9,0x40($s7) +/* f06cda4: c6120004 */ lwc1 $f18,0x4($s0) +/* f06cda8: c644000c */ lwc1 $f4,0xc($s2) +/* f06cdac: 46049032 */ c.eq.s $f18,$f4 +/* f06cdb0: 00000000 */ nop +/* f06cdb4: 45020008 */ bc1fl .L0f06cdd8 +/* f06cdb8: 8ef90040 */ lw $t9,0x40($s7) +/* f06cdbc: c6060008 */ lwc1 $f6,0x8($s0) +/* f06cdc0: c6480010 */ lwc1 $f8,0x10($s2) +/* f06cdc4: 46083032 */ c.eq.s $f6,$f8 +/* f06cdc8: 00000000 */ nop +/* f06cdcc: 45010157 */ bc1t .L0f06d32c +/* f06cdd0: 00000000 */ nop +/* f06cdd4: 8ef90040 */ lw $t9,0x40($s7) +.L0f06cdd8: +/* f06cdd8: 33280080 */ andi $t0,$t9,0x80 +/* f06cddc: 11000153 */ beqz $t0,.L0f06d32c +/* f06cde0: 00000000 */ nop +/* f06cde4: 8ee90048 */ lw $t1,0x48($s7) +/* f06cde8: 26550008 */ addiu $s5,$s2,0x8 +/* f06cdec: 02a02025 */ or $a0,$s5,$zero +/* f06cdf0: 8d2a0000 */ lw $t2,0x0($t1) +/* f06cdf4: 27a501c4 */ addiu $a1,$sp,0x1c4 +/* f06cdf8: 26460028 */ addiu $a2,$s2,0x28 +/* f06cdfc: 314b0004 */ andi $t3,$t2,0x4 +/* f06ce00: 1160014a */ beqz $t3,.L0f06d32c +/* f06ce04: 27a700b8 */ addiu $a3,$sp,0xb8 +/* f06ce08: 27ac00cc */ addiu $t4,$sp,0xcc +/* f06ce0c: 240d0014 */ addiu $t5,$zero,0x14 +/* f06ce10: afad0014 */ sw $t5,0x14($sp) +/* f06ce14: afac0010 */ sw $t4,0x10($sp) +/* f06ce18: 0c006052 */ jal func00018148 +/* f06ce1c: afb0020c */ sw $s0,0x20c($sp) +/* f06ce20: 87ae00cc */ lh $t6,0xcc($sp) +/* f06ce24: 2416ffff */ addiu $s6,$zero,-1 +/* f06ce28: 27a400cc */ addiu $a0,$sp,0xcc +/* f06ce2c: 12ce0005 */ beq $s6,$t6,.L0f06ce44 +/* f06ce30: 00000000 */ nop +/* f06ce34: 848f0002 */ lh $t7,0x2($a0) +.L0f06ce38: +/* f06ce38: 24840002 */ addiu $a0,$a0,0x2 +/* f06ce3c: 56cffffe */ bnel $s6,$t7,.L0f06ce38 +/* f06ce40: 848f0002 */ lh $t7,0x2($a0) +.L0f06ce44: +/* f06ce44: 0fc5914d */ jal roomsGetActive +/* f06ce48: 24050064 */ addiu $a1,$zero,0x64 +/* f06ce4c: 87b800cc */ lh $t8,0xcc($sp) +/* f06ce50: 27b100cc */ addiu $s1,$sp,0xcc +/* f06ce54: 3c013f80 */ lui $at,0x3f80 +/* f06ce58: 12d800d1 */ beq $s6,$t8,.L0f06d1a0 +/* f06ce5c: 27b301d0 */ addiu $s3,$sp,0x1d0 +/* f06ce60: 4481b000 */ mtc1 $at,$f22 +/* f06ce64: 3c01bf80 */ lui $at,0xbf80 +/* f06ce68: 4481a000 */ mtc1 $at,$f20 +/* f06ce6c: 86240000 */ lh $a0,0x0($s1) +.L0f06ce70: +/* f06ce70: 0fc586ad */ jal func0f161ab4 +/* f06ce74: 00008025 */ or $s0,$zero,$zero +/* f06ce78: 10400045 */ beqz $v0,.L0f06cf90 +/* f06ce7c: 02a02025 */ or $a0,$s5,$zero +/* f06ce80: 02a02025 */ or $a0,$s5,$zero +/* f06ce84: 27a501c4 */ addiu $a1,$sp,0x1c4 +/* f06ce88: 86260000 */ lh $a2,0x0($s1) +/* f06ce8c: 0fc58548 */ jal func0f161520 +/* f06ce90: 02603825 */ or $a3,$s3,$zero +/* f06ce94: 1040004e */ beqz $v0,.L0f06cfd0 +/* f06ce98: c7aa01d0 */ lwc1 $f10,0x1d0($sp) +/* f06ce9c: 46165402 */ mul.s $f16,$f10,$f22 +/* f06cea0: c7b201d4 */ lwc1 $f18,0x1d4($sp) +/* f06cea4: c7a601d8 */ lwc1 $f6,0x1d8($sp) +/* f06cea8: 87a801fa */ lh $t0,0x1fa($sp) +/* f06ceac: 46169102 */ mul.s $f4,$f18,$f22 +/* f06ceb0: 3c09800b */ lui $t1,%hi(g_Textures) +/* f06ceb4: 8d29abc0 */ lw $t1,%lo(g_Textures)($t1) +/* f06ceb8: 46163202 */ mul.s $f8,$f6,$f22 +/* f06cebc: 3c018007 */ lui $at,%hi(var80069944) +/* f06cec0: 000850c0 */ sll $t2,$t0,0x3 +/* f06cec4: e7b001d0 */ swc1 $f16,0x1d0($sp) +/* f06cec8: e7a401d4 */ swc1 $f4,0x1d4($sp) +/* f06cecc: ac289944 */ sw $t0,%lo(var80069944)($at) +/* f06ced0: 012a5821 */ addu $t3,$t1,$t2 +/* f06ced4: e7a801d8 */ swc1 $f8,0x1d8($sp) +/* f06ced8: 916c0000 */ lbu $t4,0x0($t3) +/* f06cedc: 2401000e */ addiu $at,$zero,0xe +/* f06cee0: 24100001 */ addiu $s0,$zero,0x1 +/* f06cee4: 318d000f */ andi $t5,$t4,0xf +/* f06cee8: 15a10039 */ bne $t5,$at,.L0f06cfd0 +/* f06ceec: 3c0e8007 */ lui $t6,%hi(var800699e8) +/* f06cef0: 25ce99e8 */ addiu $t6,$t6,%lo(var800699e8) +/* f06cef4: 8dc10000 */ lw $at,0x0($t6) +/* f06cef8: 27a700a4 */ addiu $a3,$sp,0xa4 +/* f06cefc: 27b901dc */ addiu $t9,$sp,0x1dc +/* f06cf00: ace10000 */ sw $at,0x0($a3) +/* f06cf04: 8dd80004 */ lw $t8,0x4($t6) +/* f06cf08: 2408001a */ addiu $t0,$zero,0x1a +/* f06cf0c: 00008025 */ or $s0,$zero,$zero +/* f06cf10: acf80004 */ sw $t8,0x4($a3) +/* f06cf14: 8dc10008 */ lw $at,0x8($t6) +/* f06cf18: 02402825 */ or $a1,$s2,$zero +/* f06cf1c: 02603025 */ or $a2,$s3,$zero +/* f06cf20: ace10008 */ sw $at,0x8($a3) +/* f06cf24: 86440028 */ lh $a0,0x28($s2) +/* f06cf28: afa80014 */ sw $t0,0x14($sp) +/* f06cf2c: 0fc4be7c */ jal sparksCreate +/* f06cf30: afb90010 */ sw $t9,0x10($sp) +/* f06cf34: 00163c00 */ sll $a3,$s6,0x10 +/* f06cf38: 00074c03 */ sra $t1,$a3,0x10 +/* f06cf3c: 240a0400 */ addiu $t2,$zero,0x400 +/* f06cf40: afaa0014 */ sw $t2,0x14($sp) +/* f06cf44: 01203825 */ or $a3,$t1,$zero +/* f06cf48: 00002025 */ or $a0,$zero,$zero +/* f06cf4c: 02402825 */ or $a1,$s2,$zero +/* f06cf50: 24068080 */ addiu $a2,$zero,-32640 +/* f06cf54: afb60010 */ sw $s6,0x10($sp) +/* f06cf58: afa00018 */ sw $zero,0x18($sp) +/* f06cf5c: afa0001c */ sw $zero,0x1c($sp) +/* f06cf60: afa00020 */ sw $zero,0x20($sp) +/* f06cf64: e7b40024 */ swc1 $f20,0x24($sp) +/* f06cf68: afa00028 */ sw $zero,0x28($sp) +/* f06cf6c: afb6002c */ sw $s6,0x2c($sp) +/* f06cf70: e7b40030 */ swc1 $f20,0x30($sp) +/* f06cf74: e7b40034 */ swc1 $f20,0x34($sp) +/* f06cf78: 0fc24e7e */ jal func0f0939f8 +/* f06cf7c: e7b40038 */ swc1 $f20,0x38($sp) +/* f06cf80: 8eeb0040 */ lw $t3,0x40($s7) +/* f06cf84: 356c0004 */ ori $t4,$t3,0x4 +/* f06cf88: 10000011 */ b .L0f06cfd0 +/* f06cf8c: aeec0040 */ sw $t4,0x40($s7) +.L0f06cf90: +/* f06cf90: 862d0000 */ lh $t5,0x0($s1) +/* f06cf94: a7b600a2 */ sh $s6,0xa2($sp) +/* f06cf98: 27a500a0 */ addiu $a1,$sp,0xa0 +/* f06cf9c: 27a601c4 */ addiu $a2,$sp,0x1c4 +/* f06cfa0: 24070020 */ addiu $a3,$zero,0x20 +/* f06cfa4: 0c00b784 */ jal cd0002de10 +/* f06cfa8: a7ad00a0 */ sh $t5,0xa0($sp) +/* f06cfac: 14400008 */ bnez $v0,.L0f06cfd0 +/* f06cfb0: 02602025 */ or $a0,$s3,$zero +/* f06cfb4: 3c067f1b */ lui $a2,%hi(var7f1a9f94) +/* f06cfb8: 24100001 */ addiu $s0,$zero,0x1 +/* f06cfbc: 24c69f94 */ addiu $a2,$a2,%lo(var7f1a9f94) +/* f06cfc0: 0c0093af */ jal cdGetPos +/* f06cfc4: 240510a1 */ addiu $a1,$zero,0x1096 +/* f06cfc8: 0c0093ba */ jal cd00024ee8 +/* f06cfcc: 27a401dc */ addiu $a0,$sp,0x1dc +.L0f06cfd0: +/* f06cfd0: 1200006f */ beqz $s0,.L0f06d190 +/* f06cfd4: c7aa01c4 */ lwc1 $f10,0x1c4($sp) +/* f06cfd8: c64c0008 */ lwc1 $f12,0x8($s2) +/* f06cfdc: c7b001d0 */ lwc1 $f16,0x1d0($sp) +/* f06cfe0: c7b201c4 */ lwc1 $f18,0x1c4($sp) +/* f06cfe4: 460a603e */ c.le.s $f12,$f10 +/* f06cfe8: 00000000 */ nop +/* f06cfec: 4502000a */ bc1fl .L0f06d018 +/* f06cff0: 460c903e */ c.le.s $f18,$f12 +/* f06cff4: 460a803e */ c.le.s $f16,$f10 +/* f06cff8: 00000000 */ nop +/* f06cffc: 45020006 */ bc1fl .L0f06d018 +/* f06d000: 460c903e */ c.le.s $f18,$f12 +/* f06d004: 4610603e */ c.le.s $f12,$f16 +/* f06d008: 00000000 */ nop +/* f06d00c: 4503000e */ bc1tl .L0f06d048 +/* f06d010: c642000c */ lwc1 $f2,0xc($s2) +/* f06d014: 460c903e */ c.le.s $f18,$f12 +.L0f06d018: +/* f06d018: c7a401d0 */ lwc1 $f4,0x1d0($sp) +/* f06d01c: 4502005d */ bc1fl .L0f06d194 +/* f06d020: 86240002 */ lh $a0,0x2($s1) +/* f06d024: 4604903e */ c.le.s $f18,$f4 +/* f06d028: 00000000 */ nop +/* f06d02c: 45020059 */ bc1fl .L0f06d194 +/* f06d030: 86240002 */ lh $a0,0x2($s1) +/* f06d034: 460c203e */ c.le.s $f4,$f12 +/* f06d038: 00000000 */ nop +/* f06d03c: 45020055 */ bc1fl .L0f06d194 +/* f06d040: 86240002 */ lh $a0,0x2($s1) +/* f06d044: c642000c */ lwc1 $f2,0xc($s2) +.L0f06d048: +/* f06d048: c7a601c8 */ lwc1 $f6,0x1c8($sp) +/* f06d04c: c7a801d4 */ lwc1 $f8,0x1d4($sp) +/* f06d050: c7aa01c8 */ lwc1 $f10,0x1c8($sp) +/* f06d054: 4606103e */ c.le.s $f2,$f6 +/* f06d058: 00000000 */ nop +/* f06d05c: 4502000a */ bc1fl .L0f06d088 +/* f06d060: 4602503e */ c.le.s $f10,$f2 +/* f06d064: 4606403e */ c.le.s $f8,$f6 +/* f06d068: 00000000 */ nop +/* f06d06c: 45020006 */ bc1fl .L0f06d088 +/* f06d070: 4602503e */ c.le.s $f10,$f2 +/* f06d074: 4608103e */ c.le.s $f2,$f8 +/* f06d078: 00000000 */ nop +/* f06d07c: 4503000e */ bc1tl .L0f06d0b8 +/* f06d080: c6400010 */ lwc1 $f0,0x10($s2) +/* f06d084: 4602503e */ c.le.s $f10,$f2 +.L0f06d088: +/* f06d088: c7b001d4 */ lwc1 $f16,0x1d4($sp) +/* f06d08c: 45020041 */ bc1fl .L0f06d194 +/* f06d090: 86240002 */ lh $a0,0x2($s1) +/* f06d094: 4610503e */ c.le.s $f10,$f16 +/* f06d098: 00000000 */ nop +/* f06d09c: 4502003d */ bc1fl .L0f06d194 +/* f06d0a0: 86240002 */ lh $a0,0x2($s1) +/* f06d0a4: 4602803e */ c.le.s $f16,$f2 +/* f06d0a8: 00000000 */ nop +/* f06d0ac: 45020039 */ bc1fl .L0f06d194 +/* f06d0b0: 86240002 */ lh $a0,0x2($s1) +/* f06d0b4: c6400010 */ lwc1 $f0,0x10($s2) +.L0f06d0b8: +/* f06d0b8: c7b201cc */ lwc1 $f18,0x1cc($sp) +/* f06d0bc: c7a401d8 */ lwc1 $f4,0x1d8($sp) +/* f06d0c0: c7a601cc */ lwc1 $f6,0x1cc($sp) +/* f06d0c4: 4612003e */ c.le.s $f0,$f18 +/* f06d0c8: 00000000 */ nop +/* f06d0cc: 4502000a */ bc1fl .L0f06d0f8 +/* f06d0d0: 4600303e */ c.le.s $f6,$f0 +/* f06d0d4: 4612203e */ c.le.s $f4,$f18 +/* f06d0d8: 00000000 */ nop +/* f06d0dc: 45020006 */ bc1fl .L0f06d0f8 +/* f06d0e0: 4600303e */ c.le.s $f6,$f0 +/* f06d0e4: 4604003e */ c.le.s $f0,$f4 +/* f06d0e8: 00000000 */ nop +/* f06d0ec: 4503000e */ bc1tl .L0f06d128 +/* f06d0f0: c7aa01d0 */ lwc1 $f10,0x1d0($sp) +/* f06d0f4: 4600303e */ c.le.s $f6,$f0 +.L0f06d0f8: +/* f06d0f8: c7a801d8 */ lwc1 $f8,0x1d8($sp) +/* f06d0fc: 45020025 */ bc1fl .L0f06d194 +/* f06d100: 86240002 */ lh $a0,0x2($s1) +/* f06d104: 4608303e */ c.le.s $f6,$f8 +/* f06d108: 00000000 */ nop +/* f06d10c: 45020021 */ bc1fl .L0f06d194 +/* f06d110: 86240002 */ lh $a0,0x2($s1) +/* f06d114: 4600403e */ c.le.s $f8,$f0 +/* f06d118: 00000000 */ nop +/* f06d11c: 4502001d */ bc1fl .L0f06d194 +/* f06d120: 86240002 */ lh $a0,0x2($s1) +/* f06d124: c7aa01d0 */ lwc1 $f10,0x1d0($sp) +.L0f06d128: +/* f06d128: c7b001d4 */ lwc1 $f16,0x1d4($sp) +/* f06d12c: 460a6032 */ c.eq.s $f12,$f10 +/* f06d130: 00000000 */ nop +/* f06d134: 4502000a */ bc1fl .L0f06d160 +/* f06d138: c7a401d0 */ lwc1 $f4,0x1d0($sp) +/* f06d13c: 46101032 */ c.eq.s $f2,$f16 +/* f06d140: c7b201d8 */ lwc1 $f18,0x1d8($sp) +/* f06d144: 45020006 */ bc1fl .L0f06d160 +/* f06d148: c7a401d0 */ lwc1 $f4,0x1d0($sp) +/* f06d14c: 46120032 */ c.eq.s $f0,$f18 +/* f06d150: 00000000 */ nop +/* f06d154: 4503000f */ bc1tl .L0f06d194 +/* f06d158: 86240002 */ lh $a0,0x2($s1) +/* f06d15c: c7a401d0 */ lwc1 $f4,0x1d0($sp) +.L0f06d160: +/* f06d160: c7a601d4 */ lwc1 $f6,0x1d4($sp) +/* f06d164: c7a801d8 */ lwc1 $f8,0x1d8($sp) +/* f06d168: c7aa01dc */ lwc1 $f10,0x1dc($sp) +/* f06d16c: afa00200 */ sw $zero,0x200($sp) +/* f06d170: e7a401c4 */ swc1 $f4,0x1c4($sp) +/* f06d174: e7a601c8 */ swc1 $f6,0x1c8($sp) +/* f06d178: e7a801cc */ swc1 $f8,0x1cc($sp) +/* f06d17c: e68a0000 */ swc1 $f10,0x0($s4) +/* f06d180: c7b001e0 */ lwc1 $f16,0x1e0($sp) +/* f06d184: e6900004 */ swc1 $f16,0x4($s4) +/* f06d188: c7b201e4 */ lwc1 $f18,0x1e4($sp) +/* f06d18c: e6920008 */ swc1 $f18,0x8($s4) +.L0f06d190: +/* f06d190: 86240002 */ lh $a0,0x2($s1) +.L0f06d194: +/* f06d194: 26310002 */ addiu $s1,$s1,0x2 +/* f06d198: 16c4ff35 */ bne $s6,$a0,.L0f06ce70 +/* f06d19c: 00000000 */ nop +.L0f06d1a0: +/* f06d1a0: 8faf0210 */ lw $t7,0x210($sp) +/* f06d1a4: 3c013f80 */ lui $at,0x3f80 +/* f06d1a8: 4481b000 */ mtc1 $at,$f22 +/* f06d1ac: 27ae00cc */ addiu $t6,$sp,0xcc +/* f06d1b0: afae0018 */ sw $t6,0x18($sp) +/* f06d1b4: 02402025 */ or $a0,$s2,$zero +/* f06d1b8: 02a02825 */ or $a1,$s5,$zero +/* f06d1bc: 27a601c4 */ addiu $a2,$sp,0x1c4 +/* f06d1c0: 2407003f */ addiu $a3,$zero,0x3f +/* f06d1c4: afb40014 */ sw $s4,0x14($sp) +/* f06d1c8: 0fc1b22b */ jal func0f06c8ac +/* f06d1cc: afaf0010 */ sw $t7,0x10($sp) +/* f06d1d0: 1440000a */ bnez $v0,.L0f06d1fc +/* f06d1d4: 8fb80200 */ lw $t8,0x200($sp) +/* f06d1d8: 17000009 */ bnez $t8,.L0f06d200 +/* f06d1dc: c7a401c4 */ lwc1 $f4,0x1c4($sp) +/* f06d1e0: 8fb90210 */ lw $t9,0x210($sp) +/* f06d1e4: e7240000 */ swc1 $f4,0x0($t9) +/* f06d1e8: c7a601c8 */ lwc1 $f6,0x1c8($sp) +/* f06d1ec: e7260004 */ swc1 $f6,0x4($t9) +/* f06d1f0: c7a801cc */ lwc1 $f8,0x1cc($sp) +/* f06d1f4: 10000002 */ b .L0f06d200 +/* f06d1f8: e7280008 */ swc1 $f8,0x8($t9) +.L0f06d1fc: +/* f06d1fc: afa00200 */ sw $zero,0x200($sp) +.L0f06d200: +/* f06d200: 8fa80200 */ lw $t0,0x200($sp) +/* f06d204: 24010001 */ addiu $at,$zero,0x1 +/* f06d208: 8fa2020c */ lw $v0,0x20c($sp) +/* f06d20c: 11010047 */ beq $t0,$at,.L0f06d32c +/* f06d210: 00000000 */ nop +/* f06d214: c44a0000 */ lwc1 $f10,0x0($v0) +/* f06d218: c6500008 */ lwc1 $f16,0x8($s2) +/* f06d21c: 46105481 */ sub.s $f18,$f10,$f16 +/* f06d220: e7b20094 */ swc1 $f18,0x94($sp) +/* f06d224: c646000c */ lwc1 $f6,0xc($s2) +/* f06d228: c4440004 */ lwc1 $f4,0x4($v0) +/* f06d22c: 46062201 */ sub.s $f8,$f4,$f6 +/* f06d230: c7a40094 */ lwc1 $f4,0x94($sp) +/* f06d234: e7a80098 */ swc1 $f8,0x98($sp) +/* f06d238: c6500010 */ lwc1 $f16,0x10($s2) +/* f06d23c: c44a0008 */ lwc1 $f10,0x8($v0) +/* f06d240: 46042182 */ mul.s $f6,$f4,$f4 +/* f06d244: c7a80098 */ lwc1 $f8,0x98($sp) +/* f06d248: 46105481 */ sub.s $f18,$f10,$f16 +/* f06d24c: 46084282 */ mul.s $f10,$f8,$f8 +/* f06d250: e7b2009c */ swc1 $f18,0x9c($sp) +/* f06d254: c7b2009c */ lwc1 $f18,0x9c($sp) +/* f06d258: 46129102 */ mul.s $f4,$f18,$f18 +/* f06d25c: 460a3400 */ add.s $f16,$f6,$f10 +/* f06d260: 0c012974 */ jal sqrtf +/* f06d264: 46102300 */ add.s $f12,$f4,$f16 +/* f06d268: 3c017f1b */ lui $at,%hi(var7f1aa268) +/* f06d26c: c42ca268 */ lwc1 $f12,%lo(var7f1aa268)($at) +/* f06d270: 3c013f00 */ lui $at,0x3f00 +/* f06d274: c7a60094 */ lwc1 $f6,0x94($sp) +/* f06d278: 4600603c */ c.lt.s $f12,$f0 +/* f06d27c: 02802025 */ or $a0,$s4,$zero +/* f06d280: 26850004 */ addiu $a1,$s4,0x4 +/* f06d284: 45020004 */ bc1fl .L0f06d298 +/* f06d288: 44811000 */ mtc1 $at,$f2 +/* f06d28c: 10000003 */ b .L0f06d29c +/* f06d290: 46006083 */ div.s $f2,$f12,$f0 +/* f06d294: 44811000 */ mtc1 $at,$f2 +.L0f06d298: +/* f06d298: 00000000 */ nop +.L0f06d29c: +/* f06d29c: 46061282 */ mul.s $f10,$f2,$f6 +/* f06d2a0: 8fa20210 */ lw $v0,0x210($sp) +/* f06d2a4: 44800000 */ mtc1 $zero,$f0 +/* f06d2a8: c4480000 */ lwc1 $f8,0x0($v0) +/* f06d2ac: c4440004 */ lwc1 $f4,0x4($v0) +/* f06d2b0: 460a4481 */ sub.s $f18,$f8,$f10 +/* f06d2b4: c44a0008 */ lwc1 $f10,0x8($v0) +/* f06d2b8: e4520000 */ swc1 $f18,0x0($v0) +/* f06d2bc: c7b00098 */ lwc1 $f16,0x98($sp) +/* f06d2c0: 46101182 */ mul.s $f6,$f2,$f16 +/* f06d2c4: 46062201 */ sub.s $f8,$f4,$f6 +/* f06d2c8: e4480004 */ swc1 $f8,0x4($v0) +/* f06d2cc: c7b2009c */ lwc1 $f18,0x9c($sp) +/* f06d2d0: 46121402 */ mul.s $f16,$f2,$f18 +/* f06d2d4: 46105101 */ sub.s $f4,$f10,$f16 +/* f06d2d8: e4440008 */ swc1 $f4,0x8($v0) +/* f06d2dc: c6860000 */ lwc1 $f6,0x0($s4) +/* f06d2e0: 46060032 */ c.eq.s $f0,$f6 +/* f06d2e4: 00000000 */ nop +/* f06d2e8: 4500000b */ bc1f .L0f06d318 +/* f06d2ec: 00000000 */ nop +/* f06d2f0: c6880004 */ lwc1 $f8,0x4($s4) +/* f06d2f4: 46080032 */ c.eq.s $f0,$f8 +/* f06d2f8: 00000000 */ nop +/* f06d2fc: 45000006 */ bc1f .L0f06d318 +/* f06d300: 00000000 */ nop +/* f06d304: c6920008 */ lwc1 $f18,0x8($s4) +/* f06d308: 46120032 */ c.eq.s $f0,$f18 +/* f06d30c: 00000000 */ nop +/* f06d310: 45030006 */ bc1tl .L0f06d32c +/* f06d314: e6960008 */ swc1 $f22,0x8($s4) +.L0f06d318: +/* f06d318: 0c0011e4 */ jal guNormalize +/* f06d31c: 26860008 */ addiu $a2,$s4,0x8 +/* f06d320: 10000002 */ b .L0f06d32c +/* f06d324: 00000000 */ nop +/* f06d328: e6960008 */ swc1 $f22,0x8($s4) +.L0f06d32c: +/* f06d32c: 3c02800a */ lui $v0,%hi(g_Vars) +/* f06d330: 24429fc0 */ addiu $v0,$v0,%lo(g_Vars) +/* f06d334: 8c490318 */ lw $t1,0x318($v0) +/* f06d338: 51200003 */ beqzl $t1,.L0f06d348 +/* f06d33c: 8fbf0074 */ lw $ra,0x74($sp) +/* f06d340: ac40048c */ sw $zero,0x48c($v0) +/* f06d344: 8fbf0074 */ lw $ra,0x74($sp) +.L0f06d348: +/* f06d348: 8fa20200 */ lw $v0,0x200($sp) +/* f06d34c: d7b40040 */ ldc1 $f20,0x40($sp) +/* f06d350: d7b60048 */ ldc1 $f22,0x48($sp) +/* f06d354: 8fb00054 */ lw $s0,0x54($sp) +/* f06d358: 8fb10058 */ lw $s1,0x58($sp) +/* f06d35c: 8fb2005c */ lw $s2,0x5c($sp) +/* f06d360: 8fb30060 */ lw $s3,0x60($sp) +/* f06d364: 8fb40064 */ lw $s4,0x64($sp) +/* f06d368: 8fb50068 */ lw $s5,0x68($sp) +/* f06d36c: 8fb6006c */ lw $s6,0x6c($sp) +/* f06d370: 8fb70070 */ lw $s7,0x70($sp) +/* f06d374: 03e00008 */ jr $ra +/* f06d378: 27bd0208 */ addiu $sp,$sp,0x208 +); #endif #if VERSION >= VERSION_PAL_FINAL @@ -9493,7 +10047,7 @@ glabel var7f1aa26c /* f06d904: 03e00008 */ jr $ra /* f06d908: 27bd00a8 */ addiu $sp,$sp,0xa8 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f06d37c .late_rodata @@ -9884,6 +10438,397 @@ glabel var7f1aa26c /* f06d904: 03e00008 */ jr $ra /* f06d908: 27bd00a8 */ addiu $sp,$sp,0xa8 ); +#else +GLOBAL_ASM( +glabel func0f06d37c +.late_rodata +glabel var7f1aa26c +.word 0x3f7d70a4 +.text +/* f06d37c: 27bdff58 */ addiu $sp,$sp,-168 +/* f06d380: afbf0034 */ sw $ra,0x34($sp) +/* f06d384: afb10030 */ sw $s1,0x30($sp) +/* f06d388: afb0002c */ sw $s0,0x2c($sp) +/* f06d38c: afa700b4 */ sw $a3,0xb4($sp) +/* f06d390: 8c900014 */ lw $s0,0x14($a0) +/* f06d394: 00c08825 */ or $s1,$a2,$zero +/* f06d398: afa500ac */ sw $a1,0xac($sp) +/* f06d39c: 0fc1acdb */ jal func0f06b36c +/* f06d3a0: afa400a8 */ sw $a0,0xa8($sp) +/* f06d3a4: 3c018007 */ lui $at,%hi(var80069930) +/* f06d3a8: 8fa500ac */ lw $a1,0xac($sp) +/* f06d3ac: ac209930 */ sw $zero,%lo(var80069930)($at) +/* f06d3b0: 240e0001 */ addiu $t6,$zero,0x1 +/* f06d3b4: 3c018007 */ lui $at,%hi(var80069944) +/* f06d3b8: afae009c */ sw $t6,0x9c($sp) +/* f06d3bc: afa00098 */ sw $zero,0x98($sp) +/* f06d3c0: ac209944 */ sw $zero,%lo(var80069944)($at) +/* f06d3c4: c4a40000 */ lwc1 $f4,0x0($a1) +/* f06d3c8: 46000086 */ mov.s $f2,$f0 +/* f06d3cc: 8faf00a8 */ lw $t7,0xa8($sp) +/* f06d3d0: e7a40080 */ swc1 $f4,0x80($sp) +/* f06d3d4: c4a60004 */ lwc1 $f6,0x4($a1) +/* f06d3d8: e7a60084 */ swc1 $f6,0x84($sp) +/* f06d3dc: c4a80008 */ lwc1 $f8,0x8($a1) +/* f06d3e0: e7a80088 */ swc1 $f8,0x88($sp) +/* f06d3e4: c6100008 */ lwc1 $f16,0x8($s0) +/* f06d3e8: c4aa0000 */ lwc1 $f10,0x0($a1) +/* f06d3ec: 46105032 */ c.eq.s $f10,$f16 +/* f06d3f0: 00000000 */ nop +/* f06d3f4: 4502000e */ bc1fl .L0f06d430 +/* f06d3f8: 8df80040 */ lw $t8,0x40($t7) +/* f06d3fc: c4b20004 */ lwc1 $f18,0x4($a1) +/* f06d400: c604000c */ lwc1 $f4,0xc($s0) +/* f06d404: 46049032 */ c.eq.s $f18,$f4 +/* f06d408: 00000000 */ nop +/* f06d40c: 45020008 */ bc1fl .L0f06d430 +/* f06d410: 8df80040 */ lw $t8,0x40($t7) +/* f06d414: c4a60008 */ lwc1 $f6,0x8($a1) +/* f06d418: c6080010 */ lwc1 $f8,0x10($s0) +/* f06d41c: 46083032 */ c.eq.s $f6,$f8 +/* f06d420: 00000000 */ nop +/* f06d424: 45030134 */ bc1tl .L0f06d8f8 +/* f06d428: 8fbf0034 */ lw $ra,0x34($sp) +/* f06d42c: 8df80040 */ lw $t8,0x40($t7) +.L0f06d430: +/* f06d430: 26040008 */ addiu $a0,$s0,0x8 +/* f06d434: 26050028 */ addiu $a1,$s0,0x28 +/* f06d438: 33190080 */ andi $t9,$t8,0x80 +/* f06d43c: 1320012d */ beqz $t9,.L0f06d8f4 +/* f06d440: 27a60080 */ addiu $a2,$sp,0x80 +/* f06d444: 44800000 */ mtc1 $zero,$f0 +/* f06d448: 2408003f */ addiu $t0,$zero,0x3f +/* f06d44c: afa80014 */ sw $t0,0x14($sp) +/* f06d450: 27a70070 */ addiu $a3,$sp,0x70 +/* f06d454: e7a20010 */ swc1 $f2,0x10($sp) +/* f06d458: afa00018 */ sw $zero,0x18($sp) +/* f06d45c: afa40040 */ sw $a0,0x40($sp) +/* f06d460: afa5003c */ sw $a1,0x3c($sp) +/* f06d464: e7a200a0 */ swc1 $f2,0xa0($sp) +/* f06d468: e7a0001c */ swc1 $f0,0x1c($sp) +/* f06d46c: 0c00b6b2 */ jal cd0002dac8 +/* f06d470: e7a00020 */ swc1 $f0,0x20($sp) +/* f06d474: 10400020 */ beqz $v0,.L0f06d4f8 +/* f06d478: 8fa400a8 */ lw $a0,0xa8($sp) +/* f06d47c: 27a50080 */ addiu $a1,$sp,0x80 +/* f06d480: 2486001c */ addiu $a2,$a0,0x1c +/* f06d484: 0fc248cf */ jal func0f09233c +/* f06d488: 27a70070 */ addiu $a3,$sp,0x70 +/* f06d48c: 44800000 */ mtc1 $zero,$f0 +/* f06d490: 2409003f */ addiu $t1,$zero,0x3f +/* f06d494: afa90010 */ sw $t1,0x10($sp) +/* f06d498: 8fa40040 */ lw $a0,0x40($sp) +/* f06d49c: 27a50080 */ addiu $a1,$sp,0x80 +/* f06d4a0: 8fa600a0 */ lw $a2,0xa0($sp) +/* f06d4a4: 27a70070 */ addiu $a3,$sp,0x70 +/* f06d4a8: afa00014 */ sw $zero,0x14($sp) +/* f06d4ac: e7a00018 */ swc1 $f0,0x18($sp) +/* f06d4b0: 0c00aa7c */ jal cdTestAToB1 +/* f06d4b4: e7a0001c */ swc1 $f0,0x1c($sp) +/* f06d4b8: 1040000d */ beqz $v0,.L0f06d4f0 +/* f06d4bc: c7aa0080 */ lwc1 $f10,0x80($sp) +/* f06d4c0: e60a0008 */ swc1 $f10,0x8($s0) +/* f06d4c4: c7b00084 */ lwc1 $f16,0x84($sp) +/* f06d4c8: 02002025 */ or $a0,$s0,$zero +/* f06d4cc: e610000c */ swc1 $f16,0xc($s0) +/* f06d4d0: c7b20088 */ lwc1 $f18,0x88($sp) +/* f06d4d4: 0fc19711 */ jal propDeregisterRooms +/* f06d4d8: e6120010 */ swc1 $f18,0x10($s0) +/* f06d4dc: 27a40070 */ addiu $a0,$sp,0x70 +/* f06d4e0: 0fc195e9 */ jal roomsCopy +/* f06d4e4: 8fa5003c */ lw $a1,0x3c($sp) +/* f06d4e8: 10000005 */ b .L0f06d500 +/* f06d4ec: 8faa009c */ lw $t2,0x9c($sp) +.L0f06d4f0: +/* f06d4f0: 10000002 */ b .L0f06d4fc +/* f06d4f4: afa0009c */ sw $zero,0x9c($sp) +.L0f06d4f8: +/* f06d4f8: afa0009c */ sw $zero,0x9c($sp) +.L0f06d4fc: +/* f06d4fc: 8faa009c */ lw $t2,0x9c($sp) +.L0f06d500: +/* f06d500: 27a40064 */ addiu $a0,$sp,0x64 +/* f06d504: 27a50058 */ addiu $a1,$sp,0x58 +/* f06d508: 154000fa */ bnez $t2,.L0f06d8f4 +/* f06d50c: 24061121 */ addiu $a2,$zero,0x1116 +/* f06d510: 3c077f1b */ lui $a3,%hi(var7f1a9fa0) +/* f06d514: 0c009393 */ jal cd00024e4c +/* f06d518: 24e79fa0 */ addiu $a3,$a3,%lo(var7f1a9fa0) +/* f06d51c: c7a40060 */ lwc1 $f4,0x60($sp) +/* f06d520: c7a6006c */ lwc1 $f6,0x6c($sp) +/* f06d524: 8fa400b4 */ lw $a0,0xb4($sp) +/* f06d528: 44800000 */ mtc1 $zero,$f0 +/* f06d52c: 46062201 */ sub.s $f8,$f4,$f6 +/* f06d530: 24850004 */ addiu $a1,$a0,0x4 +/* f06d534: e4800004 */ swc1 $f0,0x4($a0) +/* f06d538: e4880000 */ swc1 $f8,0x0($a0) +/* f06d53c: c4840000 */ lwc1 $f4,0x0($a0) +/* f06d540: c7b00058 */ lwc1 $f16,0x58($sp) +/* f06d544: c7aa0064 */ lwc1 $f10,0x64($sp) +/* f06d548: 46040032 */ c.eq.s $f0,$f4 +/* f06d54c: 46105481 */ sub.s $f18,$f10,$f16 +/* f06d550: 45000007 */ bc1f .L0f06d570 +/* f06d554: e4920008 */ swc1 $f18,0x8($a0) +/* f06d558: c4860008 */ lwc1 $f6,0x8($a0) +/* f06d55c: 3c013f80 */ lui $at,0x3f80 +/* f06d560: 46060032 */ c.eq.s $f0,$f6 +/* f06d564: 00000000 */ nop +/* f06d568: 45030006 */ bc1tl .L0f06d584 +/* f06d56c: 44814000 */ mtc1 $at,$f8 +.L0f06d570: +/* f06d570: 0c0011e4 */ jal guNormalize +/* f06d574: 24860008 */ addiu $a2,$a0,0x8 +/* f06d578: 10000005 */ b .L0f06d590 +/* f06d57c: c6020008 */ lwc1 $f2,0x8($s0) +/* f06d580: 44814000 */ mtc1 $at,$f8 +.L0f06d584: +/* f06d584: 00000000 */ nop +/* f06d588: e4880008 */ swc1 $f8,0x8($a0) +/* f06d58c: c6020008 */ lwc1 $f2,0x8($s0) +.L0f06d590: +/* f06d590: c7aa0080 */ lwc1 $f10,0x80($sp) +/* f06d594: c7b00084 */ lwc1 $f16,0x84($sp) +/* f06d598: c7a80080 */ lwc1 $f8,0x80($sp) +/* f06d59c: 46025032 */ c.eq.s $f10,$f2 +/* f06d5a0: 00000000 */ nop +/* f06d5a4: 4502000e */ bc1fl .L0f06d5e0 +/* f06d5a8: 46024281 */ sub.s $f10,$f8,$f2 +/* f06d5ac: c612000c */ lwc1 $f18,0xc($s0) +/* f06d5b0: c7a40088 */ lwc1 $f4,0x88($sp) +/* f06d5b4: 46128032 */ c.eq.s $f16,$f18 +/* f06d5b8: 00000000 */ nop +/* f06d5bc: 45020008 */ bc1fl .L0f06d5e0 +/* f06d5c0: 46024281 */ sub.s $f10,$f8,$f2 +/* f06d5c4: c6060010 */ lwc1 $f6,0x10($s0) +/* f06d5c8: c7aa0080 */ lwc1 $f10,0x80($sp) +/* f06d5cc: 46062032 */ c.eq.s $f4,$f6 +/* f06d5d0: 00000000 */ nop +/* f06d5d4: 450300ad */ bc1tl .L0f06d88c +/* f06d5d8: e62a0000 */ swc1 $f10,0x0($s1) +/* f06d5dc: 46024281 */ sub.s $f10,$f8,$f2 +.L0f06d5e0: +/* f06d5e0: c7b00084 */ lwc1 $f16,0x84($sp) +/* f06d5e4: c7a60088 */ lwc1 $f6,0x88($sp) +/* f06d5e8: 8fa40040 */ lw $a0,0x40($sp) +/* f06d5ec: e7aa008c */ swc1 $f10,0x8c($sp) +/* f06d5f0: c612000c */ lwc1 $f18,0xc($s0) +/* f06d5f4: 27a5008c */ addiu $a1,$sp,0x8c +/* f06d5f8: 02203025 */ or $a2,$s1,$zero +/* f06d5fc: 46128101 */ sub.s $f4,$f16,$f18 +/* f06d600: e7a40090 */ swc1 $f4,0x90($sp) +/* f06d604: c6080010 */ lwc1 $f8,0x10($s0) +/* f06d608: 46083281 */ sub.s $f10,$f6,$f8 +/* f06d60c: 0fc0b93e */ jal func0f02e4f8 +/* f06d610: e7aa0094 */ swc1 $f10,0x94($sp) +/* f06d614: c6020008 */ lwc1 $f2,0x8($s0) +/* f06d618: c7b00080 */ lwc1 $f16,0x80($sp) +/* f06d61c: 4610103c */ c.lt.s $f2,$f16 +/* f06d620: 00000000 */ nop +/* f06d624: 4502000f */ bc1fl .L0f06d664 +/* f06d628: c6200000 */ lwc1 $f0,0x0($s1) +/* f06d62c: c6200000 */ lwc1 $f0,0x0($s1) +/* f06d630: 4600803c */ c.lt.s $f16,$f0 +/* f06d634: 00000000 */ nop +/* f06d638: 45020004 */ bc1fl .L0f06d64c +/* f06d63c: 4602003c */ c.lt.s $f0,$f2 +/* f06d640: 10000014 */ b .L0f06d694 +/* f06d644: e6300000 */ swc1 $f16,0x0($s1) +/* f06d648: 4602003c */ c.lt.s $f0,$f2 +.L0f06d64c: +/* f06d64c: 00000000 */ nop +/* f06d650: 45020011 */ bc1fl .L0f06d698 +/* f06d654: c602000c */ lwc1 $f2,0xc($s0) +/* f06d658: 1000000e */ b .L0f06d694 +/* f06d65c: e6220000 */ swc1 $f2,0x0($s1) +/* f06d660: c6200000 */ lwc1 $f0,0x0($s1) +.L0f06d664: +/* f06d664: c7b20080 */ lwc1 $f18,0x80($sp) +/* f06d668: 4600103c */ c.lt.s $f2,$f0 +/* f06d66c: 00000000 */ nop +/* f06d670: 45020004 */ bc1fl .L0f06d684 +/* f06d674: 4612003c */ c.lt.s $f0,$f18 +/* f06d678: 10000006 */ b .L0f06d694 +/* f06d67c: e6220000 */ swc1 $f2,0x0($s1) +/* f06d680: 4612003c */ c.lt.s $f0,$f18 +.L0f06d684: +/* f06d684: 00000000 */ nop +/* f06d688: 45020003 */ bc1fl .L0f06d698 +/* f06d68c: c602000c */ lwc1 $f2,0xc($s0) +/* f06d690: e6320000 */ swc1 $f18,0x0($s1) +.L0f06d694: +/* f06d694: c602000c */ lwc1 $f2,0xc($s0) +.L0f06d698: +/* f06d698: c7a40084 */ lwc1 $f4,0x84($sp) +/* f06d69c: 4604103c */ c.lt.s $f2,$f4 +/* f06d6a0: 00000000 */ nop +/* f06d6a4: 4502000f */ bc1fl .L0f06d6e4 +/* f06d6a8: c6200004 */ lwc1 $f0,0x4($s1) +/* f06d6ac: c6200004 */ lwc1 $f0,0x4($s1) +/* f06d6b0: 4600203c */ c.lt.s $f4,$f0 +/* f06d6b4: 00000000 */ nop +/* f06d6b8: 45020004 */ bc1fl .L0f06d6cc +/* f06d6bc: 4602003c */ c.lt.s $f0,$f2 +/* f06d6c0: 10000014 */ b .L0f06d714 +/* f06d6c4: e6240004 */ swc1 $f4,0x4($s1) +/* f06d6c8: 4602003c */ c.lt.s $f0,$f2 +.L0f06d6cc: +/* f06d6cc: 00000000 */ nop +/* f06d6d0: 45020011 */ bc1fl .L0f06d718 +/* f06d6d4: c6020010 */ lwc1 $f2,0x10($s0) +/* f06d6d8: 1000000e */ b .L0f06d714 +/* f06d6dc: e6220004 */ swc1 $f2,0x4($s1) +/* f06d6e0: c6200004 */ lwc1 $f0,0x4($s1) +.L0f06d6e4: +/* f06d6e4: c7a60084 */ lwc1 $f6,0x84($sp) +/* f06d6e8: 4600103c */ c.lt.s $f2,$f0 +/* f06d6ec: 00000000 */ nop +/* f06d6f0: 45020004 */ bc1fl .L0f06d704 +/* f06d6f4: 4606003c */ c.lt.s $f0,$f6 +/* f06d6f8: 10000006 */ b .L0f06d714 +/* f06d6fc: e6220004 */ swc1 $f2,0x4($s1) +/* f06d700: 4606003c */ c.lt.s $f0,$f6 +.L0f06d704: +/* f06d704: 00000000 */ nop +/* f06d708: 45020003 */ bc1fl .L0f06d718 +/* f06d70c: c6020010 */ lwc1 $f2,0x10($s0) +/* f06d710: e6260004 */ swc1 $f6,0x4($s1) +.L0f06d714: +/* f06d714: c6020010 */ lwc1 $f2,0x10($s0) +.L0f06d718: +/* f06d718: c7a80088 */ lwc1 $f8,0x88($sp) +/* f06d71c: 4608103c */ c.lt.s $f2,$f8 +/* f06d720: 00000000 */ nop +/* f06d724: 4502000f */ bc1fl .L0f06d764 +/* f06d728: c6200008 */ lwc1 $f0,0x8($s1) +/* f06d72c: c6200008 */ lwc1 $f0,0x8($s1) +/* f06d730: 4600403c */ c.lt.s $f8,$f0 +/* f06d734: 00000000 */ nop +/* f06d738: 45020004 */ bc1fl .L0f06d74c +/* f06d73c: 4602003c */ c.lt.s $f0,$f2 +/* f06d740: 10000014 */ b .L0f06d794 +/* f06d744: e6280008 */ swc1 $f8,0x8($s1) +/* f06d748: 4602003c */ c.lt.s $f0,$f2 +.L0f06d74c: +/* f06d74c: 00000000 */ nop +/* f06d750: 45000010 */ bc1f .L0f06d794 +/* f06d754: 00000000 */ nop +/* f06d758: 1000000e */ b .L0f06d794 +/* f06d75c: e6220008 */ swc1 $f2,0x8($s1) +/* f06d760: c6200008 */ lwc1 $f0,0x8($s1) +.L0f06d764: +/* f06d764: c7aa0088 */ lwc1 $f10,0x88($sp) +/* f06d768: 4600103c */ c.lt.s $f2,$f0 +/* f06d76c: 00000000 */ nop +/* f06d770: 45020004 */ bc1fl .L0f06d784 +/* f06d774: 460a003c */ c.lt.s $f0,$f10 +/* f06d778: 10000006 */ b .L0f06d794 +/* f06d77c: e6220008 */ swc1 $f2,0x8($s1) +/* f06d780: 460a003c */ c.lt.s $f0,$f10 +.L0f06d784: +/* f06d784: 00000000 */ nop +/* f06d788: 45000002 */ bc1f .L0f06d794 +/* f06d78c: 00000000 */ nop +/* f06d790: e62a0008 */ swc1 $f10,0x8($s1) +.L0f06d794: +/* f06d794: 0c0093a6 */ jal cd00024e98 +/* f06d798: 00000000 */ nop +/* f06d79c: 3c017f1b */ lui $at,%hi(var7f1aa26c) +/* f06d7a0: c430a26c */ lwc1 $f16,%lo(var7f1aa26c)($at) +/* f06d7a4: c7b2008c */ lwc1 $f18,0x8c($sp) +/* f06d7a8: c6060008 */ lwc1 $f6,0x8($s0) +/* f06d7ac: 46100082 */ mul.s $f2,$f0,$f16 +/* f06d7b0: c7b00094 */ lwc1 $f16,0x94($sp) +/* f06d7b4: c7aa0084 */ lwc1 $f10,0x84($sp) +/* f06d7b8: 27b1004c */ addiu $s1,$sp,0x4c +/* f06d7bc: 240b003f */ addiu $t3,$zero,0x3f +/* f06d7c0: e7aa0050 */ swc1 $f10,0x50($sp) +/* f06d7c4: 44805000 */ mtc1 $zero,$f10 +/* f06d7c8: 46029102 */ mul.s $f4,$f18,$f2 +/* f06d7cc: 02203025 */ or $a2,$s1,$zero +/* f06d7d0: 8fa40040 */ lw $a0,0x40($sp) +/* f06d7d4: 46028482 */ mul.s $f18,$f16,$f2 +/* f06d7d8: 8fa5003c */ lw $a1,0x3c($sp) +/* f06d7dc: 27a70070 */ addiu $a3,$sp,0x70 +/* f06d7e0: 46062200 */ add.s $f8,$f4,$f6 +/* f06d7e4: e7a8004c */ swc1 $f8,0x4c($sp) +/* f06d7e8: c6040010 */ lwc1 $f4,0x10($s0) +/* f06d7ec: 44804000 */ mtc1 $zero,$f8 +/* f06d7f0: afa00014 */ sw $zero,0x14($sp) +/* f06d7f4: 46049180 */ add.s $f6,$f18,$f4 +/* f06d7f8: afab0010 */ sw $t3,0x10($sp) +/* f06d7fc: e7aa001c */ swc1 $f10,0x1c($sp) +/* f06d800: e7a80018 */ swc1 $f8,0x18($sp) +/* f06d804: 0c00b694 */ jal cd0002da50 +/* f06d808: e7a60054 */ swc1 $f6,0x54($sp) +/* f06d80c: 10400024 */ beqz $v0,.L0f06d8a0 +/* f06d810: 8fa400a8 */ lw $a0,0xa8($sp) +/* f06d814: 02202825 */ or $a1,$s1,$zero +/* f06d818: 2486001c */ addiu $a2,$a0,0x1c +/* f06d81c: 0fc248cf */ jal func0f09233c +/* f06d820: 27a70070 */ addiu $a3,$sp,0x70 +/* f06d824: 44808000 */ mtc1 $zero,$f16 +/* f06d828: 44809000 */ mtc1 $zero,$f18 +/* f06d82c: 02202025 */ or $a0,$s1,$zero +/* f06d830: 8fa500a0 */ lw $a1,0xa0($sp) +/* f06d834: 27a60070 */ addiu $a2,$sp,0x70 +/* f06d838: 2407003f */ addiu $a3,$zero,0x3f +/* f06d83c: afa00010 */ sw $zero,0x10($sp) +/* f06d840: e7b00014 */ swc1 $f16,0x14($sp) +/* f06d844: 0c00a9a1 */ jal cdTestVolume +/* f06d848: e7b20018 */ swc1 $f18,0x18($sp) +/* f06d84c: 10400014 */ beqz $v0,.L0f06d8a0 +/* f06d850: c7a4004c */ lwc1 $f4,0x4c($sp) +/* f06d854: e6040008 */ swc1 $f4,0x8($s0) +/* f06d858: c7a60050 */ lwc1 $f6,0x50($sp) +/* f06d85c: 02002025 */ or $a0,$s0,$zero +/* f06d860: e606000c */ swc1 $f6,0xc($s0) +/* f06d864: c7a80054 */ lwc1 $f8,0x54($sp) +/* f06d868: 0fc19711 */ jal propDeregisterRooms +/* f06d86c: e6080010 */ swc1 $f8,0x10($s0) +/* f06d870: 27a40070 */ addiu $a0,$sp,0x70 +/* f06d874: 0fc195e9 */ jal roomsCopy +/* f06d878: 8fa5003c */ lw $a1,0x3c($sp) +/* f06d87c: 240d0001 */ addiu $t5,$zero,0x1 +/* f06d880: 10000007 */ b .L0f06d8a0 +/* f06d884: afad0098 */ sw $t5,0x98($sp) +/* f06d888: e62a0000 */ swc1 $f10,0x0($s1) +.L0f06d88c: +/* f06d88c: c7b00084 */ lwc1 $f16,0x84($sp) +/* f06d890: e6300004 */ swc1 $f16,0x4($s1) +/* f06d894: c7b20088 */ lwc1 $f18,0x88($sp) +/* f06d898: e6320008 */ swc1 $f18,0x8($s1) +/* f06d89c: 27b1004c */ addiu $s1,$sp,0x4c +.L0f06d8a0: +/* f06d8a0: 8fae0098 */ lw $t6,0x98($sp) +/* f06d8a4: 02203025 */ or $a2,$s1,$zero +/* f06d8a8: 27a70070 */ addiu $a3,$sp,0x70 +/* f06d8ac: 55c00012 */ bnezl $t6,.L0f06d8f8 +/* f06d8b0: 8fbf0034 */ lw $ra,0x34($sp) +/* f06d8b4: c6040008 */ lwc1 $f4,0x8($s0) +/* f06d8b8: c7a60084 */ lwc1 $f6,0x84($sp) +/* f06d8bc: 8fa40040 */ lw $a0,0x40($sp) +/* f06d8c0: e7a4004c */ swc1 $f4,0x4c($sp) +/* f06d8c4: e7a60050 */ swc1 $f6,0x50($sp) +/* f06d8c8: c6080010 */ lwc1 $f8,0x10($s0) +/* f06d8cc: 8fa5003c */ lw $a1,0x3c($sp) +/* f06d8d0: 0fc1979d */ jal func0f065e74 +/* f06d8d4: e7a80054 */ swc1 $f8,0x54($sp) +/* f06d8d8: c7aa0050 */ lwc1 $f10,0x50($sp) +/* f06d8dc: 02002025 */ or $a0,$s0,$zero +/* f06d8e0: 0fc19711 */ jal propDeregisterRooms +/* f06d8e4: e60a000c */ swc1 $f10,0xc($s0) +/* f06d8e8: 27a40070 */ addiu $a0,$sp,0x70 +/* f06d8ec: 0fc195e9 */ jal roomsCopy +/* f06d8f0: 8fa5003c */ lw $a1,0x3c($sp) +.L0f06d8f4: +/* f06d8f4: 8fbf0034 */ lw $ra,0x34($sp) +.L0f06d8f8: +/* f06d8f8: 8fa2009c */ lw $v0,0x9c($sp) +/* f06d8fc: 8fb0002c */ lw $s0,0x2c($sp) +/* f06d900: 8fb10030 */ lw $s1,0x30($sp) +/* f06d904: 03e00008 */ jr $ra +/* f06d908: 27bd00a8 */ addiu $sp,$sp,0xa8 +); #endif /** @@ -11641,6 +12586,7 @@ glabel func0f06ef44 /* f06f09c: 27bd0178 */ addiu $sp,$sp,0x178 ); +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f06f0a0 /* f06f0a0: 27bdffd8 */ addiu $sp,$sp,-40 @@ -11814,6 +12760,181 @@ glabel func0f06f0a0 /* f06f30c: 03e00008 */ jr $ra /* f06f310: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f06f0a0 +/* f06f0a0: 27bdffd8 */ addiu $sp,$sp,-40 +/* f06f0a4: afbf001c */ sw $ra,0x1c($sp) +/* f06f0a8: afb00018 */ sw $s0,0x18($sp) +/* f06f0ac: afa40028 */ sw $a0,0x28($sp) +/* f06f0b0: afa5002c */ sw $a1,0x2c($sp) +/* f06f0b4: afa60030 */ sw $a2,0x30($sp) +/* f06f0b8: afa70034 */ sw $a3,0x34($sp) +/* f06f0bc: 8c900004 */ lw $s0,0x4($a0) +/* f06f0c0: afa00020 */ sw $zero,0x20($sp) +/* f06f0c4: 8e030040 */ lw $v1,0x40($s0) +/* f06f0c8: 306f0080 */ andi $t7,$v1,0x80 +/* f06f0cc: 51e00008 */ beqzl $t7,.L0f06f0f0 +/* f06f0d0: 92020003 */ lbu $v0,0x3($s0) +/* f06f0d4: 8e180048 */ lw $t8,0x48($s0) +/* f06f0d8: 02002025 */ or $a0,$s0,$zero +/* f06f0dc: 8f190088 */ lw $t9,0x88($t8) +/* f06f0e0: 0fc1ab10 */ jal objEndFlight +/* f06f0e4: afb90020 */ sw $t9,0x20($sp) +/* f06f0e8: 8e030040 */ lw $v1,0x40($s0) +/* f06f0ec: 92020003 */ lbu $v0,0x3($s0) +.L0f06f0f0: +/* f06f0f0: 3c050002 */ lui $a1,0x2 +/* f06f0f4: 24070008 */ addiu $a3,$zero,0x8 +/* f06f0f8: 00654025 */ or $t0,$v1,$a1 +/* f06f0fc: 14e20030 */ bne $a3,$v0,.L0f06f1c0 +/* f06f100: ae080040 */ sw $t0,0x40($s0) +/* f06f104: 9204005c */ lbu $a0,0x5c($s0) +/* f06f108: 24010035 */ addiu $at,$zero,0x35 +/* f06f10c: 10810007 */ beq $a0,$at,.L0f06f12c +/* f06f110: 2401003d */ addiu $at,$zero,0x3d +/* f06f114: 10810005 */ beq $a0,$at,.L0f06f12c +/* f06f118: 2401003e */ addiu $at,$zero,0x3e +/* f06f11c: 10810003 */ beq $a0,$at,.L0f06f12c +/* f06f120: 2401003f */ addiu $at,$zero,0x3f +/* f06f124: 5481000c */ bnel $a0,$at,.L0f06f158 +/* f06f128: 8fa50028 */ lw $a1,0x28($sp) +.L0f06f12c: +/* f06f12c: 8e090008 */ lw $t1,0x8($s0) +/* f06f130: 8e0d000c */ lw $t5,0xc($s0) +/* f06f134: 3c010040 */ lui $at,0x40 +/* f06f138: 01255025 */ or $t2,$t1,$a1 +/* f06f13c: ae0a0008 */ sw $t2,0x8($s0) +/* f06f140: 01416025 */ or $t4,$t2,$at +/* f06f144: 35ae4000 */ ori $t6,$t5,0x4000 +/* f06f148: ae0c0008 */ sw $t4,0x8($s0) +/* f06f14c: ae0e000c */ sw $t6,0xc($s0) +/* f06f150: 9204005c */ lbu $a0,0x5c($s0) +/* f06f154: 8fa50028 */ lw $a1,0x28($sp) +.L0f06f158: +/* f06f158: 0fc257f6 */ jal objectiveCheckMultiroomEntered +/* f06f15c: 24a50028 */ addiu $a1,$a1,0x28 +/* f06f160: 9204005c */ lbu $a0,0x5c($s0) +/* f06f164: 24010056 */ addiu $at,$zero,0x55 +/* f06f168: 8fa5002c */ lw $a1,0x2c($sp) +/* f06f16c: 54810006 */ bnel $a0,$at,.L0f06f188 +/* f06f170: 2401001a */ addiu $at,$zero,0x1a +/* f06f174: 0fc1bb08 */ jal func0f06ec20 +/* f06f178: 02002025 */ or $a0,$s0,$zero +/* f06f17c: 1000000e */ b .L0f06f1b8 +/* f06f180: 92020003 */ lbu $v0,0x3($s0) +/* f06f184: 2401001a */ addiu $at,$zero,0x1a +.L0f06f188: +/* f06f188: 14810007 */ bne $a0,$at,.L0f06f1a8 +/* f06f18c: 8fa5002c */ lw $a1,0x2c($sp) +/* f06f190: 02002025 */ or $a0,$s0,$zero +/* f06f194: 8fa5002c */ lw $a1,0x2c($sp) +/* f06f198: 0fc1bb59 */ jal func0f06ed64 +/* f06f19c: 8fa60030 */ lw $a2,0x30($sp) +/* f06f1a0: 10000005 */ b .L0f06f1b8 +/* f06f1a4: 92020003 */ lbu $v0,0x3($s0) +.L0f06f1a8: +/* f06f1a8: 02002025 */ or $a0,$s0,$zero +/* f06f1ac: 0fc1bad3 */ jal func0f06eb4c +/* f06f1b0: 8fa60030 */ lw $a2,0x30($sp) +/* f06f1b4: 92020003 */ lbu $v0,0x3($s0) +.L0f06f1b8: +/* f06f1b8: 1000001e */ b .L0f06f234 +/* f06f1bc: 24070008 */ addiu $a3,$zero,0x8 +.L0f06f1c0: +/* f06f1c0: 2401000d */ addiu $at,$zero,0xd +/* f06f1c4: 1441001b */ bne $v0,$at,.L0f06f234 +/* f06f1c8: 02002025 */ or $a0,$s0,$zero +/* f06f1cc: 8fa5002c */ lw $a1,0x2c($sp) +/* f06f1d0: 0fc1bad3 */ jal func0f06eb4c +/* f06f1d4: 8fa60030 */ lw $a2,0x30($sp) +/* f06f1d8: 8fa20030 */ lw $v0,0x30($sp) +/* f06f1dc: c44c0000 */ lwc1 $f12,0x0($v0) +/* f06f1e0: 0fc259d4 */ jal atan2f +/* f06f1e4: c44e0008 */ lwc1 $f14,0x8($v0) +/* f06f1e8: e6000060 */ swc1 $f0,0x60($s0) +/* f06f1ec: 8faf0030 */ lw $t7,0x30($sp) +/* f06f1f0: c5ee0008 */ lwc1 $f14,0x8($t7) +/* f06f1f4: c5e20000 */ lwc1 $f2,0x0($t7) +/* f06f1f8: 460e7102 */ mul.s $f4,$f14,$f14 +/* f06f1fc: 00000000 */ nop +/* f06f200: 46021182 */ mul.s $f6,$f2,$f2 +/* f06f204: 0c012974 */ jal sqrtf +/* f06f208: 46062300 */ add.s $f12,$f4,$f6 +/* f06f20c: 8fb80030 */ lw $t8,0x30($sp) +/* f06f210: 46000386 */ mov.s $f14,$f0 +/* f06f214: 0fc259d4 */ jal atan2f +/* f06f218: c70c0004 */ lwc1 $f12,0x4($t8) +/* f06f21c: c6080060 */ lwc1 $f8,0x60($s0) +/* f06f220: e6000074 */ swc1 $f0,0x74($s0) +/* f06f224: e6000078 */ swc1 $f0,0x78($s0) +/* f06f228: 92020003 */ lbu $v0,0x3($s0) +/* f06f22c: 24070008 */ addiu $a3,$zero,0x8 +/* f06f230: e608006c */ swc1 $f8,0x6c($s0) +.L0f06f234: +/* f06f234: 3c058007 */ lui $a1,%hi(var80069930) +/* f06f238: 8ca59930 */ lw $a1,%lo(var80069930)($a1) +/* f06f23c: 10a00029 */ beqz $a1,.L0f06f2e4 +/* f06f240: 00000000 */ nop +/* f06f244: 14e20012 */ bne $a3,$v0,.L0f06f290 +/* f06f248: 2604005c */ addiu $a0,$s0,0x5c +/* f06f24c: 0fc29f66 */ jal bgunPlayPropHitSound +/* f06f250: 2406ffff */ addiu $a2,$zero,-1 +/* f06f254: 9219005c */ lbu $t9,0x5c($s0) +/* f06f258: 2401001a */ addiu $at,$zero,0x1a +/* f06f25c: 3c038007 */ lui $v1,%hi(var80069930) +/* f06f260: 1721000b */ bne $t9,$at,.L0f06f290 +/* f06f264: 00000000 */ nop +/* f06f268: 8c639930 */ lw $v1,%lo(var80069930)($v1) +/* f06f26c: 24010003 */ addiu $at,$zero,0x3 +/* f06f270: 8fa50020 */ lw $a1,0x20($sp) +/* f06f274: 90620000 */ lbu $v0,0x0($v1) +/* f06f278: 10410003 */ beq $v0,$at,.L0f06f288 +/* f06f27c: 24010006 */ addiu $at,$zero,0x6 +/* f06f280: 14410003 */ bne $v0,$at,.L0f06f290 +/* f06f284: 00000000 */ nop +.L0f06f288: +/* f06f288: 0fc08b32 */ jal chrSetPoisoned +/* f06f28c: 8c640004 */ lw $a0,0x4($v1) +.L0f06f290: +/* f06f290: 3c058007 */ lui $a1,%hi(var80069930) +/* f06f294: 8ca59930 */ lw $a1,%lo(var80069930)($a1) +/* f06f298: 8fa40028 */ lw $a0,0x28($sp) +/* f06f29c: 3c06800a */ lui $a2,%hi(var8009ce70) +/* f06f2a0: 90a80001 */ lbu $t0,0x1($a1) +/* f06f2a4: 3c07800a */ lui $a3,%hi(var8009ce74) +/* f06f2a8: 31090002 */ andi $t1,$t0,0x2 +/* f06f2ac: 5120000a */ beqzl $t1,.L0f06f2d8 +/* f06f2b0: 8e0c0040 */ lw $t4,0x40($s0) +/* f06f2b4: 8cc6ce70 */ lw $a2,%lo(var8009ce70)($a2) +/* f06f2b8: 0fc1bbd1 */ jal func0f06ef44 +/* f06f2bc: 8ce7ce74 */ lw $a3,%lo(var8009ce74)($a3) +/* f06f2c0: 1040000f */ beqz $v0,.L0f06f300 +/* f06f2c4: 8fab0034 */ lw $t3,0x34($sp) +/* f06f2c8: 240a0001 */ addiu $t2,$zero,0x1 +/* f06f2cc: 1000000c */ b .L0f06f300 +/* f06f2d0: ad6a0000 */ sw $t2,0x0($t3) +/* f06f2d4: 8e0c0040 */ lw $t4,0x40($s0) +.L0f06f2d8: +/* f06f2d8: 358d0004 */ ori $t5,$t4,0x4 +/* f06f2dc: 10000008 */ b .L0f06f300 +/* f06f2e0: ae0d0040 */ sw $t5,0x40($s0) +.L0f06f2e4: +/* f06f2e4: 14e20006 */ bne $a3,$v0,.L0f06f300 +/* f06f2e8: 2604005c */ addiu $a0,$s0,0x5c +/* f06f2ec: 8fa70028 */ lw $a3,0x28($sp) +/* f06f2f0: 8fa5002c */ lw $a1,0x2c($sp) +/* f06f2f4: 2406ffff */ addiu $a2,$zero,-1 +/* f06f2f8: 0fc2a132 */ jal bgunPlayBgHitSound +/* f06f2fc: 24e70028 */ addiu $a3,$a3,40 +.L0f06f300: +/* f06f300: 8fbf001c */ lw $ra,0x1c($sp) +/* f06f304: 8fb00018 */ lw $s0,0x18($sp) +/* f06f308: 27bd0028 */ addiu $sp,$sp,0x28 +/* f06f30c: 03e00008 */ jr $ra +/* f06f310: 00000000 */ nop +); +#endif GLOBAL_ASM( glabel func0f06f314 @@ -15860,6 +16981,7 @@ f32 liftGetY(struct liftobj *lift) return y; } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f070f08 /* f070f08: 27bdffa0 */ addiu $sp,$sp,-96 @@ -15995,7 +17117,145 @@ glabel func0f070f08 /* f0710e4: 03e00008 */ jr $ra /* f0710e8: 27bd0060 */ addiu $sp,$sp,0x60 ); +#else +GLOBAL_ASM( +glabel func0f070f08 +/* f070f08: 27bdffa0 */ addiu $sp,$sp,-96 +/* f070f0c: afbf0044 */ sw $ra,0x44($sp) +/* f070f10: afbe0040 */ sw $s8,0x40($sp) +/* f070f14: afb7003c */ sw $s7,0x3c($sp) +/* f070f18: afb60038 */ sw $s6,0x38($sp) +/* f070f1c: afb50034 */ sw $s5,0x34($sp) +/* f070f20: afb40030 */ sw $s4,0x30($sp) +/* f070f24: afb3002c */ sw $s3,0x2c($sp) +/* f070f28: afb20028 */ sw $s2,0x28($sp) +/* f070f2c: afb10024 */ sw $s1,0x24($sp) +/* f070f30: afb00020 */ sw $s0,0x20($sp) +/* f070f34: afa50064 */ sw $a1,0x64($sp) +/* f070f38: a080005a */ sb $zero,0x5a($a0) +/* f070f3c: 00808825 */ or $s1,$a0,$zero +/* f070f40: 00009025 */ or $s2,$zero,$zero +/* f070f44: 8fb3004c */ lw $s3,0x4c($sp) +/* f070f48: 24150001 */ addiu $s5,$zero,0x1 +/* f070f4c: 24160002 */ addiu $s6,$zero,0x2 +/* f070f50: 24170003 */ addiu $s7,$zero,0x3 +/* f070f54: 241e0004 */ addiu $s8,$zero,0x4 +/* f070f58: 822f005a */ lb $t7,0x5a($s1) +.L0f070f5c: +/* f070f5c: 8e2e0044 */ lw $t6,0x44($s1) +/* f070f60: 0000a025 */ or $s4,$zero,$zero +/* f070f64: 000fc180 */ sll $t8,$t7,0x6 +/* f070f68: 01d8c821 */ addu $t9,$t6,$t8 +/* f070f6c: afb9005c */ sw $t9,0x5c($sp) +/* f070f70: 00008025 */ or $s0,$zero,$zero +.L0f070f74: +/* f070f74: 16400011 */ bnez $s2,.L0f070fbc +/* f070f78: 24050005 */ addiu $a1,$zero,0x5 +/* f070f7c: 8e280018 */ lw $t0,0x18($s1) +/* f070f80: 2413003b */ addiu $s3,$zero,0x23 +/* f070f84: 0c006a6f */ jal modelGetPartRodata +/* f070f88: 8d040008 */ lw $a0,0x8($t0) +/* f070f8c: 14400036 */ bnez $v0,.L0f071068 +/* f070f90: 00408025 */ or $s0,$v0,$zero +/* f070f94: 8e290018 */ lw $t1,0x18($s1) +/* f070f98: 00002825 */ or $a1,$zero,$zero +/* f070f9c: 0c006a6f */ jal modelGetPartRodata +/* f070fa0: 8d240008 */ lw $a0,0x8($t1) +/* f070fa4: 14400030 */ bnez $v0,.L0f071068 +/* f070fa8: 0040a025 */ or $s4,$v0,$zero +/* f070fac: 0fc1a2bd */ jal objFindBboxRodata +/* f070fb0: 02202025 */ or $a0,$s1,$zero +/* f070fb4: 1000002c */ b .L0f071068 +/* f070fb8: 0040a025 */ or $s4,$v0,$zero +.L0f070fbc: +/* f070fbc: 16550007 */ bne $s2,$s5,.L0f070fdc +/* f070fc0: 02a02825 */ or $a1,$s5,$zero +/* f070fc4: 8e2a0018 */ lw $t2,0x18($s1) +/* f070fc8: 24130004 */ addiu $s3,$zero,0x4 +/* f070fcc: 0c006a6f */ jal modelGetPartRodata +/* f070fd0: 8d440008 */ lw $a0,0x8($t2) +/* f070fd4: 10000024 */ b .L0f071068 +/* f070fd8: 00408025 */ or $s0,$v0,$zero +.L0f070fdc: +/* f070fdc: 16560007 */ bne $s2,$s6,.L0f070ffc +/* f070fe0: 02c02825 */ or $a1,$s6,$zero +/* f070fe4: 8e2b0018 */ lw $t3,0x18($s1) +/* f070fe8: 24130004 */ addiu $s3,$zero,0x4 +/* f070fec: 0c006a6f */ jal modelGetPartRodata +/* f070ff0: 8d640008 */ lw $a0,0x8($t3) +/* f070ff4: 1000001c */ b .L0f071068 +/* f070ff8: 00408025 */ or $s0,$v0,$zero +.L0f070ffc: +/* f070ffc: 16570007 */ bne $s2,$s7,.L0f07101c +/* f071000: 02e02825 */ or $a1,$s7,$zero +/* f071004: 8e2c0018 */ lw $t4,0x18($s1) +/* f071008: 24130004 */ addiu $s3,$zero,0x4 +/* f07100c: 0c006a6f */ jal modelGetPartRodata +/* f071010: 8d840008 */ lw $a0,0x8($t4) +/* f071014: 10000014 */ b .L0f071068 +/* f071018: 00408025 */ or $s0,$v0,$zero +.L0f07101c: +/* f07101c: 165e000b */ bne $s2,$s8,.L0f07104c +/* f071020: 24010005 */ addiu $at,$zero,0x5 +/* f071024: 8fad0064 */ lw $t5,0x64($sp) +/* f071028: 03c02825 */ or $a1,$s8,$zero +/* f07102c: 15a0000e */ bnez $t5,.L0f071068 +/* f071030: 00000000 */ nop +/* f071034: 8e2f0018 */ lw $t7,0x18($s1) +/* f071038: 24130004 */ addiu $s3,$zero,0x4 +/* f07103c: 0c006a6f */ jal modelGetPartRodata +/* f071040: 8de40008 */ lw $a0,0x8($t7) +/* f071044: 10000008 */ b .L0f071068 +/* f071048: 00408025 */ or $s0,$v0,$zero +.L0f07104c: +/* f07104c: 1641000a */ bne $s2,$at,.L0f071078 +/* f071050: 24050006 */ addiu $a1,$zero,0x6 +/* f071054: 8e2e0018 */ lw $t6,0x18($s1) +/* f071058: 2413003b */ addiu $s3,$zero,0x23 +/* f07105c: 0c006a6f */ jal modelGetPartRodata +/* f071060: 8dc40008 */ lw $a0,0x8($t6) +/* f071064: 00408025 */ or $s0,$v0,$zero +.L0f071068: +/* f071068: 16800003 */ bnez $s4,.L0f071078 +/* f07106c: 26520001 */ addiu $s2,$s2,0x1 +/* f071070: 1200ffc0 */ beqz $s0,.L0f070f74 +/* f071074: 00000000 */ nop +.L0f071078: +/* f071078: 16800003 */ bnez $s4,.L0f071088 +/* f07107c: 02202025 */ or $a0,$s1,$zero +/* f071080: 12000009 */ beqz $s0,.L0f0710a8 +/* f071084: 00000000 */ nop +.L0f071088: +/* f071088: 8fa5005c */ lw $a1,0x5c($sp) +/* f07108c: 02603025 */ or $a2,$s3,$zero +/* f071090: 02803825 */ or $a3,$s4,$zero +/* f071094: 0fc1c328 */ jal func0f070ca0 +/* f071098: afb00010 */ sw $s0,0x10($sp) +/* f07109c: 8238005a */ lb $t8,0x5a($s1) +/* f0710a0: 27190001 */ addiu $t9,$t8,0x1 +/* f0710a4: a239005a */ sb $t9,0x5a($s1) +.L0f0710a8: +/* f0710a8: 5680ffac */ bnezl $s4,.L0f070f5c +/* f0710ac: 822f005a */ lb $t7,0x5a($s1) +/* f0710b0: 5600ffaa */ bnezl $s0,.L0f070f5c +/* f0710b4: 822f005a */ lb $t7,0x5a($s1) +/* f0710b8: 8fbf0044 */ lw $ra,0x44($sp) +/* f0710bc: afb3004c */ sw $s3,0x4c($sp) +/* f0710c0: 8fb3002c */ lw $s3,0x2c($sp) +/* f0710c4: 8fb00020 */ lw $s0,0x20($sp) +/* f0710c8: 8fb10024 */ lw $s1,0x24($sp) +/* f0710cc: 8fb20028 */ lw $s2,0x28($sp) +/* f0710d0: 8fb40030 */ lw $s4,0x30($sp) +/* f0710d4: 8fb50034 */ lw $s5,0x34($sp) +/* f0710d8: 8fb60038 */ lw $s6,0x38($sp) +/* f0710dc: 8fb7003c */ lw $s7,0x3c($sp) +/* f0710e0: 8fbe0040 */ lw $s8,0x40($sp) +/* f0710e4: 03e00008 */ jr $ra +/* f0710e8: 27bd0060 */ addiu $sp,$sp,0x60 +); +#endif +#if VERSION >= VERSION_NTSC_1_0 void liftGoToStop(struct liftobj *lift, s32 stopnum) { u32 stack[1]; @@ -16053,6 +17313,153 @@ void liftGoToStop(struct liftobj *lift, s32 stopnum) } } } +#else +GLOBAL_ASM( +glabel liftGoToStop +/* f06fee4: 27bdfed0 */ addiu $sp,$sp,-304 +/* f06fee8: 00057840 */ sll $t7,$a1,0x1 +/* f06feec: afbf0014 */ sw $ra,0x14($sp) +/* f06fef0: afa50134 */ sw $a1,0x134($sp) +/* f06fef4: 008f4021 */ addu $t0,$a0,$t7 +/* f06fef8: 8518005c */ lh $t8,0x5c($t0) +/* f06fefc: 00803825 */ or $a3,$a0,$zero +/* f06ff00: 07020079 */ bltzl $t8,.NB0f0700e8 +/* f06ff04: 8fbf0014 */ lw $ra,0x14($sp) +/* f06ff08: 80820086 */ lb $v0,0x86($a0) +/* f06ff0c: 50a20076 */ beql $a1,$v0,.NB0f0700e8 +/* f06ff10: 8fbf0014 */ lw $ra,0x14($sp) +/* f06ff14: 80830085 */ lb $v1,0x85($a0) +/* f06ff18: 27a600dc */ addiu $a2,$sp,0xdc +/* f06ff1c: 14430003 */ bne $v0,$v1,.NB0f06ff2c +/* f06ff20: 0003c840 */ sll $t9,$v1,0x1 +/* f06ff24: 1000006f */ beqz $zero,.NB0f0700e4 +/* f06ff28: a0850086 */ sb $a1,0x86($a0) +.NB0f06ff2c: +/* f06ff2c: 00f94821 */ addu $t1,$a3,$t9 +/* f06ff30: 8524005c */ lh $a0,0x5c($t1) +/* f06ff34: afa80020 */ sw $t0,0x20($sp) +/* f06ff38: afa70130 */ sw $a3,0x130($sp) +/* f06ff3c: 0fc43fc4 */ jal padUnpack +/* f06ff40: 24050002 */ addiu $a1,$zero,0x2 +/* f06ff44: 8fa70130 */ lw $a3,0x130($sp) +/* f06ff48: 24050002 */ addiu $a1,$zero,0x2 +/* f06ff4c: 27a60088 */ addiu $a2,$sp,0x88 +/* f06ff50: 80ea0086 */ lb $t2,0x86($a3) +/* f06ff54: 000a5840 */ sll $t3,$t2,0x1 +/* f06ff58: 00eb6021 */ addu $t4,$a3,$t3 +/* f06ff5c: 0fc43fc4 */ jal padUnpack +/* f06ff60: 8584005c */ lh $a0,0x5c($t4) +/* f06ff64: 8fa80020 */ lw $t0,0x20($sp) +/* f06ff68: 24050002 */ addiu $a1,$zero,0x2 +/* f06ff6c: 27a60034 */ addiu $a2,$sp,0x34 +/* f06ff70: 0fc43fc4 */ jal padUnpack +/* f06ff74: 8504005c */ lh $a0,0x5c($t0) +/* f06ff78: c7a40088 */ lwc1 $f4,0x88($sp) +/* f06ff7c: c7a600dc */ lwc1 $f6,0xdc($sp) +/* f06ff80: 8fa70130 */ lw $a3,0x130($sp) +/* f06ff84: c7a80034 */ lwc1 $f8,0x34($sp) +/* f06ff88: 4604303e */ c.le.s $f6,$f4 +/* f06ff8c: c7a60088 */ lwc1 $f6,0x88($sp) +/* f06ff90: c7aa00dc */ lwc1 $f10,0xdc($sp) +/* f06ff94: 45020006 */ bc1fl .NB0f06ffb0 +/* f06ff98: 460a303e */ c.le.s $f6,$f10 +/* f06ff9c: 4608203e */ c.le.s $f4,$f8 +/* f06ffa0: 00000000 */ sll $zero,$zero,0x0 +/* f06ffa4: 4503000a */ bc1tl .NB0f06ffd0 +/* f06ffa8: c7b2008c */ lwc1 $f18,0x8c($sp) +/* f06ffac: 460a303e */ c.le.s $f6,$f10 +.NB0f06ffb0: +/* f06ffb0: c7a80034 */ lwc1 $f8,0x34($sp) +/* f06ffb4: 45020031 */ bc1fl .NB0f07007c +/* f06ffb8: c7a40088 */ lwc1 $f4,0x88($sp) +/* f06ffbc: 4606403e */ c.le.s $f8,$f6 +/* f06ffc0: 00000000 */ sll $zero,$zero,0x0 +/* f06ffc4: 4502002d */ bc1fl .NB0f07007c +/* f06ffc8: c7a40088 */ lwc1 $f4,0x88($sp) +/* f06ffcc: c7b2008c */ lwc1 $f18,0x8c($sp) +.NB0f06ffd0: +/* f06ffd0: c7a400e0 */ lwc1 $f4,0xe0($sp) +/* f06ffd4: c7aa0038 */ lwc1 $f10,0x38($sp) +/* f06ffd8: c7a600e0 */ lwc1 $f6,0xe0($sp) +/* f06ffdc: 4612203e */ c.le.s $f4,$f18 +/* f06ffe0: 00000000 */ sll $zero,$zero,0x0 +/* f06ffe4: 45020006 */ bc1fl .NB0f070000 +/* f06ffe8: 4606903e */ c.le.s $f18,$f6 +/* f06ffec: 460a903e */ c.le.s $f18,$f10 +/* f06fff0: 00000000 */ sll $zero,$zero,0x0 +/* f06fff4: 4503000a */ bc1tl .NB0f070020 +/* f06fff8: c7b00090 */ lwc1 $f16,0x90($sp) +/* f06fffc: 4606903e */ c.le.s $f18,$f6 +.NB0f070000: +/* f070000: c7a80038 */ lwc1 $f8,0x38($sp) +/* f070004: 4502001d */ bc1fl .NB0f07007c +/* f070008: c7a40088 */ lwc1 $f4,0x88($sp) +/* f07000c: 4612403e */ c.le.s $f8,$f18 +/* f070010: 00000000 */ sll $zero,$zero,0x0 +/* f070014: 45020019 */ bc1fl .NB0f07007c +/* f070018: c7a40088 */ lwc1 $f4,0x88($sp) +/* f07001c: c7b00090 */ lwc1 $f16,0x90($sp) +.NB0f070020: +/* f070020: c7a400e4 */ lwc1 $f4,0xe4($sp) +/* f070024: c7aa003c */ lwc1 $f10,0x3c($sp) +/* f070028: c7a600e4 */ lwc1 $f6,0xe4($sp) +/* f07002c: 4610203e */ c.le.s $f4,$f16 +/* f070030: 00000000 */ sll $zero,$zero,0x0 +/* f070034: 45020006 */ bc1fl .NB0f070050 +/* f070038: 4606803e */ c.le.s $f16,$f6 +/* f07003c: 460a803e */ c.le.s $f16,$f10 +/* f070040: 00000000 */ sll $zero,$zero,0x0 +/* f070044: 4503000a */ bc1tl .NB0f070070 +/* f070048: 8fad0134 */ lw $t5,0x134($sp) +/* f07004c: 4606803e */ c.le.s $f16,$f6 +.NB0f070050: +/* f070050: c7a8003c */ lwc1 $f8,0x3c($sp) +/* f070054: 45020009 */ bc1fl .NB0f07007c +/* f070058: c7a40088 */ lwc1 $f4,0x88($sp) +/* f07005c: 4610403e */ c.le.s $f8,$f16 +/* f070060: 00000000 */ sll $zero,$zero,0x0 +/* f070064: 45020005 */ bc1fl .NB0f07007c +/* f070068: c7a40088 */ lwc1 $f4,0x88($sp) +/* f07006c: 8fad0134 */ lw $t5,0x134($sp) +.NB0f070070: +/* f070070: 1000001c */ beqz $zero,.NB0f0700e4 +/* f070074: a0ed0086 */ sb $t5,0x86($a3) +/* f070078: c7a40088 */ lwc1 $f4,0x88($sp) +.NB0f07007c: +/* f07007c: c7aa00dc */ lwc1 $f10,0xdc($sp) +/* f070080: c7b2008c */ lwc1 $f18,0x8c($sp) +/* f070084: c7a600e0 */ lwc1 $f6,0xe0($sp) +/* f070088: 460a2001 */ sub.s $f0,$f4,$f10 +/* f07008c: c7b00090 */ lwc1 $f16,0x90($sp) +/* f070090: c7a800e4 */ lwc1 $f8,0xe4($sp) +/* f070094: 46069081 */ sub.s $f2,$f18,$f6 +/* f070098: 46000102 */ mul.s $f4,$f0,$f0 +/* f07009c: afa70130 */ sw $a3,0x130($sp) +/* f0700a0: 46088381 */ sub.s $f14,$f16,$f8 +/* f0700a4: 46021282 */ mul.s $f10,$f2,$f2 +/* f0700a8: 460a2180 */ add.s $f6,$f4,$f10 +/* f0700ac: 460e7202 */ mul.s $f8,$f14,$f14 +/* f0700b0: 0c012e84 */ jal sqrtf +/* f0700b4: 46083300 */ add.s $f12,$f6,$f8 +/* f0700b8: 8fa70130 */ lw $a3,0x130($sp) +/* f0700bc: c4e40074 */ lwc1 $f4,0x74($a3) +/* f0700c0: c4e60078 */ lwc1 $f6,0x78($a3) +/* f0700c4: 80ef0086 */ lb $t7,0x86($a3) +/* f0700c8: 46040281 */ sub.s $f10,$f0,$f4 +/* f0700cc: a0ef0085 */ sb $t7,0x85($a3) +/* f0700d0: 46003207 */ neg.s $f8,$f6 +/* f0700d4: e4ea0074 */ swc1 $f10,0x74($a3) +/* f0700d8: e4e80078 */ swc1 $f8,0x78($a3) +/* f0700dc: 8fb80134 */ lw $t8,0x134($sp) +/* f0700e0: a0f80086 */ sb $t8,0x86($a3) +.NB0f0700e4: +/* f0700e4: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f0700e8: +/* f0700e8: 27bd0130 */ addiu $sp,$sp,0x130 +/* f0700ec: 03e00008 */ jr $ra +/* f0700f0: 00000000 */ sll $zero,$zero,0x0 +); +#endif f32 objGetHov04(struct defaultobj *obj) { @@ -18488,7 +19895,7 @@ glabel var7f1aa320 /* f072ad4: 03e00008 */ jr $ra /* f072ad8: 27bd00a0 */ addiu $sp,$sp,0xa0 ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f0727d4 .late_rodata @@ -18694,6 +20101,212 @@ glabel var7f1aa320 /* f072ad4: 03e00008 */ jr $ra /* f072ad8: 27bd00a0 */ addiu $sp,$sp,0xa0 ); +#else +GLOBAL_ASM( +glabel func0f0727d4 +.late_rodata +glabel var7f1aa320 +.word 0x3dcccccd +.text +/* f0727d4: 27bdff60 */ addiu $sp,$sp,-160 +/* f0727d8: 3c013f80 */ lui $at,0x3f80 +/* f0727dc: 44812000 */ mtc1 $at,$f4 +/* f0727e0: afbf0024 */ sw $ra,0x24($sp) +/* f0727e4: afb00020 */ sw $s0,0x20($sp) +/* f0727e8: 00808025 */ or $s0,$a0,$zero +/* f0727ec: afa500a4 */ sw $a1,0xa4($sp) +/* f0727f0: afa600a8 */ sw $a2,0xa8($sp) +/* f0727f4: 0c0093ac */ jal cdGetObstacle +/* f0727f8: e7a4009c */ swc1 $f4,0x9c($sp) +/* f0727fc: 104000b2 */ beqz $v0,.L0f072ac8 +/* f072800: 8faa00a4 */ lw $t2,0xa4($sp) +/* f072804: 3c09800a */ lui $t1,%hi(g_Vars) +/* f072808: 25299fc0 */ addiu $t1,$t1,%lo(g_Vars) +/* f07280c: 8d2e0034 */ lw $t6,0x34($t1) +/* f072810: 59c000ae */ blezl $t6,.L0f072acc +/* f072814: 8fbf0024 */ lw $ra,0x24($sp) +/* f072818: 90430000 */ lbu $v1,0x0($v0) +/* f07281c: 24010003 */ addiu $at,$zero,0x3 +/* f072820: 106100a9 */ beq $v1,$at,.L0f072ac8 +/* f072824: 24010006 */ addiu $at,$zero,0x6 +/* f072828: 106100a7 */ beq $v1,$at,.L0f072ac8 +/* f07282c: 24010001 */ addiu $at,$zero,0x1 +/* f072830: 546100a6 */ bnel $v1,$at,.L0f072acc +/* f072834: 8fbf0024 */ lw $ra,0x24($sp) +/* f072838: 8c440004 */ lw $a0,0x4($v0) +/* f07283c: 8c830040 */ lw $v1,0x40($a0) +/* f072840: 00037940 */ sll $t7,$v1,0x5 +/* f072844: 05e000a0 */ bltz $t7,.L0f072ac8 +/* f072848: 0003c100 */ sll $t8,$v1,0x4 +/* f07284c: 0702009f */ bltzl $t8,.L0f072acc +/* f072850: 8fbf0024 */ lw $ra,0x24($sp) +/* f072854: 8c990010 */ lw $t9,0x10($a0) +/* f072858: 3c0c8007 */ lui $t4,%hi(var80069b74) +/* f07285c: 3c013f00 */ lui $at,0x3f00 +/* f072860: 332b0001 */ andi $t3,$t9,0x1 +/* f072864: 11600098 */ beqz $t3,.L0f072ac8 +/* f072868: 258c9b74 */ addiu $t4,$t4,%lo(var80069b74) +/* f07286c: 44816000 */ mtc1 $at,$f12 +/* f072870: 8d810000 */ lw $at,0x0($t4) +/* f072874: 27a5007c */ addiu $a1,$sp,0x7c +/* f072878: c520004c */ lwc1 $f0,0x4c($t1) +/* f07287c: aca10000 */ sw $at,0x0($a1) +/* f072880: 8d8e0004 */ lw $t6,0x4($t4) +/* f072884: 44801000 */ mtc1 $zero,$f2 +/* f072888: 240f0001 */ addiu $t7,$zero,0x1 +/* f07288c: acae0004 */ sw $t6,0x4($a1) +/* f072890: 8d810008 */ lw $at,0x8($t4) +/* f072894: 44061000 */ mfc1 $a2,$f2 +/* f072898: 24070001 */ addiu $a3,$zero,0x1 +/* f07289c: aca10008 */ sw $at,0x8($a1) +/* f0728a0: c5460000 */ lwc1 $f6,0x0($t2) +/* f0728a4: e7a20080 */ swc1 $f2,0x80($sp) +/* f0728a8: 460c3202 */ mul.s $f8,$f6,$f12 +/* f0728ac: 46004283 */ div.s $f10,$f8,$f0 +/* f0728b0: e7aa007c */ swc1 $f10,0x7c($sp) +/* f0728b4: c5440008 */ lwc1 $f4,0x8($t2) +/* f0728b8: afa20098 */ sw $v0,0x98($sp) +/* f0728bc: afa40094 */ sw $a0,0x94($sp) +/* f0728c0: 460c2182 */ mul.s $f6,$f4,$f12 +/* f0728c4: afaf0010 */ sw $t7,0x10($sp) +/* f0728c8: 46003203 */ div.s $f8,$f6,$f0 +/* f0728cc: 0fc20a87 */ jal func0f082a1c +/* f0728d0: e7a80084 */ swc1 $f8,0x84($sp) +/* f0728d4: 3c077f1b */ lui $a3,%hi(var7f1a9fac) +/* f0728d8: 24e79fac */ addiu $a3,$a3,%lo(var7f1a9fac) +/* f0728dc: 27a40070 */ addiu $a0,$sp,0x70 +/* f0728e0: 27a50064 */ addiu $a1,$sp,0x64 +/* f0728e4: 0c009393 */ jal cd00024e4c +/* f0728e8: 24061cbb */ addiu $a2,$zero,0x1c8c +/* f0728ec: 27a40058 */ addiu $a0,$sp,0x58 +/* f0728f0: 0c0094d9 */ jal cd00025364 +/* f0728f4: 27a5004c */ addiu $a1,$sp,0x4c +/* f0728f8: 1040000e */ beqz $v0,.L0f072934 +/* f0728fc: 8fa80098 */ lw $t0,0x98($sp) +/* f072900: c7aa004c */ lwc1 $f10,0x4c($sp) +/* f072904: c7a40058 */ lwc1 $f4,0x58($sp) +/* f072908: c7a80050 */ lwc1 $f8,0x50($sp) +/* f07290c: 46045181 */ sub.s $f6,$f10,$f4 +/* f072910: c7aa005c */ lwc1 $f10,0x5c($sp) +/* f072914: 460a4101 */ sub.s $f4,$f8,$f10 +/* f072918: e7a6004c */ swc1 $f6,0x4c($sp) +/* f07291c: c7a60054 */ lwc1 $f6,0x54($sp) +/* f072920: c7a80060 */ lwc1 $f8,0x60($sp) +/* f072924: e7a40050 */ swc1 $f4,0x50($sp) +/* f072928: 46083281 */ sub.s $f10,$f6,$f8 +/* f07292c: 10000019 */ b .L0f072994 +/* f072930: e7aa0054 */ swc1 $f10,0x54($sp) +.L0f072934: +/* f072934: 8e180014 */ lw $t8,0x14($s0) +/* f072938: c7040008 */ lwc1 $f4,0x8($t8) +/* f07293c: e7a40058 */ swc1 $f4,0x58($sp) +/* f072940: 8e190014 */ lw $t9,0x14($s0) +/* f072944: c726000c */ lwc1 $f6,0xc($t9) +/* f072948: e7a6005c */ swc1 $f6,0x5c($sp) +/* f07294c: 8e0b0014 */ lw $t3,0x14($s0) +/* f072950: c5680010 */ lwc1 $f8,0x10($t3) +/* f072954: e7a80060 */ swc1 $f8,0x60($sp) +/* f072958: 8e0d0014 */ lw $t5,0x14($s0) +/* f07295c: c50a0008 */ lwc1 $f10,0x8($t0) +/* f072960: c5a40008 */ lwc1 $f4,0x8($t5) +/* f072964: 46045181 */ sub.s $f6,$f10,$f4 +/* f072968: e7a6004c */ swc1 $f6,0x4c($sp) +/* f07296c: 8e0c0014 */ lw $t4,0x14($s0) +/* f072970: c508000c */ lwc1 $f8,0xc($t0) +/* f072974: c58a000c */ lwc1 $f10,0xc($t4) +/* f072978: 460a4101 */ sub.s $f4,$f8,$f10 +/* f07297c: e7a40050 */ swc1 $f4,0x50($sp) +/* f072980: 8e0e0014 */ lw $t6,0x14($s0) +/* f072984: c5060010 */ lwc1 $f6,0x10($t0) +/* f072988: c5c80010 */ lwc1 $f8,0x10($t6) +/* f07298c: 46083281 */ sub.s $f10,$f6,$f8 +/* f072990: e7aa0054 */ swc1 $f10,0x54($sp) +.L0f072994: +/* f072994: 27af0088 */ addiu $t7,$sp,0x88 +/* f072998: afaf0010 */ sw $t7,0x10($sp) +/* f07299c: 27a40070 */ addiu $a0,$sp,0x70 +/* f0729a0: 27a50064 */ addiu $a1,$sp,0x64 +/* f0729a4: 27a60058 */ addiu $a2,$sp,0x58 +/* f0729a8: 0fc0b8f7 */ jal func0f02e3dc +/* f0729ac: 27a7004c */ addiu $a3,$sp,0x4c +/* f0729b0: 44800000 */ mtc1 $zero,$f0 +/* f0729b4: c7a600a8 */ lwc1 $f6,0xa8($sp) +/* f0729b8: 3c013f00 */ lui $at,0x3f00 +/* f0729bc: 44812000 */ mtc1 $at,$f4 +/* f0729c0: 46003032 */ c.eq.s $f6,$f0 +/* f0729c4: c7a80088 */ lwc1 $f8,0x88($sp) +/* f0729c8: e7a4009c */ swc1 $f4,0x9c($sp) +/* f0729cc: c7a40090 */ lwc1 $f4,0x90($sp) +/* f0729d0: 4503003e */ bc1tl .L0f072acc +/* f0729d4: 8fbf0024 */ lw $ra,0x24($sp) +/* f0729d8: 8e020014 */ lw $v0,0x14($s0) +/* f0729dc: 3c198007 */ lui $t9,%hi(var80069b80) +/* f0729e0: 27399b80 */ addiu $t9,$t9,%lo(var80069b80) +/* f0729e4: c44a0008 */ lwc1 $f10,0x8($v0) +/* f0729e8: c4460010 */ lwc1 $f6,0x10($v0) +/* f0729ec: 8f210000 */ lw $at,0x0($t9) +/* f0729f0: 460a4081 */ sub.s $f2,$f8,$f10 +/* f0729f4: 27b80034 */ addiu $t8,$sp,0x34 +/* f0729f8: af010000 */ sw $at,0x0($t8) +/* f0729fc: 46062381 */ sub.s $f14,$f4,$f6 +/* f072a00: 46021202 */ mul.s $f8,$f2,$f2 +/* f072a04: 8f210008 */ lw $at,0x8($t9) +/* f072a08: 8f2d0004 */ lw $t5,0x4($t9) +/* f072a0c: 460e7282 */ mul.s $f10,$f14,$f14 +/* f072a10: af010008 */ sw $at,0x8($t8) +/* f072a14: af0d0004 */ sw $t5,0x4($t8) +/* f072a18: e7ae0044 */ swc1 $f14,0x44($sp) +/* f072a1c: e7a20048 */ swc1 $f2,0x48($sp) +/* f072a20: 0c012974 */ jal sqrtf +/* f072a24: 460a4300 */ add.s $f12,$f8,$f10 +/* f072a28: 3c014120 */ lui $at,0x4120 +/* f072a2c: 44819000 */ mtc1 $at,$f18 +/* f072a30: 3c013f80 */ lui $at,0x3f80 +/* f072a34: 44812000 */ mtc1 $at,$f4 +/* f072a38: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f072a3c: c428a00c */ lwc1 $f8,%lo(g_Vars+0x4c)($at) +/* f072a40: 46002303 */ div.s $f12,$f4,$f0 +/* f072a44: c7a600a8 */ lwc1 $f6,0xa8($sp) +/* f072a48: c7a20048 */ lwc1 $f2,0x48($sp) +/* f072a4c: c7ae0044 */ lwc1 $f14,0x44($sp) +/* f072a50: 3c017f1b */ lui $at,%hi(var7f1aa320) +/* f072a54: 240c0001 */ addiu $t4,$zero,0x1 +/* f072a58: afac0010 */ sw $t4,0x10($sp) +/* f072a5c: 8fa40094 */ lw $a0,0x94($sp) +/* f072a60: 27a50034 */ addiu $a1,$sp,0x34 +/* f072a64: 24070001 */ addiu $a3,$zero,0x1 +/* f072a68: 46083283 */ div.s $f10,$f6,$f8 +/* f072a6c: 460c1082 */ mul.s $f2,$f2,$f12 +/* f072a70: 00000000 */ nop +/* f072a74: 460c7382 */ mul.s $f14,$f14,$f12 +/* f072a78: 46007107 */ neg.s $f4,$f14 +/* f072a7c: e7aa00a8 */ swc1 $f10,0xa8($sp) +/* f072a80: 460a2182 */ mul.s $f6,$f4,$f10 +/* f072a84: c7a40034 */ lwc1 $f4,0x34($sp) +/* f072a88: 46123202 */ mul.s $f8,$f6,$f18 +/* f072a8c: 46082180 */ add.s $f6,$f4,$f8 +/* f072a90: 460a1102 */ mul.s $f4,$f2,$f10 +/* f072a94: e7a60034 */ swc1 $f6,0x34($sp) +/* f072a98: c7a6003c */ lwc1 $f6,0x3c($sp) +/* f072a9c: 46122202 */ mul.s $f8,$f4,$f18 +/* f072aa0: 46083100 */ add.s $f4,$f6,$f8 +/* f072aa4: c426a320 */ lwc1 $f6,%lo(var7f1aa320)($at) +/* f072aa8: 46065202 */ mul.s $f8,$f10,$f6 +/* f072aac: e7a4003c */ swc1 $f4,0x3c($sp) +/* f072ab0: 44802000 */ mtc1 $zero,$f4 +/* f072ab4: 00000000 */ nop +/* f072ab8: 46082400 */ add.s $f16,$f4,$f8 +/* f072abc: 44068000 */ mfc1 $a2,$f16 +/* f072ac0: 0fc20a87 */ jal func0f082a1c +/* f072ac4: 00000000 */ nop +.L0f072ac8: +/* f072ac8: 8fbf0024 */ lw $ra,0x24($sp) +.L0f072acc: +/* f072acc: c7a0009c */ lwc1 $f0,0x9c($sp) +/* f072ad0: 8fb00020 */ lw $s0,0x20($sp) +/* f072ad4: 03e00008 */ jr $ra +/* f072ad8: 27bd00a0 */ addiu $sp,$sp,0xa0 +); #endif #if VERSION >= VERSION_PAL_FINAL @@ -20958,6 +22571,7 @@ glabel var7f1aa3d0 ); #endif +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f073ae8 /* f073ae8: 27bdffa0 */ addiu $sp,$sp,-96 @@ -21063,6 +22677,113 @@ glabel func0f073ae8 /* f073c64: 03e00008 */ jr $ra /* f073c68: 27bd0060 */ addiu $sp,$sp,0x60 ); +#else +GLOBAL_ASM( +glabel func0f073ae8 +/* f073ae8: 27bdffa0 */ addiu $sp,$sp,-96 +/* f073aec: afbf0024 */ sw $ra,0x24($sp) +/* f073af0: afb30020 */ sw $s3,0x20($sp) +/* f073af4: afb2001c */ sw $s2,0x1c($sp) +/* f073af8: afb10018 */ sw $s1,0x18($sp) +/* f073afc: afb00014 */ sw $s0,0x14($sp) +/* f073b00: afa60068 */ sw $a2,0x68($sp) +/* f073b04: afa7006c */ sw $a3,0x6c($sp) +/* f073b08: 8cb00088 */ lw $s0,0x88($a1) +/* f073b0c: 00809025 */ or $s2,$a0,$zero +/* f073b10: 00a09825 */ or $s3,$a1,$zero +/* f073b14: 12000004 */ beqz $s0,.L0f073b28 +/* f073b18: 8c910014 */ lw $s1,0x14($a0) +/* f073b1c: 02002025 */ or $a0,$s0,$zero +/* f073b20: 0fc1905e */ jal propSetCollisionsEnabled +/* f073b24: 00002825 */ or $a1,$zero,$zero +.L0f073b28: +/* f073b28: 266500c4 */ addiu $a1,$s3,0xc4 +/* f073b2c: afa5002c */ sw $a1,0x2c($sp) +/* f073b30: 02402025 */ or $a0,$s2,$zero +/* f073b34: 8fa60068 */ lw $a2,0x68($sp) +/* f073b38: 0fc1b340 */ jal func0f06cd00 +/* f073b3c: 8fa7006c */ lw $a3,0x6c($sp) +/* f073b40: afa2005c */ sw $v0,0x5c($sp) +/* f073b44: 8e700088 */ lw $s0,0x88($s3) +/* f073b48: 12000003 */ beqz $s0,.L0f073b58 +/* f073b4c: 02002025 */ or $a0,$s0,$zero +/* f073b50: 0fc1905e */ jal propSetCollisionsEnabled +/* f073b54: 24050001 */ addiu $a1,$zero,0x1 +.L0f073b58: +/* f073b58: 8fae005c */ lw $t6,0x5c($sp) +/* f073b5c: 24020001 */ addiu $v0,$zero,0x1 +/* f073b60: 26240008 */ addiu $a0,$s1,0x8 +/* f073b64: 15c20014 */ bne $t6,$v0,.L0f073bb8 +/* f073b68: 8faf005c */ lw $t7,0x5c($sp) +/* f073b6c: 27b20048 */ addiu $s2,$sp,0x48 +/* f073b70: 26300028 */ addiu $s0,$s1,0x28 +/* f073b74: 02002825 */ or $a1,$s0,$zero +/* f073b78: 02403825 */ or $a3,$s2,$zero +/* f073b7c: 0fc1979d */ jal func0f065e74 +/* f073b80: 8fa6002c */ lw $a2,0x2c($sp) +/* f073b84: c66400c4 */ lwc1 $f4,0xc4($s3) +/* f073b88: 02202025 */ or $a0,$s1,$zero +/* f073b8c: e6240008 */ swc1 $f4,0x8($s1) +/* f073b90: c66600c8 */ lwc1 $f6,0xc8($s3) +/* f073b94: e626000c */ swc1 $f6,0xc($s1) +/* f073b98: c66800cc */ lwc1 $f8,0xcc($s3) +/* f073b9c: 0fc19711 */ jal propDeregisterRooms +/* f073ba0: e6280010 */ swc1 $f8,0x10($s1) +/* f073ba4: 02402025 */ or $a0,$s2,$zero +/* f073ba8: 0fc195e9 */ jal roomsCopy +/* f073bac: 02002825 */ or $a1,$s0,$zero +/* f073bb0: 10000023 */ b .L0f073c40 +/* f073bb4: 8e6a0000 */ lw $t2,0x0($s3) +.L0f073bb8: +/* f073bb8: 51e20021 */ beql $t7,$v0,.L0f073c40 +/* f073bbc: 8e6a0000 */ lw $t2,0x0($s3) +/* f073bc0: 92580003 */ lbu $t8,0x3($s2) +/* f073bc4: 24010008 */ addiu $at,$zero,0x8 +/* f073bc8: 5701001d */ bnel $t8,$at,.L0f073c40 +/* f073bcc: 8e6a0000 */ lw $t2,0x0($s3) +/* f073bd0: 9242005c */ lbu $v0,0x5c($s2) +/* f073bd4: 24010053 */ addiu $at,$zero,0x52 +/* f073bd8: 26240008 */ addiu $a0,$s1,0x8 +/* f073bdc: 10410004 */ beq $v0,$at,.L0f073bf0 +/* f073be0: 26300028 */ addiu $s0,$s1,0x28 +/* f073be4: 24010054 */ addiu $at,$zero,0x53 +/* f073be8: 54410015 */ bnel $v0,$at,.L0f073c40 +/* f073bec: 8e6a0000 */ lw $t2,0x0($s3) +.L0f073bf0: +/* f073bf0: a6400062 */ sh $zero,0x62($s2) +/* f073bf4: 8fa60068 */ lw $a2,0x68($sp) +/* f073bf8: 02002825 */ or $a1,$s0,$zero +/* f073bfc: 0fc1979d */ jal func0f065e74 +/* f073c00: 27a70034 */ addiu $a3,$sp,0x34 +/* f073c04: 8fb90068 */ lw $t9,0x68($sp) +/* f073c08: 02202025 */ or $a0,$s1,$zero +/* f073c0c: c72a0000 */ lwc1 $f10,0x0($t9) +/* f073c10: e62a0008 */ swc1 $f10,0x8($s1) +/* f073c14: 8fa80068 */ lw $t0,0x68($sp) +/* f073c18: c5100004 */ lwc1 $f16,0x4($t0) +/* f073c1c: e630000c */ swc1 $f16,0xc($s1) +/* f073c20: 8fa90068 */ lw $t1,0x68($sp) +/* f073c24: c5320008 */ lwc1 $f18,0x8($t1) +/* f073c28: 0fc19711 */ jal propDeregisterRooms +/* f073c2c: e6320010 */ swc1 $f18,0x10($s1) +/* f073c30: 27a40034 */ addiu $a0,$sp,0x34 +/* f073c34: 0fc195e9 */ jal roomsCopy +/* f073c38: 02002825 */ or $a1,$s0,$zero +/* f073c3c: 8e6a0000 */ lw $t2,0x0($s3) +.L0f073c40: +/* f073c40: 2401ff7f */ addiu $at,$zero,-129 +/* f073c44: 01415824 */ and $t3,$t2,$at +/* f073c48: ae6b0000 */ sw $t3,0x0($s3) +/* f073c4c: 8fbf0024 */ lw $ra,0x24($sp) +/* f073c50: 8fb30020 */ lw $s3,0x20($sp) +/* f073c54: 8fb2001c */ lw $s2,0x1c($sp) +/* f073c58: 8fb10018 */ lw $s1,0x18($sp) +/* f073c5c: 8fb00014 */ lw $s0,0x14($sp) +/* f073c60: 8fa2005c */ lw $v0,0x5c($sp) +/* f073c64: 03e00008 */ jr $ra +/* f073c68: 27bd0060 */ addiu $sp,$sp,0x60 +); +#endif #if VERSION >= VERSION_PAL_FINAL GLOBAL_ASM( @@ -37138,7 +38859,7 @@ glabel var7f1aa5a8 /* f07acc4: 03e00008 */ jr $ra /* f07acc8: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f079f1c .late_rodata @@ -38100,6 +39821,968 @@ glabel var7f1aa5a8 /* f07acc4: 03e00008 */ jr $ra /* f07acc8: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f079f1c +.late_rodata +glabel var7f1aa58c +.word 0x3e23d70a +glabel var7f1aa590 +.word 0x461c4000 +glabel var7f1aa594 +.word 0x453b8000 +glabel var7f1aa598 +.word 0x3f19999a +glabel var7f1aa59c +.word 0x3e99999a +glabel var7f1aa5a0 +.word 0xbdcccccd +glabel var7f1aa5a4 +.word 0x453b8000 +glabel var7f1aa5a8 +.word 0x3e4ccccd +.text +/* f079f1c: 27bdfe68 */ addiu $sp,$sp,-408 +/* f079f20: afbf0044 */ sw $ra,0x44($sp) +/* f079f24: 0fc5b364 */ jal lvIsPaused +/* f079f28: afa40198 */ sw $a0,0x198($sp) +/* f079f2c: 14400363 */ bnez $v0,.L0f07acbc +/* f079f30: 8fae0198 */ lw $t6,0x198($sp) +/* f079f34: 8dc20004 */ lw $v0,0x4($t6) +/* f079f38: afa0018c */ sw $zero,0x18c($sp) +/* f079f3c: afa00188 */ sw $zero,0x188($sp) +/* f079f40: 8c4f0018 */ lw $t7,0x18($v0) +/* f079f44: afa00174 */ sw $zero,0x174($sp) +/* f079f48: afaf0184 */ sw $t7,0x184($sp) +/* f079f4c: 8058005e */ lb $t8,0x5e($v0) +/* f079f50: 53000347 */ beqzl $t8,.L0f07ac70 +/* f079f54: 8fad0184 */ lw $t5,0x184($sp) +/* f079f58: 8c590008 */ lw $t9,0x8($v0) +/* f079f5c: 001940c0 */ sll $t0,$t9,0x3 +/* f079f60: 05020343 */ bltzl $t0,.L0f07ac70 +/* f079f64: 8fad0184 */ lw $t5,0x184($sp) +/* f079f68: 9049005f */ lbu $t1,0x5f($v0) +/* f079f6c: 24050005 */ addiu $a1,$zero,0x5 +/* f079f70: 252b0001 */ addiu $t3,$t1,0x1 +/* f079f74: a04b005f */ sb $t3,0x5f($v0) +/* f079f78: 8fae0184 */ lw $t6,0x184($sp) +/* f079f7c: 316c0001 */ andi $t4,$t3,0x1 +/* f079f80: 2d8d0001 */ sltiu $t5,$t4,0x1 +/* f079f84: afad018c */ sw $t5,0x18c($sp) +/* f079f88: 8dc40008 */ lw $a0,0x8($t6) +/* f079f8c: afa20194 */ sw $v0,0x194($sp) +/* f079f90: 0c006a47 */ jal modelGetPart +/* f079f94: afa20190 */ sw $v0,0x190($sp) +/* f079f98: 1040000b */ beqz $v0,.L0f079fc8 +/* f079f9c: 8fa30190 */ lw $v1,0x190($sp) +/* f079fa0: 8faf0194 */ lw $t7,0x194($sp) +/* f079fa4: 91f8005f */ lbu $t8,0x5f($t7) +/* f079fa8: 07010004 */ bgez $t8,.L0f079fbc +/* f079fac: 33190001 */ andi $t9,$t8,0x1 +/* f079fb0: 13200002 */ beqz $t9,.L0f079fbc +/* f079fb4: 00000000 */ nop +/* f079fb8: 2739fffe */ addiu $t9,$t9,-2 +.L0f079fbc: +/* f079fbc: 3b280001 */ xori $t0,$t9,0x1 +/* f079fc0: 2d080001 */ sltiu $t0,$t0,0x1 +/* f079fc4: afa80188 */ sw $t0,0x188($sp) +.L0f079fc8: +/* f079fc8: 8fa9018c */ lw $t1,0x18c($sp) +/* f079fcc: 8faa0188 */ lw $t2,0x188($sp) +/* f079fd0: 55200004 */ bnezl $t1,.L0f079fe4 +/* f079fd4: 8fab0194 */ lw $t3,0x194($sp) +/* f079fd8: 514002f0 */ beqzl $t2,.L0f07ab9c +/* f079fdc: 8fa80194 */ lw $t0,0x194($sp) +/* f079fe0: 8fab0194 */ lw $t3,0x194($sp) +.L0f079fe4: +/* f079fe4: afa00148 */ sw $zero,0x148($sp) +/* f079fe8: 3c188007 */ lui $t8,%hi(var80069cb8) +/* f079fec: 916c005f */ lbu $t4,0x5f($t3) +/* f079ff0: 8f189cb8 */ lw $t8,%lo(var80069cb8)($t8) +/* f079ff4: 3c09800a */ lui $t1,%hi(g_Vars+0x318) +/* f079ff8: 318d0003 */ andi $t5,$t4,0x3 +/* f079ffc: 2dae0001 */ sltiu $t6,$t5,0x1 +/* f07a000: afae0128 */ sw $t6,0x128($sp) +/* f07a004: 8d6f00a4 */ lw $t7,0xa4($t3) +/* f07a008: afa0011c */ sw $zero,0x11c($sp) +/* f07a00c: afa00114 */ sw $zero,0x114($sp) +/* f07a010: afa00110 */ sw $zero,0x110($sp) +/* f07a014: afb80118 */ sw $t8,0x118($sp) +/* f07a018: afaf0124 */ sw $t7,0x124($sp) +/* f07a01c: 8c640040 */ lw $a0,0x40($v1) +/* f07a020: 8d29a2d8 */ lw $t1,%lo(g_Vars+0x318)($t1) +/* f07a024: 3c01f000 */ lui $at,0xf000 +/* f07a028: 0081c824 */ and $t9,$a0,$at +/* f07a02c: 11200007 */ beqz $t1,.L0f07a04c +/* f07a030: 00192702 */ srl $a0,$t9,0x1c +/* f07a034: 0fc63410 */ jal mpGetChrFromPlayerIndex +/* f07a038: 00000000 */ nop +/* f07a03c: 10400003 */ beqz $v0,.L0f07a04c +/* f07a040: afa20110 */ sw $v0,0x110($sp) +/* f07a044: 8c4a001c */ lw $t2,0x1c($v0) +/* f07a048: afaa0114 */ sw $t2,0x114($sp) +.L0f07a04c: +/* f07a04c: 8fac0194 */ lw $t4,0x194($sp) +/* f07a050: 918d005f */ lbu $t5,0x5f($t4) +/* f07a054: 31ae0007 */ andi $t6,$t5,0x7 +/* f07a058: 55c00008 */ bnezl $t6,.L0f07a07c +/* f07a05c: 8faf0184 */ lw $t7,0x184($sp) +/* f07a060: 8fab0184 */ lw $t3,0x184($sp) +/* f07a064: 24050007 */ addiu $a1,$zero,0x7 +/* f07a068: 0c006a47 */ jal modelGetPart +/* f07a06c: 8d640008 */ lw $a0,0x8($t3) +/* f07a070: 14400006 */ bnez $v0,.L0f07a08c +/* f07a074: 00403825 */ or $a3,$v0,$zero +/* f07a078: 8faf0184 */ lw $t7,0x184($sp) +.L0f07a07c: +/* f07a07c: 24050005 */ addiu $a1,$zero,0x5 +/* f07a080: 0c006a47 */ jal modelGetPart +/* f07a084: 8de40008 */ lw $a0,0x8($t7) +/* f07a088: 00403825 */ or $a3,$v0,$zero +.L0f07a08c: +/* f07a08c: 54400009 */ bnezl $v0,.L0f07a0b4 +/* f07a090: 8fa40198 */ lw $a0,0x198($sp) +/* f07a094: 8fb80184 */ lw $t8,0x184($sp) +/* f07a098: 24050003 */ addiu $a1,$zero,0x3 +/* f07a09c: 8f040008 */ lw $a0,0x8($t8) +/* f07a0a0: 0c006a47 */ jal modelGetPart +/* f07a0a4: afa70120 */ sw $a3,0x120($sp) +/* f07a0a8: 8fa70120 */ lw $a3,0x120($sp) +/* f07a0ac: afa2011c */ sw $v0,0x11c($sp) +/* f07a0b0: 8fa40198 */ lw $a0,0x198($sp) +.L0f07a0b4: +/* f07a0b4: 00002825 */ or $a1,$zero,$zero +/* f07a0b8: 0fc1905e */ jal propSetCollisionsEnabled +/* f07a0bc: afa70120 */ sw $a3,0x120($sp) +/* f07a0c0: 8fa20198 */ lw $v0,0x198($sp) +/* f07a0c4: 8fa70120 */ lw $a3,0x120($sp) +/* f07a0c8: 90590001 */ lbu $t9,0x1($v0) +/* f07a0cc: 33280002 */ andi $t0,$t9,0x2 +/* f07a0d0: 51000042 */ beqzl $t0,.L0f07a1dc +/* f07a0d4: c44a0008 */ lwc1 $f10,0x8($v0) +/* f07a0d8: 14e00003 */ bnez $a3,.L0f07a0e8 +/* f07a0dc: 8fa9011c */ lw $t1,0x11c($sp) +/* f07a0e0: 5120003e */ beqzl $t1,.L0f07a1dc +/* f07a0e4: c44a0008 */ lwc1 $f10,0x8($v0) +.L0f07a0e8: +/* f07a0e8: 10e00010 */ beqz $a3,.L0f07a12c +/* f07a0ec: 8fa40184 */ lw $a0,0x184($sp) +/* f07a0f0: 8fa40184 */ lw $a0,0x184($sp) +/* f07a0f4: 00e02825 */ or $a1,$a3,$zero +/* f07a0f8: 00003025 */ or $a2,$zero,$zero +/* f07a0fc: 0c006973 */ jal model0001a5cc +/* f07a100: afa70120 */ sw $a3,0x120($sp) +/* f07a104: 8fa70120 */ lw $a3,0x120($sp) +/* f07a108: 00402825 */ or $a1,$v0,$zero +/* f07a10c: 8ce30004 */ lw $v1,0x4($a3) +/* f07a110: c4640000 */ lwc1 $f4,0x0($v1) +/* f07a114: e7a40168 */ swc1 $f4,0x168($sp) +/* f07a118: c4660004 */ lwc1 $f6,0x4($v1) +/* f07a11c: e7a6016c */ swc1 $f6,0x16c($sp) +/* f07a120: c4680008 */ lwc1 $f8,0x8($v1) +/* f07a124: 1000000b */ b .L0f07a154 +/* f07a128: e7a80170 */ swc1 $f8,0x170($sp) +.L0f07a12c: +/* f07a12c: 8fa5011c */ lw $a1,0x11c($sp) +/* f07a130: 0c006973 */ jal model0001a5cc +/* f07a134: 00003025 */ or $a2,$zero,$zero +/* f07a138: 44805000 */ mtc1 $zero,$f10 +/* f07a13c: 44808000 */ mtc1 $zero,$f16 +/* f07a140: 44809000 */ mtc1 $zero,$f18 +/* f07a144: 00402825 */ or $a1,$v0,$zero +/* f07a148: e7aa0168 */ swc1 $f10,0x168($sp) +/* f07a14c: e7b0016c */ swc1 $f16,0x16c($sp) +/* f07a150: e7b20170 */ swc1 $f18,0x170($sp) +.L0f07a154: +/* f07a154: 0fc2d5de */ jal currentPlayerGetUnk174c +/* f07a158: afa50108 */ sw $a1,0x108($sp) +/* f07a15c: 8fa50108 */ lw $a1,0x108($sp) +/* f07a160: 00402025 */ or $a0,$v0,$zero +/* f07a164: 0c0056f9 */ jal mtx00015be4 +/* f07a168: 27a600c8 */ addiu $a2,$sp,0xc8 +/* f07a16c: 27a400c8 */ addiu $a0,$sp,0xc8 +/* f07a170: 0c0056d9 */ jal mtx00015b64 +/* f07a174: 27a50168 */ addiu $a1,$sp,0x168 +/* f07a178: 8fa20198 */ lw $v0,0x198($sp) +/* f07a17c: 240a0020 */ addiu $t2,$zero,0x20 +/* f07a180: 240c0010 */ addiu $t4,$zero,0x10 +/* f07a184: 24450028 */ addiu $a1,$v0,0x28 +/* f07a188: afa5004c */ sw $a1,0x4c($sp) +/* f07a18c: afac0014 */ sw $t4,0x14($sp) +/* f07a190: afaa0010 */ sw $t2,0x10($sp) +/* f07a194: 27a60168 */ addiu $a2,$sp,0x168 +/* f07a198: 27a70158 */ addiu $a3,$sp,0x158 +/* f07a19c: 0c00b78d */ jal cd0002de34 +/* f07a1a0: 24440008 */ addiu $a0,$v0,0x8 +/* f07a1a4: 14400015 */ bnez $v0,.L0f07a1fc +/* f07a1a8: 8fad0198 */ lw $t5,0x198($sp) +/* f07a1ac: c5a40008 */ lwc1 $f4,0x8($t5) +/* f07a1b0: 8fa4004c */ lw $a0,0x4c($sp) +/* f07a1b4: 27a50158 */ addiu $a1,$sp,0x158 +/* f07a1b8: e7a40168 */ swc1 $f4,0x168($sp) +/* f07a1bc: c5a6000c */ lwc1 $f6,0xc($t5) +/* f07a1c0: e7a6016c */ swc1 $f6,0x16c($sp) +/* f07a1c4: c5a80010 */ lwc1 $f8,0x10($t5) +/* f07a1c8: 0fc195e9 */ jal roomsCopy +/* f07a1cc: e7a80170 */ swc1 $f8,0x170($sp) +/* f07a1d0: 1000000b */ b .L0f07a200 +/* f07a1d4: 8fae0194 */ lw $t6,0x194($sp) +/* f07a1d8: c44a0008 */ lwc1 $f10,0x8($v0) +.L0f07a1dc: +/* f07a1dc: 24440028 */ addiu $a0,$v0,0x28 +/* f07a1e0: 27a50158 */ addiu $a1,$sp,0x158 +/* f07a1e4: e7aa0168 */ swc1 $f10,0x168($sp) +/* f07a1e8: c450000c */ lwc1 $f16,0xc($v0) +/* f07a1ec: e7b0016c */ swc1 $f16,0x16c($sp) +/* f07a1f0: c4520010 */ lwc1 $f18,0x10($v0) +/* f07a1f4: 0fc195e9 */ jal roomsCopy +/* f07a1f8: e7b20170 */ swc1 $f18,0x170($sp) +.L0f07a1fc: +/* f07a1fc: 8fae0194 */ lw $t6,0x194($sp) +.L0f07a200: +/* f07a200: 0c0068f4 */ jal cosf +/* f07a204: c5cc0078 */ lwc1 $f12,0x78($t6) +/* f07a208: 8fab0194 */ lw $t3,0x194($sp) +/* f07a20c: e7a00050 */ swc1 $f0,0x50($sp) +/* f07a210: 0c0068f7 */ jal sinf +/* f07a214: c56c006c */ lwc1 $f12,0x6c($t3) +/* f07a218: c7a40050 */ lwc1 $f4,0x50($sp) +/* f07a21c: 8faf0194 */ lw $t7,0x194($sp) +/* f07a220: 46040182 */ mul.s $f6,$f0,$f4 +/* f07a224: e7a6014c */ swc1 $f6,0x14c($sp) +/* f07a228: 0c0068f7 */ jal sinf +/* f07a22c: c5ec0078 */ lwc1 $f12,0x78($t7) +/* f07a230: 8fb80194 */ lw $t8,0x194($sp) +/* f07a234: e7a00150 */ swc1 $f0,0x150($sp) +/* f07a238: 0c0068f4 */ jal cosf +/* f07a23c: c70c0078 */ lwc1 $f12,0x78($t8) +/* f07a240: 8fb90194 */ lw $t9,0x194($sp) +/* f07a244: e7a00050 */ swc1 $f0,0x50($sp) +/* f07a248: 0c0068f4 */ jal cosf +/* f07a24c: c72c006c */ lwc1 $f12,0x6c($t9) +/* f07a250: c7a80050 */ lwc1 $f8,0x50($sp) +/* f07a254: 3c014780 */ lui $at,0x4780 +/* f07a258: 44811000 */ mtc1 $at,$f2 +/* f07a25c: 46080302 */ mul.s $f12,$f0,$f8 +/* f07a260: c7aa014c */ lwc1 $f10,0x14c($sp) +/* f07a264: c7a60150 */ lwc1 $f6,0x150($sp) +/* f07a268: c7b20168 */ lwc1 $f18,0x168($sp) +/* f07a26c: 46025402 */ mul.s $f16,$f10,$f2 +/* f07a270: c7aa016c */ lwc1 $f10,0x16c($sp) +/* f07a274: 3c03800a */ lui $v1,%hi(g_Vars) +/* f07a278: 46023202 */ mul.s $f8,$f6,$f2 +/* f07a27c: 24639fc0 */ addiu $v1,$v1,%lo(g_Vars) +/* f07a280: 8c680318 */ lw $t0,0x318($v1) +/* f07a284: e7ac0154 */ swc1 $f12,0x154($sp) +/* f07a288: 8fa20124 */ lw $v0,0x124($sp) +/* f07a28c: 46128100 */ add.s $f4,$f16,$f18 +/* f07a290: 46026482 */ mul.s $f18,$f12,$f2 +/* f07a294: 27a40168 */ addiu $a0,$sp,0x168 +/* f07a298: 460a4400 */ add.s $f16,$f8,$f10 +/* f07a29c: e7a4013c */ swc1 $f4,0x13c($sp) +/* f07a2a0: c7a40170 */ lwc1 $f4,0x170($sp) +/* f07a2a4: 27a50158 */ addiu $a1,$sp,0x158 +/* f07a2a8: e7b00140 */ swc1 $f16,0x140($sp) +/* f07a2ac: 46049180 */ add.s $f6,$f18,$f4 +/* f07a2b0: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a2b4: 2407003f */ addiu $a3,$zero,0x3f +/* f07a2b8: 1500000f */ bnez $t0,.L0f07a2f8 +/* f07a2bc: e7a60144 */ swc1 $f6,0x144($sp) +/* f07a2c0: 50400006 */ beqzl $v0,.L0f07a2dc +/* f07a2c4: 8c6a029c */ lw $t2,0x29c($v1) +/* f07a2c8: 90490000 */ lbu $t1,0x0($v0) +/* f07a2cc: 24010003 */ addiu $at,$zero,0x3 +/* f07a2d0: 5121000a */ beql $t1,$at,.L0f07a2fc +/* f07a2d4: 240e0010 */ addiu $t6,$zero,0x10 +/* f07a2d8: 8c6a029c */ lw $t2,0x29c($v1) +.L0f07a2dc: +/* f07a2dc: 0540007f */ bltz $t2,.L0f07a4dc +/* f07a2e0: 00000000 */ nop +/* f07a2e4: 1040007d */ beqz $v0,.L0f07a4dc +/* f07a2e8: 00000000 */ nop +/* f07a2ec: 8c6c02a8 */ lw $t4,0x2a8($v1) +/* f07a2f0: 8d8d00bc */ lw $t5,0xbc($t4) +/* f07a2f4: 144d0079 */ bne $v0,$t5,.L0f07a4dc +.L0f07a2f8: +/* f07a2f8: 240e0010 */ addiu $t6,$zero,0x10 +.L0f07a2fc: +/* f07a2fc: 0c00b764 */ jal cdTestAToB4 +/* f07a300: afae0010 */ sw $t6,0x10($sp) +/* f07a304: 14400151 */ bnez $v0,.L0f07a84c +/* f07a308: 27a4013c */ addiu $a0,$sp,0x13c +/* f07a30c: 3c067f1b */ lui $a2,%hi(var7f1aa020) +/* f07a310: 24c6a020 */ addiu $a2,$a2,%lo(var7f1aa020) +/* f07a314: 0c0093af */ jal cdGetPos +/* f07a318: 24052cc2 */ addiu $a1,$zero,0x2c20 +/* f07a31c: 0c0093ac */ jal cdGetObstacle +/* f07a320: 00000000 */ nop +/* f07a324: 1040006a */ beqz $v0,.L0f07a4d0 +/* f07a328: afa20178 */ sw $v0,0x178($sp) +/* f07a32c: 90430000 */ lbu $v1,0x0($v0) +/* f07a330: 24010003 */ addiu $at,$zero,0x3 +/* f07a334: 3c0b800a */ lui $t3,%hi(g_Vars+0x318) +/* f07a338: 10610003 */ beq $v1,$at,.L0f07a348 +/* f07a33c: 24010006 */ addiu $at,$zero,0x6 +/* f07a340: 54610064 */ bnel $v1,$at,.L0f07a4d4 +/* f07a344: 24080001 */ addiu $t0,$zero,0x1 +.L0f07a348: +/* f07a348: 8d6ba2d8 */ lw $t3,%lo(g_Vars+0x318)($t3) +/* f07a34c: 8faf0124 */ lw $t7,0x124($sp) +/* f07a350: 2418ffff */ addiu $t8,$zero,-1 +/* f07a354: 15600003 */ bnez $t3,.L0f07a364 +/* f07a358: 241900c8 */ addiu $t9,$zero,0xc8 +/* f07a35c: 55e2005d */ bnel $t7,$v0,.L0f07a4d4 +/* f07a360: 24080001 */ addiu $t0,$zero,0x1 +.L0f07a364: +/* f07a364: afa000c0 */ sw $zero,0xc0($sp) +/* f07a368: afa000bc */ sw $zero,0xbc($sp) +/* f07a36c: afb800b8 */ sw $t8,0xb8($sp) +/* f07a370: afb900b4 */ sw $t9,0xb4($sp) +/* f07a374: 0fc2c74a */ jal gsetGetDamage +/* f07a378: 27a40118 */ addiu $a0,$sp,0x118 +/* f07a37c: 8fa80178 */ lw $t0,0x178($sp) +/* f07a380: 3c09800a */ lui $t1,%hi(g_Vars+0x318) +/* f07a384: 8d29a2d8 */ lw $t1,%lo(g_Vars+0x318)($t1) +/* f07a388: e7a000b0 */ swc1 $f0,0xb0($sp) +/* f07a38c: 8d040004 */ lw $a0,0x4($t0) +/* f07a390: 3c013f00 */ lui $at,0x3f00 +/* f07a394: 11200005 */ beqz $t1,.L0f07a3ac +/* f07a398: afa400ac */ sw $a0,0xac($sp) +/* f07a39c: 44814000 */ mtc1 $at,$f8 +/* f07a3a0: 00000000 */ nop +/* f07a3a4: 46080282 */ mul.s $f10,$f0,$f8 +/* f07a3a8: e7aa00b0 */ swc1 $f10,0xb0($sp) +.L0f07a3ac: +/* f07a3ac: 8faa0114 */ lw $t2,0x114($sp) +/* f07a3b0: 8fac0178 */ lw $t4,0x178($sp) +/* f07a3b4: 8fad0110 */ lw $t5,0x110($sp) +/* f07a3b8: 514c0007 */ beql $t2,$t4,.L0f07a3d8 +/* f07a3bc: 240e0001 */ addiu $t6,$zero,0x1 +/* f07a3c0: 11a00009 */ beqz $t5,.L0f07a3e8 +/* f07a3c4: 01a02825 */ or $a1,$t5,$zero +/* f07a3c8: 0fc12aa3 */ jal chrCompareTeams +/* f07a3cc: 24060001 */ addiu $a2,$zero,0x1 +/* f07a3d0: 10400005 */ beqz $v0,.L0f07a3e8 +/* f07a3d4: 240e0001 */ addiu $t6,$zero,0x1 +.L0f07a3d8: +/* f07a3d8: afa00128 */ sw $zero,0x128($sp) +/* f07a3dc: afa0018c */ sw $zero,0x18c($sp) +/* f07a3e0: afa00188 */ sw $zero,0x188($sp) +/* f07a3e4: afae0174 */ sw $t6,0x174($sp) +.L0f07a3e8: +/* f07a3e8: 8fab018c */ lw $t3,0x18c($sp) +/* f07a3ec: 8faf0188 */ lw $t7,0x188($sp) +/* f07a3f0: 27a40118 */ addiu $a0,$sp,0x118 +/* f07a3f4: 15600003 */ bnez $t3,.L0f07a404 +/* f07a3f8: 8fa50178 */ lw $a1,0x178($sp) +/* f07a3fc: 51e00114 */ beqzl $t7,.L0f07a850 +/* f07a400: 8fa40198 */ lw $a0,0x198($sp) +.L0f07a404: +/* f07a404: 0fc29f66 */ jal bgunPlayPropHitSound +/* f07a408: 2406ffff */ addiu $a2,$zero,-1 +/* f07a40c: 8fa400ac */ lw $a0,0xac($sp) +/* f07a410: 8c980020 */ lw $t8,0x20($a0) +/* f07a414: 53000012 */ beqzl $t8,.L0f07a460 +/* f07a418: 8fac0110 */ lw $t4,0x110($sp) +/* f07a41c: 0fc0cfe8 */ jal chrGetShield +/* f07a420: 00000000 */ nop +/* f07a424: 44808000 */ mtc1 $zero,$f16 +/* f07a428: 8fa400ac */ lw $a0,0xac($sp) +/* f07a42c: 27a5013c */ addiu $a1,$sp,0x13c +/* f07a430: 4600803c */ c.lt.s $f16,$f0 +/* f07a434: 27a6014c */ addiu $a2,$sp,0x14c +/* f07a438: 27a700c0 */ addiu $a3,$sp,0xc0 +/* f07a43c: 27b900b4 */ addiu $t9,$sp,0xb4 +/* f07a440: 45000006 */ bc1f .L0f07a45c +/* f07a444: 27a800bc */ addiu $t0,$sp,0xbc +/* f07a448: 27a900b8 */ addiu $t1,$sp,0xb8 +/* f07a44c: afa90018 */ sw $t1,0x18($sp) +/* f07a450: afb90010 */ sw $t9,0x10($sp) +/* f07a454: 0fc0ffcb */ jal chrCalculateShieldHit +/* f07a458: afa80014 */ sw $t0,0x14($sp) +.L0f07a45c: +/* f07a45c: 8fac0110 */ lw $t4,0x110($sp) +.L0f07a460: +/* f07a460: 27aa014c */ addiu $t2,$sp,0x14c +/* f07a464: 8fa400ac */ lw $a0,0xac($sp) +/* f07a468: afaa0010 */ sw $t2,0x10($sp) +/* f07a46c: 8fa50178 */ lw $a1,0x178($sp) +/* f07a470: 8fa600b4 */ lw $a2,0xb4($sp) +/* f07a474: 27a7013c */ addiu $a3,$sp,0x13c +/* f07a478: 0fc097a9 */ jal chrEmitSparks +/* f07a47c: afac0014 */ sw $t4,0x14($sp) +/* f07a480: 8fad0114 */ lw $t5,0x114($sp) +/* f07a484: 8fab0178 */ lw $t3,0x178($sp) +/* f07a488: 8faf00c0 */ lw $t7,0xc0($sp) +/* f07a48c: 8fb800bc */ lw $t8,0xbc($sp) +/* f07a490: 8fb900b8 */ lw $t9,0xb8($sp) +/* f07a494: 240e00c8 */ addiu $t6,$zero,0xc8 +/* f07a498: afae0014 */ sw $t6,0x14($sp) +/* f07a49c: 8fa400ac */ lw $a0,0xac($sp) +/* f07a4a0: 8fa500b0 */ lw $a1,0xb0($sp) +/* f07a4a4: 27a6014c */ addiu $a2,$sp,0x14c +/* f07a4a8: 27a70118 */ addiu $a3,$sp,0x118 +/* f07a4ac: afa00028 */ sw $zero,0x28($sp) +/* f07a4b0: afad0010 */ sw $t5,0x10($sp) +/* f07a4b4: afab0018 */ sw $t3,0x18($sp) +/* f07a4b8: afaf001c */ sw $t7,0x1c($sp) +/* f07a4bc: afb80020 */ sw $t8,0x20($sp) +/* f07a4c0: 0fc0d077 */ jal func0f0341dc +/* f07a4c4: afb90024 */ sw $t9,0x24($sp) +/* f07a4c8: 100000e1 */ b .L0f07a850 +/* f07a4cc: 8fa40198 */ lw $a0,0x198($sp) +.L0f07a4d0: +/* f07a4d0: 24080001 */ addiu $t0,$zero,0x1 +.L0f07a4d4: +/* f07a4d4: 100000dd */ b .L0f07a84c +/* f07a4d8: afa80148 */ sw $t0,0x148($sp) +.L0f07a4dc: +/* f07a4dc: 10400045 */ beqz $v0,.L0f07a5f4 +/* f07a4e0: 27a40168 */ addiu $a0,$sp,0x168 +/* f07a4e4: 90490000 */ lbu $t1,0x0($v0) +/* f07a4e8: 24010001 */ addiu $at,$zero,0x1 +/* f07a4ec: 27a50158 */ addiu $a1,$sp,0x158 +/* f07a4f0: 15210040 */ bne $t1,$at,.L0f07a5f4 +/* f07a4f4: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a4f8: 240a0010 */ addiu $t2,$zero,0x10 +/* f07a4fc: afa000a8 */ sw $zero,0xa8($sp) +/* f07a500: afaa0010 */ sw $t2,0x10($sp) +/* f07a504: 27a40168 */ addiu $a0,$sp,0x168 +/* f07a508: 0c00b764 */ jal cdTestAToB4 +/* f07a50c: 2407003b */ addiu $a3,$zero,0x3b +/* f07a510: 1440000a */ bnez $v0,.L0f07a53c +/* f07a514: 27a4013c */ addiu $a0,$sp,0x13c +/* f07a518: 3c067f1b */ lui $a2,%hi(var7f1aa02c) +/* f07a51c: 24c6a02c */ addiu $a2,$a2,%lo(var7f1aa02c) +/* f07a520: 0c0093af */ jal cdGetPos +/* f07a524: 24052cf9 */ addiu $a1,$zero,0x2c57 +/* f07a528: 0c0093ac */ jal cdGetObstacle +/* f07a52c: 00000000 */ nop +/* f07a530: 240c0001 */ addiu $t4,$zero,0x1 +/* f07a534: afac0148 */ sw $t4,0x148($sp) +/* f07a538: afa200a8 */ sw $v0,0xa8($sp) +.L0f07a53c: +/* f07a53c: 8fa300a8 */ lw $v1,0xa8($sp) +/* f07a540: 506000c3 */ beqzl $v1,.L0f07a850 +/* f07a544: 8fa40198 */ lw $a0,0x198($sp) +/* f07a548: 906d0000 */ lbu $t5,0x0($v1) +/* f07a54c: 24010001 */ addiu $at,$zero,0x1 +/* f07a550: 55a100bf */ bnel $t5,$at,.L0f07a850 +/* f07a554: 8fa40198 */ lw $a0,0x198($sp) +/* f07a558: 8c640004 */ lw $a0,0x4($v1) +/* f07a55c: 2401014c */ addiu $at,$zero,0x14c +/* f07a560: 3c0b8007 */ lui $t3,%hi(var80069cbc) +/* f07a564: 848e0004 */ lh $t6,0x4($a0) +/* f07a568: 27a5013c */ addiu $a1,$sp,0x13c +/* f07a56c: 24060000 */ addiu $a2,$zero,0x0 +/* f07a570: 55c100b7 */ bnel $t6,$at,.L0f07a850 +/* f07a574: 8fa40198 */ lw $a0,0x198($sp) +/* f07a578: 8d6b9cbc */ lw $t3,%lo(var80069cbc)($t3) +/* f07a57c: afa00148 */ sw $zero,0x148($sp) +/* f07a580: afa300a8 */ sw $v1,0xa8($sp) +/* f07a584: 0fc68330 */ jal frCalculateHit +/* f07a588: afab00a0 */ sw $t3,0xa0($sp) +/* f07a58c: 0fc4f92a */ jal chrIsUsingPaintball +/* f07a590: 8fa40110 */ lw $a0,0x110($sp) +/* f07a594: 1040000b */ beqz $v0,.L0f07a5c4 +/* f07a598: 8fa500a8 */ lw $a1,0xa8($sp) +/* f07a59c: 8fa500a8 */ lw $a1,0xa8($sp) +/* f07a5a0: 240f0019 */ addiu $t7,$zero,0x19 +/* f07a5a4: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a5a8: 84a40028 */ lh $a0,0x28($a1) +/* f07a5ac: afaf0014 */ sw $t7,0x14($sp) +/* f07a5b0: afa00010 */ sw $zero,0x10($sp) +/* f07a5b4: 0fc4be7c */ jal sparksCreate +/* f07a5b8: 00003825 */ or $a3,$zero,$zero +/* f07a5bc: 10000008 */ b .L0f07a5e0 +/* f07a5c0: 27a400a0 */ addiu $a0,$sp,0xa0 +.L0f07a5c4: +/* f07a5c4: 84a40028 */ lh $a0,0x28($a1) +/* f07a5c8: afa00014 */ sw $zero,0x14($sp) +/* f07a5cc: afa00010 */ sw $zero,0x10($sp) +/* f07a5d0: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a5d4: 0fc4be7c */ jal sparksCreate +/* f07a5d8: 00003825 */ or $a3,$zero,$zero +/* f07a5dc: 27a400a0 */ addiu $a0,$sp,0xa0 +.L0f07a5e0: +/* f07a5e0: 8fa500a8 */ lw $a1,0xa8($sp) +/* f07a5e4: 0fc29f66 */ jal bgunPlayPropHitSound +/* f07a5e8: 240600f2 */ addiu $a2,$zero,0xf2 +/* f07a5ec: 10000098 */ b .L0f07a850 +/* f07a5f0: 8fa40198 */ lw $a0,0x198($sp) +.L0f07a5f4: +/* f07a5f4: 24190010 */ addiu $t9,$zero,0x10 +/* f07a5f8: afb90010 */ sw $t9,0x10($sp) +/* f07a5fc: 27a50158 */ addiu $a1,$sp,0x158 +/* f07a600: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a604: 0c00b764 */ jal cdTestAToB4 +/* f07a608: 24070022 */ addiu $a3,$zero,0x22 +/* f07a60c: 14400007 */ bnez $v0,.L0f07a62c +/* f07a610: 27a4013c */ addiu $a0,$sp,0x13c +/* f07a614: 3c067f1b */ lui $a2,%hi(var7f1aa038) +/* f07a618: 24c6a038 */ addiu $a2,$a2,%lo(var7f1aa038) +/* f07a61c: 0c0093af */ jal cdGetPos +/* f07a620: 24052d13 */ addiu $a1,$zero,0x2c71 +/* f07a624: 24080001 */ addiu $t0,$zero,0x1 +/* f07a628: afa80148 */ sw $t0,0x148($sp) +.L0f07a62c: +/* f07a62c: 8faa0194 */ lw $t2,0x194($sp) +/* f07a630: 3c09800a */ lui $t1,%hi(g_Vars+0x8) +/* f07a634: 8d299fc8 */ lw $t1,%lo(g_Vars+0x8)($t1) +/* f07a638: 8d4c0094 */ lw $t4,0x94($t2) +/* f07a63c: 8fa20124 */ lw $v0,0x124($sp) +/* f07a640: 552c0083 */ bnel $t1,$t4,.L0f07a850 +/* f07a644: 8fa40198 */ lw $a0,0x198($sp) +/* f07a648: 50400081 */ beqzl $v0,.L0f07a850 +/* f07a64c: 8fa40198 */ lw $a0,0x198($sp) +/* f07a650: 904d0000 */ lbu $t5,0x0($v0) +/* f07a654: 24010006 */ addiu $at,$zero,0x6 +/* f07a658: c7a40168 */ lwc1 $f4,0x168($sp) +/* f07a65c: 55a1007c */ bnel $t5,$at,.L0f07a850 +/* f07a660: 8fa40198 */ lw $a0,0x198($sp) +/* f07a664: c4520008 */ lwc1 $f18,0x8($v0) +/* f07a668: c446000c */ lwc1 $f6,0xc($v0) +/* f07a66c: c7a8016c */ lwc1 $f8,0x16c($sp) +/* f07a670: 46049001 */ sub.s $f0,$f18,$f4 +/* f07a674: c44a0010 */ lwc1 $f10,0x10($v0) +/* f07a678: c7b00170 */ lwc1 $f16,0x170($sp) +/* f07a67c: 46083081 */ sub.s $f2,$f6,$f8 +/* f07a680: 46000482 */ mul.s $f18,$f0,$f0 +/* f07a684: 46105301 */ sub.s $f12,$f10,$f16 +/* f07a688: 46021182 */ mul.s $f6,$f2,$f2 +/* f07a68c: 46069280 */ add.s $f10,$f18,$f6 +/* f07a690: 460c6482 */ mul.s $f18,$f12,$f12 +/* f07a694: c7a6013c */ lwc1 $f6,0x13c($sp) +/* f07a698: 46043001 */ sub.s $f0,$f6,$f4 +/* f07a69c: 46125380 */ add.s $f14,$f10,$f18 +/* f07a6a0: c7aa0140 */ lwc1 $f10,0x140($sp) +/* f07a6a4: 46000182 */ mul.s $f6,$f0,$f0 +/* f07a6a8: c7b20144 */ lwc1 $f18,0x144($sp) +/* f07a6ac: 46085081 */ sub.s $f2,$f10,$f8 +/* f07a6b0: 46109301 */ sub.s $f12,$f18,$f16 +/* f07a6b4: 46021102 */ mul.s $f4,$f2,$f2 +/* f07a6b8: 46043280 */ add.s $f10,$f6,$f4 +/* f07a6bc: 460c6202 */ mul.s $f8,$f12,$f12 +/* f07a6c0: 46085480 */ add.s $f18,$f10,$f8 +/* f07a6c4: 4612703e */ c.le.s $f14,$f18 +/* f07a6c8: 00000000 */ nop +/* f07a6cc: 45020060 */ bc1fl .L0f07a850 +/* f07a6d0: 8fa40198 */ lw $a0,0x198($sp) +/* f07a6d4: 0c012974 */ jal sqrtf +/* f07a6d8: 46007306 */ mov.s $f12,$f14 +/* f07a6dc: 3c014348 */ lui $at,0x4348 +/* f07a6e0: 44816000 */ mtc1 $at,$f12 +/* f07a6e4: 3c017f1b */ lui $at,%hi(var7f1aa58c) +/* f07a6e8: c430a58c */ lwc1 $f16,%lo(var7f1aa58c)($at) +/* f07a6ec: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f07a6f0: c426a00c */ lwc1 $f6,%lo(g_Vars+0x4c)($at) +/* f07a6f4: 3c018007 */ lui $at,%hi(var80069950) +/* f07a6f8: 4600603c */ c.lt.s $f12,$f0 +/* f07a6fc: 46068102 */ mul.s $f4,$f16,$f6 +/* f07a700: c42a9950 */ lwc1 $f10,%lo(var80069950)($at) +/* f07a704: 8fae0194 */ lw $t6,0x194($sp) +/* f07a708: 460a2082 */ mul.s $f2,$f4,$f10 +/* f07a70c: 45020005 */ bc1fl .L0f07a724 +/* f07a710: c5d200a0 */ lwc1 $f18,0xa0($t6) +/* f07a714: 46006203 */ div.s $f8,$f12,$f0 +/* f07a718: 46081082 */ mul.s $f2,$f2,$f8 +/* f07a71c: 00000000 */ nop +/* f07a720: c5d200a0 */ lwc1 $f18,0xa0($t6) +.L0f07a724: +/* f07a724: 3c013f80 */ lui $at,0x3f80 +/* f07a728: 44813000 */ mtc1 $at,$f6 +/* f07a72c: 46029400 */ add.s $f16,$f18,$f2 +/* f07a730: 4610303e */ c.le.s $f6,$f16 +/* f07a734: e5d000a0 */ swc1 $f16,0xa0($t6) +/* f07a738: 8fab0124 */ lw $t3,0x124($sp) +/* f07a73c: 45020044 */ bc1fl .L0f07a850 +/* f07a740: 8fa40198 */ lw $a0,0x198($sp) +/* f07a744: c5640008 */ lwc1 $f4,0x8($t3) +/* f07a748: e7a4013c */ swc1 $f4,0x13c($sp) +/* f07a74c: c56a000c */ lwc1 $f10,0xc($t3) +/* f07a750: e7aa0140 */ swc1 $f10,0x140($sp) +/* f07a754: c5680010 */ lwc1 $f8,0x10($t3) +/* f07a758: afa00148 */ sw $zero,0x148($sp) +/* f07a75c: 0c004b70 */ jal random +/* f07a760: e7a80144 */ swc1 $f8,0x144($sp) +/* f07a764: 304f0001 */ andi $t7,$v0,0x1 +/* f07a768: 11e00012 */ beqz $t7,.L0f07a7b4 +/* f07a76c: 00000000 */ nop +/* f07a770: 0c004b70 */ jal random +/* f07a774: 00000000 */ nop +/* f07a778: 2401000a */ addiu $at,$zero,0xa +/* f07a77c: 0041001b */ divu $zero,$v0,$at +/* f07a780: 0000c010 */ mfhi $t8 +/* f07a784: 27190002 */ addiu $t9,$t8,0x2 +/* f07a788: 44998000 */ mtc1 $t9,$f16 +/* f07a78c: c7b20140 */ lwc1 $f18,0x140($sp) +/* f07a790: 07210005 */ bgez $t9,.L0f07a7a8 +/* f07a794: 468081a0 */ cvt.s.w $f6,$f16 +/* f07a798: 3c014f80 */ lui $at,0x4f80 +/* f07a79c: 44812000 */ mtc1 $at,$f4 +/* f07a7a0: 00000000 */ nop +/* f07a7a4: 46043180 */ add.s $f6,$f6,$f4 +.L0f07a7a8: +/* f07a7a8: 46069280 */ add.s $f10,$f18,$f6 +/* f07a7ac: 10000011 */ b .L0f07a7f4 +/* f07a7b0: e7aa0140 */ swc1 $f10,0x140($sp) +.L0f07a7b4: +/* f07a7b4: 0c004b70 */ jal random +/* f07a7b8: 00000000 */ nop +/* f07a7bc: 2401000a */ addiu $at,$zero,0xa +/* f07a7c0: 0041001b */ divu $zero,$v0,$at +/* f07a7c4: 00004010 */ mfhi $t0 +/* f07a7c8: 250a0002 */ addiu $t2,$t0,0x2 +/* f07a7cc: 448a8000 */ mtc1 $t2,$f16 +/* f07a7d0: c7a80140 */ lwc1 $f8,0x140($sp) +/* f07a7d4: 05410005 */ bgez $t2,.L0f07a7ec +/* f07a7d8: 46808120 */ cvt.s.w $f4,$f16 +/* f07a7dc: 3c014f80 */ lui $at,0x4f80 +/* f07a7e0: 44819000 */ mtc1 $at,$f18 +/* f07a7e4: 00000000 */ nop +/* f07a7e8: 46122100 */ add.s $f4,$f4,$f18 +.L0f07a7ec: +/* f07a7ec: 46044181 */ sub.s $f6,$f8,$f4 +/* f07a7f0: e7a60140 */ swc1 $f6,0x140($sp) +.L0f07a7f4: +/* f07a7f4: 27a40118 */ addiu $a0,$sp,0x118 +/* f07a7f8: 8fa50124 */ lw $a1,0x124($sp) +/* f07a7fc: 0fc29f66 */ jal bgunPlayPropHitSound +/* f07a800: 2406ffff */ addiu $a2,$zero,-1 +/* f07a804: 3c013f00 */ lui $at,0x3f00 +/* f07a808: 44815000 */ mtc1 $at,$f10 +/* f07a80c: 3c018007 */ lui $at,%hi(var80069954) +/* f07a810: c4309954 */ lwc1 $f16,%lo(var80069954)($at) +/* f07a814: 8fa90124 */ lw $t1,0x124($sp) +/* f07a818: 240c00c8 */ addiu $t4,$zero,0xc8 +/* f07a81c: 46105002 */ mul.s $f0,$f10,$f16 +/* f07a820: 8d240004 */ lw $a0,0x4($t1) +/* f07a824: afac0014 */ sw $t4,0x14($sp) +/* f07a828: afa00010 */ sw $zero,0x10($sp) +/* f07a82c: 27a6014c */ addiu $a2,$sp,0x14c +/* f07a830: 27a70118 */ addiu $a3,$sp,0x118 +/* f07a834: 44050000 */ mfc1 $a1,$f0 +/* f07a838: 0fc0d0cc */ jal chrDamageByImpact +/* f07a83c: 00000000 */ nop +/* f07a840: 44809000 */ mtc1 $zero,$f18 +/* f07a844: 8fad0194 */ lw $t5,0x194($sp) +/* f07a848: e5b200a0 */ swc1 $f18,0xa0($t5) +.L0f07a84c: +/* f07a84c: 8fa40198 */ lw $a0,0x198($sp) +.L0f07a850: +/* f07a850: 0fc1905e */ jal propSetCollisionsEnabled +/* f07a854: 24050001 */ addiu $a1,$zero,0x1 +/* f07a858: 8fae018c */ lw $t6,0x18c($sp) +/* f07a85c: 8fab0188 */ lw $t3,0x188($sp) +/* f07a860: 8faf0194 */ lw $t7,0x194($sp) +/* f07a864: 15c00003 */ bnez $t6,.L0f07a874 +/* f07a868: 27a40168 */ addiu $a0,$sp,0x168 +/* f07a86c: 51600009 */ beqzl $t3,.L0f07a894 +/* f07a870: 8fb90148 */ lw $t9,0x148($sp) +.L0f07a874: +/* f07a874: 91e200a9 */ lbu $v0,0xa9($t7) +/* f07a878: 240100ff */ addiu $at,$zero,0xff +/* f07a87c: 58400005 */ blezl $v0,.L0f07a894 +/* f07a880: 8fb90148 */ lw $t9,0x148($sp) +/* f07a884: 10410002 */ beq $v0,$at,.L0f07a890 +/* f07a888: 2458ffff */ addiu $t8,$v0,-1 +/* f07a88c: a1f800a9 */ sb $t8,0xa9($t7) +.L0f07a890: +/* f07a890: 8fb90148 */ lw $t9,0x148($sp) +.L0f07a894: +/* f07a894: 27a5013c */ addiu $a1,$sp,0x13c +/* f07a898: 27a60158 */ addiu $a2,$sp,0x158 +/* f07a89c: 13200024 */ beqz $t9,.L0f07a930 +/* f07a8a0: 27a7012c */ addiu $a3,$sp,0x12c +/* f07a8a4: afa00010 */ sw $zero,0x10($sp) +/* f07a8a8: 0c006052 */ jal func00018148 +/* f07a8ac: afa00014 */ sw $zero,0x14($sp) +/* f07a8b0: 0fc4f92a */ jal chrIsUsingPaintball +/* f07a8b4: 8fa40110 */ lw $a0,0x110($sp) +/* f07a8b8: 1040000b */ beqz $v0,.L0f07a8e8 +/* f07a8bc: 8faa0194 */ lw $t2,0x194($sp) +/* f07a8c0: 24080019 */ addiu $t0,$zero,0x19 +/* f07a8c4: afa80014 */ sw $t0,0x14($sp) +/* f07a8c8: 87a4012c */ lh $a0,0x12c($sp) +/* f07a8cc: 00002825 */ or $a1,$zero,$zero +/* f07a8d0: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a8d4: 00003825 */ or $a3,$zero,$zero +/* f07a8d8: 0fc4be7c */ jal sparksCreate +/* f07a8dc: afa00010 */ sw $zero,0x10($sp) +/* f07a8e0: 1000000f */ b .L0f07a920 +/* f07a8e4: 27a40118 */ addiu $a0,$sp,0x118 +.L0f07a8e8: +/* f07a8e8: 85490004 */ lh $t1,0x4($t2) +/* f07a8ec: 24010144 */ addiu $at,$zero,0x144 +/* f07a8f0: 87a4012c */ lh $a0,0x12c($sp) +/* f07a8f4: 15210003 */ bne $t1,$at,.L0f07a904 +/* f07a8f8: 00002825 */ or $a1,$zero,$zero +/* f07a8fc: 10000002 */ b .L0f07a908 +/* f07a900: 24020017 */ addiu $v0,$zero,0x17 +.L0f07a904: +/* f07a904: 00001025 */ or $v0,$zero,$zero +.L0f07a908: +/* f07a908: 27a6013c */ addiu $a2,$sp,0x13c +/* f07a90c: 00003825 */ or $a3,$zero,$zero +/* f07a910: afa00010 */ sw $zero,0x10($sp) +/* f07a914: 0fc4be7c */ jal sparksCreate +/* f07a918: afa20014 */ sw $v0,0x14($sp) +/* f07a91c: 27a40118 */ addiu $a0,$sp,0x118 +.L0f07a920: +/* f07a920: 27a5013c */ addiu $a1,$sp,0x13c +/* f07a924: 2406ffff */ addiu $a2,$zero,-1 +/* f07a928: 0fc2a132 */ jal bgunPlayBgHitSound +/* f07a92c: 27a7012c */ addiu $a3,$sp,0x12c +.L0f07a930: +/* f07a930: 8fac0128 */ lw $t4,0x128($sp) +/* f07a934: c7a8013c */ lwc1 $f8,0x13c($sp) +/* f07a938: c7a40168 */ lwc1 $f4,0x168($sp) +/* f07a93c: 51800097 */ beqzl $t4,.L0f07ab9c +/* f07a940: 8fa80194 */ lw $t0,0x194($sp) +/* f07a944: 46044181 */ sub.s $f6,$f8,$f4 +/* f07a948: c7aa0140 */ lwc1 $f10,0x140($sp) +/* f07a94c: c7b0016c */ lwc1 $f16,0x16c($sp) +/* f07a950: c7a40170 */ lwc1 $f4,0x170($sp) +/* f07a954: c7a80144 */ lwc1 $f8,0x144($sp) +/* f07a958: 46105481 */ sub.s $f18,$f10,$f16 +/* f07a95c: 8fad0194 */ lw $t5,0x194($sp) +/* f07a960: 46063402 */ mul.s $f16,$f6,$f6 +/* f07a964: 46044281 */ sub.s $f10,$f8,$f4 +/* f07a968: 8da3009c */ lw $v1,0x9c($t5) +/* f07a96c: 46129202 */ mul.s $f8,$f18,$f18 +/* f07a970: e7a60068 */ swc1 $f6,0x68($sp) +/* f07a974: e7aa0070 */ swc1 $f10,0x70($sp) +/* f07a978: c7aa0070 */ lwc1 $f10,0x70($sp) +/* f07a97c: c7a60070 */ lwc1 $f6,0x70($sp) +/* f07a980: e7b2006c */ swc1 $f18,0x6c($sp) +/* f07a984: afa30078 */ sw $v1,0x78($sp) +/* f07a988: 46065482 */ mul.s $f18,$f10,$f6 +/* f07a98c: 46088100 */ add.s $f4,$f16,$f8 +/* f07a990: 0c012974 */ jal sqrtf +/* f07a994: 46049300 */ add.s $f12,$f18,$f4 +/* f07a998: 44808000 */ mtc1 $zero,$f16 +/* f07a99c: 8fa30078 */ lw $v1,0x78($sp) +/* f07a9a0: 46000306 */ mov.s $f12,$f0 +/* f07a9a4: 4600803c */ c.lt.s $f16,$f0 +/* f07a9a8: 3c017f1b */ lui $at,%hi(var7f1aa590) +/* f07a9ac: c7a80168 */ lwc1 $f8,0x168($sp) +/* f07a9b0: 4502007a */ bc1fl .L0f07ab9c +/* f07a9b4: 8fa80194 */ lw $t0,0x194($sp) +/* f07a9b8: c42ea590 */ lwc1 $f14,%lo(var7f1aa590)($at) +/* f07a9bc: e4680004 */ swc1 $f8,0x4($v1) +/* f07a9c0: 3c013f80 */ lui $at,0x3f80 +/* f07a9c4: 44814000 */ mtc1 $at,$f8 +/* f07a9c8: c7aa016c */ lwc1 $f10,0x16c($sp) +/* f07a9cc: 4600703c */ c.lt.s $f14,$f0 +/* f07a9d0: 240f002b */ addiu $t7,$zero,0x2b +/* f07a9d4: 46004083 */ div.s $f2,$f8,$f0 +/* f07a9d8: e46a0008 */ swc1 $f10,0x8($v1) +/* f07a9dc: c7a60170 */ lwc1 $f6,0x170($sp) +/* f07a9e0: 2418000c */ addiu $t8,$zero,0xc +/* f07a9e4: e466000c */ swc1 $f6,0xc($v1) +/* f07a9e8: c7b20068 */ lwc1 $f18,0x68($sp) +/* f07a9ec: e4720010 */ swc1 $f18,0x10($v1) +/* f07a9f0: c7a4006c */ lwc1 $f4,0x6c($sp) +/* f07a9f4: c46a0010 */ lwc1 $f10,0x10($v1) +/* f07a9f8: e4640014 */ swc1 $f4,0x14($v1) +/* f07a9fc: c7b00070 */ lwc1 $f16,0x70($sp) +/* f07aa00: c4720014 */ lwc1 $f18,0x14($v1) +/* f07aa04: e4700018 */ swc1 $f16,0x18($v1) +/* f07aa08: c4700018 */ lwc1 $f16,0x18($v1) +/* f07aa0c: 46025182 */ mul.s $f6,$f10,$f2 +/* f07aa10: 00000000 */ nop +/* f07aa14: 46029102 */ mul.s $f4,$f18,$f2 +/* f07aa18: 00000000 */ nop +/* f07aa1c: 46028202 */ mul.s $f8,$f16,$f2 +/* f07aa20: e4660010 */ swc1 $f6,0x10($v1) +/* f07aa24: e4640014 */ swc1 $f4,0x14($v1) +/* f07aa28: 45000002 */ bc1f .L0f07aa34 +/* f07aa2c: e4680018 */ swc1 $f8,0x18($v1) +/* f07aa30: 46007306 */ mov.s $f12,$f14 +.L0f07aa34: +/* f07aa34: a0600000 */ sb $zero,0x0($v1) +/* f07aa38: 8fae0194 */ lw $t6,0x194($sp) +/* f07aa3c: 24010144 */ addiu $at,$zero,0x144 +/* f07aa40: 85cb0004 */ lh $t3,0x4($t6) +/* f07aa44: 55610004 */ bnel $t3,$at,.L0f07aa58 +/* f07aa48: a06f0001 */ sb $t7,0x1($v1) +/* f07aa4c: 10000002 */ b .L0f07aa58 +/* f07aa50: a0780001 */ sb $t8,0x1($v1) +/* f07aa54: a06f0001 */ sb $t7,0x1($v1) +.L0f07aa58: +/* f07aa58: 3c0143fa */ lui $at,0x43fa +/* f07aa5c: 44810000 */ mtc1 $at,$f0 +/* f07aa60: e46c001c */ swc1 $f12,0x1c($v1) +/* f07aa64: 4600603c */ c.lt.s $f12,$f0 +/* f07aa68: 00000000 */ nop +/* f07aa6c: 45020003 */ bc1fl .L0f07aa7c +/* f07aa70: 80790001 */ lb $t9,0x1($v1) +/* f07aa74: 46000306 */ mov.s $f12,$f0 +/* f07aa78: 80790001 */ lb $t9,0x1($v1) +.L0f07aa7c: +/* f07aa7c: 2401001d */ addiu $at,$zero,0x1d +/* f07aa80: 17210026 */ bne $t9,$at,.L0f07ab1c +/* f07aa84: 3c017f1b */ lui $at,%hi(var7f1aa594) +/* f07aa88: c422a594 */ lwc1 $f2,%lo(var7f1aa594)($at) +/* f07aa8c: 3c013e80 */ lui $at,0x3e80 +/* f07aa90: 44815000 */ mtc1 $at,$f10 +/* f07aa94: 3c017f1b */ lui $at,%hi(var7f1aa598) +/* f07aa98: 460c5182 */ mul.s $f6,$f10,$f12 +/* f07aa9c: e4660020 */ swc1 $f6,0x20($v1) +/* f07aaa0: c432a598 */ lwc1 $f18,%lo(var7f1aa598)($at) +/* f07aaa4: 460c9002 */ mul.s $f0,$f18,$f12 +/* f07aaa8: 4600103c */ c.lt.s $f2,$f0 +/* f07aaac: e4600024 */ swc1 $f0,0x24($v1) +/* f07aab0: 45020003 */ bc1fl .L0f07aac0 +/* f07aab4: afa30078 */ sw $v1,0x78($sp) +/* f07aab8: e4620024 */ swc1 $f2,0x24($v1) +/* f07aabc: afa30078 */ sw $v1,0x78($sp) +.L0f07aac0: +/* f07aac0: 0c004b70 */ jal random +/* f07aac4: e7ac007c */ swc1 $f12,0x7c($sp) +/* f07aac8: 44822000 */ mtc1 $v0,$f4 +/* f07aacc: 8fa30078 */ lw $v1,0x78($sp) +/* f07aad0: c7ac007c */ lwc1 $f12,0x7c($sp) +/* f07aad4: 04410005 */ bgez $v0,.L0f07aaec +/* f07aad8: 46802420 */ cvt.s.w $f16,$f4 +/* f07aadc: 3c014f80 */ lui $at,0x4f80 +/* f07aae0: 44814000 */ mtc1 $at,$f8 +/* f07aae4: 00000000 */ nop +/* f07aae8: 46088400 */ add.s $f16,$f16,$f8 +.L0f07aaec: +/* f07aaec: 3c012f80 */ lui $at,0x2f80 +/* f07aaf0: 44815000 */ mtc1 $at,$f10 +/* f07aaf4: 3c017f1b */ lui $at,%hi(var7f1aa59c) +/* f07aaf8: c432a59c */ lwc1 $f18,%lo(var7f1aa59c)($at) +/* f07aafc: 460a8182 */ mul.s $f6,$f16,$f10 +/* f07ab00: 3c017f1b */ lui $at,%hi(var7f1aa5a0) +/* f07ab04: c428a5a0 */ lwc1 $f8,%lo(var7f1aa5a0)($at) +/* f07ab08: 46123102 */ mul.s $f4,$f6,$f18 +/* f07ab0c: 46044401 */ sub.s $f16,$f8,$f4 +/* f07ab10: 460c8282 */ mul.s $f10,$f16,$f12 +/* f07ab14: 10000020 */ b .L0f07ab98 +/* f07ab18: e46a0028 */ swc1 $f10,0x28($v1) +.L0f07ab1c: +/* f07ab1c: 3c017f1b */ lui $at,%hi(var7f1aa5a4) +/* f07ab20: c422a5a4 */ lwc1 $f2,%lo(var7f1aa5a4)($at) +/* f07ab24: 3c017f1b */ lui $at,%hi(var7f1aa5a8) +/* f07ab28: c426a5a8 */ lwc1 $f6,%lo(var7f1aa5a8)($at) +/* f07ab2c: 460c3002 */ mul.s $f0,$f6,$f12 +/* f07ab30: 4600103c */ c.lt.s $f2,$f0 +/* f07ab34: e4600020 */ swc1 $f0,0x20($v1) +/* f07ab38: e4600024 */ swc1 $f0,0x24($v1) +/* f07ab3c: 45000002 */ bc1f .L0f07ab48 +/* f07ab40: 00000000 */ nop +/* f07ab44: e4620024 */ swc1 $f2,0x24($v1) +.L0f07ab48: +/* f07ab48: 0c004b70 */ jal random +/* f07ab4c: afa30078 */ sw $v1,0x78($sp) +/* f07ab50: 44829000 */ mtc1 $v0,$f18 +/* f07ab54: 8fa30078 */ lw $v1,0x78($sp) +/* f07ab58: 04410005 */ bgez $v0,.L0f07ab70 +/* f07ab5c: 46809220 */ cvt.s.w $f8,$f18 +/* f07ab60: 3c014f80 */ lui $at,0x4f80 +/* f07ab64: 44812000 */ mtc1 $at,$f4 +/* f07ab68: 00000000 */ nop +/* f07ab6c: 46044200 */ add.s $f8,$f8,$f4 +.L0f07ab70: +/* f07ab70: 3c012f80 */ lui $at,0x2f80 +/* f07ab74: 44818000 */ mtc1 $at,$f16 +/* f07ab78: 3c013f80 */ lui $at,0x3f80 +/* f07ab7c: 44813000 */ mtc1 $at,$f6 +/* f07ab80: 46104002 */ mul.s $f0,$f8,$f16 +/* f07ab84: c4640020 */ lwc1 $f4,0x20($v1) +/* f07ab88: 46000280 */ add.s $f10,$f0,$f0 +/* f07ab8c: 46065481 */ sub.s $f18,$f10,$f6 +/* f07ab90: 46049202 */ mul.s $f8,$f18,$f4 +/* f07ab94: e4680028 */ swc1 $f8,0x28($v1) +.L0f07ab98: +/* f07ab98: 8fa80194 */ lw $t0,0x194($sp) +.L0f07ab9c: +/* f07ab9c: 3c09800a */ lui $t1,%hi(g_Vars+0x8) +/* f07aba0: 8d299fc8 */ lw $t1,%lo(g_Vars+0x8)($t1) +/* f07aba4: 8d0a0098 */ lw $t2,0x98($t0) +/* f07aba8: 240c0002 */ addiu $t4,$zero,0x2 +/* f07abac: 24050001 */ addiu $a1,$zero,0x1 +/* f07abb0: 0149082a */ slt $at,$t2,$t1 +/* f07abb4: 1020002d */ beqz $at,.L0f07ac6c +/* f07abb8: 3406ffff */ dli $a2,0xffff +/* f07abbc: afac0064 */ sw $t4,0x64($sp) +/* f07abc0: 0fc249af */ jal func0f0926bc +/* f07abc4: 8fa40198 */ lw $a0,0x198($sp) +/* f07abc8: 8fad0174 */ lw $t5,0x174($sp) +/* f07abcc: 8fae0194 */ lw $t6,0x194($sp) +/* f07abd0: 00002025 */ or $a0,$zero,$zero +/* f07abd4: 15a0001f */ bnez $t5,.L0f07ac54 +/* f07abd8: 2407ffff */ addiu $a3,$zero,-1 +/* f07abdc: 85c30004 */ lh $v1,0x4($t6) +/* f07abe0: 24010144 */ addiu $at,$zero,0x144 +/* f07abe4: 3402806f */ dli $v0,0x806f +/* f07abe8: 14610002 */ bne $v1,$at,.L0f07abf4 +/* f07abec: 240fffff */ addiu $t7,$zero,-1 +/* f07abf0: 34028040 */ dli $v0,0x8040 +.L0f07abf4: +/* f07abf4: 24010157 */ addiu $at,$zero,0x157 +/* f07abf8: 14610004 */ bne $v1,$at,.L0f07ac0c +/* f07abfc: 2419ffff */ addiu $t9,$zero,-1 +/* f07ac00: 240b0004 */ addiu $t3,$zero,0x4 +/* f07ac04: 34028044 */ dli $v0,0x8044 +/* f07ac08: afab0064 */ sw $t3,0x64($sp) +.L0f07ac0c: +/* f07ac0c: 3c01bf80 */ lui $at,0xbf80 +/* f07ac10: 44810000 */ mtc1 $at,$f0 +/* f07ac14: 00023400 */ sll $a2,$v0,0x10 +/* f07ac18: 0006c403 */ sra $t8,$a2,0x10 +/* f07ac1c: 03003025 */ or $a2,$t8,$zero +/* f07ac20: 8fa50198 */ lw $a1,0x198($sp) +/* f07ac24: afaf0010 */ sw $t7,0x10($sp) +/* f07ac28: afa00014 */ sw $zero,0x14($sp) +/* f07ac2c: afa00018 */ sw $zero,0x18($sp) +/* f07ac30: afa0001c */ sw $zero,0x1c($sp) +/* f07ac34: afa00020 */ sw $zero,0x20($sp) +/* f07ac38: afa00028 */ sw $zero,0x28($sp) +/* f07ac3c: afb9002c */ sw $t9,0x2c($sp) +/* f07ac40: e7a00024 */ swc1 $f0,0x24($sp) +/* f07ac44: e7a00030 */ swc1 $f0,0x30($sp) +/* f07ac48: e7a00034 */ swc1 $f0,0x34($sp) +/* f07ac4c: 0fc24e7e */ jal func0f0939f8 +/* f07ac50: e7a00038 */ swc1 $f0,0x38($sp) +.L0f07ac54: +/* f07ac54: 3c0a800a */ lui $t2,%hi(g_Vars+0x8) +/* f07ac58: 8d4a9fc8 */ lw $t2,%lo(g_Vars+0x8)($t2) +/* f07ac5c: 8fa80064 */ lw $t0,0x64($sp) +/* f07ac60: 8fac0194 */ lw $t4,0x194($sp) +/* f07ac64: 010a4821 */ addu $t1,$t0,$t2 +/* f07ac68: ad890098 */ sw $t1,0x98($t4) +.L0f07ac6c: +/* f07ac6c: 8fad0184 */ lw $t5,0x184($sp) +.L0f07ac70: +/* f07ac70: 24050005 */ addiu $a1,$zero,0x5 +/* f07ac74: 0c006a47 */ jal modelGetPart +/* f07ac78: 8da40008 */ lw $a0,0x8($t5) +/* f07ac7c: 10400005 */ beqz $v0,.L0f07ac94 +/* f07ac80: 00402825 */ or $a1,$v0,$zero +/* f07ac84: 0c006a87 */ jal modelGetNodeRwData +/* f07ac88: 8fa40184 */ lw $a0,0x184($sp) +/* f07ac8c: 8fae018c */ lw $t6,0x18c($sp) +/* f07ac90: a44e0000 */ sh $t6,0x0($v0) +.L0f07ac94: +/* f07ac94: 8fab0184 */ lw $t3,0x184($sp) +/* f07ac98: 24050007 */ addiu $a1,$zero,0x7 +/* f07ac9c: 0c006a47 */ jal modelGetPart +/* f07aca0: 8d640008 */ lw $a0,0x8($t3) +/* f07aca4: 10400005 */ beqz $v0,.L0f07acbc +/* f07aca8: 00402825 */ or $a1,$v0,$zero +/* f07acac: 0c006a87 */ jal modelGetNodeRwData +/* f07acb0: 8fa40184 */ lw $a0,0x184($sp) +/* f07acb4: 8fb80188 */ lw $t8,0x188($sp) +/* f07acb8: a4580000 */ sh $t8,0x0($v0) +.L0f07acbc: +/* f07acbc: 8fbf0044 */ lw $ra,0x44($sp) +/* f07acc0: 27bd0198 */ addiu $sp,$sp,0x198 +/* f07acc4: 03e00008 */ jr $ra +/* f07acc8: 00000000 */ nop +); #endif GLOBAL_ASM( @@ -38890,7 +41573,7 @@ glabel var7f1aa610 /* f07ba30: 03e00008 */ jr $ra /* f07ba34: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f07b3f0 .late_rodata @@ -39351,6 +42034,467 @@ glabel var7f1aa610 /* f07ba30: 03e00008 */ jr $ra /* f07ba34: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f07b3f0 +.late_rodata +glabel var7f1aa5d4 +.word 0x3dcccccd +glabel var7f1aa5d8 +.word 0x40c907a9 +glabel var7f1aa5dc +.word 0x40c907a9 +glabel var7f1aa5e0 +.word 0x40490fdb +glabel var7f1aa5e4 +.word 0xc0490fdb +glabel var7f1aa5e8 +.word 0x40c907a9 +glabel var7f1aa5ec +.word 0x40c907a9 +glabel var7f1aa5f0 +.word 0x40490fdb +glabel var7f1aa5f4 +.word 0x3eb2b8c2 +glabel var7f1aa5f8 +.word 0x3c8efa35 +glabel var7f1aa5fc +.word 0x3c8efa35 +glabel var7f1aa600 +.word 0x3b187c24 +glabel var7f1aa604 +.word 0x3b987c24 +glabel var7f1aa608 +.word 0x3e0ef461 +glabel var7f1aa60c +.word 0xbb987c24 +glabel var7f1aa610 +.word 0xbb987c24 +.text +/* f07b3f0: 27bdfee0 */ addiu $sp,$sp,-288 +/* f07b3f4: afbf0024 */ sw $ra,0x24($sp) +/* f07b3f8: afb00020 */ sw $s0,0x20($sp) +/* f07b3fc: afa40120 */ sw $a0,0x120($sp) +/* f07b400: afa50124 */ sw $a1,0x124($sp) +/* f07b404: 8c820004 */ lw $v0,0x4($a0) +/* f07b408: 3c013f80 */ lui $at,0x3f80 +/* f07b40c: 44812000 */ mtc1 $at,$f4 +/* f07b410: afa2011c */ sw $v0,0x11c($sp) +/* f07b414: 8c4f0018 */ lw $t7,0x18($v0) +/* f07b418: e7a40108 */ swc1 $f4,0x108($sp) +/* f07b41c: 44808000 */ mtc1 $zero,$f16 +/* f07b420: afaf0114 */ sw $t7,0x114($sp) +/* f07b424: c44600d0 */ lwc1 $f6,0xd0($v0) +/* f07b428: 00408025 */ or $s0,$v0,$zero +/* f07b42c: 00402025 */ or $a0,$v0,$zero +/* f07b430: e7a600ec */ swc1 $f6,0xec($sp) +/* f07b434: c44800d4 */ lwc1 $f8,0xd4($v0) +/* f07b438: e7a800e8 */ swc1 $f8,0xe8($sp) +/* f07b43c: c44a00c8 */ lwc1 $f10,0xc8($v0) +/* f07b440: e7aa00e4 */ swc1 $f10,0xe4($sp) +/* f07b444: c44400cc */ lwc1 $f4,0xcc($v0) +/* f07b448: e7b00110 */ swc1 $f16,0x110($sp) +/* f07b44c: e7b0010c */ swc1 $f16,0x10c($sp) +/* f07b450: 0fc1eb6e */ jal chopperGetTargetProp +/* f07b454: e7a400e0 */ swc1 $f4,0xe0($sp) +/* f07b458: afa200dc */ sw $v0,0xdc($sp) +/* f07b45c: afa000d4 */ sw $zero,0xd4($sp) +/* f07b460: 8e0300e0 */ lw $v1,0xe0($s0) +/* f07b464: 24010003 */ addiu $at,$zero,0x3 +/* f07b468: c7a2010c */ lwc1 $f2,0x10c($sp) +/* f07b46c: 90640000 */ lbu $a0,0x0($v1) +/* f07b470: c7b00110 */ lwc1 $f16,0x110($sp) +/* f07b474: 24050001 */ addiu $a1,$zero,0x1 +/* f07b478: 0081001a */ div $zero,$a0,$at +/* f07b47c: 0000c010 */ mfhi $t8 +/* f07b480: 2f190001 */ sltiu $t9,$t8,0x1 +/* f07b484: a0790001 */ sb $t9,0x1($v1) +/* f07b488: 8fa80124 */ lw $t0,0x124($sp) +/* f07b48c: 8fa90114 */ lw $t1,0x114($sp) +/* f07b490: 510000b2 */ beqzl $t0,.L0f07b75c +/* f07b494: c60000d8 */ lwc1 $f0,0xd8($s0) +/* f07b498: 0c006a6f */ jal modelGetPartRodata +/* f07b49c: 8d240008 */ lw $a0,0x8($t1) +/* f07b4a0: 8faa00dc */ lw $t2,0xdc($sp) +/* f07b4a4: afa200d0 */ sw $v0,0xd0($sp) +/* f07b4a8: 3c0141a0 */ lui $at,0x41a0 +/* f07b4ac: 44814000 */ mtc1 $at,$f8 +/* f07b4b0: c546000c */ lwc1 $f6,0xc($t2) +/* f07b4b4: 46083281 */ sub.s $f10,$f6,$f8 +/* f07b4b8: 0c004b70 */ jal random +/* f07b4bc: e7aa004c */ swc1 $f10,0x4c($sp) +/* f07b4c0: 0c004b70 */ jal random +/* f07b4c4: afa2003c */ sw $v0,0x3c($sp) +/* f07b4c8: 44802000 */ mtc1 $zero,$f4 +/* f07b4cc: 04010005 */ bgez $zero,.L0f07b4e4 +/* f07b4d0: 468021a0 */ cvt.s.w $f6,$f4 +/* f07b4d4: 3c014f80 */ lui $at,0x4f80 +/* f07b4d8: 44814000 */ mtc1 $at,$f8 +/* f07b4dc: 00000000 */ nop +/* f07b4e0: 46083180 */ add.s $f6,$f6,$f8 +.L0f07b4e4: +/* f07b4e4: 3c0141f0 */ lui $at,0x41f0 +/* f07b4e8: 44815000 */ mtc1 $at,$f10 +/* f07b4ec: 8fab00d0 */ lw $t3,0xd0($sp) +/* f07b4f0: 460a3102 */ mul.s $f4,$f6,$f10 +/* f07b4f4: c5680000 */ lwc1 $f8,0x0($t3) +/* f07b4f8: 46082180 */ add.s $f6,$f4,$f8 +/* f07b4fc: 0c004b70 */ jal random +/* f07b500: e7a600f0 */ swc1 $f6,0xf0($sp) +/* f07b504: 44805000 */ mtc1 $zero,$f10 +/* f07b508: 8fa3011c */ lw $v1,0x11c($sp) +/* f07b50c: 04010005 */ bgez $zero,.L0f07b524 +/* f07b510: 46805120 */ cvt.s.w $f4,$f10 +/* f07b514: 3c014f80 */ lui $at,0x4f80 +/* f07b518: 44814000 */ mtc1 $at,$f8 +/* f07b51c: 00000000 */ nop +/* f07b520: 46082100 */ add.s $f4,$f4,$f8 +.L0f07b524: +/* f07b524: 3c0141f0 */ lui $at,0x41f0 +/* f07b528: 44813000 */ mtc1 $at,$f6 +/* f07b52c: 8fac00d0 */ lw $t4,0xd0($sp) +/* f07b530: 3c014248 */ lui $at,0x4248 +/* f07b534: 46062282 */ mul.s $f10,$f4,$f6 +/* f07b538: 44812000 */ mtc1 $at,$f4 +/* f07b53c: c5880004 */ lwc1 $f8,0x4($t4) +/* f07b540: 3c01437a */ lui $at,0x437a +/* f07b544: 2464001c */ addiu $a0,$v1,0x1c +/* f07b548: 46044181 */ sub.s $f6,$f8,$f4 +/* f07b54c: 46065200 */ add.s $f8,$f10,$f6 +/* f07b550: 44815000 */ mtc1 $at,$f10 +/* f07b554: 24010128 */ addiu $at,$zero,0x128 +/* f07b558: e7a800f4 */ swc1 $f8,0xf4($sp) +/* f07b55c: c5840008 */ lwc1 $f4,0x8($t4) +/* f07b560: 460a2180 */ add.s $f6,$f4,$f10 +/* f07b564: e7a600f8 */ swc1 $f6,0xf8($sp) +/* f07b568: 846d0004 */ lh $t5,0x4($v1) +/* f07b56c: 15a1000e */ bne $t5,$at,.L0f07b5a8 +/* f07b570: 00000000 */ nop +/* f07b574: 8c6e0018 */ lw $t6,0x18($v1) +/* f07b578: 3c017f1b */ lui $at,%hi(var7f1aa5d4) +/* f07b57c: c424a5d4 */ lwc1 $f4,%lo(var7f1aa5d4)($at) +/* f07b580: c5ca0014 */ lwc1 $f10,0x14($t6) +/* f07b584: 460a2003 */ div.s $f0,$f4,$f10 +/* f07b588: c7a400f0 */ lwc1 $f4,0xf0($sp) +/* f07b58c: 46002282 */ mul.s $f10,$f4,$f0 +/* f07b590: e7aa00f0 */ swc1 $f10,0xf0($sp) +/* f07b594: 46004102 */ mul.s $f4,$f8,$f0 +/* f07b598: 00000000 */ nop +/* f07b59c: 46003282 */ mul.s $f10,$f6,$f0 +/* f07b5a0: e7a400f4 */ swc1 $f4,0xf4($sp) +/* f07b5a4: e7aa00f8 */ swc1 $f10,0xf8($sp) +.L0f07b5a8: +/* f07b5a8: 0c005755 */ jal mtx00015d54 +/* f07b5ac: 27a50050 */ addiu $a1,$sp,0x50 +/* f07b5b0: 27a400f0 */ addiu $a0,$sp,0xf0 +/* f07b5b4: 0c0059b7 */ jal mtx000166dc +/* f07b5b8: 27a50090 */ addiu $a1,$sp,0x90 +/* f07b5bc: 27a40050 */ addiu $a0,$sp,0x50 +/* f07b5c0: 0c00567f */ jal mtx000159fc +/* f07b5c4: 27a50090 */ addiu $a1,$sp,0x90 +/* f07b5c8: 8fa30120 */ lw $v1,0x120($sp) +/* f07b5cc: c7a400c0 */ lwc1 $f4,0xc0($sp) +/* f07b5d0: 8fa200dc */ lw $v0,0xdc($sp) +/* f07b5d4: c4680008 */ lwc1 $f8,0x8($v1) +/* f07b5d8: 46044180 */ add.s $f6,$f8,$f4 +/* f07b5dc: c7a800c4 */ lwc1 $f8,0xc4($sp) +/* f07b5e0: e7a600f0 */ swc1 $f6,0xf0($sp) +/* f07b5e4: c46a000c */ lwc1 $f10,0xc($v1) +/* f07b5e8: 46085100 */ add.s $f4,$f10,$f8 +/* f07b5ec: c7aa00c8 */ lwc1 $f10,0xc8($sp) +/* f07b5f0: e7a400f4 */ swc1 $f4,0xf4($sp) +/* f07b5f4: c4660010 */ lwc1 $f6,0x10($v1) +/* f07b5f8: 460a3200 */ add.s $f8,$f6,$f10 +/* f07b5fc: c7a600f0 */ lwc1 $f6,0xf0($sp) +/* f07b600: e7a800f8 */ swc1 $f8,0xf8($sp) +/* f07b604: c7a800f8 */ lwc1 $f8,0xf8($sp) +/* f07b608: c44a0010 */ lwc1 $f10,0x10($v0) +/* f07b60c: c4440008 */ lwc1 $f4,0x8($v0) +/* f07b610: 46085381 */ sub.s $f14,$f10,$f8 +/* f07b614: 0fc259d4 */ jal atan2f +/* f07b618: 46062301 */ sub.s $f12,$f4,$f6 +/* f07b61c: 44802000 */ mtc1 $zero,$f4 +/* f07b620: 46000406 */ mov.s $f16,$f0 +/* f07b624: 3c017f1b */ lui $at,%hi(var7f1aa5d8) +/* f07b628: 4604003e */ c.le.s $f0,$f4 +/* f07b62c: 8faf00dc */ lw $t7,0xdc($sp) +/* f07b630: 45000003 */ bc1f .L0f07b640 +/* f07b634: 00000000 */ nop +/* f07b638: c432a5d8 */ lwc1 $f18,%lo(var7f1aa5d8)($at) +/* f07b63c: 46120400 */ add.s $f16,$f0,$f18 +.L0f07b640: +/* f07b640: 3c017f1b */ lui $at,%hi(var7f1aa5dc) +/* f07b644: c432a5dc */ lwc1 $f18,%lo(var7f1aa5dc)($at) +/* f07b648: 4610903c */ c.lt.s $f18,$f16 +/* f07b64c: 00000000 */ nop +/* f07b650: 45020003 */ bc1fl .L0f07b660 +/* f07b654: c606007c */ lwc1 $f6,0x7c($s0) +/* f07b658: 46128401 */ sub.s $f16,$f16,$f18 +/* f07b65c: c606007c */ lwc1 $f6,0x7c($s0) +.L0f07b660: +/* f07b660: 3c017f1b */ lui $at,%hi(var7f1aa5e0) +/* f07b664: c42aa5e0 */ lwc1 $f10,%lo(var7f1aa5e0)($at) +/* f07b668: 46068401 */ sub.s $f16,$f16,$f6 +/* f07b66c: 3c017f1b */ lui $at,%hi(var7f1aa5e4) +/* f07b670: c7a600f0 */ lwc1 $f6,0xf0($sp) +/* f07b674: 4610503c */ c.lt.s $f10,$f16 +/* f07b678: 00000000 */ nop +/* f07b67c: 45000002 */ bc1f .L0f07b688 +/* f07b680: 00000000 */ nop +/* f07b684: 46128401 */ sub.s $f16,$f16,$f18 +.L0f07b688: +/* f07b688: c428a5e4 */ lwc1 $f8,%lo(var7f1aa5e4)($at) +/* f07b68c: 4608803c */ c.lt.s $f16,$f8 +/* f07b690: 00000000 */ nop +/* f07b694: 45020003 */ bc1fl .L0f07b6a4 +/* f07b698: c5e40008 */ lwc1 $f4,0x8($t7) +/* f07b69c: 46128400 */ add.s $f16,$f16,$f18 +/* f07b6a0: c5e40008 */ lwc1 $f4,0x8($t7) +.L0f07b6a4: +/* f07b6a4: c5ea0010 */ lwc1 $f10,0x10($t7) +/* f07b6a8: c7a800f8 */ lwc1 $f8,0xf8($sp) +/* f07b6ac: 46062001 */ sub.s $f0,$f4,$f6 +/* f07b6b0: e7b00110 */ swc1 $f16,0x110($sp) +/* f07b6b4: 46085081 */ sub.s $f2,$f10,$f8 +/* f07b6b8: 46000102 */ mul.s $f4,$f0,$f0 +/* f07b6bc: 00000000 */ nop +/* f07b6c0: 46021182 */ mul.s $f6,$f2,$f2 +/* f07b6c4: 0c012974 */ jal sqrtf +/* f07b6c8: 46062300 */ add.s $f12,$f4,$f6 +/* f07b6cc: c7aa004c */ lwc1 $f10,0x4c($sp) +/* f07b6d0: c7a800f4 */ lwc1 $f8,0xf4($sp) +/* f07b6d4: 46000386 */ mov.s $f14,$f0 +/* f07b6d8: 0fc259d4 */ jal atan2f +/* f07b6dc: 46085301 */ sub.s $f12,$f10,$f8 +/* f07b6e0: c6040080 */ lwc1 $f4,0x80($s0) +/* f07b6e4: 3c017f1b */ lui $at,%hi(var7f1aa5ec) +/* f07b6e8: c432a5ec */ lwc1 $f18,%lo(var7f1aa5ec)($at) +/* f07b6ec: 46040181 */ sub.s $f6,$f0,$f4 +/* f07b6f0: 3c017f1b */ lui $at,%hi(var7f1aa5f0) +/* f07b6f4: c42aa5f0 */ lwc1 $f10,%lo(var7f1aa5f0)($at) +/* f07b6f8: c7b00110 */ lwc1 $f16,0x110($sp) +/* f07b6fc: 46123080 */ add.s $f2,$f6,$f18 +/* f07b700: 3c017f1b */ lui $at,%hi(var7f1aa5f4) +/* f07b704: 4602503c */ c.lt.s $f10,$f2 +/* f07b708: 00000000 */ nop +/* f07b70c: 45000002 */ bc1f .L0f07b718 +/* f07b710: 00000000 */ nop +/* f07b714: 46121081 */ sub.s $f2,$f2,$f18 +.L0f07b718: +/* f07b718: c42ca5f4 */ lwc1 $f12,%lo(var7f1aa5f4)($at) +/* f07b71c: c60000d8 */ lwc1 $f0,0xd8($s0) +/* f07b720: 3c017f1b */ lui $at,%hi(var7f1aa5f8) +/* f07b724: 460c003c */ c.lt.s $f0,$f12 +/* f07b728: 00000000 */ nop +/* f07b72c: 45000008 */ bc1f .L0f07b750 +/* f07b730: 00000000 */ nop +/* f07b734: c428a5f8 */ lwc1 $f8,%lo(var7f1aa5f8)($at) +/* f07b738: 3c01800a */ lui $at,%hi(g_Vars+0x44) +/* f07b73c: c424a004 */ lwc1 $f4,%lo(g_Vars+0x44)($at) +/* f07b740: 46044182 */ mul.s $f6,$f8,$f4 +/* f07b744: 46060280 */ add.s $f10,$f0,$f6 +/* f07b748: 10000014 */ b .L0f07b79c +/* f07b74c: e60a00d8 */ swc1 $f10,0xd8($s0) +.L0f07b750: +/* f07b750: 10000012 */ b .L0f07b79c +/* f07b754: e60c00d8 */ swc1 $f12,0xd8($s0) +/* f07b758: c60000d8 */ lwc1 $f0,0xd8($s0) +.L0f07b75c: +/* f07b75c: 44804000 */ mtc1 $zero,$f8 +/* f07b760: 3c013e00 */ lui $at,0x3e00 +/* f07b764: 44819000 */ mtc1 $at,$f18 +/* f07b768: 4600403c */ c.lt.s $f8,$f0 +/* f07b76c: 3c017f1b */ lui $at,%hi(var7f1aa5fc) +/* f07b770: 45020007 */ bc1fl .L0f07b790 +/* f07b774: 44805000 */ mtc1 $zero,$f10 +/* f07b778: c424a5fc */ lwc1 $f4,%lo(var7f1aa5fc)($at) +/* f07b77c: 46040181 */ sub.s $f6,$f0,$f4 +/* f07b780: e60600d8 */ swc1 $f6,0xd8($s0) +/* f07b784: 10000005 */ b .L0f07b79c +/* f07b788: e7b20108 */ swc1 $f18,0x108($sp) +/* f07b78c: 44805000 */ mtc1 $zero,$f10 +.L0f07b790: +/* f07b790: 00000000 */ nop +/* f07b794: e60a00d8 */ swc1 $f10,0xd8($s0) +/* f07b798: e7b20108 */ swc1 $f18,0x108($sp) +.L0f07b79c: +/* f07b79c: 3c01800a */ lui $at,%hi(g_Vars+0x44) +/* f07b7a0: c424a004 */ lwc1 $f4,%lo(g_Vars+0x44)($at) +/* f07b7a4: c60800d8 */ lwc1 $f8,0xd8($s0) +/* f07b7a8: c60a00dc */ lwc1 $f10,0xdc($s0) +/* f07b7ac: c7b20108 */ lwc1 $f18,0x108($sp) +/* f07b7b0: 46044182 */ mul.s $f6,$f8,$f4 +/* f07b7b4: 3c017f1b */ lui $at,%hi(var7f1aa600) +/* f07b7b8: 44058000 */ mfc1 $a1,$f16 +/* f07b7bc: 27a400ec */ addiu $a0,$sp,0xec +/* f07b7c0: 27a600e4 */ addiu $a2,$sp,0xe4 +/* f07b7c4: 46065200 */ add.s $f8,$f10,$f6 +/* f07b7c8: e60800dc */ swc1 $f8,0xdc($s0) +/* f07b7cc: c424a600 */ lwc1 $f4,%lo(var7f1aa600)($at) +/* f07b7d0: 3c017f1b */ lui $at,%hi(var7f1aa604) +/* f07b7d4: c42aa604 */ lwc1 $f10,%lo(var7f1aa604)($at) +/* f07b7d8: 46122302 */ mul.s $f12,$f4,$f18 +/* f07b7dc: 3c017f1b */ lui $at,%hi(var7f1aa608) +/* f07b7e0: c426a608 */ lwc1 $f6,%lo(var7f1aa608)($at) +/* f07b7e4: 46125002 */ mul.s $f0,$f10,$f18 +/* f07b7e8: e7b00110 */ swc1 $f16,0x110($sp) +/* f07b7ec: e7a2010c */ swc1 $f2,0x10c($sp) +/* f07b7f0: 46123382 */ mul.s $f14,$f6,$f18 +/* f07b7f4: 44076000 */ mfc1 $a3,$f12 +/* f07b7f8: e7ac0034 */ swc1 $f12,0x34($sp) +/* f07b7fc: e7a00010 */ swc1 $f0,0x10($sp) +/* f07b800: e7a00030 */ swc1 $f0,0x30($sp) +/* f07b804: e7ae0014 */ swc1 $f14,0x14($sp) +/* f07b808: 0fc1b643 */ jal applySpeed +/* f07b80c: e7ae002c */ swc1 $f14,0x2c($sp) +/* f07b810: c7b00110 */ lwc1 $f16,0x110($sp) +/* f07b814: c7a800ec */ lwc1 $f8,0xec($sp) +/* f07b818: c7a2010c */ lwc1 $f2,0x10c($sp) +/* f07b81c: c7a00030 */ lwc1 $f0,0x30($sp) +/* f07b820: 46104032 */ c.eq.s $f8,$f16 +/* f07b824: 44051000 */ mfc1 $a1,$f2 +/* f07b828: c7ac0034 */ lwc1 $f12,0x34($sp) +/* f07b82c: c7ae002c */ lwc1 $f14,0x2c($sp) +/* f07b830: 45000011 */ bc1f .L0f07b878 +/* f07b834: 27a400e8 */ addiu $a0,$sp,0xe8 +/* f07b838: c7b000e4 */ lwc1 $f16,0xe4($sp) +/* f07b83c: 3c017f1b */ lui $at,%hi(var7f1aa60c) +/* f07b840: c7aa0108 */ lwc1 $f10,0x108($sp) +/* f07b844: 4600803e */ c.le.s $f16,$f0 +/* f07b848: 00000000 */ nop +/* f07b84c: 4502000b */ bc1fl .L0f07b87c +/* f07b850: 44076000 */ mfc1 $a3,$f12 +/* f07b854: c424a60c */ lwc1 $f4,%lo(var7f1aa60c)($at) +/* f07b858: 460a2182 */ mul.s $f6,$f4,$f10 +/* f07b85c: 4610303e */ c.le.s $f6,$f16 +/* f07b860: 00000000 */ nop +/* f07b864: 45020005 */ bc1fl .L0f07b87c +/* f07b868: 44076000 */ mfc1 $a3,$f12 +/* f07b86c: 44808000 */ mtc1 $zero,$f16 +/* f07b870: 00000000 */ nop +/* f07b874: e7b000e4 */ swc1 $f16,0xe4($sp) +.L0f07b878: +/* f07b878: 44076000 */ mfc1 $a3,$f12 +.L0f07b87c: +/* f07b87c: 27a600e0 */ addiu $a2,$sp,0xe0 +/* f07b880: e7a00010 */ swc1 $f0,0x10($sp) +/* f07b884: e7ae0014 */ swc1 $f14,0x14($sp) +/* f07b888: e7a00030 */ swc1 $f0,0x30($sp) +/* f07b88c: 0fc1b643 */ jal applySpeed +/* f07b890: e7a2010c */ swc1 $f2,0x10c($sp) +/* f07b894: c7a2010c */ lwc1 $f2,0x10c($sp) +/* f07b898: c7a800e8 */ lwc1 $f8,0xe8($sp) +/* f07b89c: c7a00030 */ lwc1 $f0,0x30($sp) +/* f07b8a0: 46024032 */ c.eq.s $f8,$f2 +/* f07b8a4: c7a200e0 */ lwc1 $f2,0xe0($sp) +/* f07b8a8: 45020010 */ bc1fl .L0f07b8ec +/* f07b8ac: c7a800ec */ lwc1 $f8,0xec($sp) +/* f07b8b0: 4600103e */ c.le.s $f2,$f0 +/* f07b8b4: 3c017f1b */ lui $at,%hi(var7f1aa610) +/* f07b8b8: c7aa0108 */ lwc1 $f10,0x108($sp) +/* f07b8bc: 4502000b */ bc1fl .L0f07b8ec +/* f07b8c0: c7a800ec */ lwc1 $f8,0xec($sp) +/* f07b8c4: c424a610 */ lwc1 $f4,%lo(var7f1aa610)($at) +/* f07b8c8: 460a2182 */ mul.s $f6,$f4,$f10 +/* f07b8cc: 4602303e */ c.le.s $f6,$f2 +/* f07b8d0: 00000000 */ nop +/* f07b8d4: 45020005 */ bc1fl .L0f07b8ec +/* f07b8d8: c7a800ec */ lwc1 $f8,0xec($sp) +/* f07b8dc: 44801000 */ mtc1 $zero,$f2 +/* f07b8e0: 00000000 */ nop +/* f07b8e4: e7a200e0 */ swc1 $f2,0xe0($sp) +/* f07b8e8: c7a800ec */ lwc1 $f8,0xec($sp) +.L0f07b8ec: +/* f07b8ec: 8e1800e0 */ lw $t8,0xe0($s0) +/* f07b8f0: e60800d0 */ swc1 $f8,0xd0($s0) +/* f07b8f4: c7a400e8 */ lwc1 $f4,0xe8($sp) +/* f07b8f8: e60400d4 */ swc1 $f4,0xd4($s0) +/* f07b8fc: c7aa00e4 */ lwc1 $f10,0xe4($sp) +/* f07b900: e60a00c8 */ swc1 $f10,0xc8($s0) +/* f07b904: c7a600e0 */ lwc1 $f6,0xe0($sp) +/* f07b908: e60600cc */ swc1 $f6,0xcc($s0) +/* f07b90c: 93190000 */ lbu $t9,0x0($t8) +/* f07b910: 07210004 */ bgez $t9,.L0f07b924 +/* f07b914: 33280001 */ andi $t0,$t9,0x1 +/* f07b918: 11000002 */ beqz $t0,.L0f07b924 +/* f07b91c: 00000000 */ nop +/* f07b920: 2508fffe */ addiu $t0,$t0,-2 +.L0f07b924: +/* f07b924: 55000003 */ bnezl $t0,.L0f07b934 +/* f07b928: 8fa90114 */ lw $t1,0x114($sp) +/* f07b92c: afa00124 */ sw $zero,0x124($sp) +/* f07b930: 8fa90114 */ lw $t1,0x114($sp) +.L0f07b934: +/* f07b934: 24050003 */ addiu $a1,$zero,0x3 +/* f07b938: 0c006a47 */ jal modelGetPart +/* f07b93c: 8d240008 */ lw $a0,0x8($t1) +/* f07b940: 10400004 */ beqz $v0,.L0f07b954 +/* f07b944: 00402825 */ or $a1,$v0,$zero +/* f07b948: 0c006a87 */ jal modelGetNodeRwData +/* f07b94c: 8fa40114 */ lw $a0,0x114($sp) +/* f07b950: afa200d4 */ sw $v0,0xd4($sp) +.L0f07b954: +/* f07b954: 8faa0124 */ lw $t2,0x124($sp) +/* f07b958: 8faf00d4 */ lw $t7,0xd4($sp) +/* f07b95c: 1140002a */ beqz $t2,.L0f07ba08 +/* f07b960: 00000000 */ nop +/* f07b964: c60800d4 */ lwc1 $f8,0xd4($s0) +/* f07b968: c6040080 */ lwc1 $f4,0x80($s0) +/* f07b96c: 46044280 */ add.s $f10,$f8,$f4 +/* f07b970: e7aa0044 */ swc1 $f10,0x44($sp) +/* f07b974: c608007c */ lwc1 $f8,0x7c($s0) +/* f07b978: c60600d0 */ lwc1 $f6,0xd0($s0) +/* f07b97c: 46083300 */ add.s $f12,$f6,$f8 +/* f07b980: 0c0068f7 */ jal sinf +/* f07b984: e7ac0040 */ swc1 $f12,0x40($sp) +/* f07b988: e7a00038 */ swc1 $f0,0x38($sp) +/* f07b98c: 0c0068f4 */ jal cosf +/* f07b990: c7ac0044 */ lwc1 $f12,0x44($sp) +/* f07b994: c7a40038 */ lwc1 $f4,0x38($sp) +/* f07b998: c7ac0044 */ lwc1 $f12,0x44($sp) +/* f07b99c: 46040282 */ mul.s $f10,$f0,$f4 +/* f07b9a0: 0c0068f7 */ jal sinf +/* f07b9a4: e7aa00fc */ swc1 $f10,0xfc($sp) +/* f07b9a8: e7a00100 */ swc1 $f0,0x100($sp) +/* f07b9ac: 0c0068f4 */ jal cosf +/* f07b9b0: c7ac0040 */ lwc1 $f12,0x40($sp) +/* f07b9b4: e7a00038 */ swc1 $f0,0x38($sp) +/* f07b9b8: 0c0068f4 */ jal cosf +/* f07b9bc: c7ac0044 */ lwc1 $f12,0x44($sp) +/* f07b9c0: c7a60038 */ lwc1 $f6,0x38($sp) +/* f07b9c4: 8fac00dc */ lw $t4,0xdc($sp) +/* f07b9c8: 240b0059 */ addiu $t3,$zero,0x58 +/* f07b9cc: 46060202 */ mul.s $f8,$f0,$f6 +/* f07b9d0: 8fa40120 */ lw $a0,0x120($sp) +/* f07b9d4: 27a600f0 */ addiu $a2,$sp,0xf0 +/* f07b9d8: 27a700fc */ addiu $a3,$sp,0xfc +/* f07b9dc: e7a80104 */ swc1 $f8,0x104($sp) +/* f07b9e0: 8e0500e0 */ lw $a1,0xe0($s0) +/* f07b9e4: afab0010 */ sw $t3,0x10($sp) +/* f07b9e8: 0fc244b7 */ jal projectileCreate +/* f07b9ec: afac0014 */ sw $t4,0x14($sp) +/* f07b9f0: 8fad00d4 */ lw $t5,0xd4($sp) +/* f07b9f4: 240e0001 */ addiu $t6,$zero,0x1 +/* f07b9f8: 51a00007 */ beqzl $t5,.L0f07ba18 +/* f07b9fc: 8e0300e0 */ lw $v1,0xe0($s0) +/* f07ba00: 10000004 */ b .L0f07ba14 +/* f07ba04: a5ae0000 */ sh $t6,0x0($t5) +.L0f07ba08: +/* f07ba08: 51e00003 */ beqzl $t7,.L0f07ba18 +/* f07ba0c: 8e0300e0 */ lw $v1,0xe0($s0) +/* f07ba10: a5e00000 */ sh $zero,0x0($t7) +.L0f07ba14: +/* f07ba14: 8e0300e0 */ lw $v1,0xe0($s0) +.L0f07ba18: +/* f07ba18: 90780000 */ lbu $t8,0x0($v1) +/* f07ba1c: 27190001 */ addiu $t9,$t8,0x1 +/* f07ba20: a0790000 */ sb $t9,0x0($v1) +/* f07ba24: 8fbf0024 */ lw $ra,0x24($sp) +/* f07ba28: 8fb00020 */ lw $s0,0x20($sp) +/* f07ba2c: 27bd0120 */ addiu $sp,$sp,0x120 +/* f07ba30: 03e00008 */ jr $ra +/* f07ba34: 00000000 */ nop +); #endif #if VERSION >= VERSION_PAL_FINAL @@ -39877,6 +43021,530 @@ glabel var7f1aa668 /* f07c124: 03e00008 */ jr $ra /* f07c128: 00000000 */ nop ); +#elif VERSION >= VERSION_NTSC_1_0 +GLOBAL_ASM( +glabel func0f07ba38 +.late_rodata +glabel var7f1aa614 +.word 0x406ccccd +glabel var7f1aa618 +.word 0x3cfc9630 +glabel var7f1aa61c +.word 0x3d567664 +glabel var7f1aa620 +.word 0x40c907a9 +glabel var7f1aa624 +.word 0x3c23d70a +glabel var7f1aa628 +.word 0x3e19999a +glabel var7f1aa62c +.word 0x3f7ae148 +glabel var7f1aa630 +.word 0x40490fdb +glabel var7f1aa634 +.word 0x40b9999a +glabel var7f1aa638 +.word 0x39e4ba35 +glabel var7f1aa63c +.word 0x3c566e92 +glabel var7f1aa640 +.word 0x39e4ba35 +glabel var7f1aa644 +.word 0xb9e4ba35 +glabel var7f1aa648 +.word 0x39e4ba35 +glabel var7f1aa64c +.word 0x3c566e92 +glabel var7f1aa650 +.word 0x39e4ba35 +glabel var7f1aa654 +.word 0xb9e4ba35 +glabel var7f1aa658 +.word 0x3dcccccd +glabel var7f1aa65c +.word 0x40c907a9 +glabel var7f1aa660 +.word 0x40c907a9 +glabel var7f1aa664 +.word 0x3ee66666 +glabel var7f1aa668 +.word 0x3e32b021 +.text +/* f07ba38: 27bdfe88 */ addiu $sp,$sp,-376 +/* f07ba3c: afbf0024 */ sw $ra,0x24($sp) +/* f07ba40: afb00020 */ sw $s0,0x20($sp) +/* f07ba44: afa40178 */ sw $a0,0x178($sp) +/* f07ba48: afa5017c */ sw $a1,0x17c($sp) +/* f07ba4c: afa60180 */ sw $a2,0x180($sp) +/* f07ba50: 8c900004 */ lw $s0,0x4($a0) +/* f07ba54: 3c017f1b */ lui $at,%hi(var7f1aa614) +/* f07ba58: c604007c */ lwc1 $f4,0x7c($s0) +/* f07ba5c: e7a40150 */ swc1 $f4,0x150($sp) +/* f07ba60: c6060080 */ lwc1 $f6,0x80($s0) +/* f07ba64: e7a6014c */ swc1 $f6,0x14c($sp) +/* f07ba68: c6080084 */ lwc1 $f8,0x84($s0) +/* f07ba6c: e7a80148 */ swc1 $f8,0x148($sp) +/* f07ba70: c60a0070 */ lwc1 $f10,0x70($s0) +/* f07ba74: e7aa0144 */ swc1 $f10,0x144($sp) +/* f07ba78: c6120074 */ lwc1 $f18,0x74($s0) +/* f07ba7c: e7b20140 */ swc1 $f18,0x140($sp) +/* f07ba80: c4e40000 */ lwc1 $f4,0x0($a3) +/* f07ba84: c61200a4 */ lwc1 $f18,0xa4($s0) +/* f07ba88: e60400a8 */ swc1 $f4,0xa8($s0) +/* f07ba8c: c4e60004 */ lwc1 $f6,0x4($a3) +/* f07ba90: e60600ac */ swc1 $f6,0xac($s0) +/* f07ba94: c4e80008 */ lwc1 $f8,0x8($a3) +/* f07ba98: e60800b0 */ swc1 $f8,0xb0($s0) +/* f07ba9c: c4ea0000 */ lwc1 $f10,0x0($a3) +/* f07baa0: c4e60004 */ lwc1 $f6,0x4($a3) +/* f07baa4: 46125102 */ mul.s $f4,$f10,$f18 +/* f07baa8: c4f20008 */ lwc1 $f18,0x8($a3) +/* f07baac: e4e40000 */ swc1 $f4,0x0($a3) +/* f07bab0: c60800a4 */ lwc1 $f8,0xa4($s0) +/* f07bab4: 46083282 */ mul.s $f10,$f6,$f8 +/* f07bab8: e4ea0004 */ swc1 $f10,0x4($a3) +/* f07babc: c60400a4 */ lwc1 $f4,0xa4($s0) +/* f07bac0: 46049182 */ mul.s $f6,$f18,$f4 +/* f07bac4: e4e60008 */ swc1 $f6,0x8($a3) +/* f07bac8: c428a614 */ lwc1 $f8,%lo(var7f1aa614)($at) +/* f07bacc: c60000a4 */ lwc1 $f0,0xa4($s0) +/* f07bad0: 4608003c */ c.lt.s $f0,$f8 +/* f07bad4: 00000000 */ nop +/* f07bad8: 45000007 */ bc1f .L0f07baf8 +/* f07badc: 3c017f1b */ lui $at,%hi(var7f1aa618) +/* f07bae0: c42aa618 */ lwc1 $f10,%lo(var7f1aa618)($at) +/* f07bae4: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f07bae8: c432a00c */ lwc1 $f18,%lo(g_Vars+0x4c)($at) +/* f07baec: 46125102 */ mul.s $f4,$f10,$f18 +/* f07baf0: 46040180 */ add.s $f6,$f0,$f4 +/* f07baf4: e60600a4 */ swc1 $f6,0xa4($s0) +.L0f07baf8: +/* f07baf8: 3c017f1b */ lui $at,%hi(var7f1aa61c) +/* f07bafc: c42aa61c */ lwc1 $f10,%lo(var7f1aa61c)($at) +/* f07bb00: c60800b4 */ lwc1 $f8,0xb4($s0) +/* f07bb04: 3c017f1b */ lui $at,%hi(var7f1aa620) +/* f07bb08: 460a4480 */ add.s $f18,$f8,$f10 +/* f07bb0c: e61200b4 */ swc1 $f18,0xb4($s0) +/* f07bb10: c60600b4 */ lwc1 $f6,0xb4($s0) +/* f07bb14: c424a620 */ lwc1 $f4,%lo(var7f1aa620)($at) +/* f07bb18: 4606203c */ c.lt.s $f4,$f6 +/* f07bb1c: 00000000 */ nop +/* f07bb20: 4502001d */ bc1fl .L0f07bb98 +/* f07bb24: c60c00b4 */ lwc1 $f12,0xb4($s0) +/* f07bb28: 44804000 */ mtc1 $zero,$f8 +/* f07bb2c: 00000000 */ nop +/* f07bb30: e60800b4 */ swc1 $f8,0xb4($s0) +/* f07bb34: 0c004b70 */ jal random +/* f07bb38: afa70184 */ sw $a3,0x184($sp) +/* f07bb3c: 304f0007 */ andi $t7,$v0,0x7 +/* f07bb40: 25f80002 */ addiu $t8,$t7,0x2 +/* f07bb44: 44985000 */ mtc1 $t8,$f10 +/* f07bb48: 8fa70184 */ lw $a3,0x184($sp) +/* f07bb4c: 07010005 */ bgez $t8,.L0f07bb64 +/* f07bb50: 468054a0 */ cvt.s.w $f18,$f10 +/* f07bb54: 3c014f80 */ lui $at,0x4f80 +/* f07bb58: 44812000 */ mtc1 $at,$f4 +/* f07bb5c: 00000000 */ nop +/* f07bb60: 46049480 */ add.s $f18,$f18,$f4 +.L0f07bb64: +/* f07bb64: 3c017f1b */ lui $at,%hi(var7f1aa624) +/* f07bb68: c426a624 */ lwc1 $f6,%lo(var7f1aa624)($at) +/* f07bb6c: 8e190008 */ lw $t9,0x8($s0) +/* f07bb70: 3c017f1b */ lui $at,%hi(var7f1aa628) +/* f07bb74: 46069202 */ mul.s $f8,$f18,$f6 +/* f07bb78: 00194000 */ sll $t0,$t9,0x0 +/* f07bb7c: 05010005 */ bgez $t0,.L0f07bb94 +/* f07bb80: e60800b8 */ swc1 $f8,0xb8($s0) +/* f07bb84: c60a00b8 */ lwc1 $f10,0xb8($s0) +/* f07bb88: c424a628 */ lwc1 $f4,%lo(var7f1aa628)($at) +/* f07bb8c: 46045482 */ mul.s $f18,$f10,$f4 +/* f07bb90: e61200b8 */ swc1 $f18,0xb8($s0) +.L0f07bb94: +/* f07bb94: c60c00b4 */ lwc1 $f12,0xb4($s0) +.L0f07bb98: +/* f07bb98: 0c0068f7 */ jal sinf +/* f07bb9c: afa70184 */ sw $a3,0x184($sp) +/* f07bba0: c60800b8 */ lwc1 $f8,0xb8($s0) +/* f07bba4: 8fa70184 */ lw $a3,0x184($sp) +/* f07bba8: 3c017f1b */ lui $at,%hi(var7f1aa62c) +/* f07bbac: 46004282 */ mul.s $f10,$f8,$f0 +/* f07bbb0: c4e60004 */ lwc1 $f6,0x4($a3) +/* f07bbb4: c42ca62c */ lwc1 $f12,%lo(var7f1aa62c)($at) +/* f07bbb8: 3c03800a */ lui $v1,%hi(g_Vars+0x38) +/* f07bbbc: 24020001 */ addiu $v0,$zero,0x1 +/* f07bbc0: 46006086 */ mov.s $f2,$f12 +/* f07bbc4: 460a3100 */ add.s $f4,$f6,$f10 +/* f07bbc8: e4e40004 */ swc1 $f4,0x4($a3) +/* f07bbcc: 8c639ff8 */ lw $v1,%lo(g_Vars+0x38)($v1) +/* f07bbd0: 28610002 */ slti $at,$v1,0x2 +/* f07bbd4: 14200005 */ bnez $at,.L0f07bbec +/* f07bbd8: 24420001 */ addiu $v0,$v0,0x1 +.L0f07bbdc: +/* f07bbdc: 0043082a */ slt $at,$v0,$v1 +/* f07bbe0: 460c1082 */ mul.s $f2,$f2,$f12 +/* f07bbe4: 5420fffd */ bnezl $at,.L0f07bbdc +/* f07bbe8: 24420001 */ addiu $v0,$v0,0x1 +.L0f07bbec: +/* f07bbec: c6120098 */ lwc1 $f18,0x98($s0) +/* f07bbf0: c4e80000 */ lwc1 $f8,0x0($a3) +/* f07bbf4: c60a009c */ lwc1 $f10,0x9c($s0) +/* f07bbf8: 92020096 */ lbu $v0,0x96($s0) +/* f07bbfc: 46089180 */ add.s $f6,$f18,$f8 +/* f07bc00: c60800a0 */ lwc1 $f8,0xa0($s0) +/* f07bc04: 24010002 */ addiu $at,$zero,0x2 +/* f07bc08: e6060098 */ swc1 $f6,0x98($s0) +/* f07bc0c: c4e40004 */ lwc1 $f4,0x4($a3) +/* f07bc10: 46045480 */ add.s $f18,$f10,$f4 +/* f07bc14: c6040098 */ lwc1 $f4,0x98($s0) +/* f07bc18: e612009c */ swc1 $f18,0x9c($s0) +/* f07bc1c: c4e60008 */ lwc1 $f6,0x8($a3) +/* f07bc20: 46022482 */ mul.s $f18,$f4,$f2 +/* f07bc24: 46064280 */ add.s $f10,$f8,$f6 +/* f07bc28: c608009c */ lwc1 $f8,0x9c($s0) +/* f07bc2c: e60a00a0 */ swc1 $f10,0xa0($s0) +/* f07bc30: 46024182 */ mul.s $f6,$f8,$f2 +/* f07bc34: c60a00a0 */ lwc1 $f10,0xa0($s0) +/* f07bc38: e6120098 */ swc1 $f18,0x98($s0) +/* f07bc3c: 46025102 */ mul.s $f4,$f10,$f2 +/* f07bc40: e606009c */ swc1 $f6,0x9c($s0) +/* f07bc44: 1041002b */ beq $v0,$at,.L0f07bcf4 +/* f07bc48: e60400a0 */ swc1 $f4,0xa0($s0) +/* f07bc4c: 14400004 */ bnez $v0,.L0f07bc60 +/* f07bc50: 3c0140a0 */ lui $at,0x40a0 +/* f07bc54: 8e0900c4 */ lw $t1,0xc4($s0) +/* f07bc58: 59200005 */ blezl $t1,.L0f07bc70 +/* f07bc5c: 3c014100 */ lui $at,0x4100 +.L0f07bc60: +/* f07bc60: 44810000 */ mtc1 $at,$f0 +/* f07bc64: 10000005 */ b .L0f07bc7c +/* f07bc68: c6020098 */ lwc1 $f2,0x98($s0) +/* f07bc6c: 3c014100 */ lui $at,0x4100 +.L0f07bc70: +/* f07bc70: 44810000 */ mtc1 $at,$f0 +/* f07bc74: 00000000 */ nop +/* f07bc78: c6020098 */ lwc1 $f2,0x98($s0) +.L0f07bc7c: +/* f07bc7c: c60c009c */ lwc1 $f12,0x9c($s0) +/* f07bc80: c60e00a0 */ lwc1 $f14,0xa0($s0) +/* f07bc84: 46021482 */ mul.s $f18,$f2,$f2 +/* f07bc88: 26040098 */ addiu $a0,$s0,0x98 +/* f07bc8c: 2605009c */ addiu $a1,$s0,0x9c +/* f07bc90: 460c6202 */ mul.s $f8,$f12,$f12 +/* f07bc94: 260600a0 */ addiu $a2,$s0,0xa0 +/* f07bc98: 460e7282 */ mul.s $f10,$f14,$f14 +/* f07bc9c: 00000000 */ nop +/* f07bca0: 46000102 */ mul.s $f4,$f0,$f0 +/* f07bca4: 46089180 */ add.s $f6,$f18,$f8 +/* f07bca8: 460a3400 */ add.s $f16,$f6,$f10 +/* f07bcac: 4610203c */ c.lt.s $f4,$f16 +/* f07bcb0: 00000000 */ nop +/* f07bcb4: 4500000f */ bc1f .L0f07bcf4 +/* f07bcb8: 00000000 */ nop +/* f07bcbc: 0c0011e4 */ jal guNormalize +/* f07bcc0: e7a0010c */ swc1 $f0,0x10c($sp) +/* f07bcc4: c7a0010c */ lwc1 $f0,0x10c($sp) +/* f07bcc8: c6120098 */ lwc1 $f18,0x98($s0) +/* f07bccc: c606009c */ lwc1 $f6,0x9c($s0) +/* f07bcd0: c60400a0 */ lwc1 $f4,0xa0($s0) +/* f07bcd4: 46009202 */ mul.s $f8,$f18,$f0 +/* f07bcd8: 00000000 */ nop +/* f07bcdc: 46003282 */ mul.s $f10,$f6,$f0 +/* f07bce0: 00000000 */ nop +/* f07bce4: 46002482 */ mul.s $f18,$f4,$f0 +/* f07bce8: e6080098 */ swc1 $f8,0x98($s0) +/* f07bcec: e60a009c */ swc1 $f10,0x9c($s0) +/* f07bcf0: e61200a0 */ swc1 $f18,0xa0($s0) +.L0f07bcf4: +/* f07bcf4: 3c017f1b */ lui $at,%hi(var7f1aa630) +/* f07bcf8: c7a20180 */ lwc1 $f2,0x180($sp) +/* f07bcfc: c428a630 */ lwc1 $f8,%lo(var7f1aa630)($at) +/* f07bd00: 3c073964 */ lui $a3,0x3964 +/* f07bd04: 34e7ba35 */ ori $a3,$a3,0xba35 +/* f07bd08: 4602403c */ c.lt.s $f8,$f2 +/* f07bd0c: 27a40150 */ addiu $a0,$sp,0x150 +/* f07bd10: 27a60144 */ addiu $a2,$sp,0x144 +/* f07bd14: 45000007 */ bc1f .L0f07bd34 +/* f07bd18: 3c017f1b */ lui $at,%hi(var7f1aa634) +/* f07bd1c: c420a634 */ lwc1 $f0,%lo(var7f1aa634)($at) +/* f07bd20: 4600103c */ c.lt.s $f2,$f0 +/* f07bd24: 00000000 */ nop +/* f07bd28: 45000002 */ bc1f .L0f07bd34 +/* f07bd2c: 00000000 */ nop +/* f07bd30: e7a00180 */ swc1 $f0,0x180($sp) +.L0f07bd34: +/* f07bd34: 3c017f1b */ lui $at,%hi(var7f1aa638) +/* f07bd38: c426a638 */ lwc1 $f6,%lo(var7f1aa638)($at) +/* f07bd3c: 3c017f1b */ lui $at,%hi(var7f1aa63c) +/* f07bd40: c42aa63c */ lwc1 $f10,%lo(var7f1aa63c)($at) +/* f07bd44: 8fa5017c */ lw $a1,0x17c($sp) +/* f07bd48: e7a60010 */ swc1 $f6,0x10($sp) +/* f07bd4c: 0fc1b6c0 */ jal applyRotation +/* f07bd50: e7aa0014 */ swc1 $f10,0x14($sp) +/* f07bd54: c7a40150 */ lwc1 $f4,0x150($sp) +/* f07bd58: c7b2017c */ lwc1 $f18,0x17c($sp) +/* f07bd5c: 3c073964 */ lui $a3,0x3964 +/* f07bd60: 34e7ba35 */ ori $a3,$a3,0xba35 +/* f07bd64: 46122032 */ c.eq.s $f4,$f18 +/* f07bd68: 27a4014c */ addiu $a0,$sp,0x14c +/* f07bd6c: 27a60140 */ addiu $a2,$sp,0x140 +/* f07bd70: 45000010 */ bc1f .L0f07bdb4 +/* f07bd74: 3c017f1b */ lui $at,%hi(var7f1aa640) +/* f07bd78: c428a640 */ lwc1 $f8,%lo(var7f1aa640)($at) +/* f07bd7c: c7a20144 */ lwc1 $f2,0x144($sp) +/* f07bd80: 3c017f1b */ lui $at,%hi(var7f1aa644) +/* f07bd84: 4608103e */ c.le.s $f2,$f8 +/* f07bd88: 00000000 */ nop +/* f07bd8c: 45000009 */ bc1f .L0f07bdb4 +/* f07bd90: 00000000 */ nop +/* f07bd94: c426a644 */ lwc1 $f6,%lo(var7f1aa644)($at) +/* f07bd98: 4602303e */ c.le.s $f6,$f2 +/* f07bd9c: 00000000 */ nop +/* f07bda0: 45000004 */ bc1f .L0f07bdb4 +/* f07bda4: 00000000 */ nop +/* f07bda8: 44801000 */ mtc1 $zero,$f2 +/* f07bdac: 00000000 */ nop +/* f07bdb0: e7a20144 */ swc1 $f2,0x144($sp) +.L0f07bdb4: +/* f07bdb4: 3c017f1b */ lui $at,%hi(var7f1aa648) +/* f07bdb8: c42aa648 */ lwc1 $f10,%lo(var7f1aa648)($at) +/* f07bdbc: 3c017f1b */ lui $at,%hi(var7f1aa64c) +/* f07bdc0: c424a64c */ lwc1 $f4,%lo(var7f1aa64c)($at) +/* f07bdc4: 8fa50180 */ lw $a1,0x180($sp) +/* f07bdc8: e7aa0010 */ swc1 $f10,0x10($sp) +/* f07bdcc: 0fc1b6c0 */ jal applyRotation +/* f07bdd0: e7a40014 */ swc1 $f4,0x14($sp) +/* f07bdd4: c7a0014c */ lwc1 $f0,0x14c($sp) +/* f07bdd8: c7b20180 */ lwc1 $f18,0x180($sp) +/* f07bddc: 46120032 */ c.eq.s $f0,$f18 +/* f07bde0: 00000000 */ nop +/* f07bde4: 45000010 */ bc1f .L0f07be28 +/* f07bde8: 3c017f1b */ lui $at,%hi(var7f1aa650) +/* f07bdec: c428a650 */ lwc1 $f8,%lo(var7f1aa650)($at) +/* f07bdf0: c7a20140 */ lwc1 $f2,0x140($sp) +/* f07bdf4: 3c017f1b */ lui $at,%hi(var7f1aa654) +/* f07bdf8: 4608103e */ c.le.s $f2,$f8 +/* f07bdfc: 00000000 */ nop +/* f07be00: 4502000a */ bc1fl .L0f07be2c +/* f07be04: c7a20144 */ lwc1 $f2,0x144($sp) +/* f07be08: c426a654 */ lwc1 $f6,%lo(var7f1aa654)($at) +/* f07be0c: 4602303e */ c.le.s $f6,$f2 +/* f07be10: 00000000 */ nop +/* f07be14: 45020005 */ bc1fl .L0f07be2c +/* f07be18: c7a20144 */ lwc1 $f2,0x144($sp) +/* f07be1c: 44801000 */ mtc1 $zero,$f2 +/* f07be20: 00000000 */ nop +/* f07be24: e7a20140 */ swc1 $f2,0x140($sp) +.L0f07be28: +/* f07be28: c7a20144 */ lwc1 $f2,0x144($sp) +.L0f07be2c: +/* f07be2c: 3c014220 */ lui $at,0x4220 +/* f07be30: 44812000 */ mtc1 $at,$f4 +/* f07be34: 46001287 */ neg.s $f10,$f2 +/* f07be38: c7ae0148 */ lwc1 $f14,0x148($sp) +/* f07be3c: 46045482 */ mul.s $f18,$f10,$f4 +/* f07be40: 3c017f1b */ lui $at,%hi(var7f1aa658) +/* f07be44: c426a658 */ lwc1 $f6,%lo(var7f1aa658)($at) +/* f07be48: 3c017f1b */ lui $at,%hi(var7f1aa65c) +/* f07be4c: c424a65c */ lwc1 $f4,%lo(var7f1aa65c)($at) +/* f07be50: 460e9201 */ sub.s $f8,$f18,$f14 +/* f07be54: 46002481 */ sub.s $f18,$f4,$f0 +/* f07be58: 46064282 */ mul.s $f10,$f8,$f6 +/* f07be5c: c7a80150 */ lwc1 $f8,0x150($sp) +/* f07be60: 44803000 */ mtc1 $zero,$f6 +/* f07be64: e7b200fc */ swc1 $f18,0xfc($sp) +/* f07be68: e7a80100 */ swc1 $f8,0x100($sp) +/* f07be6c: e7a60104 */ swc1 $f6,0x104($sp) +/* f07be70: 460a7380 */ add.s $f14,$f14,$f10 +/* f07be74: 44805000 */ mtc1 $zero,$f10 +/* f07be78: 00000000 */ nop +/* f07be7c: 460e503e */ c.le.s $f10,$f14 +/* f07be80: 00000000 */ nop +/* f07be84: 45000007 */ bc1f .L0f07bea4 +/* f07be88: 00000000 */ nop +/* f07be8c: 46007306 */ mov.s $f12,$f14 +/* f07be90: 27a5003c */ addiu $a1,$sp,0x3c +/* f07be94: 0c005900 */ jal mtx00016400 +/* f07be98: e7ae0148 */ swc1 $f14,0x148($sp) +/* f07be9c: 10000008 */ b .L0f07bec0 +/* f07bea0: 27a400fc */ addiu $a0,$sp,0xfc +.L0f07bea4: +/* f07bea4: 3c017f1b */ lui $at,%hi(var7f1aa660) +/* f07bea8: c424a660 */ lwc1 $f4,%lo(var7f1aa660)($at) +/* f07beac: 27a5003c */ addiu $a1,$sp,0x3c +/* f07beb0: e7ae0148 */ swc1 $f14,0x148($sp) +/* f07beb4: 0c005900 */ jal mtx00016400 +/* f07beb8: 46047300 */ add.s $f12,$f14,$f4 +/* f07bebc: 27a400fc */ addiu $a0,$sp,0xfc +.L0f07bec0: +/* f07bec0: 0c005923 */ jal mtx0001648c +/* f07bec4: 27a5007c */ addiu $a1,$sp,0x7c +/* f07bec8: 8e0a0018 */ lw $t2,0x18($s0) +/* f07becc: 27a5007c */ addiu $a1,$sp,0x7c +/* f07bed0: 0c0057c1 */ jal mtx00015f04 +/* f07bed4: c54c0014 */ lwc1 $f12,0x14($t2) +/* f07bed8: 27a4007c */ addiu $a0,$sp,0x7c +/* f07bedc: 27a5003c */ addiu $a1,$sp,0x3c +/* f07bee0: 0c005680 */ jal mtx00015a00 +/* f07bee4: 27a600bc */ addiu $a2,$sp,0xbc +/* f07bee8: 27a400bc */ addiu $a0,$sp,0xbc +/* f07beec: 0c005768 */ jal mtx00015da0 +/* f07bef0: 27a5011c */ addiu $a1,$sp,0x11c +/* f07bef4: 27a4011c */ addiu $a0,$sp,0x11c +/* f07bef8: 0c005736 */ jal mtx00015cd8 +/* f07befc: 2605001c */ addiu $a1,$s0,0x1c +/* f07bf00: 3c017f1b */ lui $at,%hi(var7f1aa664) +/* f07bf04: c432a664 */ lwc1 $f18,%lo(var7f1aa664)($at) +/* f07bf08: c60800a4 */ lwc1 $f8,0xa4($s0) +/* f07bf0c: 8fab0188 */ lw $t3,0x188($sp) +/* f07bf10: 4608903c */ c.lt.s $f18,$f8 +/* f07bf14: 00000000 */ nop +/* f07bf18: 4502001a */ bc1fl .L0f07bf84 +/* f07bf1c: 8fa40178 */ lw $a0,0x178($sp) +/* f07bf20: 55600018 */ bnezl $t3,.L0f07bf84 +/* f07bf24: 8fa40178 */ lw $a0,0x178($sp) +/* f07bf28: 8e0c000c */ lw $t4,0xc($s0) +/* f07bf2c: 000c6b00 */ sll $t5,$t4,0xc +/* f07bf30: 05a20014 */ bltzl $t5,.L0f07bf84 +/* f07bf34: 8fa40178 */ lw $a0,0x178($sp) +/* f07bf38: 0fc21a6a */ jal objIsHealthy +/* f07bf3c: 02002025 */ or $a0,$s0,$zero +/* f07bf40: 1040000f */ beqz $v0,.L0f07bf80 +/* f07bf44: 3c0e800a */ lui $t6,%hi(g_Vars+0x4b4) +/* f07bf48: 8dcea474 */ lw $t6,%lo(g_Vars+0x4b4)($t6) +/* f07bf4c: 24010022 */ addiu $at,$zero,0x22 +/* f07bf50: 8fa40178 */ lw $a0,0x178($sp) +/* f07bf54: 15c10003 */ bne $t6,$at,.L0f07bf64 +/* f07bf58: 24060006 */ addiu $a2,$zero,0x6 +/* f07bf5c: 10000002 */ b .L0f07bf68 +/* f07bf60: 3402810d */ dli $v0,0x810d +.L0f07bf64: +/* f07bf64: 34028110 */ dli $v0,0x8110 +.L0f07bf68: +/* f07bf68: 00022c00 */ sll $a1,$v0,0x10 +/* f07bf6c: 00057c03 */ sra $t7,$a1,0x10 +/* f07bf70: 0fc24a53 */ jal func0f09294c +/* f07bf74: 01e02825 */ or $a1,$t7,$zero +/* f07bf78: 10000006 */ b .L0f07bf94 +/* f07bf7c: c7a60150 */ lwc1 $f6,0x150($sp) +.L0f07bf80: +/* f07bf80: 8fa40178 */ lw $a0,0x178($sp) +.L0f07bf84: +/* f07bf84: 24050006 */ addiu $a1,$zero,0x6 +/* f07bf88: 0fc249af */ jal func0f0926bc +/* f07bf8c: 3406ffff */ dli $a2,0xffff +/* f07bf90: c7a60150 */ lwc1 $f6,0x150($sp) +.L0f07bf94: +/* f07bf94: 3c017f1b */ lui $at,%hi(var7f1aa668) +/* f07bf98: e606007c */ swc1 $f6,0x7c($s0) +/* f07bf9c: c7aa014c */ lwc1 $f10,0x14c($sp) +/* f07bfa0: e60a0080 */ swc1 $f10,0x80($s0) +/* f07bfa4: c7a40148 */ lwc1 $f4,0x148($sp) +/* f07bfa8: e6040084 */ swc1 $f4,0x84($s0) +/* f07bfac: c7b20144 */ lwc1 $f18,0x144($sp) +/* f07bfb0: e6120070 */ swc1 $f18,0x70($s0) +/* f07bfb4: c7a80140 */ lwc1 $f8,0x140($sp) +/* f07bfb8: e6080074 */ swc1 $f8,0x74($s0) +/* f07bfbc: c7a6017c */ lwc1 $f6,0x17c($sp) +/* f07bfc0: c7aa0150 */ lwc1 $f10,0x150($sp) +/* f07bfc4: c7b2017c */ lwc1 $f18,0x17c($sp) +/* f07bfc8: c7a40150 */ lwc1 $f4,0x150($sp) +/* f07bfcc: 460a303c */ c.lt.s $f6,$f10 +/* f07bfd0: 00000000 */ nop +/* f07bfd4: 45020004 */ bc1fl .L0f07bfe8 +/* f07bfd8: 46122081 */ sub.s $f2,$f4,$f18 +/* f07bfdc: 10000003 */ b .L0f07bfec +/* f07bfe0: 46065081 */ sub.s $f2,$f10,$f6 +/* f07bfe4: 46122081 */ sub.s $f2,$f4,$f18 +.L0f07bfe8: +/* f07bfe8: 46001087 */ neg.s $f2,$f2 +.L0f07bfec: +/* f07bfec: c428a668 */ lwc1 $f8,%lo(var7f1aa668)($at) +/* f07bff0: 8fa20178 */ lw $v0,0x178($sp) +/* f07bff4: 0000c025 */ or $t8,$zero,$zero +/* f07bff8: 4608103c */ c.lt.s $f2,$f8 +/* f07bffc: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f07c000: 45020003 */ bc1fl .L0f07c010 +/* f07c004: a6180092 */ sh $t8,0x92($s0) +/* f07c008: 24180001 */ addiu $t8,$zero,0x1 +/* f07c00c: a6180092 */ sh $t8,0x92($s0) +.L0f07c010: +/* f07c010: c420a00c */ lwc1 $f0,%lo(g_Vars+0x4c)($at) +/* f07c014: c6060098 */ lwc1 $f6,0x98($s0) +/* f07c018: c44a0008 */ lwc1 $f10,0x8($v0) +/* f07c01c: 24450028 */ addiu $a1,$v0,0x28 +/* f07c020: 46003102 */ mul.s $f4,$f6,$f0 +/* f07c024: 24440008 */ addiu $a0,$v0,0x8 +/* f07c028: 27a60154 */ addiu $a2,$sp,0x154 +/* f07c02c: 27a70160 */ addiu $a3,$sp,0x160 +/* f07c030: 46045480 */ add.s $f18,$f10,$f4 +/* f07c034: e7b20154 */ swc1 $f18,0x154($sp) +/* f07c038: c606009c */ lwc1 $f6,0x9c($s0) +/* f07c03c: c448000c */ lwc1 $f8,0xc($v0) +/* f07c040: 46003282 */ mul.s $f10,$f6,$f0 +/* f07c044: 460a4100 */ add.s $f4,$f8,$f10 +/* f07c048: e7a40158 */ swc1 $f4,0x158($sp) +/* f07c04c: c60600a0 */ lwc1 $f6,0xa0($s0) +/* f07c050: c4520010 */ lwc1 $f18,0x10($v0) +/* f07c054: afa50030 */ sw $a1,0x30($sp) +/* f07c058: 46003202 */ mul.s $f8,$f6,$f0 +/* f07c05c: 46089280 */ add.s $f10,$f18,$f8 +/* f07c060: 0fc1979d */ jal func0f065e74 +/* f07c064: e7aa015c */ swc1 $f10,0x15c($sp) +/* f07c068: 8fa40178 */ lw $a0,0x178($sp) +/* f07c06c: c7a40154 */ lwc1 $f4,0x154($sp) +/* f07c070: e4840008 */ swc1 $f4,0x8($a0) +/* f07c074: c7a60158 */ lwc1 $f6,0x158($sp) +/* f07c078: e486000c */ swc1 $f6,0xc($a0) +/* f07c07c: c7b2015c */ lwc1 $f18,0x15c($sp) +/* f07c080: 0fc19711 */ jal propDeregisterRooms +/* f07c084: e4920010 */ swc1 $f18,0x10($a0) +/* f07c088: 27a40160 */ addiu $a0,$sp,0x160 +/* f07c08c: 0fc195e9 */ jal roomsCopy +/* f07c090: 8fa50030 */ lw $a1,0x30($sp) +/* f07c094: 02002025 */ or $a0,$s0,$zero +/* f07c098: 00002825 */ or $a1,$zero,$zero +/* f07c09c: 0fc1a71c */ jal func0f069c70 +/* f07c0a0: 24060001 */ addiu $a2,$zero,0x1 +/* f07c0a4: 8fa40178 */ lw $a0,0x178($sp) +/* f07c0a8: 0fc1ecfc */ jal func0f07b3f0 +/* f07c0ac: 8fa50188 */ lw $a1,0x188($sp) +/* f07c0b0: 8e19000c */ lw $t9,0xc($s0) +/* f07c0b4: 00194300 */ sll $t0,$t9,0xc +/* f07c0b8: 05020014 */ bltzl $t0,.L0f07c10c +/* f07c0bc: 8fa40178 */ lw $a0,0x178($sp) +/* f07c0c0: 0fc21a6a */ jal objIsHealthy +/* f07c0c4: 02002025 */ or $a0,$s0,$zero +/* f07c0c8: 1040000f */ beqz $v0,.L0f07c108 +/* f07c0cc: 3c09800a */ lui $t1,%hi(g_Vars+0x4b4) +/* f07c0d0: 8d29a474 */ lw $t1,%lo(g_Vars+0x4b4)($t1) +/* f07c0d4: 24010022 */ addiu $at,$zero,0x22 +/* f07c0d8: 8fa40178 */ lw $a0,0x178($sp) +/* f07c0dc: 15210003 */ bne $t1,$at,.L0f07c0ec +/* f07c0e0: 24060005 */ addiu $a2,$zero,0x5 +/* f07c0e4: 10000002 */ b .L0f07c0f0 +/* f07c0e8: 3402810c */ dli $v0,0x810c +.L0f07c0ec: +/* f07c0ec: 3402810f */ dli $v0,0x810f +.L0f07c0f0: +/* f07c0f0: 00022c00 */ sll $a1,$v0,0x10 +/* f07c0f4: 00055403 */ sra $t2,$a1,0x10 +/* f07c0f8: 0fc24a53 */ jal func0f09294c +/* f07c0fc: 01402825 */ or $a1,$t2,$zero +/* f07c100: 10000006 */ b .L0f07c11c +/* f07c104: 8fbf0024 */ lw $ra,0x24($sp) +.L0f07c108: +/* f07c108: 8fa40178 */ lw $a0,0x178($sp) +.L0f07c10c: +/* f07c10c: 24050005 */ addiu $a1,$zero,0x5 +/* f07c110: 0fc249af */ jal func0f0926bc +/* f07c114: 3406ffff */ dli $a2,0xffff +/* f07c118: 8fbf0024 */ lw $ra,0x24($sp) +.L0f07c11c: +/* f07c11c: 8fb00020 */ lw $s0,0x20($sp) +/* f07c120: 27bd0178 */ addiu $sp,$sp,0x178 +/* f07c124: 03e00008 */ jr $ra +/* f07c128: 00000000 */ nop +); #else GLOBAL_ASM( glabel func0f07ba38 @@ -40272,9 +43940,9 @@ glabel var7f1aa668 /* f07bf54: 15c10003 */ bne $t6,$at,.L0f07bf64 /* f07bf58: 24060006 */ addiu $a2,$zero,0x6 /* f07bf5c: 10000002 */ b .L0f07bf68 -/* f07bf60: 3402810d */ dli $v0,0x810d +/* f07bf60: 3402810d */ dli $v0,0x810c .L0f07bf64: -/* f07bf64: 34028110 */ dli $v0,0x8110 +/* f07bf64: 34028110 */ dli $v0,0x810f .L0f07bf68: /* f07bf68: 00022c00 */ sll $a1,$v0,0x10 /* f07bf6c: 00057c03 */ sra $t7,$a1,0x10 @@ -40378,9 +44046,9 @@ glabel var7f1aa668 /* f07c0dc: 15210003 */ bne $t1,$at,.L0f07c0ec /* f07c0e0: 24060005 */ addiu $a2,$zero,0x5 /* f07c0e4: 10000002 */ b .L0f07c0f0 -/* f07c0e8: 3402810c */ dli $v0,0x810c +/* f07c0e8: 3402810c */ dli $v0,0x810b .L0f07c0ec: -/* f07c0ec: 3402810f */ dli $v0,0x810f +/* f07c0ec: 3402810f */ dli $v0,0x810e .L0f07c0f0: /* f07c0f0: 00022c00 */ sll $a1,$v0,0x10 /* f07c0f4: 00055403 */ sra $t2,$a1,0x10 @@ -60426,6 +64094,7 @@ void currentPlayerQueuePickupAmmoHudmsg(s32 ammotype, s32 pickupqty) hudmsgCreateWithFlags(buffer, HUDMSGTYPE_DEFAULT, HUDMSGFLAG_ONLYIFALIVE); } +#if VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel func0f088028 /* f088028: 27bdffd8 */ addiu $sp,$sp,-40 @@ -60536,6 +64205,118 @@ glabel func0f088028 /* f088194: 03e00008 */ jr $ra /* f088198: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel func0f088028 +/* f088028: 27bdffd8 */ addiu $sp,$sp,-40 +/* f08802c: afb00018 */ sw $s0,0x18($sp) +/* f088030: 00808025 */ or $s0,$a0,$zero +/* f088034: afbf001c */ sw $ra,0x1c($sp) +/* f088038: afa5002c */ sw $a1,0x2c($sp) +/* f08803c: afa60030 */ sw $a2,0x30($sp) +/* f088040: 18a00051 */ blez $a1,.L0f088188 +/* f088044: afa70034 */ sw $a3,0x34($sp) +/* f088048: 0fc2a5dc */ jal bgunGetReservedAmmoCount +/* f08804c: 00000000 */ nop +/* f088050: afa20020 */ sw $v0,0x20($sp) +/* f088054: 0fc2a63d */ jal bgunGetCapacityByAmmotype +/* f088058: 02002025 */ or $a0,$s0,$zero +/* f08805c: 8faf0020 */ lw $t7,0x20($sp) +/* f088060: 01e2082a */ slt $at,$t7,$v0 +/* f088064: 5020000e */ beqzl $at,.L0f0880a0 +/* f088068: 8fa80030 */ lw $t0,0x30($sp) +/* f08806c: 0fc2a5dc */ jal bgunGetReservedAmmoCount +/* f088070: 02002025 */ or $a0,$s0,$zero +/* f088074: 8fb8002c */ lw $t8,0x2c($sp) +/* f088078: 02002025 */ or $a0,$s0,$zero +/* f08807c: 0fc2a58a */ jal bgunSetAmmoQuantity +/* f088080: 00582821 */ addu $a1,$v0,$t8 +/* f088084: 8fb90034 */ lw $t9,0x34($sp) +/* f088088: 02002025 */ or $a0,$s0,$zero +/* f08808c: 53200004 */ beqzl $t9,.L0f0880a0 +/* f088090: 8fa80030 */ lw $t0,0x30($sp) +/* f088094: 0fc21fec */ jal currentPlayerQueuePickupAmmoHudmsg +/* f088098: 8fa5002c */ lw $a1,0x2c($sp) +/* f08809c: 8fa80030 */ lw $t0,0x30($sp) +.L0f0880a0: +/* f0880a0: 51000004 */ beqzl $t0,.L0f0880b4 +/* f0880a4: 24010007 */ addiu $at,$zero,0x7 +/* f0880a8: 0fc21ec3 */ jal ammotypePlayPickupSound +/* f0880ac: 02002025 */ or $a0,$s0,$zero +/* f0880b0: 24010007 */ addiu $at,$zero,0x7 +.L0f0880b4: +/* f0880b4: 56010004 */ bnel $s0,$at,.L0f0880c8 +/* f0880b8: 2401000c */ addiu $at,$zero,0xc +/* f0880bc: 1000002e */ b .L0f088178 +/* f0880c0: 2404001e */ addiu $a0,$zero,0x1e +/* f0880c4: 2401000c */ addiu $at,$zero,0xc +.L0f0880c8: +/* f0880c8: 56010004 */ bnel $s0,$at,.L0f0880dc +/* f0880cc: 2401000d */ addiu $at,$zero,0xd +/* f0880d0: 10000029 */ b .L0f088178 +/* f0880d4: 24040022 */ addiu $a0,$zero,0x22 +/* f0880d8: 2401000d */ addiu $at,$zero,0xd +.L0f0880dc: +/* f0880dc: 56010004 */ bnel $s0,$at,.L0f0880f0 +/* f0880e0: 2401000e */ addiu $at,$zero,0xe +/* f0880e4: 10000024 */ b .L0f088178 +/* f0880e8: 24040021 */ addiu $a0,$zero,0x21 +/* f0880ec: 2401000e */ addiu $at,$zero,0xe +.L0f0880f0: +/* f0880f0: 56010004 */ bnel $s0,$at,.L0f088104 +/* f0880f4: 24010012 */ addiu $at,$zero,0x12 +/* f0880f8: 1000001f */ b .L0f088178 +/* f0880fc: 24040020 */ addiu $a0,$zero,0x20 +/* f088100: 24010012 */ addiu $at,$zero,0x12 +.L0f088104: +/* f088104: 56010004 */ bnel $s0,$at,.L0f088118 +/* f088108: 24010009 */ addiu $at,$zero,0x9 +/* f08810c: 1000001a */ b .L0f088178 +/* f088110: 2404001f */ addiu $a0,$zero,0x1f +/* f088114: 24010009 */ addiu $at,$zero,0x9 +.L0f088118: +/* f088118: 56010004 */ bnel $s0,$at,.L0f08812c +/* f08811c: 24010020 */ addiu $at,$zero,0x20 +/* f088120: 10000015 */ b .L0f088178 +/* f088124: 2404001a */ addiu $a0,$zero,0x1a +/* f088128: 24010020 */ addiu $at,$zero,0x20 +.L0f08812c: +/* f08812c: 56010004 */ bnel $s0,$at,.L0f088140 +/* f088130: 2401001e */ addiu $at,$zero,0x1e +/* f088134: 10000010 */ b .L0f088178 +/* f088138: 24040035 */ addiu $a0,$zero,0x35 +/* f08813c: 2401001e */ addiu $at,$zero,0x1e +.L0f088140: +/* f088140: 56010004 */ bnel $s0,$at,.L0f088154 +/* f088144: 24010014 */ addiu $at,$zero,0x14 +/* f088148: 1000000b */ b .L0f088178 +/* f08814c: 24040057 */ addiu $a0,$zero,0x56 +/* f088150: 24010014 */ addiu $at,$zero,0x14 +.L0f088154: +/* f088154: 56010004 */ bnel $s0,$at,.L0f088168 +/* f088158: 24010015 */ addiu $at,$zero,0x15 +/* f08815c: 10000006 */ b .L0f088178 +/* f088160: 24040031 */ addiu $a0,$zero,0x31 +/* f088164: 24010015 */ addiu $at,$zero,0x15 +.L0f088168: +/* f088168: 16010003 */ bne $s0,$at,.L0f088178 +/* f08816c: 2404ffff */ addiu $a0,$zero,-1 +/* f088170: 10000001 */ b .L0f088178 +/* f088174: 24040023 */ addiu $a0,$zero,0x23 +.L0f088178: +/* f088178: 04820004 */ bltzl $a0,.L0f08818c +/* f08817c: 8fbf001c */ lw $ra,0x1c($sp) +/* f088180: 0fc44762 */ jal invGiveSingleWeapon +/* f088184: 00000000 */ nop +.L0f088188: +/* f088188: 8fbf001c */ lw $ra,0x1c($sp) +.L0f08818c: +/* f08818c: 8fb00018 */ lw $s0,0x18($sp) +/* f088190: 27bd0028 */ addiu $sp,$sp,0x28 +/* f088194: 03e00008 */ jr $ra +/* f088198: 00000000 */ nop +); +#endif s32 ammocrateGetPickupAmmoQty(struct ammocrateobj *crate) { @@ -61474,7 +65255,7 @@ glabel var7f1aae70 /* f08900c: 03e00008 */ jr $ra /* f089010: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel propPickupByPlayer .late_rodata @@ -62121,6 +65902,653 @@ glabel var7f1aae70 /* f08900c: 03e00008 */ jr $ra /* f089010: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel propPickupByPlayer +.late_rodata +glabel var7f1aadc0 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadc4 +.word propPickupByPlayer+0x74 # f0888b4 +glabel var7f1aadc8 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadcc +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadd0 +.word propPickupByPlayer+0xf4 # f088934 +glabel var7f1aadd4 +.word propPickupByPlayer+0x1f4 # f088a34 +glabel var7f1aadd8 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aaddc +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aade0 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aade4 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aade8 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadec +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadf0 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadf4 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadf8 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aadfc +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae00 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae04 +.word propPickupByPlayer+0x134 # f088974 +glabel var7f1aae08 +.word propPickupByPlayer+0x590 # f088dd0 +glabel var7f1aae0c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae10 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae14 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae18 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae1c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae20 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae24 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae28 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae2c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae30 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae34 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae38 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae3c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae40 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae44 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae48 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae4c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae50 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae54 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae58 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae5c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae60 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae64 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae68 +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae6c +.word propPickupByPlayer+0x6e0 # f088f20 +glabel var7f1aae70 +.word propPickupByPlayer+0x6e0 # f088f20 +.text +/* f088840: 27bdff60 */ addiu $sp,$sp,-160 +/* f088844: afbf0024 */ sw $ra,0x24($sp) +/* f088848: afa400a0 */ sw $a0,0xa0($sp) +/* f08884c: afa500a4 */ sw $a1,0xa4($sp) +/* f088850: 3c08800a */ lui $t0,%hi(g_Vars) +/* f088854: 8c860004 */ lw $a2,0x4($a0) +/* f088858: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f08885c: 8d020284 */ lw $v0,0x284($t0) +/* f088860: afa00094 */ sw $zero,0x94($sp) +/* f088864: afa6009c */ sw $a2,0x9c($sp) +/* f088868: 8c4f00d8 */ lw $t7,0xd8($v0) +/* f08886c: 15e00005 */ bnez $t7,.L0f088884 +/* f088870: 00000000 */ nop +/* f088874: 8d180034 */ lw $t8,0x34($t0) +/* f088878: 8fb9009c */ lw $t9,0x9c($sp) +/* f08887c: 57000004 */ bnezl $t8,.L0f088890 +/* f088880: 93290003 */ lbu $t1,0x3($t9) +.L0f088884: +/* f088884: 100001df */ b .L0f089004 +/* f088888: 00001025 */ or $v0,$zero,$zero +/* f08888c: 93290003 */ lbu $t1,0x3($t9) +.L0f088890: +/* f088890: 252afffd */ addiu $t2,$t1,-3 +/* f088894: 2d41002d */ sltiu $at,$t2,0x2d +/* f088898: 102001a1 */ beqz $at,.L0f088f20 +/* f08889c: 000a5080 */ sll $t2,$t2,0x2 +/* f0888a0: 3c017f1b */ lui $at,%hi(var7f1aadc0) +/* f0888a4: 002a0821 */ addu $at,$at,$t2 +/* f0888a8: 8c2aadc0 */ lw $t2,%lo(var7f1aadc0)($at) +/* f0888ac: 01400008 */ jr $t2 +/* f0888b0: 00000000 */ nop +/* f0888b4: 8d0b04cc */ lw $t3,0x4cc($t0) +/* f0888b8: 3c048009 */ lui $a0,%hi(var80095200) +/* f0888bc: 240500e5 */ addiu $a1,$zero,0xe5 +/* f0888c0: 1560000d */ bnez $t3,.L0f0888f8 +/* f0888c4: 00003025 */ or $a2,$zero,$zero +/* f0888c8: 3c01bf80 */ lui $at,0xbf80 +/* f0888cc: 44812000 */ mtc1 $at,$f4 +/* f0888d0: 240cffff */ addiu $t4,$zero,-1 +/* f0888d4: 240dffff */ addiu $t5,$zero,-1 +/* f0888d8: 240effff */ addiu $t6,$zero,-1 +/* f0888dc: afae001c */ sw $t6,0x1c($sp) +/* f0888e0: afad0018 */ sw $t5,0x18($sp) +/* f0888e4: afac0010 */ sw $t4,0x10($sp) +/* f0888e8: 8c845200 */ lw $a0,%lo(var80095200)($a0) +/* f0888ec: 2407ffff */ addiu $a3,$zero,-1 +/* f0888f0: 0c004241 */ jal sndStart +/* f0888f4: e7a40014 */ swc1 $f4,0x14($sp) +.L0f0888f8: +/* f0888f8: 8faf00a4 */ lw $t7,0xa4($sp) +/* f0888fc: 11e0000b */ beqz $t7,.L0f08892c +/* f088900: 00000000 */ nop +/* f088904: 0fc44bfb */ jal invGetActivatedTextByObj +/* f088908: 8fa4009c */ lw $a0,0x9c($sp) +/* f08890c: 14400004 */ bnez $v0,.L0f088920 +/* f088910: 00402025 */ or $a0,$v0,$zero +/* f088914: 0fc5b9f1 */ jal langGet +/* f088918: 24045228 */ addiu $a0,$zero,0x5228 +/* f08891c: 00402025 */ or $a0,$v0,$zero +.L0f088920: +/* f088920: 00002825 */ or $a1,$zero,$zero +/* f088924: 0fc377e9 */ jal hudmsgCreateWithFlags +/* f088928: 24060009 */ addiu $a2,$zero,0x9 +.L0f08892c: +/* f08892c: 1000019d */ b .L0f088fa4 +/* f088930: 24020004 */ addiu $v0,$zero,0x4 +/* f088934: 00c02025 */ or $a0,$a2,$zero +/* f088938: 0fc22067 */ jal ammocrateGetPickupAmmoQty +/* f08893c: afa6008c */ sw $a2,0x8c($sp) +/* f088940: 3c06800a */ lui $a2,%hi(g_Vars+0x4cc) +/* f088944: 8cc6a48c */ lw $a2,%lo(g_Vars+0x4cc)($a2) +/* f088948: 8fb9008c */ lw $t9,0x8c($sp) +/* f08894c: 00402825 */ or $a1,$v0,$zero +/* f088950: 2cd80001 */ sltiu $t8,$a2,0x1 +/* f088954: 03003025 */ or $a2,$t8,$zero +/* f088958: 8fa700a4 */ lw $a3,0xa4($sp) +/* f08895c: 0fc2200a */ jal func0f088028 +/* f088960: 8f24005c */ lw $a0,0x5c($t9) +/* f088964: 24090001 */ addiu $t1,$zero,0x1 +/* f088968: afa90098 */ sw $t1,0x98($sp) +/* f08896c: 1000018d */ b .L0f088fa4 +/* f088970: 24020001 */ addiu $v0,$zero,0x1 +/* f088974: 00001025 */ or $v0,$zero,$zero +/* f088978: 00c01825 */ or $v1,$a2,$zero +.L0f08897c: +/* f08897c: 3c08800a */ lui $t0,%hi(g_Vars) +/* f088980: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f088984: 8d0a0318 */ lw $t2,0x318($t0) +/* f088988: 9465005e */ lhu $a1,0x5e($v1) +/* f08898c: 24440001 */ addiu $a0,$v0,0x1 +/* f088990: 15400009 */ bnez $t2,.L0f0889b8 +/* f088994: 00003025 */ or $a2,$zero,$zero +/* f088998: 44853000 */ mtc1 $a1,$f6 +/* f08899c: 3c018007 */ lui $at,%hi(g_AmmoMultiplier) +/* f0889a0: c42a995c */ lwc1 $f10,%lo(g_AmmoMultiplier)($at) +/* f0889a4: 46803220 */ cvt.s.w $f8,$f6 +/* f0889a8: 460a4402 */ mul.s $f16,$f8,$f10 +/* f0889ac: 4600848d */ trunc.w.s $f18,$f16 +/* f0889b0: 44059000 */ mfc1 $a1,$f18 +/* f0889b4: 00000000 */ nop +.L0f0889b8: +/* f0889b8: 8fa700a4 */ lw $a3,0xa4($sp) +/* f0889bc: afa30028 */ sw $v1,0x28($sp) +/* f0889c0: 0fc2200a */ jal func0f088028 +/* f0889c4: afa4002c */ sw $a0,0x2c($sp) +/* f0889c8: 8fa2002c */ lw $v0,0x2c($sp) +/* f0889cc: 8fa30028 */ lw $v1,0x28($sp) +/* f0889d0: 24010013 */ addiu $at,$zero,0x13 +/* f0889d4: 1441ffe9 */ bne $v0,$at,.L0f08897c +/* f0889d8: 24630004 */ addiu $v1,$v1,0x4 +/* f0889dc: 3c0c800a */ lui $t4,%hi(g_Vars+0x4cc) +/* f0889e0: 8d8ca48c */ lw $t4,%lo(g_Vars+0x4cc)($t4) +/* f0889e4: 3c048009 */ lui $a0,%hi(var80095200) +/* f0889e8: 240500ea */ addiu $a1,$zero,0xea +/* f0889ec: 1580000d */ bnez $t4,.L0f088a24 +/* f0889f0: 00003025 */ or $a2,$zero,$zero +/* f0889f4: 3c01bf80 */ lui $at,0xbf80 +/* f0889f8: 44812000 */ mtc1 $at,$f4 +/* f0889fc: 240dffff */ addiu $t5,$zero,-1 +/* f088a00: 240effff */ addiu $t6,$zero,-1 +/* f088a04: 240fffff */ addiu $t7,$zero,-1 +/* f088a08: afaf001c */ sw $t7,0x1c($sp) +/* f088a0c: afae0018 */ sw $t6,0x18($sp) +/* f088a10: afad0010 */ sw $t5,0x10($sp) +/* f088a14: 8c845200 */ lw $a0,%lo(var80095200)($a0) +/* f088a18: 2407ffff */ addiu $a3,$zero,-1 +/* f088a1c: 0c004241 */ jal sndStart +/* f088a20: e7a40014 */ swc1 $f4,0x14($sp) +.L0f088a24: +/* f088a24: 24180001 */ addiu $t8,$zero,0x1 +/* f088a28: afb80098 */ sw $t8,0x98($sp) +/* f088a2c: 1000015d */ b .L0f088fa4 +/* f088a30: 24020001 */ addiu $v0,$zero,0x1 +/* f088a34: 8d190318 */ lw $t9,0x318($t0) +/* f088a38: afa60074 */ sw $a2,0x74($sp) +/* f088a3c: afa00070 */ sw $zero,0x70($sp) +/* f088a40: 13200022 */ beqz $t9,.L0f088acc +/* f088a44: afa00068 */ sw $zero,0x68($sp) +/* f088a48: 90c5005c */ lbu $a1,0x5c($a2) +/* f088a4c: 24010057 */ addiu $at,$zero,0x56 +/* f088a50: 54a1000f */ bnel $a1,$at,.L0f088a90 +/* f088a54: 24010036 */ addiu $at,$zero,0x36 +/* f088a58: 8c4a00bc */ lw $t2,0xbc($v0) +/* f088a5c: 8fa500a0 */ lw $a1,0xa0($sp) +/* f088a60: 0fc61a26 */ jal chrGiveBriefcase +/* f088a64: 8d440004 */ lw $a0,0x4($t2) +/* f088a68: 10400006 */ beqz $v0,.L0f088a84 +/* f088a6c: 00401825 */ or $v1,$v0,$zero +/* f088a70: 8fab0074 */ lw $t3,0x74($sp) +/* f088a74: 9164005c */ lbu $a0,0x5c($t3) +/* f088a78: 0fc21f44 */ jal weaponPlayPickupSound +/* f088a7c: afa20064 */ sw $v0,0x64($sp) +/* f088a80: 8fa30064 */ lw $v1,0x64($sp) +.L0f088a84: +/* f088a84: 1000015f */ b .L0f089004 +/* f088a88: 00601025 */ or $v0,$v1,$zero +/* f088a8c: 24010036 */ addiu $at,$zero,0x36 +.L0f088a90: +/* f088a90: 54a1000f */ bnel $a1,$at,.L0f088ad0 +/* f088a94: 8d0f04cc */ lw $t7,0x4cc($t0) +/* f088a98: 8c4c00bc */ lw $t4,0xbc($v0) +/* f088a9c: 8fa500a0 */ lw $a1,0xa0($sp) +/* f088aa0: 0fc61d04 */ jal chrGiveUplink +/* f088aa4: 8d840004 */ lw $a0,0x4($t4) +/* f088aa8: 10400006 */ beqz $v0,.L0f088ac4 +/* f088aac: 00401825 */ or $v1,$v0,$zero +/* f088ab0: 8fad0074 */ lw $t5,0x74($sp) +/* f088ab4: 91a4005c */ lbu $a0,0x5c($t5) +/* f088ab8: 0fc21f44 */ jal weaponPlayPickupSound +/* f088abc: afa20064 */ sw $v0,0x64($sp) +/* f088ac0: 8fa30064 */ lw $v1,0x64($sp) +.L0f088ac4: +/* f088ac4: 1000014f */ b .L0f089004 +/* f088ac8: 00601025 */ or $v0,$v1,$zero +.L0f088acc: +/* f088acc: 8d0f04cc */ lw $t7,0x4cc($t0) +.L0f088ad0: +/* f088ad0: 8fae0074 */ lw $t6,0x74($sp) +/* f088ad4: 15e00007 */ bnez $t7,.L0f088af4 +/* f088ad8: 91c5005c */ lbu $a1,0x5c($t6) +/* f088adc: 0fc21f44 */ jal weaponPlayPickupSound +/* f088ae0: 00a02025 */ or $a0,$a1,$zero +/* f088ae4: 8fb80074 */ lw $t8,0x74($sp) +/* f088ae8: 3c08800a */ lui $t0,%hi(g_Vars) +/* f088aec: 25089fc0 */ addiu $t0,$t0,%lo(g_Vars) +/* f088af0: 9305005c */ lbu $a1,0x5c($t8) +.L0f088af4: +/* f088af4: 8fb9009c */ lw $t9,0x9c($sp) +/* f088af8: 24010056 */ addiu $at,$zero,0x55 +/* f088afc: 8f290040 */ lw $t1,0x40($t9) +/* f088b00: 312a0400 */ andi $t2,$t1,0x400 +/* f088b04: 11400020 */ beqz $t2,.L0f088b88 +/* f088b08: 00000000 */ nop +/* f088b0c: 28a1002d */ slti $at,$a1,0x2d +/* f088b10: 50200007 */ beqzl $at,.L0f088b30 +/* f088b14: 8fac00a4 */ lw $t4,0xa4($sp) +/* f088b18: 0fc4483c */ jal invGiveWeaponsByProp +/* f088b1c: 8fa400a0 */ lw $a0,0xa0($sp) +/* f088b20: 240b0001 */ addiu $t3,$zero,0x1 +/* f088b24: afa20068 */ sw $v0,0x68($sp) +/* f088b28: afab0094 */ sw $t3,0x94($sp) +/* f088b2c: 8fac00a4 */ lw $t4,0xa4($sp) +.L0f088b30: +/* f088b30: 51800013 */ beqzl $t4,.L0f088b80 +/* f088b34: 24180004 */ addiu $t8,$zero,0x4 +/* f088b38: 0fc44bfb */ jal invGetActivatedTextByObj +/* f088b3c: 8fa4009c */ lw $a0,0x9c($sp) +/* f088b40: 10400006 */ beqz $v0,.L0f088b5c +/* f088b44: 00402025 */ or $a0,$v0,$zero +/* f088b48: 00002825 */ or $a1,$zero,$zero +/* f088b4c: 0fc377e9 */ jal hudmsgCreateWithFlags +/* f088b50: 24060009 */ addiu $a2,$zero,0x9 +/* f088b54: 10000008 */ b .L0f088b78 +/* f088b58: 240f0001 */ addiu $t7,$zero,0x1 +.L0f088b5c: +/* f088b5c: 8fa50068 */ lw $a1,0x68($sp) +/* f088b60: 8fad0074 */ lw $t5,0x74($sp) +/* f088b64: 38ae0002 */ xori $t6,$a1,0x2 +/* f088b68: 2dc50001 */ sltiu $a1,$t6,0x1 +/* f088b6c: 0fc221f2 */ jal currentPlayerQueuePickupWeaponHudmsg +/* f088b70: 91a4005c */ lbu $a0,0x5c($t5) +/* f088b74: 240f0001 */ addiu $t7,$zero,0x1 +.L0f088b78: +/* f088b78: afaf0070 */ sw $t7,0x70($sp) +/* f088b7c: 24180004 */ addiu $t8,$zero,0x4 +.L0f088b80: +/* f088b80: 10000033 */ b .L0f088c50 +/* f088b84: afb80098 */ sw $t8,0x98($sp) +.L0f088b88: +/* f088b88: 14a10011 */ bne $a1,$at,.L0f088bd0 +/* f088b8c: 24190001 */ addiu $t9,$zero,0x1 +/* f088b90: 8d0604cc */ lw $a2,0x4cc($t0) +/* f088b94: 24090001 */ addiu $t1,$zero,0x1 +/* f088b98: afb90068 */ sw $t9,0x68($sp) +/* f088b9c: 2cca0001 */ sltiu $t2,$a2,0x1 +/* f088ba0: afa90094 */ sw $t1,0x94($sp) +/* f088ba4: 01403025 */ or $a2,$t2,$zero +/* f088ba8: 24040003 */ addiu $a0,$zero,0x3 +/* f088bac: 24050001 */ addiu $a1,$zero,0x1 +/* f088bb0: 0fc2200a */ jal func0f088028 +/* f088bb4: 24070001 */ addiu $a3,$zero,0x1 +/* f088bb8: 240b0001 */ addiu $t3,$zero,0x1 +/* f088bbc: 240c0001 */ addiu $t4,$zero,0x1 +/* f088bc0: afab0098 */ sw $t3,0x98($sp) +/* f088bc4: afa000a4 */ sw $zero,0xa4($sp) +/* f088bc8: 10000021 */ b .L0f088c50 +/* f088bcc: afac0070 */ sw $t4,0x70($sp) +.L0f088bd0: +/* f088bd0: 0fc4483c */ jal invGiveWeaponsByProp +/* f088bd4: 8fa400a0 */ lw $a0,0xa0($sp) +/* f088bd8: 10400003 */ beqz $v0,.L0f088be8 +/* f088bdc: afa20068 */ sw $v0,0x68($sp) +/* f088be0: 240d0001 */ addiu $t5,$zero,0x1 +/* f088be4: afad0070 */ sw $t5,0x70($sp) +.L0f088be8: +/* f088be8: 8faf00a4 */ lw $t7,0xa4($sp) +/* f088bec: 240e0001 */ addiu $t6,$zero,0x1 +/* f088bf0: afae0094 */ sw $t6,0x94($sp) +/* f088bf4: 11e00014 */ beqz $t7,.L0f088c48 +/* f088bf8: 8fb80074 */ lw $t8,0x74($sp) +/* f088bfc: 0fc44c0d */ jal invGetActivatedTextByWeaponNum +/* f088c00: 9304005c */ lbu $a0,0x5c($t8) +/* f088c04: 10400008 */ beqz $v0,.L0f088c28 +/* f088c08: 00402025 */ or $a0,$v0,$zero +/* f088c0c: 24190001 */ addiu $t9,$zero,0x1 +/* f088c10: afb90070 */ sw $t9,0x70($sp) +/* f088c14: 00002825 */ or $a1,$zero,$zero +/* f088c18: 0fc377e9 */ jal hudmsgCreateWithFlags +/* f088c1c: 24060009 */ addiu $a2,$zero,0x9 +/* f088c20: 1000000a */ b .L0f088c4c +/* f088c24: 240c0001 */ addiu $t4,$zero,0x1 +.L0f088c28: +/* f088c28: 8fa90070 */ lw $t1,0x70($sp) +/* f088c2c: 8fa50068 */ lw $a1,0x68($sp) +/* f088c30: 8faa0074 */ lw $t2,0x74($sp) +/* f088c34: 11200004 */ beqz $t1,.L0f088c48 +/* f088c38: 38ab0002 */ xori $t3,$a1,0x2 +/* f088c3c: 9144005c */ lbu $a0,0x5c($t2) +/* f088c40: 0fc221f2 */ jal currentPlayerQueuePickupWeaponHudmsg +/* f088c44: 2d650001 */ sltiu $a1,$t3,0x1 +.L0f088c48: +/* f088c48: 240c0001 */ addiu $t4,$zero,0x1 +.L0f088c4c: +/* f088c4c: afac0098 */ sw $t4,0x98($sp) +.L0f088c50: +/* f088c50: 8fad0068 */ lw $t5,0x68($sp) +/* f088c54: 24010002 */ addiu $at,$zero,0x2 +/* f088c58: 55a10010 */ bnel $t5,$at,.L0f088c9c +/* f088c5c: 8fb90074 */ lw $t9,0x74($sp) +/* f088c60: 0fc2866a */ jal bgunGetWeaponNum +/* f088c64: 00002025 */ or $a0,$zero,$zero +/* f088c68: 8fae0074 */ lw $t6,0x74($sp) +/* f088c6c: 91cf005c */ lbu $t7,0x5c($t6) +/* f088c70: 544f000a */ bnel $v0,$t7,.L0f088c9c +/* f088c74: 8fb90074 */ lw $t9,0x74($sp) +/* f088c78: 0fc2866a */ jal bgunGetWeaponNum +/* f088c7c: 24040001 */ addiu $a0,$zero,0x1 +/* f088c80: 8fb80074 */ lw $t8,0x74($sp) +/* f088c84: 9305005c */ lbu $a1,0x5c($t8) +/* f088c88: 50450004 */ beql $v0,$a1,.L0f088c9c +/* f088c8c: 8fb90074 */ lw $t9,0x74($sp) +/* f088c90: 0fc28824 */ jal bgunEquipWeapon2 +/* f088c94: 24040001 */ addiu $a0,$zero,0x1 +/* f088c98: 8fb90074 */ lw $t9,0x74($sp) +.L0f088c9c: +/* f088c9c: 00002825 */ or $a1,$zero,$zero +/* f088ca0: 0fc2a685 */ jal bgunGetAmmoTypeForWeapon +/* f088ca4: 9324005c */ lbu $a0,0x5c($t9) +/* f088ca8: 1040001d */ beqz $v0,.L0f088d20 +/* f088cac: afa2006c */ sw $v0,0x6c($sp) +/* f088cb0: 0fc22095 */ jal weaponGetPickupAmmoQty +/* f088cb4: 8fa40074 */ lw $a0,0x74($sp) +/* f088cb8: 18400019 */ blez $v0,.L0f088d20 +/* f088cbc: afa20058 */ sw $v0,0x58($sp) +/* f088cc0: 0fc2a5dc */ jal bgunGetReservedAmmoCount +/* f088cc4: 8fa4006c */ lw $a0,0x6c($sp) +/* f088cc8: 8fa4006c */ lw $a0,0x6c($sp) +/* f088ccc: 0fc2a5dc */ jal bgunGetReservedAmmoCount +/* f088cd0: afa20054 */ sw $v0,0x54($sp) +/* f088cd4: 8fa4006c */ lw $a0,0x6c($sp) +/* f088cd8: 0fc2a63d */ jal bgunGetCapacityByAmmotype +/* f088cdc: afa2003c */ sw $v0,0x3c($sp) +/* f088ce0: 8fa6003c */ lw $a2,0x3c($sp) +/* f088ce4: 8fa50054 */ lw $a1,0x54($sp) +/* f088ce8: 8fa90058 */ lw $t1,0x58($sp) +/* f088cec: 00c2082a */ slt $at,$a2,$v0 +/* f088cf0: 1020000b */ beqz $at,.L0f088d20 +/* f088cf4: 00a92821 */ addu $a1,$a1,$t1 +/* f088cf8: 0fc2a58a */ jal bgunSetAmmoQuantity +/* f088cfc: 8fa4006c */ lw $a0,0x6c($sp) +/* f088d00: 8faa0070 */ lw $t2,0x70($sp) +/* f088d04: 8fab00a4 */ lw $t3,0xa4($sp) +/* f088d08: 55400006 */ bnezl $t2,.L0f088d24 +/* f088d0c: 8fac0074 */ lw $t4,0x74($sp) +/* f088d10: 11600003 */ beqz $t3,.L0f088d20 +/* f088d14: 8fa4006c */ lw $a0,0x6c($sp) +/* f088d18: 0fc21fec */ jal currentPlayerQueuePickupAmmoHudmsg +/* f088d1c: 8fa50058 */ lw $a1,0x58($sp) +.L0f088d20: +/* f088d20: 8fac0074 */ lw $t4,0x74($sp) +.L0f088d24: +/* f088d24: 24010012 */ addiu $at,$zero,0x12 +/* f088d28: 918d005c */ lbu $t5,0x5c($t4) +/* f088d2c: 55a1001b */ bnel $t5,$at,.L0f088d9c +/* f088d30: 8fb80074 */ lw $t8,0x74($sp) +/* f088d34: 0fc22095 */ jal weaponGetPickupAmmoQty +/* f088d38: 01802025 */ or $a0,$t4,$zero +/* f088d3c: afa20050 */ sw $v0,0x50($sp) +/* f088d40: 0fc2a5dc */ jal bgunGetReservedAmmoCount +/* f088d44: 2404000b */ addiu $a0,$zero,0xb +/* f088d48: 2404000b */ addiu $a0,$zero,0xb +/* f088d4c: 0fc2a63d */ jal bgunGetCapacityByAmmotype +/* f088d50: afa2003c */ sw $v0,0x3c($sp) +/* f088d54: 8fa6003c */ lw $a2,0x3c($sp) +/* f088d58: 00c2082a */ slt $at,$a2,$v0 +/* f088d5c: 5020000f */ beqzl $at,.L0f088d9c +/* f088d60: 8fb80074 */ lw $t8,0x74($sp) +/* f088d64: 0fc2a5dc */ jal bgunGetReservedAmmoCount +/* f088d68: 2404000b */ addiu $a0,$zero,0xb +/* f088d6c: 2404000b */ addiu $a0,$zero,0xb +/* f088d70: 0fc2a58a */ jal bgunSetAmmoQuantity +/* f088d74: 24450005 */ addiu $a1,$v0,0x5 +/* f088d78: 8fae0070 */ lw $t6,0x70($sp) +/* f088d7c: 8faf00a4 */ lw $t7,0xa4($sp) +/* f088d80: 55c00006 */ bnezl $t6,.L0f088d9c +/* f088d84: 8fb80074 */ lw $t8,0x74($sp) +/* f088d88: 11e00003 */ beqz $t7,.L0f088d98 +/* f088d8c: 2404000b */ addiu $a0,$zero,0xb +/* f088d90: 0fc21fec */ jal currentPlayerQueuePickupAmmoHudmsg +/* f088d94: 8fa50050 */ lw $a1,0x50($sp) +.L0f088d98: +/* f088d98: 8fb80074 */ lw $t8,0x74($sp) +.L0f088d9c: +/* f088d9c: 2401002e */ addiu $at,$zero,0x2e +/* f088da0: 3c09800a */ lui $t1,%hi(g_Vars+0x284) +/* f088da4: 9319005c */ lbu $t9,0x5c($t8) +/* f088da8: 17210007 */ bne $t9,$at,.L0f088dc8 +/* f088dac: 00000000 */ nop +/* f088db0: 8d29a244 */ lw $t1,%lo(g_Vars+0x284)($t1) +/* f088db4: 8d2a0480 */ lw $t2,0x480($t1) +/* f088db8: 15400003 */ bnez $t2,.L0f088dc8 +/* f088dbc: 00000000 */ nop +/* f088dc0: 0fc0458c */ jal currentPlayerInitEyespy +/* f088dc4: 00000000 */ nop +.L0f088dc8: +/* f088dc8: 10000076 */ b .L0f088fa4 +/* f088dcc: 8fa20098 */ lw $v0,0x98($sp) +/* f088dd0: 0fc30884 */ jal currentPlayerSetShieldFrac +/* f088dd4: c4cc0060 */ lwc1 $f12,0x60($a2) +/* f088dd8: 3c0b800a */ lui $t3,%hi(g_Vars+0x4cc) +/* f088ddc: 8d6ba48c */ lw $t3,%lo(g_Vars+0x4cc)($t3) +/* f088de0: 3c048009 */ lui $a0,%hi(var80095200) +/* f088de4: 240501cd */ addiu $a1,$zero,0x1cd +/* f088de8: 1560000d */ bnez $t3,.L0f088e20 +/* f088dec: 00003025 */ or $a2,$zero,$zero +/* f088df0: 3c01bf80 */ lui $at,0xbf80 +/* f088df4: 44813000 */ mtc1 $at,$f6 +/* f088df8: 240dffff */ addiu $t5,$zero,-1 +/* f088dfc: 240cffff */ addiu $t4,$zero,-1 +/* f088e00: 240effff */ addiu $t6,$zero,-1 +/* f088e04: afae001c */ sw $t6,0x1c($sp) +/* f088e08: afac0018 */ sw $t4,0x18($sp) +/* f088e0c: afad0010 */ sw $t5,0x10($sp) +/* f088e10: 8c845200 */ lw $a0,%lo(var80095200)($a0) +/* f088e14: 2407ffff */ addiu $a3,$zero,-1 +/* f088e18: 0c004241 */ jal sndStart +/* f088e1c: e7a60014 */ swc1 $f6,0x14($sp) +.L0f088e20: +/* f088e20: 8faf00a4 */ lw $t7,0xa4($sp) +/* f088e24: 51e0003b */ beqzl $t7,.L0f088f14 +/* f088e28: 240e0001 */ addiu $t6,$zero,0x1 +/* f088e2c: 0fc44bfb */ jal invGetActivatedTextByObj +/* f088e30: 8fa4009c */ lw $a0,0x9c($sp) +/* f088e34: 14400033 */ bnez $v0,.L0f088f04 +/* f088e38: 00402025 */ or $a0,$v0,$zero +/* f088e3c: 3c18800a */ lui $t8,%hi(g_Vars+0x6c) +/* f088e40: 8f18a02c */ lw $t8,%lo(g_Vars+0x6c)($t8) +/* f088e44: 3c19800a */ lui $t9,%hi(g_Vars+0x68) +/* f088e48: 3c09800a */ lui $t1,%hi(g_Vars+0x64) +/* f088e4c: 13000003 */ beqz $t8,.L0f088e5c +/* f088e50: 3c0a800a */ lui $t2,%hi(g_Vars+0x70) +/* f088e54: 10000002 */ b .L0f088e60 +/* f088e58: 24050001 */ addiu $a1,$zero,0x1 +.L0f088e5c: +/* f088e5c: 00002825 */ or $a1,$zero,$zero +.L0f088e60: +/* f088e60: 8f39a028 */ lw $t9,%lo(g_Vars+0x68)($t9) +/* f088e64: 00001825 */ or $v1,$zero,$zero +/* f088e68: 00002025 */ or $a0,$zero,$zero +/* f088e6c: 13200003 */ beqz $t9,.L0f088e7c +/* f088e70: 00003025 */ or $a2,$zero,$zero +/* f088e74: 10000001 */ b .L0f088e7c +/* f088e78: 24030001 */ addiu $v1,$zero,0x1 +.L0f088e7c: +/* f088e7c: 8d29a024 */ lw $t1,%lo(g_Vars+0x64)($t1) +/* f088e80: 11200003 */ beqz $t1,.L0f088e90 +/* f088e84: 00000000 */ nop +/* f088e88: 10000001 */ b .L0f088e90 +/* f088e8c: 24040001 */ addiu $a0,$zero,0x1 +.L0f088e90: +/* f088e90: 8d4aa030 */ lw $t2,%lo(g_Vars+0x70)($t2) +/* f088e94: 11400003 */ beqz $t2,.L0f088ea4 +/* f088e98: 00000000 */ nop +/* f088e9c: 10000001 */ b .L0f088ea4 +/* f088ea0: 24060001 */ addiu $a2,$zero,0x1 +.L0f088ea4: +/* f088ea4: 00c45821 */ addu $t3,$a2,$a0 +/* f088ea8: 01636821 */ addu $t5,$t3,$v1 +/* f088eac: 01a51021 */ addu $v0,$t5,$a1 +/* f088eb0: 28410003 */ slti $at,$v0,0x3 +/* f088eb4: 10200010 */ beqz $at,.L0f088ef8 +/* f088eb8: 24010002 */ addiu $at,$zero,0x2 +/* f088ebc: 1441000a */ bne $v0,$at,.L0f088ee8 +/* f088ec0: 00000000 */ nop +/* f088ec4: 0fc54bcd */ jal optionsGetScreenSplit +/* f088ec8: 00000000 */ nop +/* f088ecc: 24010001 */ addiu $at,$zero,0x1 +/* f088ed0: 10410009 */ beq $v0,$at,.L0f088ef8 +/* f088ed4: 3c0c8009 */ lui $t4,%hi(g_Is4Mb) +/* f088ed8: 918c0af0 */ lbu $t4,%lo(g_Is4Mb)($t4) +/* f088edc: 24010001 */ addiu $at,$zero,0x1 +/* f088ee0: 11810005 */ beq $t4,$at,.L0f088ef8 +/* f088ee4: 00000000 */ nop +.L0f088ee8: +/* f088ee8: 0fc5b9f1 */ jal langGet +/* f088eec: 24045229 */ addiu $a0,$zero,0x5229 +/* f088ef0: 10000004 */ b .L0f088f04 +/* f088ef4: 00402025 */ or $a0,$v0,$zero +.L0f088ef8: +/* f088ef8: 0fc5b9f1 */ jal langGet +/* f088efc: 2404522a */ addiu $a0,$zero,0x522a +/* f088f00: 00402025 */ or $a0,$v0,$zero +.L0f088f04: +/* f088f04: 00002825 */ or $a1,$zero,$zero +/* f088f08: 0fc377e9 */ jal hudmsgCreateWithFlags +/* f088f0c: 24060001 */ addiu $a2,$zero,0x1 +/* f088f10: 240e0001 */ addiu $t6,$zero,0x1 +.L0f088f14: +/* f088f14: afae0098 */ sw $t6,0x98($sp) +/* f088f18: 10000022 */ b .L0f088fa4 +/* f088f1c: 24020001 */ addiu $v0,$zero,0x1 +.L0f088f20: +/* f088f20: 8d0f04cc */ lw $t7,0x4cc($t0) +/* f088f24: 3c048009 */ lui $a0,%hi(var80095200) +/* f088f28: 240500e5 */ addiu $a1,$zero,0xe5 +/* f088f2c: 15e0000d */ bnez $t7,.L0f088f64 +/* f088f30: 00003025 */ or $a2,$zero,$zero +/* f088f34: 3c01bf80 */ lui $at,0xbf80 +/* f088f38: 44814000 */ mtc1 $at,$f8 +/* f088f3c: 2418ffff */ addiu $t8,$zero,-1 +/* f088f40: 2419ffff */ addiu $t9,$zero,-1 +/* f088f44: 2409ffff */ addiu $t1,$zero,-1 +/* f088f48: afa9001c */ sw $t1,0x1c($sp) +/* f088f4c: afb90018 */ sw $t9,0x18($sp) +/* f088f50: afb80010 */ sw $t8,0x10($sp) +/* f088f54: 8c845200 */ lw $a0,%lo(var80095200)($a0) +/* f088f58: 2407ffff */ addiu $a3,$zero,-1 +/* f088f5c: 0c004241 */ jal sndStart +/* f088f60: e7a80014 */ swc1 $f8,0x14($sp) +.L0f088f64: +/* f088f64: 8faa00a4 */ lw $t2,0xa4($sp) +/* f088f68: 5140000c */ beqzl $t2,.L0f088f9c +/* f088f6c: 240b0004 */ addiu $t3,$zero,0x4 +/* f088f70: 0fc44bfb */ jal invGetActivatedTextByObj +/* f088f74: 8fa4009c */ lw $a0,0x9c($sp) +/* f088f78: 14400004 */ bnez $v0,.L0f088f8c +/* f088f7c: 00402025 */ or $a0,$v0,$zero +/* f088f80: 0fc5b9f1 */ jal langGet +/* f088f84: 2404522b */ addiu $a0,$zero,0x522b +/* f088f88: 00402025 */ or $a0,$v0,$zero +.L0f088f8c: +/* f088f8c: 00002825 */ or $a1,$zero,$zero +/* f088f90: 0fc377e9 */ jal hudmsgCreateWithFlags +/* f088f94: 24060009 */ addiu $a2,$zero,0x9 +/* f088f98: 240b0004 */ addiu $t3,$zero,0x4 +.L0f088f9c: +/* f088f9c: afab0098 */ sw $t3,0x98($sp) +/* f088fa0: 24020004 */ addiu $v0,$zero,0x4 +.L0f088fa4: +/* f088fa4: 24010001 */ addiu $at,$zero,0x1 +/* f088fa8: 1441000d */ bne $v0,$at,.L0f088fe0 +/* f088fac: 8fad009c */ lw $t5,0x9c($sp) +/* f088fb0: 8dac0040 */ lw $t4,0x40($t5) +/* f088fb4: 318e0010 */ andi $t6,$t4,0x10 +/* f088fb8: 15c00009 */ bnez $t6,.L0f088fe0 +/* f088fbc: 00000000 */ nop +/* f088fc0: 91a60002 */ lbu $a2,0x2($t5) +/* f088fc4: 01a02025 */ or $a0,$t5,$zero +/* f088fc8: 00002825 */ or $a1,$zero,$zero +/* f088fcc: 30cf0004 */ andi $t7,$a2,0x4 +/* f088fd0: 0fc1ab4b */ jal objRemove2 +/* f088fd4: 01e03025 */ or $a2,$t7,$zero +/* f088fd8: 1000000a */ b .L0f089004 +/* f088fdc: 24020001 */ addiu $v0,$zero,0x1 +.L0f088fe0: +/* f088fe0: 10400007 */ beqz $v0,.L0f089000 +/* f088fe4: 8fb80094 */ lw $t8,0x94($sp) +/* f088fe8: 17000003 */ bnez $t8,.L0f088ff8 +/* f088fec: 00000000 */ nop +/* f088ff0: 0fc447f3 */ jal invGiveProp +/* f088ff4: 8fa400a0 */ lw $a0,0xa0($sp) +.L0f088ff8: +/* f088ff8: 10000002 */ b .L0f089004 +/* f088ffc: 24020004 */ addiu $v0,$zero,0x4 +.L0f089000: +/* f089000: 00001025 */ or $v0,$zero,$zero +.L0f089004: +/* f089004: 8fbf0024 */ lw $ra,0x24($sp) +/* f089008: 27bd00a0 */ addiu $sp,$sp,0xa0 +/* f08900c: 03e00008 */ jr $ra +/* f089010: 00000000 */ nop +); #endif // Mismatch: Goal stores obj in a2 and sp9c, and copies it from a2 for the more @@ -64285,7 +68713,11 @@ struct autogunobj *laptopDeploy(s32 modelnum, struct gset *gset, struct chrdata laptop = &g_ThrownLaptops[index]; if (laptop->base.prop) { +#if VERSION >= VERSION_NTSC_1_0 explosionCreateSimple(NULL, &laptop->base.prop->pos, laptop->base.prop->rooms, EXPLOSIONTYPE_3, index); +#else + explosionCreateSimple(NULL, &laptop->base.prop->pos, laptop->base.prop->rooms, EXPLOSIONTYPE_3, 0); +#endif objRemove(&laptop->base, true); } @@ -68952,6 +73384,7 @@ void func0f0910ac(void) || (g_Vars.normmplayerisrunning && g_MpSetup.scenario == MPSCENARIO_HACKERCENTRAL && i == WEAPON_DATAUPLINK)) { +#if VERSION >= VERSION_NTSC_1_0 if (g_Vars.coopplayernum >= 0) { bool canremove = true; struct prop *child = g_Vars.currentplayer->prop->child; @@ -68975,18 +73408,39 @@ void func0f0910ac(void) invRemoveItemByNum(i); } -#if VERSION >= VERSION_NTSC_1_0 if (!bgunIsMissionCritical(i)) { func0f091250(i); } -#else - func0f091250(i); -#endif } else { -#if VERSION >= VERSION_NTSC_1_0 func0f091250(i); -#endif } +#else + if (g_Vars.coopplayernum >= 0) { + bool canremove = true; + struct prop *child = g_Vars.currentplayer->prop->child; + + while (child) { + struct defaultobj *obj = child->obj; + + if (obj->type == OBJTYPE_WEAPON) { + struct weaponobj *weapon = child->weapon; + + if (i == weapon->weaponnum && (obj->flags3 & OBJFLAG3_00400000)) { + canremove = false; + break; + } + } + + child = child->next; + } + + if (canremove) { + invRemoveItemByNum(i); + } + } + + func0f091250(i); +#endif } } } @@ -69741,7 +74195,7 @@ glabel var7f1ab214 /* f091d7c: 03e00008 */ jr $ra /* f091d80: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel projectileCreate .late_rodata @@ -70470,6 +74924,735 @@ glabel var7f1ab214 /* f091d7c: 03e00008 */ jr $ra /* f091d80: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel projectileCreate +.late_rodata +glabel var7f1ab20c +.word 0x481c4000 +glabel var7f1ab210 +.word 0x3e8e38e3 +glabel var7f1ab214 +.word 0x3e23d70a +.text +/* f0912dc: 27bdfe00 */ addiu $sp,$sp,-512 +/* f0912e0: afbf0044 */ sw $ra,0x44($sp) +/* f0912e4: afa40200 */ sw $a0,0x200($sp) +/* f0912e8: afa50204 */ sw $a1,0x204($sp) +/* f0912ec: afa60208 */ sw $a2,0x208($sp) +/* f0912f0: 0fc5b364 */ jal lvIsPaused +/* f0912f4: afa7020c */ sw $a3,0x20c($sp) +/* f0912f8: 1440029e */ bnez $v0,.L0f091d74 +/* f0912fc: 8fa30208 */ lw $v1,0x208($sp) +/* f091300: afa001fc */ sw $zero,0x1fc($sp) +/* f091304: afa001d8 */ sw $zero,0x1d8($sp) +/* f091308: a3a001c7 */ sb $zero,0x1c7($sp) +/* f09130c: a3a00187 */ sb $zero,0x187($sp) +/* f091310: c4640000 */ lwc1 $f4,0x0($v1) +/* f091314: 93ae0213 */ lbu $t6,0x213($sp) +/* f091318: 2401001c */ addiu $at,$zero,0x1c +/* f09131c: e7a4018c */ swc1 $f4,0x18c($sp) +/* f091320: c4660004 */ lwc1 $f6,0x4($v1) +/* f091324: 240f0001 */ addiu $t7,$zero,0x1 +/* f091328: 3c0a800a */ lui $t2,%hi(g_Vars+0x8) +/* f09132c: e7a60190 */ swc1 $f6,0x190($sp) +/* f091330: c4680008 */ lwc1 $f8,0x8($v1) +/* f091334: afae0054 */ sw $t6,0x54($sp) +/* f091338: 15c1000b */ bne $t6,$at,.L0f091368 +/* f09133c: e7a80194 */ swc1 $f8,0x194($sp) +/* f091340: 3c014220 */ lui $at,0x4220 +/* f091344: 44818000 */ mtc1 $at,$f16 +/* f091348: c7aa0190 */ lwc1 $f10,0x190($sp) +/* f09134c: 2418ffff */ addiu $t8,$zero,-1 +/* f091350: 24190001 */ addiu $t9,$zero,0x1 +/* f091354: 46105481 */ sub.s $f18,$f10,$f16 +/* f091358: a3af01c7 */ sb $t7,0x1c7($sp) +/* f09135c: a3b80198 */ sb $t8,0x198($sp) +/* f091360: a3b90187 */ sb $t9,0x187($sp) +/* f091364: e7b20190 */ swc1 $f18,0x190($sp) +.L0f091368: +/* f091368: 8fa80204 */ lw $t0,0x204($sp) +/* f09136c: 5100008d */ beqzl $t0,.L0f0915a4 +/* f091370: 8fa20214 */ lw $v0,0x214($sp) +/* f091374: 8d090008 */ lw $t1,0x8($t0) +/* f091378: 8d4a9fc8 */ lw $t2,%lo(g_Vars+0x8)($t2) +/* f09137c: 8fab0054 */ lw $t3,0x54($sp) +/* f091380: 012a082a */ slt $at,$t1,$t2 +/* f091384: 10200086 */ beqz $at,.L0f0915a0 +/* f091388: 2401002b */ addiu $at,$zero,0x2b +/* f09138c: 11610028 */ beq $t3,$at,.L0f091430 +/* f091390: 8fa40200 */ lw $a0,0x200($sp) +/* f091394: 24010059 */ addiu $at,$zero,0x58 +/* f091398: 11610006 */ beq $t3,$at,.L0f0913b4 +/* f09139c: 8fa40200 */ lw $a0,0x200($sp) +/* f0913a0: 2401005a */ addiu $at,$zero,0x59 +/* f0913a4: 11610043 */ beq $t3,$at,.L0f0914b4 +/* f0913a8: 8fa40200 */ lw $a0,0x200($sp) +/* f0913ac: 1000005f */ b .L0f09152c +/* f0913b0: 8fa40200 */ lw $a0,0x200($sp) +.L0f0913b4: +/* f0913b4: 24050007 */ addiu $a1,$zero,0x7 +/* f0913b8: 0fc249af */ jal func0f0926bc +/* f0913bc: 3406ffff */ dli $a2,0xffff +/* f0913c0: 3c01bf80 */ lui $at,0xbf80 +/* f0913c4: 44810000 */ mtc1 $at,$f0 +/* f0913c8: 240cffff */ addiu $t4,$zero,-1 +/* f0913cc: 240d0007 */ addiu $t5,$zero,0x7 +/* f0913d0: 240effff */ addiu $t6,$zero,-1 +/* f0913d4: afae002c */ sw $t6,0x2c($sp) +/* f0913d8: afad001c */ sw $t5,0x1c($sp) +/* f0913dc: afac0010 */ sw $t4,0x10($sp) +/* f0913e0: 00002025 */ or $a0,$zero,$zero +/* f0913e4: 8fa50200 */ lw $a1,0x200($sp) +/* f0913e8: 2406810e */ addiu $a2,$zero,-32499 +/* f0913ec: 2407ffff */ addiu $a3,$zero,-1 +/* f0913f0: afa00014 */ sw $zero,0x14($sp) +/* f0913f4: afa00018 */ sw $zero,0x18($sp) +/* f0913f8: afa00020 */ sw $zero,0x20($sp) +/* f0913fc: afa00028 */ sw $zero,0x28($sp) +/* f091400: e7a00024 */ swc1 $f0,0x24($sp) +/* f091404: e7a00030 */ swc1 $f0,0x30($sp) +/* f091408: e7a00034 */ swc1 $f0,0x34($sp) +/* f09140c: 0fc24e7e */ jal func0f0939f8 +/* f091410: e7a00038 */ swc1 $f0,0x38($sp) +/* f091414: 3c0f800a */ lui $t7,%hi(g_Vars+0x8) +/* f091418: 8def9fc8 */ lw $t7,%lo(g_Vars+0x8)($t7) +/* f09141c: 8fb90204 */ lw $t9,0x204($sp) +/* f091420: 25f80004 */ addiu $t8,$t7,0x4 +/* f091424: af380008 */ sw $t8,0x8($t9) +/* f091428: 1000005d */ b .L0f0915a0 +/* f09142c: 8fa30208 */ lw $v1,0x208($sp) +.L0f091430: +/* f091430: 24050001 */ addiu $a1,$zero,0x1 +/* f091434: 0fc249af */ jal func0f0926bc +/* f091438: 3406ffff */ dli $a2,0xffff +/* f09143c: 3c01bf80 */ lui $at,0xbf80 +/* f091440: 44812000 */ mtc1 $at,$f4 +/* f091444: 44813000 */ mtc1 $at,$f6 +/* f091448: 44814000 */ mtc1 $at,$f8 +/* f09144c: 44815000 */ mtc1 $at,$f10 +/* f091450: 2408ffff */ addiu $t0,$zero,-1 +/* f091454: 2409ffff */ addiu $t1,$zero,-1 +/* f091458: afa9002c */ sw $t1,0x2c($sp) +/* f09145c: afa80010 */ sw $t0,0x10($sp) +/* f091460: 00002025 */ or $a0,$zero,$zero +/* f091464: 8fa50200 */ lw $a1,0x200($sp) +/* f091468: 2406805a */ addiu $a2,$zero,-32678 +/* f09146c: 2407ffff */ addiu $a3,$zero,-1 +/* f091470: afa00014 */ sw $zero,0x14($sp) +/* f091474: afa00018 */ sw $zero,0x18($sp) +/* f091478: afa0001c */ sw $zero,0x1c($sp) +/* f09147c: afa00020 */ sw $zero,0x20($sp) +/* f091480: afa00028 */ sw $zero,0x28($sp) +/* f091484: e7a40024 */ swc1 $f4,0x24($sp) +/* f091488: e7a60030 */ swc1 $f6,0x30($sp) +/* f09148c: e7a80034 */ swc1 $f8,0x34($sp) +/* f091490: 0fc24e7e */ jal func0f0939f8 +/* f091494: e7aa0038 */ swc1 $f10,0x38($sp) +/* f091498: 3c0a800a */ lui $t2,%hi(g_Vars+0x8) +/* f09149c: 8d4a9fc8 */ lw $t2,%lo(g_Vars+0x8)($t2) +/* f0914a0: 8fac0204 */ lw $t4,0x204($sp) +/* f0914a4: 254b0002 */ addiu $t3,$t2,0x2 +/* f0914a8: ad8b0008 */ sw $t3,0x8($t4) +/* f0914ac: 1000003c */ b .L0f0915a0 +/* f0914b0: 8fa30208 */ lw $v1,0x208($sp) +.L0f0914b4: +/* f0914b4: 24050001 */ addiu $a1,$zero,0x1 +/* f0914b8: 0fc249af */ jal func0f0926bc +/* f0914bc: 3406ffff */ dli $a2,0xffff +/* f0914c0: 3c01bf80 */ lui $at,0xbf80 +/* f0914c4: 44810000 */ mtc1 $at,$f0 +/* f0914c8: 240dffff */ addiu $t5,$zero,-1 +/* f0914cc: 240effff */ addiu $t6,$zero,-1 +/* f0914d0: afae002c */ sw $t6,0x2c($sp) +/* f0914d4: afad0010 */ sw $t5,0x10($sp) +/* f0914d8: 00002025 */ or $a0,$zero,$zero +/* f0914dc: 8fa50200 */ lw $a1,0x200($sp) +/* f0914e0: 24068043 */ addiu $a2,$zero,-32701 +/* f0914e4: 2407ffff */ addiu $a3,$zero,-1 +/* f0914e8: afa00014 */ sw $zero,0x14($sp) +/* f0914ec: afa00018 */ sw $zero,0x18($sp) +/* f0914f0: afa0001c */ sw $zero,0x1c($sp) +/* f0914f4: afa00020 */ sw $zero,0x20($sp) +/* f0914f8: afa00028 */ sw $zero,0x28($sp) +/* f0914fc: e7a00024 */ swc1 $f0,0x24($sp) +/* f091500: e7a00030 */ swc1 $f0,0x30($sp) +/* f091504: e7a00034 */ swc1 $f0,0x34($sp) +/* f091508: 0fc24e7e */ jal func0f0939f8 +/* f09150c: e7a00038 */ swc1 $f0,0x38($sp) +/* f091510: 3c0f800a */ lui $t7,%hi(g_Vars+0x8) +/* f091514: 8def9fc8 */ lw $t7,%lo(g_Vars+0x8)($t7) +/* f091518: 8fb90204 */ lw $t9,0x204($sp) +/* f09151c: 25f80008 */ addiu $t8,$t7,0x8 +/* f091520: af380008 */ sw $t8,0x8($t9) +/* f091524: 1000001e */ b .L0f0915a0 +/* f091528: 8fa30208 */ lw $v1,0x208($sp) +.L0f09152c: +/* f09152c: 24050001 */ addiu $a1,$zero,0x1 +/* f091530: 0fc249af */ jal func0f0926bc +/* f091534: 3406ffff */ dli $a2,0xffff +/* f091538: 3c01bf80 */ lui $at,0xbf80 +/* f09153c: 44810000 */ mtc1 $at,$f0 +/* f091540: 2408ffff */ addiu $t0,$zero,-1 +/* f091544: 2409ffff */ addiu $t1,$zero,-1 +/* f091548: afa9002c */ sw $t1,0x2c($sp) +/* f09154c: afa80010 */ sw $t0,0x10($sp) +/* f091550: 00002025 */ or $a0,$zero,$zero +/* f091554: 8fa50200 */ lw $a1,0x200($sp) +/* f091558: 24068045 */ addiu $a2,$zero,-32699 +/* f09155c: 2407ffff */ addiu $a3,$zero,-1 +/* f091560: afa00014 */ sw $zero,0x14($sp) +/* f091564: afa00018 */ sw $zero,0x18($sp) +/* f091568: afa0001c */ sw $zero,0x1c($sp) +/* f09156c: afa00020 */ sw $zero,0x20($sp) +/* f091570: afa00028 */ sw $zero,0x28($sp) +/* f091574: e7a00024 */ swc1 $f0,0x24($sp) +/* f091578: e7a00030 */ swc1 $f0,0x30($sp) +/* f09157c: e7a00034 */ swc1 $f0,0x34($sp) +/* f091580: 0fc24e7e */ jal func0f0939f8 +/* f091584: e7a00038 */ swc1 $f0,0x38($sp) +/* f091588: 3c0a800a */ lui $t2,%hi(g_Vars+0x8) +/* f09158c: 8d4a9fc8 */ lw $t2,%lo(g_Vars+0x8)($t2) +/* f091590: 8fac0204 */ lw $t4,0x204($sp) +/* f091594: 254b0002 */ addiu $t3,$t2,0x2 +/* f091598: ad8b0008 */ sw $t3,0x8($t4) +/* f09159c: 8fa30208 */ lw $v1,0x208($sp) +.L0f0915a0: +/* f0915a0: 8fa20214 */ lw $v0,0x214($sp) +.L0f0915a4: +/* f0915a4: 8fa6020c */ lw $a2,0x20c($sp) +/* f0915a8: 3c014e00 */ lui $at,0x4e00 +/* f0915ac: 1040001d */ beqz $v0,.L0f091624 +/* f0915b0: 3c198007 */ lui $t9,%hi(var8006ae04) +/* f0915b4: 3c014170 */ lui $at,0x4170 +/* f0915b8: 44817000 */ mtc1 $at,$f14 +/* f0915bc: c4c60000 */ lwc1 $f6,0x0($a2) +/* f0915c0: c4500008 */ lwc1 $f16,0x8($v0) +/* f0915c4: c4720000 */ lwc1 $f18,0x0($v1) +/* f0915c8: 460e3202 */ mul.s $f8,$f6,$f14 +/* f0915cc: c4c60004 */ lwc1 $f6,0x4($a2) +/* f0915d0: 46128101 */ sub.s $f4,$f16,$f18 +/* f0915d4: c4700004 */ lwc1 $f16,0x4($v1) +/* f0915d8: c44a000c */ lwc1 $f10,0xc($v0) +/* f0915dc: 46082001 */ sub.s $f0,$f4,$f8 +/* f0915e0: 460e3102 */ mul.s $f4,$f6,$f14 +/* f0915e4: c4c60008 */ lwc1 $f6,0x8($a2) +/* f0915e8: 46105481 */ sub.s $f18,$f10,$f16 +/* f0915ec: c46a0008 */ lwc1 $f10,0x8($v1) +/* f0915f0: c4480010 */ lwc1 $f8,0x10($v0) +/* f0915f4: 46049081 */ sub.s $f2,$f18,$f4 +/* f0915f8: 460e3482 */ mul.s $f18,$f6,$f14 +/* f0915fc: 460a4401 */ sub.s $f16,$f8,$f10 +/* f091600: 46000102 */ mul.s $f4,$f0,$f0 +/* f091604: 00000000 */ nop +/* f091608: 46021202 */ mul.s $f8,$f2,$f2 +/* f09160c: 46128301 */ sub.s $f12,$f16,$f18 +/* f091610: 460c6182 */ mul.s $f6,$f12,$f12 +/* f091614: 46082280 */ add.s $f10,$f4,$f8 +/* f091618: 46065400 */ add.s $f16,$f10,$f6 +/* f09161c: 10000004 */ b .L0f091630 +/* f091620: e7b001dc */ swc1 $f16,0x1dc($sp) +.L0f091624: +/* f091624: 44819000 */ mtc1 $at,$f18 +/* f091628: 8fa6020c */ lw $a2,0x20c($sp) +/* f09162c: e7b201dc */ swc1 $f18,0x1dc($sp) +.L0f091630: +/* f091630: 8fad0054 */ lw $t5,0x54($sp) +/* f091634: 24010018 */ addiu $at,$zero,0x18 +/* f091638: 8fae0200 */ lw $t6,0x200($sp) +/* f09163c: 15a1006d */ bne $t5,$at,.L0f0917f4 +/* f091640: 00000000 */ nop +/* f091644: 0fc1eb7d */ jal chopperFromHovercar +/* f091648: 8dc40004 */ lw $a0,0x4($t6) +/* f09164c: 104001c9 */ beqz $v0,.L0f091d74 +/* f091650: 3c017f1b */ lui $at,%hi(var7f1ab20c) +/* f091654: c424b20c */ lwc1 $f4,%lo(var7f1ab20c)($at) +/* f091658: c7a801dc */ lwc1 $f8,0x1dc($sp) +/* f09165c: 4608203c */ c.lt.s $f4,$f8 +/* f091660: 00000000 */ nop +/* f091664: 450201c4 */ bc1fl .L0f091d78 +/* f091668: 8fbf0044 */ lw $ra,0x44($sp) +/* f09166c: c44a0080 */ lwc1 $f10,0x80($v0) +/* f091670: 2404011f */ addiu $a0,$zero,0x11f +/* f091674: 24050053 */ addiu $a1,$zero,0x52 +/* f091678: e7aa009c */ swc1 $f10,0x9c($sp) +/* f09167c: c446007c */ lwc1 $f6,0x7c($v0) +/* f091680: 00003025 */ or $a2,$zero,$zero +/* f091684: 0fc22e20 */ jal func0f08b880 +/* f091688: e7a60098 */ swc1 $f6,0x98($sp) +/* f09168c: 104001b9 */ beqz $v0,.L0f091d74 +/* f091690: afa2017c */ sw $v0,0x17c($sp) +/* f091694: 0c00566c */ jal mtx000159b0 +/* f091698: 27a4013c */ addiu $a0,$sp,0x13c +/* f09169c: c7ac009c */ lwc1 $f12,0x9c($sp) +/* f0916a0: 0c0058ba */ jal mtx000162e8 +/* f0916a4: 27a500e0 */ addiu $a1,$sp,0xe0 +/* f0916a8: c7ac0098 */ lwc1 $f12,0x98($sp) +/* f0916ac: 0c0058dd */ jal mtx00016374 +/* f0916b0: 27a500a0 */ addiu $a1,$sp,0xa0 +/* f0916b4: 27a400a0 */ addiu $a0,$sp,0xa0 +/* f0916b8: 0c0056f8 */ jal mtx00015be0 +/* f0916bc: 27a500e0 */ addiu $a1,$sp,0xe0 +/* f0916c0: 8fa3020c */ lw $v1,0x20c($sp) +/* f0916c4: 3c017f1b */ lui $at,%hi(var7f1ab210) +/* f0916c8: c422b210 */ lwc1 $f2,%lo(var7f1ab210)($at) +/* f0916cc: c4700000 */ lwc1 $f16,0x0($v1) +/* f0916d0: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f0916d4: c420a00c */ lwc1 $f0,%lo(g_Vars+0x4c)($at) +/* f0916d8: 46028482 */ mul.s $f18,$f16,$f2 +/* f0916dc: 8fa20200 */ lw $v0,0x200($sp) +/* f0916e0: 8fa50208 */ lw $a1,0x208($sp) +/* f0916e4: 27af0130 */ addiu $t7,$sp,0x130 +/* f0916e8: 27b8013c */ addiu $t8,$sp,0x13c +/* f0916ec: 8fa4017c */ lw $a0,0x17c($sp) +/* f0916f0: 27a700e0 */ addiu $a3,$sp,0xe0 +/* f0916f4: e7b20120 */ swc1 $f18,0x120($sp) +/* f0916f8: c4640004 */ lwc1 $f4,0x4($v1) +/* f0916fc: c7b00120 */ lwc1 $f16,0x120($sp) +/* f091700: 24460028 */ addiu $a2,$v0,0x28 +/* f091704: 46022202 */ mul.s $f8,$f4,$f2 +/* f091708: e7a80124 */ swc1 $f8,0x124($sp) +/* f09170c: c46a0008 */ lwc1 $f10,0x8($v1) +/* f091710: c7a40124 */ lwc1 $f4,0x124($sp) +/* f091714: afb80014 */ sw $t8,0x14($sp) +/* f091718: 46025182 */ mul.s $f6,$f10,$f2 +/* f09171c: afaf0010 */ sw $t7,0x10($sp) +/* f091720: afa20018 */ sw $v0,0x18($sp) +/* f091724: 46008482 */ mul.s $f18,$f16,$f0 +/* f091728: afa5001c */ sw $a1,0x1c($sp) +/* f09172c: 46002202 */ mul.s $f8,$f4,$f0 +/* f091730: e7a60128 */ swc1 $f6,0x128($sp) +/* f091734: c7aa0128 */ lwc1 $f10,0x128($sp) +/* f091738: e7b20130 */ swc1 $f18,0x130($sp) +/* f09173c: 46005182 */ mul.s $f6,$f10,$f0 +/* f091740: e7a80134 */ swc1 $f8,0x134($sp) +/* f091744: 0fc27af3 */ jal bgun0f09ebcc +/* f091748: e7a60138 */ swc1 $f6,0x138($sp) +/* f09174c: 8fa3017c */ lw $v1,0x17c($sp) +/* f091750: 8c790040 */ lw $t9,0x40($v1) +/* f091754: 33280080 */ andi $t0,$t9,0x80 +/* f091758: 51000187 */ beqzl $t0,.L0f091d78 +/* f09175c: 8fbf0044 */ lw $ra,0x44($sp) +/* f091760: 8c620048 */ lw $v0,0x48($v1) +/* f091764: 2409ffff */ addiu $t1,$zero,-1 +/* f091768: a4690062 */ sh $t1,0x62($v1) +/* f09176c: 8c4a0000 */ lw $t2,0x0($v0) +/* f091770: 3c01bf80 */ lui $at,0xbf80 +/* f091774: 44810000 */ mtc1 $at,$f0 +/* f091778: 354b0010 */ ori $t3,$t2,0x10 +/* f09177c: ac4b0000 */ sw $t3,0x0($v0) +/* f091780: 8c6c0048 */ lw $t4,0x48($v1) +/* f091784: c7b00120 */ lwc1 $f16,0x120($sp) +/* f091788: 240fffff */ addiu $t7,$zero,-1 +/* f09178c: 2418ffff */ addiu $t8,$zero,-1 +/* f091790: e5900010 */ swc1 $f16,0x10($t4) +/* f091794: 8c6d0048 */ lw $t5,0x48($v1) +/* f091798: c7b20124 */ lwc1 $f18,0x124($sp) +/* f09179c: 00002025 */ or $a0,$zero,$zero +/* f0917a0: 24068053 */ addiu $a2,$zero,-32685 +/* f0917a4: e5b20014 */ swc1 $f18,0x14($t5) +/* f0917a8: 8c6e0048 */ lw $t6,0x48($v1) +/* f0917ac: c7a40128 */ lwc1 $f4,0x128($sp) +/* f0917b0: 2407ffff */ addiu $a3,$zero,-1 +/* f0917b4: e5c40018 */ swc1 $f4,0x18($t6) +/* f0917b8: 8c650014 */ lw $a1,0x14($v1) +/* f0917bc: afb8002c */ sw $t8,0x2c($sp) +/* f0917c0: afa00028 */ sw $zero,0x28($sp) +/* f0917c4: afa00020 */ sw $zero,0x20($sp) +/* f0917c8: afa0001c */ sw $zero,0x1c($sp) +/* f0917cc: afa00018 */ sw $zero,0x18($sp) +/* f0917d0: afa00014 */ sw $zero,0x14($sp) +/* f0917d4: afaf0010 */ sw $t7,0x10($sp) +/* f0917d8: e7a00038 */ swc1 $f0,0x38($sp) +/* f0917dc: e7a00034 */ swc1 $f0,0x34($sp) +/* f0917e0: e7a00030 */ swc1 $f0,0x30($sp) +/* f0917e4: 0fc24e7e */ jal func0f0939f8 +/* f0917e8: e7a00024 */ swc1 $f0,0x24($sp) +/* f0917ec: 10000162 */ b .L0f091d78 +/* f0917f0: 8fbf0044 */ lw $ra,0x44($sp) +.L0f0917f4: +/* f0917f4: 8f39ae04 */ lw $t9,%lo(var8006ae04)($t9) +/* f0917f8: 93a80213 */ lbu $t0,0x213($sp) +/* f0917fc: 3c014780 */ lui $at,0x4780 +/* f091800: afb90094 */ sw $t9,0x94($sp) +/* f091804: a3a80094 */ sb $t0,0x94($sp) +/* f091808: 44810000 */ mtc1 $at,$f0 +/* f09180c: c4c80000 */ lwc1 $f8,0x0($a2) +/* f091810: c4660000 */ lwc1 $f6,0x0($v1) +/* f091814: 8fa40200 */ lw $a0,0x200($sp) +/* f091818: 46004282 */ mul.s $f10,$f8,$f0 +/* f09181c: 00002825 */ or $a1,$zero,$zero +/* f091820: 46065400 */ add.s $f16,$f10,$f6 +/* f091824: e7b001f0 */ swc1 $f16,0x1f0($sp) +/* f091828: c4d20004 */ lwc1 $f18,0x4($a2) +/* f09182c: c4680004 */ lwc1 $f8,0x4($v1) +/* f091830: 46009102 */ mul.s $f4,$f18,$f0 +/* f091834: 46082280 */ add.s $f10,$f4,$f8 +/* f091838: e7aa01f4 */ swc1 $f10,0x1f4($sp) +/* f09183c: c4c60008 */ lwc1 $f6,0x8($a2) +/* f091840: c4720008 */ lwc1 $f18,0x8($v1) +/* f091844: 46003402 */ mul.s $f16,$f6,$f0 +/* f091848: 46128100 */ add.s $f4,$f16,$f18 +/* f09184c: 0fc1905e */ jal propSetCollisionsEnabled +/* f091850: e7a401f8 */ swc1 $f4,0x1f8($sp) +/* f091854: 8fa50200 */ lw $a1,0x200($sp) +/* f091858: 24090010 */ addiu $t1,$zero,0x10 +/* f09185c: afa90010 */ sw $t1,0x10($sp) +/* f091860: 24a50028 */ addiu $a1,$a1,0x28 +/* f091864: afa50050 */ sw $a1,0x50($sp) +/* f091868: 8fa40208 */ lw $a0,0x208($sp) +/* f09186c: 27a601f0 */ addiu $a2,$sp,0x1f0 +/* f091870: 0c00b764 */ jal cdTestAToB4 +/* f091874: 2407003b */ addiu $a3,$zero,0x3b +/* f091878: 1440000a */ bnez $v0,.L0f0918a4 +/* f09187c: 240a0001 */ addiu $t2,$zero,0x1 +/* f091880: 3c067f1b */ lui $a2,%hi(var7f1aa1c0) +/* f091884: afaa01fc */ sw $t2,0x1fc($sp) +/* f091888: 24c6a1c0 */ addiu $a2,$a2,%lo(var7f1aa1c0) +/* f09188c: 27a401f0 */ addiu $a0,$sp,0x1f0 +/* f091890: 0c0093af */ jal cdGetPos +/* f091894: 24055fa2 */ addiu $a1,$zero,0x5e49 +/* f091898: 0c0093ac */ jal cdGetObstacle +/* f09189c: 00000000 */ nop +/* f0918a0: afa201d8 */ sw $v0,0x1d8($sp) +.L0f0918a4: +/* f0918a4: 8fa40200 */ lw $a0,0x200($sp) +/* f0918a8: 0fc1905e */ jal propSetCollisionsEnabled +/* f0918ac: 24050001 */ addiu $a1,$zero,0x1 +/* f0918b0: 8fab0208 */ lw $t3,0x208($sp) +/* f0918b4: 8fac0214 */ lw $t4,0x214($sp) +/* f0918b8: c7a801f0 */ lwc1 $f8,0x1f0($sp) +/* f0918bc: c7a601f4 */ lwc1 $f6,0x1f4($sp) +/* f0918c0: c7b201f8 */ lwc1 $f18,0x1f8($sp) +/* f0918c4: c56a0000 */ lwc1 $f10,0x0($t3) +/* f0918c8: c5700004 */ lwc1 $f16,0x4($t3) +/* f0918cc: c5640008 */ lwc1 $f4,0x8($t3) +/* f0918d0: 460a4001 */ sub.s $f0,$f8,$f10 +/* f0918d4: 46103081 */ sub.s $f2,$f6,$f16 +/* f0918d8: 1180007b */ beqz $t4,.L0f091ac8 +/* f0918dc: 46049301 */ sub.s $f12,$f18,$f4 +/* f0918e0: 46000202 */ mul.s $f8,$f0,$f0 +/* f0918e4: c7a401dc */ lwc1 $f4,0x1dc($sp) +/* f0918e8: 46021282 */ mul.s $f10,$f2,$f2 +/* f0918ec: 460a4180 */ add.s $f6,$f8,$f10 +/* f0918f0: 460c6402 */ mul.s $f16,$f12,$f12 +/* f0918f4: 46103480 */ add.s $f18,$f6,$f16 +/* f0918f8: 4612203e */ c.le.s $f4,$f18 +/* f0918fc: 00000000 */ nop +/* f091900: 45020072 */ bc1fl .L0f091acc +/* f091904: 8fae01fc */ lw $t6,0x1fc($sp) +/* f091908: 0c012974 */ jal sqrtf +/* f09190c: 46002306 */ mov.s $f12,$f4 +/* f091910: 8fa20214 */ lw $v0,0x214($sp) +/* f091914: 3c0141a0 */ lui $at,0x41a0 +/* f091918: 44813000 */ mtc1 $at,$f6 +/* f09191c: c4480008 */ lwc1 $f8,0x8($v0) +/* f091920: 8fa40208 */ lw $a0,0x208($sp) +/* f091924: 8fa5020c */ lw $a1,0x20c($sp) +/* f091928: e7a80084 */ swc1 $f8,0x84($sp) +/* f09192c: c44a000c */ lwc1 $f10,0xc($v0) +/* f091930: 27a60084 */ addiu $a2,$sp,0x84 +/* f091934: 3c0741f0 */ lui $a3,0x41f0 +/* f091938: 46065401 */ sub.s $f16,$f10,$f6 +/* f09193c: e7b00088 */ swc1 $f16,0x88($sp) +/* f091940: c4520010 */ lwc1 $f18,0x10($v0) +/* f091944: e7a00090 */ swc1 $f0,0x90($sp) +/* f091948: 0fc1ace7 */ jal func0f06b39c +/* f09194c: e7b2008c */ swc1 $f18,0x8c($sp) +/* f091950: 1040005d */ beqz $v0,.L0f091ac8 +/* f091954: c7a20090 */ lwc1 $f2,0x90($sp) +/* f091958: 3c014348 */ lui $at,0x4348 +/* f09195c: 44816000 */ mtc1 $at,$f12 +/* f091960: 3c017f1b */ lui $at,%hi(var7f1ab214) +/* f091964: c424b214 */ lwc1 $f4,%lo(var7f1ab214)($at) +/* f091968: 3c01800a */ lui $at,%hi(g_Vars+0x4c) +/* f09196c: c428a00c */ lwc1 $f8,%lo(g_Vars+0x4c)($at) +/* f091970: 8fad0204 */ lw $t5,0x204($sp) +/* f091974: 4602603c */ c.lt.s $f12,$f2 +/* f091978: 46082282 */ mul.s $f10,$f4,$f8 +/* f09197c: c5a6000c */ lwc1 $f6,0xc($t5) +/* f091980: 8fae0204 */ lw $t6,0x204($sp) +/* f091984: 46065002 */ mul.s $f0,$f10,$f6 +/* f091988: 45020005 */ bc1fl .L0f0919a0 +/* f09198c: c5d20014 */ lwc1 $f18,0x14($t6) +/* f091990: 46026403 */ div.s $f16,$f12,$f2 +/* f091994: 46100002 */ mul.s $f0,$f0,$f16 +/* f091998: 00000000 */ nop +/* f09199c: c5d20014 */ lwc1 $f18,0x14($t6) +.L0f0919a0: +/* f0919a0: 3c013f80 */ lui $at,0x3f80 +/* f0919a4: 44814000 */ mtc1 $at,$f8 +/* f0919a8: 46009100 */ add.s $f4,$f18,$f0 +/* f0919ac: 4604403e */ c.le.s $f8,$f4 +/* f0919b0: e5c40014 */ swc1 $f4,0x14($t6) +/* f0919b4: 8fa20214 */ lw $v0,0x214($sp) +/* f0919b8: 45020044 */ bc1fl .L0f091acc +/* f0919bc: 8fae01fc */ lw $t6,0x1fc($sp) +/* f0919c0: afa001fc */ sw $zero,0x1fc($sp) +/* f0919c4: c44a0008 */ lwc1 $f10,0x8($v0) +/* f0919c8: e7aa01f0 */ swc1 $f10,0x1f0($sp) +/* f0919cc: c446000c */ lwc1 $f6,0xc($v0) +/* f0919d0: e7a601f4 */ swc1 $f6,0x1f4($sp) +/* f0919d4: c4500010 */ lwc1 $f16,0x10($v0) +/* f0919d8: 0c004b70 */ jal random +/* f0919dc: e7b001f8 */ swc1 $f16,0x1f8($sp) +/* f0919e0: 304f0001 */ andi $t7,$v0,0x1 +/* f0919e4: 11e00012 */ beqz $t7,.L0f091a30 +/* f0919e8: 00000000 */ nop +/* f0919ec: 0c004b70 */ jal random +/* f0919f0: 00000000 */ nop +/* f0919f4: 2401000a */ addiu $at,$zero,0xa +/* f0919f8: 0041001b */ divu $zero,$v0,$at +/* f0919fc: 0000c010 */ mfhi $t8 +/* f091a00: 27190002 */ addiu $t9,$t8,0x2 +/* f091a04: 44992000 */ mtc1 $t9,$f4 +/* f091a08: c7b201f4 */ lwc1 $f18,0x1f4($sp) +/* f091a0c: 07210005 */ bgez $t9,.L0f091a24 +/* f091a10: 46802220 */ cvt.s.w $f8,$f4 +/* f091a14: 3c014f80 */ lui $at,0x4f80 +/* f091a18: 44815000 */ mtc1 $at,$f10 +/* f091a1c: 00000000 */ nop +/* f091a20: 460a4200 */ add.s $f8,$f8,$f10 +.L0f091a24: +/* f091a24: 46089180 */ add.s $f6,$f18,$f8 +/* f091a28: 10000011 */ b .L0f091a70 +/* f091a2c: e7a601f4 */ swc1 $f6,0x1f4($sp) +.L0f091a30: +/* f091a30: 0c004b70 */ jal random +/* f091a34: 00000000 */ nop +/* f091a38: 2401000a */ addiu $at,$zero,0xa +/* f091a3c: 0041001b */ divu $zero,$v0,$at +/* f091a40: 00004010 */ mfhi $t0 +/* f091a44: 25090002 */ addiu $t1,$t0,0x2 +/* f091a48: 44892000 */ mtc1 $t1,$f4 +/* f091a4c: c7b001f4 */ lwc1 $f16,0x1f4($sp) +/* f091a50: 05210005 */ bgez $t1,.L0f091a68 +/* f091a54: 468022a0 */ cvt.s.w $f10,$f4 +/* f091a58: 3c014f80 */ lui $at,0x4f80 +/* f091a5c: 44819000 */ mtc1 $at,$f18 +/* f091a60: 00000000 */ nop +/* f091a64: 46125280 */ add.s $f10,$f10,$f18 +.L0f091a68: +/* f091a68: 460a8201 */ sub.s $f8,$f16,$f10 +/* f091a6c: e7a801f4 */ swc1 $f8,0x1f4($sp) +.L0f091a70: +/* f091a70: 27a40094 */ addiu $a0,$sp,0x94 +/* f091a74: 8fa50214 */ lw $a1,0x214($sp) +/* f091a78: 0fc29f66 */ jal bgunPlayPropHitSound +/* f091a7c: 2406ffff */ addiu $a2,$zero,-1 +/* f091a80: 0fc2c74a */ jal gsetGetDamage +/* f091a84: 27a40094 */ addiu $a0,$sp,0x94 +/* f091a88: 8fab0204 */ lw $t3,0x204($sp) +/* f091a8c: 8faa0214 */ lw $t2,0x214($sp) +/* f091a90: 240c00c8 */ addiu $t4,$zero,0xc8 +/* f091a94: c5660010 */ lwc1 $f6,0x10($t3) +/* f091a98: 8d440004 */ lw $a0,0x4($t2) +/* f091a9c: afac0014 */ sw $t4,0x14($sp) +/* f091aa0: 46060102 */ mul.s $f4,$f0,$f6 +/* f091aa4: afa00010 */ sw $zero,0x10($sp) +/* f091aa8: 8fa6020c */ lw $a2,0x20c($sp) +/* f091aac: 27a70094 */ addiu $a3,$sp,0x94 +/* f091ab0: 44052000 */ mfc1 $a1,$f4 +/* f091ab4: 0fc0d0cc */ jal chrDamageByImpact +/* f091ab8: 00000000 */ nop +/* f091abc: 44809000 */ mtc1 $zero,$f18 +/* f091ac0: 8fad0204 */ lw $t5,0x204($sp) +/* f091ac4: e5b20014 */ swc1 $f18,0x14($t5) +.L0f091ac8: +/* f091ac8: 8fae01fc */ lw $t6,0x1fc($sp) +.L0f091acc: +/* f091acc: 8faf01d8 */ lw $t7,0x1d8($sp) +/* f091ad0: 51c00093 */ beqzl $t6,.L0f091d20 +/* f091ad4: 93ae01c7 */ lbu $t6,0x1c7($sp) +/* f091ad8: 11e0007d */ beqz $t7,.L0f091cd0 +/* f091adc: 8fa40208 */ lw $a0,0x208($sp) +/* f091ae0: 91e20000 */ lbu $v0,0x0($t7) +/* f091ae4: 24010003 */ addiu $at,$zero,0x3 +/* f091ae8: 2418ffff */ addiu $t8,$zero,-1 +/* f091aec: 10410004 */ beq $v0,$at,.L0f091b00 +/* f091af0: 241900c8 */ addiu $t9,$zero,0xc8 +/* f091af4: 24010006 */ addiu $at,$zero,0x6 +/* f091af8: 54410040 */ bnel $v0,$at,.L0f091bfc +/* f091afc: 24010001 */ addiu $at,$zero,0x1 +.L0f091b00: +/* f091b00: 8fa801d8 */ lw $t0,0x1d8($sp) +/* f091b04: 8faa0054 */ lw $t2,0x54($sp) +/* f091b08: afa0007c */ sw $zero,0x7c($sp) +/* f091b0c: afa00078 */ sw $zero,0x78($sp) +/* f091b10: afb80074 */ sw $t8,0x74($sp) +/* f091b14: afb90070 */ sw $t9,0x70($sp) +/* f091b18: 8d090004 */ lw $t1,0x4($t0) +/* f091b1c: 24010059 */ addiu $at,$zero,0x58 +/* f091b20: 11410005 */ beq $t2,$at,.L0f091b38 +/* f091b24: afa9006c */ sw $t1,0x6c($sp) +/* f091b28: 27a40094 */ addiu $a0,$sp,0x94 +/* f091b2c: 01002825 */ or $a1,$t0,$zero +/* f091b30: 0fc29f66 */ jal bgunPlayPropHitSound +/* f091b34: 2406ffff */ addiu $a2,$zero,-1 +.L0f091b38: +/* f091b38: 8fab006c */ lw $t3,0x6c($sp) +/* f091b3c: 27a501f0 */ addiu $a1,$sp,0x1f0 +/* f091b40: 8fa6020c */ lw $a2,0x20c($sp) +/* f091b44: 8d6c0020 */ lw $t4,0x20($t3) +/* f091b48: 27a7007c */ addiu $a3,$sp,0x7c +/* f091b4c: 27ad0070 */ addiu $t5,$sp,0x70 +/* f091b50: 11800007 */ beqz $t4,.L0f091b70 +/* f091b54: 01602025 */ or $a0,$t3,$zero +/* f091b58: 27ae0078 */ addiu $t6,$sp,0x78 +/* f091b5c: 27af0074 */ addiu $t7,$sp,0x74 +/* f091b60: afaf0018 */ sw $t7,0x18($sp) +/* f091b64: afae0014 */ sw $t6,0x14($sp) +/* f091b68: 0fc0ffcb */ jal chrCalculateShieldHit +/* f091b6c: afad0010 */ sw $t5,0x10($sp) +.L0f091b70: +/* f091b70: 8fb8020c */ lw $t8,0x20c($sp) +/* f091b74: 8fa4006c */ lw $a0,0x6c($sp) +/* f091b78: 8fa501d8 */ lw $a1,0x1d8($sp) +/* f091b7c: 8fa60070 */ lw $a2,0x70($sp) +/* f091b80: 27a701f0 */ addiu $a3,$sp,0x1f0 +/* f091b84: afa00014 */ sw $zero,0x14($sp) +/* f091b88: 0fc097a9 */ jal chrEmitSparks +/* f091b8c: afb80010 */ sw $t8,0x10($sp) +/* f091b90: 93b90187 */ lbu $t9,0x187($sp) +/* f091b94: 8faa006c */ lw $t2,0x6c($sp) +/* f091b98: 13200002 */ beqz $t9,.L0f091ba4 +/* f091b9c: 24091388 */ addiu $t1,$zero,0x1388 +/* f091ba0: a54902d8 */ sh $t1,0x2d8($t2) +.L0f091ba4: +/* f091ba4: 0fc2c74a */ jal gsetGetDamage +/* f091ba8: 27a40094 */ addiu $a0,$sp,0x94 +/* f091bac: 8fa80070 */ lw $t0,0x70($sp) +/* f091bb0: 8fac01d8 */ lw $t4,0x1d8($sp) +/* f091bb4: 8fab007c */ lw $t3,0x7c($sp) +/* f091bb8: 8fad0078 */ lw $t5,0x78($sp) +/* f091bbc: 8fae0074 */ lw $t6,0x74($sp) +/* f091bc0: 44050000 */ mfc1 $a1,$f0 +/* f091bc4: 8fa4006c */ lw $a0,0x6c($sp) +/* f091bc8: 8fa6020c */ lw $a2,0x20c($sp) +/* f091bcc: 27a70094 */ addiu $a3,$sp,0x94 +/* f091bd0: afa00010 */ sw $zero,0x10($sp) +/* f091bd4: afa00028 */ sw $zero,0x28($sp) +/* f091bd8: afa80014 */ sw $t0,0x14($sp) +/* f091bdc: afac0018 */ sw $t4,0x18($sp) +/* f091be0: afab001c */ sw $t3,0x1c($sp) +/* f091be4: afad0020 */ sw $t5,0x20($sp) +/* f091be8: 0fc0d077 */ jal func0f0341dc +/* f091bec: afae0024 */ sw $t6,0x24($sp) +/* f091bf0: 1000004b */ b .L0f091d20 +/* f091bf4: 93ae01c7 */ lbu $t6,0x1c7($sp) +/* f091bf8: 24010001 */ addiu $at,$zero,0x1 +.L0f091bfc: +/* f091bfc: 10410006 */ beq $v0,$at,.L0f091c18 +/* f091c00: 8faf01d8 */ lw $t7,0x1d8($sp) +/* f091c04: 24010004 */ addiu $at,$zero,0x4 +/* f091c08: 10410003 */ beq $v0,$at,.L0f091c18 +/* f091c0c: 24010002 */ addiu $at,$zero,0x2 +/* f091c10: 54410043 */ bnel $v0,$at,.L0f091d20 +/* f091c14: 93ae01c7 */ lbu $t6,0x1c7($sp) +.L0f091c18: +/* f091c18: 8fb90054 */ lw $t9,0x54($sp) +/* f091c1c: 8df80004 */ lw $t8,0x4($t7) +/* f091c20: 24010059 */ addiu $at,$zero,0x58 +/* f091c24: 13210005 */ beq $t9,$at,.L0f091c3c +/* f091c28: afb80068 */ sw $t8,0x68($sp) +/* f091c2c: 27a40094 */ addiu $a0,$sp,0x94 +/* f091c30: 01e02825 */ or $a1,$t7,$zero +/* f091c34: 0fc29f66 */ jal bgunPlayPropHitSound +/* f091c38: 2406ffff */ addiu $a2,$zero,-1 +.L0f091c3c: +/* f091c3c: 8fa40208 */ lw $a0,0x208($sp) +/* f091c40: 8fa50050 */ lw $a1,0x50($sp) +/* f091c44: 27a601f0 */ addiu $a2,$sp,0x1f0 +/* f091c48: 0fc1979d */ jal func0f065e74 +/* f091c4c: 27a701c8 */ addiu $a3,$sp,0x1c8 +/* f091c50: 87a401c8 */ lh $a0,0x1c8($sp) +/* f091c54: 8fa501d8 */ lw $a1,0x1d8($sp) +/* f091c58: 27a601f0 */ addiu $a2,$sp,0x1f0 +/* f091c5c: 00003825 */ or $a3,$zero,$zero +/* f091c60: afa00010 */ sw $zero,0x10($sp) +/* f091c64: 0fc4be7c */ jal sparksCreate +/* f091c68: afa00014 */ sw $zero,0x14($sp) +/* f091c6c: 0fc2c74a */ jal gsetGetDamage +/* f091c70: 27a40094 */ addiu $a0,$sp,0x94 +/* f091c74: 8fa901d8 */ lw $t1,0x1d8($sp) +/* f091c78: 44050000 */ mfc1 $a1,$f0 +/* f091c7c: 240affff */ addiu $t2,$zero,-1 +/* f091c80: 8d240004 */ lw $a0,0x4($t1) +/* f091c84: afaa0010 */ sw $t2,0x10($sp) +/* f091c88: 27a601f0 */ addiu $a2,$sp,0x1f0 +/* f091c8c: 0fc2149c */ jal objTakeGunfire +/* f091c90: 8fa70054 */ lw $a3,0x54($sp) +/* f091c94: 8fa20068 */ lw $v0,0x68($sp) +/* f091c98: 24010008 */ addiu $at,$zero,0x8 +/* f091c9c: 90480003 */ lbu $t0,0x3($v0) +/* f091ca0: 5501001f */ bnel $t0,$at,.L0f091d20 +/* f091ca4: 93ae01c7 */ lbu $t6,0x1c7($sp) +/* f091ca8: 904c005c */ lbu $t4,0x5c($v0) +/* f091cac: 2401000f */ addiu $at,$zero,0xf +/* f091cb0: 5581001b */ bnel $t4,$at,.L0f091d20 +/* f091cb4: 93ae01c7 */ lbu $t6,0x1c7($sp) +/* f091cb8: 904b005f */ lbu $t3,0x5f($v0) +/* f091cbc: 24010001 */ addiu $at,$zero,0x1 +/* f091cc0: 55610017 */ bnel $t3,$at,.L0f091d20 +/* f091cc4: 93ae01c7 */ lbu $t6,0x1c7($sp) +/* f091cc8: 10000014 */ b .L0f091d1c +/* f091ccc: a4400062 */ sh $zero,0x62($v0) +.L0f091cd0: +/* f091cd0: 8fa50050 */ lw $a1,0x50($sp) +/* f091cd4: 27a601f0 */ addiu $a2,$sp,0x1f0 +/* f091cd8: 0fc1979d */ jal func0f065e74 +/* f091cdc: 27a701c8 */ addiu $a3,$sp,0x1c8 +/* f091ce0: 8fad0054 */ lw $t5,0x54($sp) +/* f091ce4: 24010059 */ addiu $at,$zero,0x58 +/* f091ce8: 27a40094 */ addiu $a0,$sp,0x94 +/* f091cec: 11a10004 */ beq $t5,$at,.L0f091d00 +/* f091cf0: 27a501f0 */ addiu $a1,$sp,0x1f0 +/* f091cf4: 2406ffff */ addiu $a2,$zero,-1 +/* f091cf8: 0fc2a132 */ jal bgunPlayBgHitSound +/* f091cfc: 27a701c8 */ addiu $a3,$sp,0x1c8 +.L0f091d00: +/* f091d00: 87a401c8 */ lh $a0,0x1c8($sp) +/* f091d04: 00002825 */ or $a1,$zero,$zero +/* f091d08: 27a601f0 */ addiu $a2,$sp,0x1f0 +/* f091d0c: 00003825 */ or $a3,$zero,$zero +/* f091d10: afa00010 */ sw $zero,0x10($sp) +/* f091d14: 0fc4be7c */ jal sparksCreate +/* f091d18: afa00014 */ sw $zero,0x14($sp) +.L0f091d1c: +/* f091d1c: 93ae01c7 */ lbu $t6,0x1c7($sp) +.L0f091d20: +/* f091d20: 8fb80204 */ lw $t8,0x204($sp) +/* f091d24: 93af01c7 */ lbu $t7,0x1c7($sp) +/* f091d28: 15c00006 */ bnez $t6,.L0f091d44 +/* f091d2c: 93aa01c7 */ lbu $t2,0x1c7($sp) +/* f091d30: 53000011 */ beqzl $t8,.L0f091d78 +/* f091d34: 8fbf0044 */ lw $ra,0x44($sp) +/* f091d38: 93190001 */ lbu $t9,0x1($t8) +/* f091d3c: 5320000e */ beqzl $t9,.L0f091d78 +/* f091d40: 8fbf0044 */ lw $ra,0x44($sp) +.L0f091d44: +/* f091d44: 11e00003 */ beqz $t7,.L0f091d54 +/* f091d48: 27a6018c */ addiu $a2,$sp,0x18c +/* f091d4c: 10000003 */ b .L0f091d5c +/* f091d50: 27a40198 */ addiu $a0,$sp,0x198 +.L0f091d54: +/* f091d54: 8fa90204 */ lw $t1,0x204($sp) +/* f091d58: 8d240004 */ lw $a0,0x4($t1) +.L0f091d5c: +/* f091d5c: 11400003 */ beqz $t2,.L0f091d6c +/* f091d60: 8fa50054 */ lw $a1,0x54($sp) +/* f091d64: 10000001 */ b .L0f091d6c +/* f091d68: 24050002 */ addiu $a1,$zero,0x2 +.L0f091d6c: +/* f091d6c: 0fc2af9c */ jal beamCreate +/* f091d70: 27a701f0 */ addiu $a3,$sp,0x1f0 +.L0f091d74: +/* f091d74: 8fbf0044 */ lw $ra,0x44($sp) +.L0f091d78: +/* f091d78: 27bd0200 */ addiu $sp,$sp,0x200 +/* f091d7c: 03e00008 */ jr $ra +/* f091d80: 00000000 */ nop +); #endif void objSetModelPartVisible(struct defaultobj *obj, s32 partnum, bool visible) diff --git a/src/game/savebuffer.c b/src/game/savebuffer.c index 72e6f8852..84480d68b 100644 --- a/src/game/savebuffer.c +++ b/src/game/savebuffer.c @@ -19,17 +19,17 @@ const char var7f1adbb4[] = "rsub"; const char var7f1adbbc[] = ":%02d"; const char var7f1adbc4[] = "%d"; -u32 var8009de90; -u32 var8009de94; -u32 var8009de98; -u32 var8009de9c; - #if VERSION >= VERSION_NTSC_1_0 Vp *var80070f10 = NULL; #else Vp var80070f10; #endif +u32 var8009de90; +u32 var8009de94; +u32 var8009de98; +u32 var8009de9c; + u32 var80070f14 = 0x000003e8; u32 var80070f18 = 0x00000014; u32 var80070f1c = 0x00000005; diff --git a/src/game/splat.c b/src/game/splat.c index 89deaf990..8352e97dd 100644 --- a/src/game/splat.c +++ b/src/game/splat.c @@ -171,8 +171,14 @@ s32 func0f148f18(s32 qty, f32 arg1, struct prop *prop, struct splat *arg3, struc mtx0001648c((struct coord *)spe4, &spa4); mtx00015b14(&spa4, (struct coord *)spfc, &splat->unk028); mtx00015b14(&spa4, (struct coord *)spf0, &splat->unk00c); + +#if VERSION >= VERSION_NTSC_1_0 func0f177164(&splat->unk028, &splat->unk028, 403, "splat.c"); func0f177164(&splat->unk00c, &splat->unk00c, 404, "splat.c"); +#else + func0f177164(&splat->unk028, &splat->unk028, 405, "splat.c"); + func0f177164(&splat->unk00c, &splat->unk00c, 406, "splat.c"); +#endif if (func0f149274(arg1, prop, splat, dist, arg6, arg7, arg8, arg9, arg10)) { numdropped++; diff --git a/src/game/title.c b/src/game/title.c index aa099e293..9de048c5e 100644 --- a/src/game/title.c +++ b/src/game/title.c @@ -4136,7 +4136,7 @@ glabel var7f1a8468 /* f017f2c: c42827bc */ lwc1 $f8,%lo(var800627bc)($at) /* f017f30: 46043282 */ mul.s $f10,$f6,$f4 /* f017f34: 460a4000 */ add.s $f0,$f8,$f10 -/* f017f38: e42027bc */ swc1 $f0,0x27bc($at) +/* f017f38: e42027bc */ swc1 $f0,%lo(var800627bc)($at) /* f017f3c: 3c017f1b */ lui $at,%hi(var7f1a8438) /* f017f40: c4248438 */ lwc1 $f4,%lo(var7f1a8438)($at) /* f017f44: 3c018006 */ lui $at,%hi(var800627bc) diff --git a/src/game/training/menus.c b/src/game/training/menus.c index 6fe55a06f..2be0e1c98 100644 --- a/src/game/training/menus.c +++ b/src/game/training/menus.c @@ -6210,7 +6210,7 @@ glabel var7f1b99d8 /* f1a754c: 03e00008 */ jr $ra /* f1a7550: 00000000 */ nop ); -#else +#elif VERSION >= VERSION_NTSC_1_0 GLOBAL_ASM( glabel ciHangarHolographMenuDialog .late_rodata @@ -6344,6 +6344,140 @@ glabel var7f1b99d8 /* f1a754c: 03e00008 */ jr $ra /* f1a7550: 00000000 */ nop ); +#else +GLOBAL_ASM( +glabel ciHangarHolographMenuDialog +.late_rodata +glabel var7f1b99d4 +.word 0x3a83126f +glabel var7f1b99d8 +.word 0x3c23d70a +.text +/* f1a1360: 27bdff60 */ addiu $sp,$sp,-160 +/* f1a1364: afa600a8 */ sw $a2,0xa8($sp) +/* f1a1368: 00803025 */ or $a2,$a0,$zero +/* f1a136c: afa400a0 */ sw $a0,0xa0($sp) +/* f1a1370: afbf0014 */ sw $ra,0x14($sp) +/* f1a1374: 3c048009 */ lui $a0,0x8009 +/* f1a1378: afa500a4 */ sw $a1,0xa4($sp) +/* f1a137c: 9084b0d4 */ lbu $a0,-0x4f2c($a0) +/* f1a1380: 0fc66ddf */ jal ciGetHangarBioIndexBySlot +/* f1a1384: afa600a0 */ sw $a2,0xa0($sp) +/* f1a1388: 2841000e */ slti $at,$v0,0xe +/* f1a138c: 14200065 */ bnez $at,.NB0f1a1524 +/* f1a1390: 8fa600a0 */ lw $a2,0xa0($sp) +/* f1a1394: 3c0e8009 */ lui $t6,0x8009 +/* f1a1398: 27a70030 */ addiu $a3,$sp,0x30 +/* f1a139c: 25cebf3c */ addiu $t6,$t6,-16580 +/* f1a13a0: 25d8006c */ addiu $t8,$t6,0x6c +/* f1a13a4: 00e0c825 */ or $t9,$a3,$zero +.NB0f1a13a8: +/* f1a13a8: 8dc10000 */ lw $at,0x0($t6) +/* f1a13ac: 25ce000c */ addiu $t6,$t6,0xc +/* f1a13b0: 2739000c */ addiu $t9,$t9,0xc +/* f1a13b4: af21fff4 */ sw $at,-0xc($t9) +/* f1a13b8: 8dc1fff8 */ lw $at,-0x8($t6) +/* f1a13bc: af21fff8 */ sw $at,-0x8($t9) +/* f1a13c0: 8dc1fffc */ lw $at,-0x4($t6) +/* f1a13c4: 15d8fff8 */ bne $t6,$t8,.NB0f1a13a8 +/* f1a13c8: af21fffc */ sw $at,-0x4($t9) +/* f1a13cc: 24010064 */ addiu $at,$zero,0x64 +/* f1a13d0: 10c10008 */ beq $a2,$at,.NB0f1a13f4 +/* f1a13d4: 3c088007 */ lui $t0,0x8007 +/* f1a13d8: 24010065 */ addiu $at,$zero,0x65 +/* f1a13dc: 10c10051 */ beq $a2,$at,.NB0f1a1524 +/* f1a13e0: 24010066 */ addiu $at,$zero,0x66 +/* f1a13e4: 10c10019 */ beq $a2,$at,.NB0f1a144c +/* f1a13e8: 00000000 */ sll $zero,$zero,0x0 +/* f1a13ec: 1000004e */ beqz $zero,.NB0f1a1528 +/* f1a13f0: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f1a13f4: +/* f1a13f4: 8d083af0 */ lw $t0,0x3af0($t0) +/* f1a13f8: 44800000 */ mtc1 $zero,$f0 +/* f1a13fc: 3c0a800a */ lui $t2,0x800a +/* f1a1400: 000848c0 */ sll $t1,$t0,0x3 +/* f1a1404: 01284823 */ subu $t1,$t1,$t0 +/* f1a1408: 000948c0 */ sll $t1,$t1,0x3 +/* f1a140c: 01284823 */ subu $t1,$t1,$t0 +/* f1a1410: 00094900 */ sll $t1,$t1,0x4 +/* f1a1414: 01284823 */ subu $t1,$t1,$t0 +/* f1a1418: 00094880 */ sll $t1,$t1,0x2 +/* f1a141c: 254a27c0 */ addiu $t2,$t2,0x27c0 +/* f1a1420: 012a1821 */ addu $v1,$t1,$t2 +/* f1a1424: e4600ce4 */ swc1 $f0,0xce4($v1) +/* f1a1428: e4600cbc */ swc1 $f0,0xcbc($v1) +/* f1a142c: e4600ce8 */ swc1 $f0,0xce8($v1) +/* f1a1430: e4600cc0 */ swc1 $f0,0xcc0($v1) +/* f1a1434: e4600cd4 */ swc1 $f0,0xcd4($v1) +/* f1a1438: e4600cac */ swc1 $f0,0xcac($v1) +/* f1a143c: e4600cd8 */ swc1 $f0,0xcd8($v1) +/* f1a1440: e4600cb0 */ swc1 $f0,0xcb0($v1) +/* f1a1444: 10000037 */ beqz $zero,.NB0f1a1524 +/* f1a1448: e4600cb8 */ swc1 $f0,0xcb8($v1) +.NB0f1a144c: +/* f1a144c: 3c0b8007 */ lui $t3,0x8007 +/* f1a1450: 8d6b3af0 */ lw $t3,0x3af0($t3) +/* f1a1454: 3c0d800a */ lui $t5,0x800a +/* f1a1458: 25ad27c0 */ addiu $t5,$t5,0x27c0 +/* f1a145c: 000b60c0 */ sll $t4,$t3,0x3 +/* f1a1460: 018b6023 */ subu $t4,$t4,$t3 +/* f1a1464: 000c60c0 */ sll $t4,$t4,0x3 +/* f1a1468: 018b6023 */ subu $t4,$t4,$t3 +/* f1a146c: 000c6100 */ sll $t4,$t4,0x4 +/* f1a1470: 018b6023 */ subu $t4,$t4,$t3 +/* f1a1474: 000c6080 */ sll $t4,$t4,0x2 +/* f1a1478: 018d1821 */ addu $v1,$t4,$t5 +/* f1a147c: 8c640488 */ lw $a0,0x488($v1) +/* f1a1480: 50800029 */ beqzl $a0,.NB0f1a1528 +/* f1a1484: 8fbf0014 */ lw $ra,0x14($sp) +/* f1a1488: 8faf00a4 */ lw $t7,0xa4($sp) +/* f1a148c: 8c980000 */ lw $t8,0x0($a0) +/* f1a1490: 2445fff2 */ addiu $a1,$v0,-14 +/* f1a1494: 00057080 */ sll $t6,$a1,0x2 +/* f1a1498: 15f80022 */ bne $t7,$t8,.NB0f1a1524 +/* f1a149c: 01c57023 */ subu $t6,$t6,$a1 +/* f1a14a0: 000e7080 */ sll $t6,$t6,0x2 +/* f1a14a4: 00ee2021 */ addu $a0,$a3,$t6 +/* f1a14a8: 8c990004 */ lw $t9,0x4($a0) +/* f1a14ac: 94880008 */ lhu $t0,0x8($a0) +/* f1a14b0: 3c014f80 */ lui $at,0x4f80 +/* f1a14b4: 44992000 */ mtc1 $t9,$f4 +/* f1a14b8: 44883000 */ mtc1 $t0,$f6 +/* f1a14bc: 46802020 */ cvt.s.w $f0,$f4 +/* f1a14c0: 05010004 */ bgez $t0,.NB0f1a14d4 +/* f1a14c4: 46803220 */ cvt.s.w $f8,$f6 +/* f1a14c8: 44815000 */ mtc1 $at,$f10 +/* f1a14cc: 00000000 */ sll $zero,$zero,0x0 +/* f1a14d0: 460a4200 */ add.s $f8,$f8,$f10 +.NB0f1a14d4: +/* f1a14d4: 3c017f1b */ lui $at,0x7f1b +/* f1a14d8: c4303ff4 */ lwc1 $f16,0x3ff4($at) +/* f1a14dc: 8c890000 */ lw $t1,0x0($a0) +/* f1a14e0: e4600cb0 */ swc1 $f0,0xcb0($v1) +/* f1a14e4: 46104302 */ mul.s $f12,$f8,$f16 +/* f1a14e8: e4600cd8 */ swc1 $f0,0xcd8($v1) +/* f1a14ec: 3c017f1b */ lui $at,0x7f1b +/* f1a14f0: ac6907a8 */ sw $t1,0x7a8($v1) +/* f1a14f4: c46a0cc0 */ lwc1 $f10,0xcc0($v1) +/* f1a14f8: 3c0a8009 */ lui $t2,0x8009 +/* f1a14fc: 254abf34 */ addiu $t2,$t2,-16588 +/* f1a1500: e46c0ce0 */ swc1 $f12,0xce0($v1) +/* f1a1504: c4323ff8 */ lwc1 $f18,0x3ff8($at) +/* f1a1508: 3c01800a */ lui $at,0x800a +/* f1a150c: c424e6c4 */ lwc1 $f4,-0x193c($at) +/* f1a1510: ac6a0d50 */ sw $t2,0xd50($v1) +/* f1a1514: 46049182 */ mul.s $f6,$f18,$f4 +/* f1a1518: 46065080 */ add.s $f2,$f10,$f6 +/* f1a151c: e4620ce8 */ swc1 $f2,0xce8($v1) +/* f1a1520: e4620cc0 */ swc1 $f2,0xcc0($v1) +.NB0f1a1524: +/* f1a1524: 8fbf0014 */ lw $ra,0x14($sp) +.NB0f1a1528: +/* f1a1528: 27bd00a0 */ addiu $sp,$sp,0xa0 +/* f1a152c: 00001025 */ or $v0,$zero,$zero +/* f1a1530: 03e00008 */ jr $ra +/* f1a1534: 00000000 */ sll $zero,$zero,0x0 +); #endif s8 var800897c4[] = {-73, 0, 5, 0}; diff --git a/src/game/weather/weather.c b/src/game/weather/weather.c index d76c94342..f00a4cf03 100644 --- a/src/game/weather/weather.c +++ b/src/game/weather/weather.c @@ -742,13 +742,17 @@ bool weatherIsRoomWeatherProof(s32 room) if (g_StageIndex == STAGEINDEX_CRASHSITE) { // Rooms listed do not have weather + // Note that ntsc-beta is likely the same actual rooms as the newer + // versions; they just have shifted numbers. if (room == 0x1f || room == 0x20 || room == 0x21 || room == 0x22 || room == 0x23 || room == 0x24 +#if VERSION >= VERSION_NTSC_1_0 || room == 0x51 +#endif || room == 0x52 || room == 0x53 || room == 0x54 @@ -768,8 +772,13 @@ bool weatherIsRoomWeatherProof(s32 room) || room == 0x62 || room == 0x63 || room == 0x64 +#if VERSION < VERSION_NTSC_1_0 + || room == 0x65 +#endif || room == 0x2d +#if VERSION >= VERSION_NTSC_1_0 || room == 0x40 +#endif || room == 0x41 || room == 0x42 || room == 0x43 @@ -785,7 +794,11 @@ bool weatherIsRoomWeatherProof(s32 room) || room == 0x4d || room == 0x4e || room == 0x4f - || room == 0x50) { + || room == 0x50 +#if VERSION < VERSION_NTSC_1_0 + || room == 0x51 +#endif + ) { return true; } diff --git a/src/include/bss.h b/src/include/bss.h index 333d50d82..da22932cb 100644 --- a/src/include/bss.h +++ b/src/include/bss.h @@ -178,7 +178,7 @@ extern u32 var8009de94; extern u32 var8009de98; extern u32 var8009de9c; extern u8 g_MpSelectedPlayersForStats[4]; -extern char g_CheatMarqueeString[252]; +extern char g_CheatMarqueeString[]; extern u8 *g_BlurBuffer; extern s32 var8009dfc0; extern struct briefing g_Briefing; diff --git a/src/include/constants.h b/src/include/constants.h index 7e3dd52e0..527b3347c 100644 --- a/src/include/constants.h +++ b/src/include/constants.h @@ -2760,7 +2760,6 @@ #define MPWEAPON_SHIELD 0x25 #define MPWEAPON_DISABLED 0x26 -#define NUM_AICOMMANDS 481 #define NUM_BODIES 151 #define NUM_CHALLENGES 30 #define NUM_CHEATS 42 @@ -2780,7 +2779,6 @@ #define NUM_SOLOSTAGES 21 #define NUM_STAGES 90 #define NUM_TEXTURES 3504 -#define NUM_WEAPONS 94 #define OBJECTIVE_INCOMPLETE 0 #define OBJECTIVE_COMPLETE 1 diff --git a/src/include/data.h b/src/include/data.h index 93ab7897c..48d3295bb 100644 --- a/src/include/data.h +++ b/src/include/data.h @@ -290,8 +290,8 @@ extern u32 var800711f0; extern char *g_StringPointer; extern char *g_StringPointer2; #else -extern char g_StringPointer[125]; -extern char g_StringPointer2[125]; +extern char g_StringPointer[]; +extern char g_StringPointer2[]; #endif extern s32 g_MpPlayerNum; extern u32 var800714d8; diff --git a/src/include/types.h b/src/include/types.h index 19a599c30..89485c134 100644 --- a/src/include/types.h +++ b/src/include/types.h @@ -3852,34 +3852,38 @@ struct menudata_mpend { }; struct menudata_filemgr { - /*0xe1c*/ u32 filetypeplusone; - /*0xe20*/ u32 device; - /*0xe24*/ u32 unke24; + /*0xe1c*/ u32 filetypeplusone; // used + /*0xe20*/ u32 device; // used + /*0xe24*/ u32 unke24; // used union { - u32 isdeletingforsave; + u32 isdeletingforsave; // used u32 noteindex; }; - /*0xe2c*/ u32 unke2c; + /*0xe2c*/ u32 unke2c; // used /*0xe30*/ u32 unke30; - /*0xe34*/ u16 errno; - /*0xe38*/ struct filelistfile *filetodelete; - /*0xe3c*/ u8 device1; - /*0xe3d*/ u8 filetypetodelete; - /*0xe3e*/ u8 unke3e; - /*0xe3f*/ u8 listnum; + /*0xe34*/ u16 errno; // used + /*0xe38*/ struct filelistfile *filetodelete; // used + /*0xe3c*/ u8 device1; // used + /*0xe3d*/ u8 filetypetodelete; // used + /*0xe3e*/ u8 unke3e; // used + /*0xe3f*/ u8 listnum; // used /*0xe40*/ u16 unke40_00 : 1; /*0xe40*/ u16 unke40_01 : 1; /*0xe40*/ u16 unke40_02 : 14; /*0xe42*/ u8 fileop; union { - void *unke44; + void *unke44; // used s32 mpplayernum; }; - /*0xe48*/ u32 fileid; - /*0xe4c*/ u32 deviceserial; - /*0xe50*/ u16 isretryingsave; + /*0xe48*/ u32 fileid; // used + /*0xe4c*/ u32 deviceserial; // used + /*0xe50*/ u16 isretryingsave; // used /*0xe52*/ u8 device2; +#if VERSION >= VERSION_NTSC_1_0 /*0xe53*/ char filename[20]; +#else + /*0xe53*/ char filename[4]; +#endif /*0xe68*/ struct perfectheadtexturelist *headtextures; /*0xe6c*/ s8 device3; }; @@ -3918,7 +3922,11 @@ struct perfectheadtexturelist { }; struct menu { +#if VERSION >= VERSION_NTSC_1_0 struct menuframe frames[10]; +#else + struct menuframe frames[9]; +#endif /*0x460*/ s16 numframes; /*0x464*/ struct menulayer layers[6]; /*0x4f4*/ s16 depth; // index into layers. 1-indexed? @@ -4003,6 +4011,7 @@ struct menu { /*0x630*/ u32 unk630; /*0x634*/ u32 unk634; /*0x638*/ u32 unk638; +#if VERSION >= VERSION_NTSC_1_0 /*0x63c*/ u32 unk63c; /*0x640*/ u32 unk640; /*0x644*/ u32 unk644; @@ -4011,6 +4020,7 @@ struct menu { /*0x650*/ u32 unk650; /*0x654*/ u32 unk654; /*0x658*/ u32 unk658; +#endif /*0x65c*/ s32 unk65c; /*0x660*/ u16 unk660[1][5]; // length unknown /*0x66c*/ u32 unk66c; @@ -4035,11 +4045,13 @@ struct menu { /*0x6b8*/ u32 unk6b8; /*0x6bc*/ u32 unk6bc; /*0x6c0*/ u32 unk6c0; +#if VERSION >= VERSION_NTSC_1_0 /*0x6c4*/ u32 unk6c4; /*0x6c8*/ u32 unk6c8; /*0x6cc*/ u32 unk6cc; /*0x6d0*/ u32 unk6d0; /*0x6d4*/ u32 unk6d4; +#endif /*0x6d8*/ s32 unk6d8; /*0x6dc*/ u32 unk6dc; /*0x6e0*/ u32 unk6e0; diff --git a/src/lib/base.c b/src/lib/base.c index 08e465117..3a1d9b93c 100644 --- a/src/lib/base.c +++ b/src/lib/base.c @@ -7,6 +7,8 @@ #if VERSION < VERSION_NTSC_1_0 // This data doesn't belong here, but I don't know what the data is or where // exactly it should go yet. +u8 var8009c9e0nb[0x17e0]; + u32 var800606e0nb[] = { 0xb8000000, 0x00000000, 0x00000000, 0x00227a00, 0x007a348b, 0x00223434, 0x00115811, 0x00696900, diff --git a/src/lib/boot.c b/src/lib/boot.c index cb2eeec4e..9bcb0171a 100644 --- a/src/lib/boot.c +++ b/src/lib/boot.c @@ -548,9 +548,9 @@ glabel bootAllocateStack #endif #if VERSION < VERSION_NTSC_1_0 -s32 bootGetMemSize(void) +u8 *bootGetStackPos(void) { - return g_OsMemSize; + return g_StackAllocatedPos; } #endif diff --git a/src/lib/crash.c b/src/lib/crash.c index 41629c137..20641c922 100644 --- a/src/lib/crash.c +++ b/src/lib/crash.c @@ -10,15 +10,21 @@ #define MSG_FAULT 0x10 +#if VERSION >= VERSION_NTSC_1_0 +#define MAX_LINES 29 +#else +#define MAX_LINES 31 +#endif + +#if VERSION < VERSION_NTSC_1_0 +u32 padding[18]; +#endif + OSThread g_FaultThread; u8 g_FaultStack[STACKSIZE_FAULT]; OSMesgQueue g_FaultMesgQueue; OSMesg g_FaultMesg; -#if VERSION < VERSION_NTSC_1_0 -u32 padding[2]; -#endif - u32 var8005d5b0 = 0; s16 g_CrashCurX = 0; s16 g_CrashCurY = 0; @@ -121,10 +127,11 @@ struct crashdescription g_CrashFpcsrDescriptions[] = { }; char (*g_CrashCharBuffer)[71] = NULL; -u16 *g_CrashFrameBuffer = NULL; #if VERSION < VERSION_NTSC_1_0 -u32 somethingnb[] = { +u32 var8005f138nb = 0; + +u32 var8005f13cnb[] = { 0x22220200, 0x55000000, 0x05f5f500, 0x27427200, 0x05124500, 0x34255300, 0x22000000, 0x24444420, 0x42222240, 0x06f6f600, 0x00272000, 0x00000240, @@ -152,6 +159,8 @@ u32 somethingnb[] = { }; #endif +u16 *g_CrashFrameBuffer = NULL; + extern u32 _libSegmentStart; extern u32 _libSegmentEnd; @@ -229,7 +238,7 @@ glabel faultproc /* c298: afa00064 */ sw $zero,0x64($sp) /* c29c: 2404000c */ addiu $a0,$zero,0xc /* c2a0: 02802825 */ or $a1,$s4,$zero -/* c2a4: 0c01263c */ jal 0x498f0 +/* c2a4: 0c01263c */ jal osSetEventMesg /* c2a8: 24060010 */ addiu $a2,$zero,0x10 /* c2ac: 3c018009 */ lui $at,0x8009 /* c2b0: ac207108 */ sw $zero,0x7108($at) @@ -240,23 +249,23 @@ glabel faultproc /* c2c0: 02802025 */ or $a0,$s4,$zero .NB0000c2c4: /* c2c4: 02202825 */ or $a1,$s1,$zero -/* c2c8: 0c0126b0 */ jal 0x49ac0 +/* c2c8: 0c0126b0 */ jal osRecvMesg /* c2cc: 24060001 */ addiu $a2,$zero,0x1 -/* c2d0: 0c012688 */ jal 0x49a20 +/* c2d0: 0c012688 */ jal osSetIntMask /* c2d4: 24040001 */ addiu $a0,$zero,0x1 -/* c2d8: 0c013eb8 */ jal 0x4fae0 +/* c2d8: 0c013eb8 */ jal __osGetCurrFaultedThread /* c2dc: 00408025 */ or $s0,$v0,$zero /* c2e0: 3c018009 */ lui $at,0x8009 /* c2e4: 1040fff6 */ beqz $v0,.NB0000c2c0 /* c2e8: ac227104 */ sw $v0,0x7104($at) -/* c2ec: 0c012688 */ jal 0x49a20 +/* c2ec: 0c012688 */ jal osSetIntMask /* c2f0: 02002025 */ or $a0,$s0,$zero /* c2f4: 3c048009 */ lui $a0,0x8009 /* c2f8: 8c847104 */ lw $a0,0x7104($a0) /* c2fc: 02402825 */ or $a1,$s2,$zero -/* c300: 0c003297 */ jal 0xca5c +/* c300: 0c003297 */ jal crashGenerate /* c304: 02603025 */ or $a2,$s3,$zero -/* c308: 0c00073b */ jal 0x1cec +/* c308: 0c00073b */ jal schedSetCrashedUnexpectedly /* c30c: 24040001 */ addiu $a0,$zero,0x1 /* c310: 1000ffec */ beqz $zero,.NB0000c2c4 /* c314: 02802025 */ or $a0,$s4,$zero @@ -1352,15 +1361,9 @@ void crashPutChar(s32 x, s32 y, char c) c = '?'; } -#if VERSION >= VERSION_NTSC_1_0 - if (x >= 0 && x < 72 && y >= 0 && y < 30 && g_CrashCharBuffer != NULL) { + if (x >= 0 && x < 72 && y >= 0 && y <= MAX_LINES && g_CrashCharBuffer != NULL) { g_CrashCharBuffer[y][x] = c; } -#else - if (x >= 0 && x < 72 && y >= 0 && y < 32 && g_CrashCharBuffer != NULL) { - g_CrashCharBuffer[y][x] = c; - } -#endif } void crashAppendChar(char c) @@ -1382,17 +1385,10 @@ void crashAppendChar(char c) g_CrashCurX = 0; } -#if VERSION >= VERSION_NTSC_1_0 - if (g_CrashCurY > 28) { - crashScroll(g_CrashCurY - 28); - g_CrashCurY = 28; + if (g_CrashCurY >= MAX_LINES) { + crashScroll(g_CrashCurY - MAX_LINES + 1); + g_CrashCurY = MAX_LINES - 1; } -#else - if (g_CrashCurY > 30) { - crashScroll(g_CrashCurY - 30); - g_CrashCurY = 30; - } -#endif if (c != '\n') { crashPutChar(g_CrashCurX, g_CrashCurY, c); @@ -1416,7 +1412,7 @@ void crashScroll(s32 numlines) } while (numlines-- > 0) { - for (y = 0; y < 29; y++) { + for (y = 0; y < MAX_LINES; y++) { for (x = 0; x < 71; x++) { g_CrashCharBuffer[y][x] = g_CrashCharBuffer[y + 1][x]; } @@ -1657,7 +1653,7 @@ void crashRenderFrame(u8 *fb) height = (viGetHeight() - 10) / 7 - 1; if (g_CrashCharBuffer != NULL) { - for (y = 0; y < height && y < 29; y++) { + for (y = 0; y < height && y < MAX_LINES; y++) { for (x = 0; x < width - 5 && x < 71; x++) { crashRenderChar(20 + x * 4, 7 + y * 7, g_CrashCharBuffer[y][x]); } diff --git a/src/lib/dma.c b/src/lib/dma.c index 539a38fb1..4a95a7e29 100644 --- a/src/lib/dma.c +++ b/src/lib/dma.c @@ -5,6 +5,10 @@ #include "data.h" #include "types.h" +#if VERSION < VERSION_NTSC_1_0 +u8 var80097110nb[0x950]; +#endif + volatile u32 g_DmaNumSlotsBusy; u32 var80094ae4; OSIoMesg g_DmaIoMsgs[32]; diff --git a/src/lib/gvars.c b/src/lib/gvars.c index 4e358088b..eac51af4f 100644 --- a/src/lib/gvars.c +++ b/src/lib/gvars.c @@ -4,6 +4,10 @@ #include "data.h" #include "types.h" +#if VERSION < VERSION_NTSC_1_0 +u32 var8009e6b0[4]; +#endif + struct g_vars g_Vars; void gvarsInit(void) diff --git a/src/lib/joy.c b/src/lib/joy.c index 2a8c836ad..b3c96d383 100644 --- a/src/lib/joy.c +++ b/src/lib/joy.c @@ -34,32 +34,21 @@ struct joydata g_JoyData[2]; s32 g_JoyDisableCooldown[4]; OSMesgQueue g_PiMesgQueue; -OSMesg var80099e90; -u32 var80099e94; -u32 var80099e98; -u32 var80099e9c; -u32 var80099ea0; -u32 var80099ea4; -u32 var80099ea8; -u32 var80099eac; -u32 var80099eb0; -u32 var80099eb4; -OSMesg var80099eb8; -u32 var80099ebc; +OSMesg var80099e90[10]; +OSMesg var80099eb8[2]; OSMesgQueue g_JoyStopCyclicPollingMesgQueue; -OSMesg var80099ed8; -u32 var80099edc; +OSMesg var80099ed8[2]; OSMesgQueue g_JoyStopCyclicPollingDoneMesgQueue; -OSMesg var80099ef8; -u32 var80099efc; +OSMesg var80099ef8[2]; OSMesgQueue g_JoyStartCyclicPollingMesgQueue; -OSMesg var80099f18; -u32 var80099f1c; +OSMesg var80099f18[2]; OSMesgQueue g_JoyStartCyclicPollingDoneMesgQueue; OSContStatus var80099f38[4]; +#if VERSION >= VERSION_NTSC_1_0 u8 g_JoyPfsStates[100]; u32 var80099fac; u32 var80099fb0; +#endif const char var70054080[] = "joyReset\n"; const char var7005408c[] = "joyReset: doing nothing\n"; @@ -100,8 +89,8 @@ u32 var8005eee8 = 0; u32 var8005eeec = 0; u32 var8005eef0 = 1; #else -u32 var8005eee8nb = 3; -u8 var8005eeecnb = 0; +u32 var800612c8nb = 3; +u8 var800612ccnb = 0; #endif #if VERSION >= VERSION_NTSC_1_0 @@ -164,7 +153,7 @@ u32 joy00013980(void) #if VERSION >= VERSION_NTSC_1_0 return var8005eeec; #else - return var8005eeecnb; + return var8005eed8; #endif } #endif @@ -309,11 +298,11 @@ void joySystemInit(void) s32 i; s32 j; - osCreateMesgQueue(&g_JoyStopCyclicPollingMesgQueue, &var80099eb8, 1); - osCreateMesgQueue(&g_JoyStopCyclicPollingDoneMesgQueue, &var80099ed8, 1); - osCreateMesgQueue(&g_JoyStartCyclicPollingMesgQueue, &var80099ef8, 1); - osCreateMesgQueue(&g_JoyStartCyclicPollingDoneMesgQueue, &var80099f18, 1); - osCreateMesgQueue(&g_PiMesgQueue, &var80099e90, 10); + osCreateMesgQueue(&g_JoyStopCyclicPollingMesgQueue, var80099eb8, 1); + osCreateMesgQueue(&g_JoyStopCyclicPollingDoneMesgQueue, var80099ed8, 1); + osCreateMesgQueue(&g_JoyStartCyclicPollingMesgQueue, var80099ef8, 1); + osCreateMesgQueue(&g_JoyStartCyclicPollingDoneMesgQueue, var80099f18, 1); + osCreateMesgQueue(&g_PiMesgQueue, var80099e90, ARRAYCOUNT(var80099e90)); osSetEventMesg(OS_EVENT_SI, &g_PiMesgQueue, NULL); @@ -551,6 +540,10 @@ glabel func0001509cnb ); #endif +#if VERSION < VERSION_NTSC_1_0 +u32 var800612d4nb = 0; +#endif + /** * The use of the static variable suggests that the function is able to be * called recursively, but its behaviour should not be run when recursing. @@ -584,7 +577,7 @@ void joyDebugJoy(void) #if VERSION >= VERSION_NTSC_1_0 mainOverrideVariable("debugjoy", &var8005ef08); #else - mainOverrideVariable("joyforce", &var8005ef08); + mainOverrideVariable("joyforce", &var800612c8nb); #endif #if VERSION >= VERSION_NTSC_1_0 @@ -1328,7 +1321,7 @@ void joyReset(void) { s32 i; - osCreateMesgQueue(&g_PiMesgQueue, &var80099e90, 10); + osCreateMesgQueue(&g_PiMesgQueue, var80099e90, ARRAYCOUNT(var80099e90)); osSetEventMesg(OS_EVENT_SI, &g_PiMesgQueue, 0); for (i = 0; i < 4; i++) { diff --git a/src/lib/reset.c b/src/lib/reset.c index ed88abfe3..f5f5ec2ed 100644 --- a/src/lib/reset.c +++ b/src/lib/reset.c @@ -21,7 +21,11 @@ void resetproc(void *data) { OSMesg msg = 0; OSViMode *mode; +#if VERSION >= VERSION_NTSC_1_0 u32 stack[4]; +#else + u32 stack[2]; +#endif static u64 prenmitime; diff --git a/src/lib/snd.c b/src/lib/snd.c index 0f155df15..e6c56668a 100644 --- a/src/lib/snd.c +++ b/src/lib/snd.c @@ -2266,8 +2266,10 @@ void sndInit(void) #if VERSION >= VERSION_PAL_FINAL u32 heaplen = 1024 * 446; -#else +#elif VERSION >= VERSION_NTSC_1_0 u32 heaplen = 1024 * 441; +#else + u32 heaplen = 1024 * 438; #endif g_Vars.langfilteron = false; @@ -2318,7 +2320,7 @@ void sndInit(void) // Allocate some space at the start of the heap for a string identifier. // This might be used to determine if the heap has overflowed. - g_SndGuardStringPtr = alHeapDBAlloc(0, 0, &g_SndHeap, 1, 32); + g_SndGuardStringPtr = alHeapAlloc(&g_SndHeap, 1, 32); strcpy(g_SndGuardStringPtr, g_SndGuardString); // Load sfx.ctl @@ -2326,7 +2328,7 @@ void sndInit(void) // Load seq.ctl var80095200 = 0xffffffff; - bankfile = alHeapDBAlloc(0, 0, &g_SndHeap, 1, len); + bankfile = alHeapAlloc(&g_SndHeap, 1, len); dmaExec(bankfile, (u32) &_seqctlSegmentRomStart, len); // Load seq.tbl diff --git a/src/lib/ultra/io/pfsisplug.c b/src/lib/ultra/io/pfsisplug.c index 897c36a46..995b66e4b 100644 --- a/src/lib/ultra/io/pfsisplug.c +++ b/src/lib/ultra/io/pfsisplug.c @@ -1,3 +1,4 @@ +#include "versions.h" #include #include "controller.h" #include "siint.h" @@ -18,7 +19,7 @@ s32 osPfsIsPlug(OSMesgQueue *queue, u8 *pattern) int crc_error_cnt; ret = 0; bits = 0; - crc_error_cnt = 1; + crc_error_cnt = VERSION >= VERSION_NTSC_1_0 ? 1 : 3; __osSiGetAccess(); diff --git a/src/lib/ultra/os/initialize.c b/src/lib/ultra/os/initialize.c index 2ba25ada6..054a2c096 100644 --- a/src/lib/ultra/os/initialize.c +++ b/src/lib/ultra/os/initialize.c @@ -1,3 +1,4 @@ +#include "versions.h" #include #include #include @@ -60,7 +61,9 @@ void osInitialize(void) bzero(&osAppNMIBuffer, 0x40); } -#if !PAL +#if VERSION >= VERSION_PAL_FINAL + // empty +#elif VERSION >= VERSION_NTSC_1_0 if (osTvType == OS_TV_PAL) { osViClock = VI_PAL_CLOCK; } else if (osTvType == OS_TV_MPAL) { @@ -68,6 +71,14 @@ void osInitialize(void) } else { osViClock = VI_NTSC_CLOCK; } +#else + if (osTvType == OS_TV_PAL) { + osViClock = VI_PAL_CLOCK; + } else if (osTvType == OS_TV_MPAL) { + osViClock = VI_MPAL_CLOCK; + } else { + osViClock = VI_NTSC_CLOCK; + } #endif if (__osGetCause() & CAUSE_IP5) { diff --git a/src/lib/vi.c b/src/lib/vi.c index 47346b504..7088e3ba3 100644 --- a/src/lib/vi.c +++ b/src/lib/vi.c @@ -206,7 +206,11 @@ void viAllocateFbs(s32 stagenum) fbsize = IS4MB() ? 320 * 220 * 2 : 320 * 220 * 4; if (IS4MB() && PLAYERCOUNT() == 2) { +#if VERSION >= VERSION_NTSC_1_0 fbsize = 320 * 220; +#else + fbsize = 320 * 240; +#endif g_Vars.fourmeg2player = true; } else if ((g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) && PLAYERCOUNT() == 2) { #if PAL diff --git a/src/romheader/romheader.s b/src/romheader/romheader.s index 589084523..941b40538 100644 --- a/src/romheader/romheader.s +++ b/src/romheader/romheader.s @@ -13,10 +13,21 @@ .word 0x00001449 # Release address .word 0x00000000 # CRC 1 .word 0x00000000 # CRC 2 -.word 0x00000000 -.word 0x00000000 +.if VERSION == VERSION_NTSC_BETA +.word 0x54e4d838 +.word 0x2fbd9536 +.else +.word 0x00000000 +.word 0x00000000 +.endif + +.if VERSION == VERSION_NTSC_BETA +.ascii "Perfect Dark DBGNTSC" +.else .ascii "Perfect Dark " +.endif + .word 0x00000000 .byte 0x00 .byte 0x00 diff --git a/tools/extract b/tools/extract index 8ff872148..97c6d6a08 100755 --- a/tools/extract +++ b/tools/extract @@ -458,7 +458,7 @@ class Extractor: 'files': [0x29160, 0x28080, 0x28080, 0x29b90, 0x28910, 0x28800, ], 'data': [0x30850, 0x39850, 0x39850, 0x39850, 0x39850, 0x39850, ], 'game': [0x43c40, 0x4fc40, 0x4fc40, 0x4fc40, 0x4fc40, 0x4fc40, ], - 'garbage': [0x155cc0, 0x194b20, 0x194b20, 0x0, 0x180330, 0x0, ], + 'garbage': [0x148c40, 0x194b20, 0x194b20, 0x0, 0x180330, 0x0, ], 'animations': [0x155dc0, 0x1a15c0, 0x1a15c0, 0x18cdc0, 0x18cdc0, 0x190c50, ], 'mpconfigs': [0x785130, 0x7d0a40, 0x7d0a40, 0x7bc240, 0x7bc240, 0x7c00d0, ], 'firingrange': [0x79e410, 0x7e9d20, 0x7e9d20, 0x7d5520, 0x7d5520, 0x7d93b0, ], diff --git a/tools/mkrom/mkrom.h b/tools/mkrom/mkrom.h index 99c7913dc..d070b455f 100644 --- a/tools/mkrom/mkrom.h +++ b/tools/mkrom/mkrom.h @@ -54,6 +54,12 @@ struct state { * Size of the above gametable allocation in bytes. */ size_t gametablelen; + + /** + * NTSC beta doesn't duplicate zip data unneccessarily so it must be + * identified and handled differently. + */ + bool is_ntscbeta; }; void game_zip(void); diff --git a/tools/mkrom/pack.c b/tools/mkrom/pack.c index 4d04891a1..7767b5810 100644 --- a/tools/mkrom/pack.c +++ b/tools/mkrom/pack.c @@ -72,19 +72,21 @@ void pack_game(void) memcpy(&state.rom[gamezipstart], state.gametable, state.gametablelen); - // Paste the second segment, truncating it to fit the allocation - truncatedlen = gamezipend - gamezipstart - state.gamezipslen; + if (!state.is_ntscbeta) { + // Paste the second segment, truncating it to fit the allocation + truncatedlen = gamezipend - gamezipstart - state.gamezipslen; - if (truncatedlen > state.gamezipslen) { - truncatedlen = state.gamezipslen; + if (truncatedlen > state.gamezipslen) { + truncatedlen = state.gamezipslen; + } + + memcpy(&state.rom[gamezipstart + state.gamezipslen], state.gamezips, truncatedlen); + + // The final two bytes from the real segment are duplicated into + // the first two bytes of the second segment's offset table + state.rom[gamezipstart + state.gamezipslen + 0] = state.rom[gamezipstart + state.gamezipslen - 2]; + state.rom[gamezipstart + state.gamezipslen + 1] = state.rom[gamezipstart + state.gamezipslen - 1]; } - - memcpy(&state.rom[gamezipstart + state.gamezipslen], state.gamezips, truncatedlen); - - // The final two bytes from the real segment are duplicated into - // the first two bytes of the second segment's offset table - state.rom[gamezipstart + state.gamezipslen + 0] = state.rom[gamezipstart + state.gamezipslen - 2]; - state.rom[gamezipstart + state.gamezipslen + 1] = state.rom[gamezipstart + state.gamezipslen - 1]; } /** @@ -117,17 +119,19 @@ void pack_lib(void) // Copy the buffer to its real spot in the ROM copy("lib", buffer, seglen, "ROMALLOCATION_LIB"); - // Copy it truncated to its fake spot - map_get_segment_rompos("libzip", &libzipstart, &libzipend); + if (!state.is_ntscbeta) { + // Copy it truncated to its fake spot + map_get_segment_rompos("libzip", &libzipstart, &libzipend); - truncatedlen = libzipend - libzipstart - seglen; + truncatedlen = libzipend - libzipstart - seglen; - if (truncatedlen > seglen) { - truncatedlen = seglen; + if (truncatedlen > seglen) { + truncatedlen = seglen; + } + + memcpy(state.rom + libzipstart + seglen, buffer, truncatedlen); } - memcpy(state.rom + libzipstart + seglen, buffer, truncatedlen); - free(buffer); } diff --git a/tools/mkrom/rom.c b/tools/mkrom/rom.c index d548f23ec..9ab525167 100644 --- a/tools/mkrom/rom.c +++ b/tools/mkrom/rom.c @@ -1,5 +1,6 @@ #include #include +#include #include "mkrom.h" extern struct state state; @@ -29,6 +30,8 @@ void rom_load(char *filename) fseek(fp, 0, SEEK_SET); fread(state.rom, state.romlen, 1, fp); fclose(fp); + + state.is_ntscbeta = strncmp(&state.rom[0x20], "Perfect Dark DBGNTSC", 20) == 0; } /**