diff --git a/src/game/cheats.c b/src/game/cheats.c index 93bfdc178..08752eaae 100644 --- a/src/game/cheats.c +++ b/src/game/cheats.c @@ -486,10 +486,10 @@ char *cheatGetMarquee(struct menu_item *arg0) u8 difficultyname[256]; u8 cheatname[256]; - if (g_MenuStack[g_MenuStackDepth].unk00 && g_MenuStack[g_MenuStackDepth].unk00->item && g_MenuStack[g_MenuStackDepth].unk00->item->type == MENUITEMTYPE_CHECKBOX) { - cheat_id = g_MenuStack[g_MenuStackDepth].unk00->item->param; + if (g_MenuStack[g_MpPlayerNum].unk00 && g_MenuStack[g_MpPlayerNum].unk00->item && g_MenuStack[g_MpPlayerNum].unk00->item->type == MENUITEMTYPE_CHECKBOX) { + cheat_id = g_MenuStack[g_MpPlayerNum].unk00->item->param; - if (g_MenuStack[g_MenuStackDepth].unk00->dialog == &menudialog_cheats_buddies && g_MenuStack[g_MenuStackDepth].unk00->item == &menuitems_cheats_buddies[0]) { + if (g_MenuStack[g_MpPlayerNum].unk00->dialog == &menudialog_cheats_buddies && g_MenuStack[g_MpPlayerNum].unk00->item == &menuitems_cheats_buddies[0]) { // Velvet sprintf(g_CheatMarqueeString, "%s: %s", textGet(0x548f), textGet(0x5475)); // "Buddy Available", "Velvet Dark" return g_CheatMarqueeString; @@ -498,7 +498,7 @@ char *cheatGetMarquee(struct menu_item *arg0) if (cheatIsUnlocked(cheat_id)) { // Show cheat name sprintf(g_CheatMarqueeString, "%s: %s\n", - g_MenuStack[g_MenuStackDepth].unk00->dialog == &menudialog_cheats_buddies ? textGet(0x548f) : textGet(0x5488), // "Buddy Available", "Cheat available" + g_MenuStack[g_MpPlayerNum].unk00->dialog == &menudialog_cheats_buddies ? textGet(0x548f) : textGet(0x5488), // "Buddy Available", "Cheat available" textGet(g_Cheats[cheat_id].nametextid) ); return g_CheatMarqueeString; diff --git a/src/game/game_015470.c b/src/game/game_015470.c index d899f025f..7fbd4661e 100644 --- a/src/game/game_015470.c +++ b/src/game/game_015470.c @@ -8105,12 +8105,12 @@ glabel func0f01bf28 /* f01c598: 0fc66d50 */ jal func0f19b540 /* f01c59c: 00000000 */ sll $zero,$zero,0x0 .L0f01c5a0: -/* f01c5a0: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) +/* f01c5a0: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) /* f01c5a4: 3c05800a */ lui $a1,%hi(var8009e000) /* f01c5a8: 3c038008 */ lui $v1,%hi(g_MpReadyMenuDialog) /* f01c5ac: 246357b8 */ addiu $v1,$v1,%lo(g_MpReadyMenuDialog) /* f01c5b0: 24a5e000 */ addiu $a1,$a1,%lo(var8009e000) -/* f01c5b4: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f01c5b4: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) /* f01c5b8: 00008825 */ or $s1,$zero,$zero /* f01c5bc: 24040e70 */ addiu $a0,$zero,0xe70 .L0f01c5c0: @@ -8147,8 +8147,8 @@ glabel func0f01bf28 /* f01c630: 000d6900 */ sll $t5,$t5,0x4 /* f01c634: 01af1821 */ addu $v1,$t5,$t7 /* f01c638: 8c6e04f8 */ lw $t6,0x4f8($v1) -/* f01c63c: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) -/* f01c640: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f01c63c: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) +/* f01c640: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) /* f01c644: 11c00025 */ beqz $t6,.L0f01c6dc /* f01c648: acd10000 */ sw $s1,0x0($a2) /* f01c64c: 8e78006c */ lw $t8,0x6c($s3) @@ -8727,8 +8727,8 @@ glabel func0f01bf28 .L0f01ce44: /* f01ce44: 00116880 */ sll $t5,$s1,0x2 /* f01ce48: 01b16821 */ addu $t5,$t5,$s1 -/* f01ce4c: 3c19800b */ lui $t9,%hi(g_Options) -/* f01ce50: 2739c7b8 */ addiu $t9,$t9,%lo(g_Options) +/* f01ce4c: 3c19800b */ lui $t9,%hi(g_MpChrs) +/* f01ce50: 2739c7b8 */ addiu $t9,$t9,%lo(g_MpChrs) /* f01ce54: 000d6940 */ sll $t5,$t5,0x5 /* f01ce58: 01b91021 */ addu $v0,$t5,$t9 /* f01ce5c: afa20058 */ sw $v0,0x58($sp) @@ -8908,8 +8908,8 @@ glabel func0f01bf28 .L0f01d0c8: /* f01d0c8: 3c05800b */ lui $a1,%hi(var800acad8) /* f01d0cc: 3c06800b */ lui $a2,0x800b -/* f01d0d0: 3c07800b */ lui $a3,%hi(g_Options) -/* f01d0d4: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f01d0d0: 3c07800b */ lui $a3,%hi(g_MpChrs) +/* f01d0d4: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f01d0d8: 24c6c858 */ addiu $a2,$a2,-14248 /* f01d0dc: 24a5cad8 */ addiu $a1,$a1,%lo(var800acad8) /* f01d0e0: 00807825 */ or $t7,$a0,$zero diff --git a/src/game/game_097a50.c b/src/game/game_097a50.c index 0e48438fe..e7e9899d1 100644 --- a/src/game/game_097a50.c +++ b/src/game/game_097a50.c @@ -20028,8 +20028,8 @@ glabel func0f0a895c /* f0a8ae4: 24e2ffff */ addiu $v0,$a3,-1 /* f0a8ae8: 0002c8c3 */ sra $t9,$v0,0x3 /* f0a8aec: 8dcf0070 */ lw $t7,0x70($t6) -/* f0a8af0: 3c0a800b */ lui $t2,%hi(g_Options) -/* f0a8af4: 254ac7b8 */ addiu $t2,$t2,%lo(g_Options) +/* f0a8af0: 3c0a800b */ lui $t2,%hi(g_MpChrs) +/* f0a8af4: 254ac7b8 */ addiu $t2,$t2,%lo(g_MpChrs) /* f0a8af8: 000fc080 */ sll $t8,$t7,0x2 /* f0a8afc: 030fc021 */ addu $t8,$t8,$t7 /* f0a8b00: 0018c140 */ sll $t8,$t8,0x5 @@ -20080,9 +20080,9 @@ glabel func0f0a895c /* f0a8ba0: 24e2ffff */ addiu $v0,$a3,-1 /* f0a8ba4: 8d0d0288 */ lw $t5,0x288($t0) /* f0a8ba8: 0002c0c3 */ sra $t8,$v0,0x3 -/* f0a8bac: 3c0b800b */ lui $t3,%hi(g_Options) +/* f0a8bac: 3c0b800b */ lui $t3,%hi(g_MpChrs) /* f0a8bb0: 8dae0070 */ lw $t6,0x70($t5) -/* f0a8bb4: 256bc7b8 */ addiu $t3,$t3,%lo(g_Options) +/* f0a8bb4: 256bc7b8 */ addiu $t3,$t3,%lo(g_MpChrs) /* f0a8bb8: 304a0007 */ andi $t2,$v0,0x7 /* f0a8bbc: 000e7880 */ sll $t7,$t6,0x2 /* f0a8bc0: 01ee7821 */ addu $t7,$t7,$t6 @@ -20101,8 +20101,8 @@ glabel func0f0a895c /* f0a8bec: 24e2ffff */ addiu $v0,$a3,-1 /* f0a8bf0: 0002c0c3 */ sra $t8,$v0,0x3 /* f0a8bf4: 8dae0070 */ lw $t6,0x70($t5) -/* f0a8bf8: 3c0b800b */ lui $t3,%hi(g_Options) -/* f0a8bfc: 256bc7b8 */ addiu $t3,$t3,%lo(g_Options) +/* f0a8bf8: 3c0b800b */ lui $t3,%hi(g_MpChrs) +/* f0a8bfc: 256bc7b8 */ addiu $t3,$t3,%lo(g_MpChrs) /* f0a8c00: 000e7880 */ sll $t7,$t6,0x2 /* f0a8c04: 01ee7821 */ addu $t7,$t7,$t6 /* f0a8c08: 000f7940 */ sll $t7,$t7,0x5 diff --git a/src/game/game_0b0420.c b/src/game/game_0b0420.c index 2852b34fa..dedfe64f0 100644 --- a/src/game/game_0b0420.c +++ b/src/game/game_0b0420.c @@ -414,8 +414,8 @@ glabel func0f0b0818 /* f0b0864: 00035080 */ sll $t2,$v1,0x2 /* f0b0868: 0003c080 */ sll $t8,$v1,0x2 /* f0b086c: 0303c021 */ addu $t8,$t8,$v1 -/* f0b0870: 3c19800b */ lui $t9,%hi(g_Options) -/* f0b0874: 2739c7b8 */ addiu $t9,$t9,%lo(g_Options) +/* f0b0870: 3c19800b */ lui $t9,%hi(g_MpChrs) +/* f0b0874: 2739c7b8 */ addiu $t9,$t9,%lo(g_MpChrs) /* f0b0878: 0018c140 */ sll $t8,$t8,0x5 /* f0b087c: 10000007 */ beqz $zero,.L0f0b089c /* f0b0880: 03194021 */ addu $t0,$t8,$t9 @@ -556,8 +556,8 @@ glabel func0f0b09f4 /* f0b0a68: 00026080 */ sll $t4,$v0,0x2 /* f0b0a6c: 00024880 */ sll $t1,$v0,0x2 /* f0b0a70: 01224821 */ addu $t1,$t1,$v0 -/* f0b0a74: 3c0a800b */ lui $t2,%hi(g_Options) -/* f0b0a78: 254ac7b8 */ addiu $t2,$t2,%lo(g_Options) +/* f0b0a74: 3c0a800b */ lui $t2,%hi(g_MpChrs) +/* f0b0a78: 254ac7b8 */ addiu $t2,$t2,%lo(g_MpChrs) /* f0b0a7c: 00094940 */ sll $t1,$t1,0x5 /* f0b0a80: 012a5821 */ addu $t3,$t1,$t2 /* f0b0a84: 1000000a */ beqz $zero,.L0f0b0ab0 @@ -586,8 +586,8 @@ glabel func0f0b09f4 /* f0b0ad8: 00025080 */ sll $t2,$v0,0x2 /* f0b0adc: 0002c880 */ sll $t9,$v0,0x2 /* f0b0ae0: 0322c821 */ addu $t9,$t9,$v0 -/* f0b0ae4: 3c09800b */ lui $t1,%hi(g_Options) -/* f0b0ae8: 2529c7b8 */ addiu $t1,$t1,%lo(g_Options) +/* f0b0ae4: 3c09800b */ lui $t1,%hi(g_MpChrs) +/* f0b0ae8: 2529c7b8 */ addiu $t1,$t1,%lo(g_MpChrs) /* f0b0aec: 0019c940 */ sll $t9,$t9,0x5 /* f0b0af0: 10000009 */ beqz $zero,.L0f0b0b18 /* f0b0af4: 03291821 */ addu $v1,$t9,$t1 diff --git a/src/game/game_0b28d0.c b/src/game/game_0b28d0.c index cf59d673b..f71714a8c 100644 --- a/src/game/game_0b28d0.c +++ b/src/game/game_0b28d0.c @@ -7784,13 +7784,13 @@ glabel func0f0b8ba0 /* f0b9234: 8da60004 */ lw $a2,0x4($t5) /* f0b9238: 8e02028c */ lw $v0,0x28c($s0) /* f0b923c: 3c01800b */ lui $at,0x800b -/* f0b9240: 3c0f800b */ lui $t7,%hi(g_Options) +/* f0b9240: 3c0f800b */ lui $t7,%hi(g_MpChrs) /* f0b9244: 00027080 */ sll $t6,$v0,0x2 /* f0b9248: 002e0821 */ addu $at,$at,$t6 /* f0b924c: ac26c4d0 */ sw $a2,-0x3b30($at) /* f0b9250: 8e080288 */ lw $t0,0x288($s0) /* f0b9254: 3c01800b */ lui $at,0x800b -/* f0b9258: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f0b9258: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f0b925c: 8d180070 */ lw $t8,0x70($t0) /* f0b9260: 002e0821 */ addu $at,$at,$t6 /* f0b9264: 0018c880 */ sll $t9,$t8,0x2 @@ -16782,8 +16782,8 @@ glabel func0f0c1404 /* f0c1434: 904f1922 */ lbu $t7,0x1922($v0) /* f0c1438: 15e0006f */ bnez $t7,.L0f0c15f8 .L0f0c143c: -/* f0c143c: 3c028007 */ lui $v0,%hi(g_MenuStackDepth) -/* f0c1440: 24421448 */ addiu $v0,$v0,%lo(g_MenuStackDepth) +/* f0c143c: 3c028007 */ lui $v0,%hi(g_MpPlayerNum) +/* f0c1440: 24421448 */ addiu $v0,$v0,%lo(g_MpPlayerNum) /* f0c1444: 8c580000 */ lw $t8,0x0($v0) /* f0c1448: 8e190288 */ lw $t9,0x288($s0) /* f0c144c: afb80024 */ sw $t8,0x24($sp) diff --git a/src/game/game_0dcdb0.c b/src/game/game_0dcdb0.c index f7073e44e..d8d161d4c 100644 --- a/src/game/game_0dcdb0.c +++ b/src/game/game_0dcdb0.c @@ -23663,8 +23663,8 @@ glabel func0f0ee648 /* f0ee6ac: 10200008 */ beqz $at,.L0f0ee6d0 /* f0ee6b0: 0003c880 */ sll $t9,$v1,0x2 /* f0ee6b4: 0323c821 */ addu $t9,$t9,$v1 -/* f0ee6b8: 3c08800b */ lui $t0,%hi(g_Options) -/* f0ee6bc: 2508c7b8 */ addiu $t0,$t0,%lo(g_Options) +/* f0ee6b8: 3c08800b */ lui $t0,%hi(g_MpChrs) +/* f0ee6bc: 2508c7b8 */ addiu $t0,$t0,%lo(g_MpChrs) /* f0ee6c0: 0019c940 */ sll $t9,$t9,0x5 /* f0ee6c4: 03284821 */ addu $t1,$t9,$t0 /* f0ee6c8: 1000000b */ beqz $zero,.L0f0ee6f8 @@ -24264,8 +24264,8 @@ glabel func0f0ee648 /* f0eefa8: 8fad00b4 */ lw $t5,0xb4($sp) /* f0eefac: 00104080 */ sll $t0,$s0,0x2 /* f0eefb0: 01104021 */ addu $t0,$t0,$s0 -/* f0eefb4: 3c18800b */ lui $t8,%hi(g_Options) -/* f0eefb8: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f0eefb4: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f0eefb8: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f0eefbc: 00084140 */ sll $t0,$t0,0x5 /* f0eefc0: 1000000a */ beqz $zero,.L0f0eefec /* f0eefc4: 01183821 */ addu $a3,$t0,$t8 @@ -25363,8 +25363,8 @@ glabel func0f0eff78 /* f0eff90: afa500a4 */ sw $a1,0xa4($sp) /* f0eff94: 0fc54f49 */ jal func0f153d24 /* f0eff98: afa70068 */ sw $a3,0x68($sp) -/* f0eff9c: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) -/* f0effa0: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f0eff9c: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) +/* f0effa0: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) /* f0effa4: 8cce0000 */ lw $t6,0x0($a2) /* f0effa8: 24080e70 */ addiu $t0,$zero,0xe70 /* f0effac: 3c05800a */ lui $a1,%hi(var8009e000) diff --git a/src/game/game_0f09f0.c b/src/game/game_0f09f0.c index 838064a43..bc486456a 100644 --- a/src/game/game_0f09f0.c +++ b/src/game/game_0f09f0.c @@ -2357,12 +2357,12 @@ glabel func0f0f2354 /* f0f2358: afb1000c */ sw $s1,0xc($sp) /* f0f235c: afb00008 */ sw $s0,0x8($sp) /* f0f2360: 90820004 */ lbu $v0,0x4($a0) -/* f0f2364: 3c0c8007 */ lui $t4,%hi(g_MenuStackDepth) +/* f0f2364: 3c0c8007 */ lui $t4,%hi(g_MpPlayerNum) /* f0f2368: 00a08025 */ or $s0,$a1,$zero /* f0f236c: ace20000 */ sw $v0,0x0($a3) /* f0f2370: 908f0005 */ lbu $t7,0x5($a0) /* f0f2374: 90830004 */ lbu $v1,0x4($a0) -/* f0f2378: 258c1448 */ addiu $t4,$t4,%lo(g_MenuStackDepth) +/* f0f2378: 258c1448 */ addiu $t4,$t4,%lo(g_MpPlayerNum) /* f0f237c: 24110014 */ addiu $s1,$zero,0x14 /* f0f2380: 006fc021 */ addu $t8,$v1,$t7 /* f0f2384: 0058082a */ slt $at,$v0,$t8 @@ -2453,8 +2453,8 @@ glabel func0f0f2354 /* f0f24c8: 1420ffb3 */ bnez $at,.L0f0f2398 /* f0f24cc: 00000000 */ sll $zero,$zero,0x0 .L0f0f24d0: -/* f0f24d0: 3c0c8007 */ lui $t4,%hi(g_MenuStackDepth) -/* f0f24d4: 258c1448 */ addiu $t4,$t4,%lo(g_MenuStackDepth) +/* f0f24d0: 3c0c8007 */ lui $t4,%hi(g_MpPlayerNum) +/* f0f24d4: 258c1448 */ addiu $t4,$t4,%lo(g_MpPlayerNum) /* f0f24d8: 240d000a */ addiu $t5,$zero,0xa /* f0f24dc: ace30000 */ sw $v1,0x0($a3) /* f0f24e0: 006d0019 */ multu $v1,$t5 @@ -2840,10 +2840,10 @@ glabel func0f0f29cc /* f0f2a0c: 0fc3c8d5 */ jal func0f0f2354 /* f0f2a10: 27a70058 */ addiu $a3,$sp,0x58 /* f0f2a14: 8fa5005c */ lw $a1,0x5c($sp) -/* f0f2a18: 3c168007 */ lui $s6,%hi(g_MenuStackDepth) +/* f0f2a18: 3c168007 */ lui $s6,%hi(g_MpPlayerNum) /* f0f2a1c: 3c15800a */ lui $s5,%hi(var8009e000) /* f0f2a20: 26b5e000 */ addiu $s5,$s5,%lo(var8009e000) -/* f0f2a24: 26d61448 */ addiu $s6,$s6,%lo(g_MenuStackDepth) +/* f0f2a24: 26d61448 */ addiu $s6,$s6,%lo(g_MpPlayerNum) /* f0f2a28: 241e0014 */ addiu $s8,$zero,0x14 /* f0f2a2c: 2417000a */ addiu $s7,$zero,0xa /* f0f2a30: 00a0a025 */ or $s4,$a1,$zero @@ -3096,8 +3096,8 @@ glabel func0f0f2cf4 /* f0f2d94: a238003c */ sb $t8,0x3c($s1) /* f0f2d98: 44824000 */ mtc1 $v0,$f8 /* f0f2d9c: 3c03800a */ lui $v1,%hi(var8009e000) -/* f0f2da0: 3c058007 */ lui $a1,%hi(g_MenuStackDepth) -/* f0f2da4: 24a51448 */ addiu $a1,$a1,%lo(g_MenuStackDepth) +/* f0f2da0: 3c058007 */ lui $a1,%hi(g_MpPlayerNum) +/* f0f2da4: 24a51448 */ addiu $a1,$a1,%lo(g_MpPlayerNum) /* f0f2da8: 2463e000 */ addiu $v1,$v1,%lo(var8009e000) /* f0f2dac: 24060e70 */ addiu $a2,$zero,0xe70 /* f0f2db0: 04410005 */ bgez $v0,.L0f0f2dc8 @@ -3226,8 +3226,8 @@ glabel menuPushDialog /* f0f2f74: afb00018 */ sw $s0,0x18($sp) /* f0f2f78: 1080009d */ beqz $a0,.L0f0f31f0 /* f0f2f7c: afa40040 */ sw $a0,0x40($sp) -/* f0f2f80: 3c158007 */ lui $s5,%hi(g_MenuStackDepth) -/* f0f2f84: 26b51448 */ addiu $s5,$s5,%lo(g_MenuStackDepth) +/* f0f2f80: 3c158007 */ lui $s5,%hi(g_MpPlayerNum) +/* f0f2f84: 26b51448 */ addiu $s5,$s5,%lo(g_MpPlayerNum) /* f0f2f88: 8eaf0000 */ lw $t7,0x0($s5) /* f0f2f8c: 24160e70 */ addiu $s6,$zero,0xe70 /* f0f2f90: 3c14800a */ lui $s4,%hi(var8009e000) @@ -3415,8 +3415,8 @@ glabel func0f0f3220 /* f0f3234: afbf0014 */ sw $ra,0x14($sp) /* f0f3238: 1461003d */ bne $v1,$at,.L0f0f3330 /* f0f323c: 24080001 */ addiu $t0,$zero,0x1 -/* f0f3240: 3c078007 */ lui $a3,%hi(g_MenuStackDepth) -/* f0f3244: 24e71448 */ addiu $a3,$a3,%lo(g_MenuStackDepth) +/* f0f3240: 3c078007 */ lui $a3,%hi(g_MpPlayerNum) +/* f0f3244: 24e71448 */ addiu $a3,$a3,%lo(g_MpPlayerNum) /* f0f3248: 3c03800a */ lui $v1,%hi(var800a0b50) /* f0f324c: 8ce90000 */ lw $t1,0x0($a3) /* f0f3250: 24630b50 */ addiu $v1,$v1,%lo(var800a0b50) @@ -3474,8 +3474,8 @@ glabel func0f0f3220 /* f0f330c: afa80024 */ sw $t0,0x24($sp) /* f0f3310: 0fc42539 */ jal func0f1094e4 /* f0f3314: afa9001c */ sw $t1,0x1c($sp) -/* f0f3318: 3c078007 */ lui $a3,%hi(g_MenuStackDepth) -/* f0f331c: 24e71448 */ addiu $a3,$a3,%lo(g_MenuStackDepth) +/* f0f3318: 3c078007 */ lui $a3,%hi(g_MpPlayerNum) +/* f0f331c: 24e71448 */ addiu $a3,$a3,%lo(g_MpPlayerNum) /* f0f3320: 8fa80024 */ lw $t0,0x24($sp) /* f0f3324: 8fa9001c */ lw $t1,0x1c($sp) .L0f0f3328: @@ -3484,14 +3484,14 @@ glabel func0f0f3220 .L0f0f3330: /* f0f3330: 28610004 */ slti $at,$v1,0x4 /* f0f3334: 10200016 */ beqz $at,.L0f0f3390 -/* f0f3338: 3c078007 */ lui $a3,%hi(g_MenuStackDepth) +/* f0f3338: 3c078007 */ lui $a3,%hi(g_MpPlayerNum) /* f0f333c: 00037080 */ sll $t6,$v1,0x2 -/* f0f3340: 24e71448 */ addiu $a3,$a3,%lo(g_MenuStackDepth) +/* f0f3340: 24e71448 */ addiu $a3,$a3,%lo(g_MpPlayerNum) /* f0f3344: 01c37021 */ addu $t6,$t6,$v1 /* f0f3348: 8ced0000 */ lw $t5,0x0($a3) /* f0f334c: 000e7140 */ sll $t6,$t6,0x5 -/* f0f3350: 3c18800b */ lui $t8,%hi(g_Options) -/* f0f3354: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f0f3350: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f0f3354: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f0f3358: 25cf004c */ addiu $t7,$t6,0x4c /* f0f335c: ace30000 */ sw $v1,0x0($a3) /* f0f3360: 01f82021 */ addu $a0,$t7,$t8 @@ -3502,8 +3502,8 @@ glabel func0f0f3220 /* f0f3374: 0fc42539 */ jal func0f1094e4 /* f0f3378: afad0018 */ sw $t5,0x18($sp) /* f0f337c: 8fb90018 */ lw $t9,0x18($sp) -/* f0f3380: 3c078007 */ lui $a3,%hi(g_MenuStackDepth) -/* f0f3384: 24e71448 */ addiu $a3,$a3,%lo(g_MenuStackDepth) +/* f0f3380: 3c078007 */ lui $a3,%hi(g_MpPlayerNum) +/* f0f3384: 24e71448 */ addiu $a3,$a3,%lo(g_MpPlayerNum) /* f0f3388: 8fa80024 */ lw $t0,0x24($sp) /* f0f338c: acf90000 */ sw $t9,0x0($a3) .L0f0f3390: @@ -5475,11 +5475,11 @@ glabel func0f0f5004 /* f0f5004: 27bdffa0 */ addiu $sp,$sp,-96 /* f0f5008: 3c0e7f1b */ lui $t6,%hi(var7f1b25f8) /* f0f500c: 27a20000 */ addiu $v0,$sp,0x0 -/* f0f5010: 3c03800b */ lui $v1,%hi(g_Options) -/* f0f5014: 3c078007 */ lui $a3,%hi(g_MenuStackDepth) +/* f0f5010: 3c03800b */ lui $v1,%hi(g_MpChrs) +/* f0f5014: 3c078007 */ lui $a3,%hi(g_MpPlayerNum) /* f0f5018: 25ce25f8 */ addiu $t6,$t6,%lo(var7f1b25f8) -/* f0f501c: 24e71448 */ addiu $a3,$a3,%lo(g_MenuStackDepth) -/* f0f5020: 2463c7b8 */ addiu $v1,$v1,%lo(g_Options) +/* f0f501c: 24e71448 */ addiu $a3,$a3,%lo(g_MpPlayerNum) +/* f0f5020: 2463c7b8 */ addiu $v1,$v1,%lo(g_MpChrs) /* f0f5024: 240800a0 */ addiu $t0,$zero,0xa0 /* f0f5028: 2409000c */ addiu $t1,$zero,0xc /* f0f502c: 25d90060 */ addiu $t9,$t6,0x60 @@ -8866,8 +8866,8 @@ GLOBAL_ASM( glabel func0f0f8120 /* f0f8120: 27bdffd0 */ addiu $sp,$sp,-48 /* f0f8124: afb2001c */ sw $s2,0x1c($sp) -/* f0f8128: 3c128007 */ lui $s2,%hi(g_MenuStackDepth) -/* f0f812c: 26521448 */ addiu $s2,$s2,%lo(g_MenuStackDepth) +/* f0f8128: 3c128007 */ lui $s2,%hi(g_MpPlayerNum) +/* f0f812c: 26521448 */ addiu $s2,$s2,%lo(g_MpPlayerNum) /* f0f8130: 8e4e0000 */ lw $t6,0x0($s2) /* f0f8134: afb30020 */ sw $s3,0x20($sp) /* f0f8138: 24130e70 */ addiu $s3,$zero,0xe70 @@ -8933,8 +8933,8 @@ GLOBAL_ASM( glabel func0f0f820c /* f0f820c: 27bdffd0 */ addiu $sp,$sp,-48 /* f0f8210: afb30020 */ sw $s3,0x20($sp) -/* f0f8214: 3c138007 */ lui $s3,%hi(g_MenuStackDepth) -/* f0f8218: 26731448 */ addiu $s3,$s3,%lo(g_MenuStackDepth) +/* f0f8214: 3c138007 */ lui $s3,%hi(g_MpPlayerNum) +/* f0f8218: 26731448 */ addiu $s3,$s3,%lo(g_MpPlayerNum) /* f0f821c: 8e6e0000 */ lw $t6,0x0($s3) /* f0f8220: afb10018 */ sw $s1,0x18($sp) /* f0f8224: afb2001c */ sw $s2,0x1c($sp) @@ -9932,8 +9932,8 @@ GLOBAL_ASM( glabel func0f0f9030 /* f0f9030: 27bdff98 */ addiu $sp,$sp,-104 /* f0f9034: afb40024 */ sw $s4,0x24($sp) -/* f0f9038: 3c148007 */ lui $s4,%hi(g_MenuStackDepth) -/* f0f903c: 26941448 */ addiu $s4,$s4,%lo(g_MenuStackDepth) +/* f0f9038: 3c148007 */ lui $s4,%hi(g_MpPlayerNum) +/* f0f903c: 26941448 */ addiu $s4,$s4,%lo(g_MpPlayerNum) /* f0f9040: 8e8e0000 */ lw $t6,0x0($s4) /* f0f9044: afb50028 */ sw $s5,0x28($sp) /* f0f9048: 24150e70 */ addiu $s5,$zero,0xe70 @@ -11527,8 +11527,8 @@ GLOBAL_ASM( glabel func0f0fa704 /* f0fa704: 27bdfed0 */ addiu $sp,$sp,-304 /* f0fa708: afb70034 */ sw $s7,0x34($sp) -/* f0fa70c: 3c178007 */ lui $s7,%hi(g_MenuStackDepth) -/* f0fa710: 26f71448 */ addiu $s7,$s7,%lo(g_MenuStackDepth) +/* f0fa70c: 3c178007 */ lui $s7,%hi(g_MpPlayerNum) +/* f0fa710: 26f71448 */ addiu $s7,$s7,%lo(g_MpPlayerNum) /* f0fa714: 8eee0000 */ lw $t6,0x0($s7) /* f0fa718: afbe0038 */ sw $s8,0x38($sp) /* f0fa71c: 241e0e70 */ addiu $s8,$zero,0xe70 @@ -13046,8 +13046,8 @@ GLOBAL_ASM( glabel func0f0fbc30 /* f0fbc30: 27bdfee8 */ addiu $sp,$sp,-280 /* f0fbc34: afb10038 */ sw $s1,0x38($sp) -/* f0fbc38: 3c118007 */ lui $s1,%hi(g_MenuStackDepth) -/* f0fbc3c: 26311448 */ addiu $s1,$s1,%lo(g_MenuStackDepth) +/* f0fbc38: 3c118007 */ lui $s1,%hi(g_MpPlayerNum) +/* f0fbc3c: 26311448 */ addiu $s1,$s1,%lo(g_MpPlayerNum) /* f0fbc40: ae200000 */ sw $zero,0x0($s1) /* f0fbc44: 3c0e8007 */ lui $t6,0x8007 /* f0fbc48: 8dce06c8 */ lw $t6,0x6c8($t6) @@ -14211,10 +14211,10 @@ glabel menuhandler000fcc34 /* f0fcc78: 3c168007 */ lui $s6,%hi(menudialog_pakrepairfailed) /* f0fcc7c: 3c158007 */ lui $s5,%hi(menudialog_pakremoved) /* f0fcc80: 3c148007 */ lui $s4,%hi(menudialog_pakrepaired) -/* f0fcc84: 3c128007 */ lui $s2,%hi(g_MenuStackDepth) +/* f0fcc84: 3c128007 */ lui $s2,%hi(g_MpPlayerNum) /* f0fcc88: 3c11800a */ lui $s1,%hi(var8009e000) /* f0fcc8c: 2631e000 */ addiu $s1,$s1,%lo(var8009e000) -/* f0fcc90: 26521448 */ addiu $s2,$s2,%lo(g_MenuStackDepth) +/* f0fcc90: 26521448 */ addiu $s2,$s2,%lo(g_MpPlayerNum) /* f0fcc94: 269415b0 */ addiu $s4,$s4,%lo(menudialog_pakrepaired) /* f0fcc98: 26b51548 */ addiu $s5,$s5,%lo(menudialog_pakremoved) /* f0fcc9c: 26d61618 */ addiu $s6,$s6,%lo(menudialog_pakrepairfailed) @@ -14372,10 +14372,10 @@ glabel func0f0fce8c /* f0fcea4: 3c19800a */ lui $t9,%hi(var8009e000) /* f0fcea8: 2739e000 */ addiu $t9,$t9,%lo(var8009e000) /* f0fceac: 0018c100 */ sll $t8,$t8,0x4 -/* f0fceb0: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) +/* f0fceb0: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) /* f0fceb4: 03191021 */ addu $v0,$t8,$t9 /* f0fceb8: 8c4904f8 */ lw $t1,0x4f8($v0) -/* f0fcebc: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f0fcebc: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f0fcec0: 8d0e0000 */ lw $t6,0x0($t0) /* f0fcec4: 27bdffe0 */ addiu $sp,$sp,-32 /* f0fcec8: afbf0014 */ sw $ra,0x14($sp) diff --git a/src/game/game_102240.c b/src/game/game_102240.c index cb1f8bf31..37f0ba09e 100644 --- a/src/game/game_102240.c +++ b/src/game/game_102240.c @@ -304,19 +304,19 @@ s32 menuhandler001024fc(u32 operation, struct menu_item *item, s32 *value) s32 menuhandlerReversePitch(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return !optionsGetForwardPitch(optionsindex); + return !optionsGetForwardPitch(mpchrnum); case MENUOP_SET: - optionsSetForwardPitch(optionsindex, *enable == false); + optionsSetForwardPitch(mpchrnum, *enable == false); g_Vars.unk000458 |= 1; } @@ -646,8 +646,8 @@ glabel menuhandlerScreenSplit /* f1029d8: 01255021 */ addu $t2,$t1,$a1 /* f1029dc: 29410002 */ slti $at,$t2,0x2 /* f1029e0: 14200012 */ bnez $at,.L0f102a2c -/* f1029e4: 3c028007 */ lui $v0,%hi(g_MenuStackDepth) -/* f1029e8: 24421448 */ addiu $v0,$v0,%lo(g_MenuStackDepth) +/* f1029e4: 3c028007 */ lui $v0,%hi(g_MpPlayerNum) +/* f1029e8: 24421448 */ addiu $v0,$v0,%lo(g_MpPlayerNum) /* f1029ec: 8c4b0000 */ lw $t3,0x0($v0) /* f1029f0: ac400000 */ sw $zero,0x0($v0) /* f1029f4: 0fc3e048 */ jal func0f0f8120 @@ -677,19 +677,19 @@ glabel menuhandlerScreenSplit s32 menuhandlerLookAhead(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetLookAhead(optionsindex); + return optionsGetLookAhead(mpchrnum); case MENUOP_SET: - optionsSetLookAhead(optionsindex, *enable); + optionsSetLookAhead(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -698,19 +698,19 @@ s32 menuhandlerLookAhead(u32 operation, struct menu_item *item, bool *enable) s32 menuhandlerHeadRoll(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetHeadRoll(optionsindex); + return optionsGetHeadRoll(mpchrnum); case MENUOP_SET: - optionsSetHeadRoll(optionsindex, *enable); + optionsSetHeadRoll(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -789,19 +789,19 @@ s32 menuhandlerHiRes(u32 operation, struct menu_item *item, bool *enable) s32 menuhandlerAmmoOnScreen(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetAmmoOnScreen(optionsindex); + return optionsGetAmmoOnScreen(mpchrnum); case MENUOP_SET: - optionsSetAmmoOnScreen(optionsindex, *enable); + optionsSetAmmoOnScreen(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -810,24 +810,24 @@ s32 menuhandlerAmmoOnScreen(u32 operation, struct menu_item *item, bool *enable) s32 menuhandlerShowGunFunction(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_CHECKDISABLED: - if (optionsGetAmmoOnScreen(optionsindex) == 0) { + if (optionsGetAmmoOnScreen(mpchrnum) == 0) { return true; } break; case MENUOP_GET: - return optionsGetShowGunFunction(optionsindex); + return optionsGetShowGunFunction(mpchrnum); case MENUOP_SET: - optionsSetShowGunFunction(optionsindex, *enable); + optionsSetShowGunFunction(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -836,19 +836,19 @@ s32 menuhandlerShowGunFunction(u32 operation, struct menu_item *item, bool *enab s32 menuhandlerShowMissionTime(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetShowMissionTime(optionsindex); + return optionsGetShowMissionTime(mpchrnum); case MENUOP_SET: - optionsSetShowMissionTime(optionsindex, *enable); + optionsSetShowMissionTime(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -857,24 +857,24 @@ s32 menuhandlerShowMissionTime(u32 operation, struct menu_item *item, bool *enab s32 menuhandlerAlwaysShowTarget(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_CHECKDISABLED: - if (optionsGetSightOnScreen(optionsindex) == 0) { + if (optionsGetSightOnScreen(mpchrnum) == 0) { return true; } break; case MENUOP_GET: - return optionsGetAlwaysShowTarget(optionsindex); + return optionsGetAlwaysShowTarget(mpchrnum); case MENUOP_SET: - optionsSetAlwaysShowTarget(optionsindex, *enable); + optionsSetAlwaysShowTarget(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -883,24 +883,24 @@ s32 menuhandlerAlwaysShowTarget(u32 operation, struct menu_item *item, bool *ena s32 menuhandlerShowZoomRange(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_CHECKDISABLED: - if (optionsGetSightOnScreen(optionsindex) == 0) { + if (optionsGetSightOnScreen(mpchrnum) == 0) { return true; } break; case MENUOP_GET: - return optionsGetShowZoomRange(optionsindex); + return optionsGetShowZoomRange(mpchrnum); case MENUOP_SET: - optionsSetShowZoomRange(optionsindex, *enable); + optionsSetShowZoomRange(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -909,19 +909,19 @@ s32 menuhandlerShowZoomRange(u32 operation, struct menu_item *item, bool *enable s32 menuhandlerPaintball(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetPaintball(optionsindex); + return optionsGetPaintball(mpchrnum); case MENUOP_SET: - optionsSetPaintball(optionsindex, *enable); + optionsSetPaintball(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -930,19 +930,19 @@ s32 menuhandlerPaintball(u32 operation, struct menu_item *item, bool *enable) s32 menuhandlerSightOnScreen(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetSightOnScreen(optionsindex); + return optionsGetSightOnScreen(mpchrnum); case MENUOP_SET: - optionsSetSightOnScreen(optionsindex, *enable); + optionsSetSightOnScreen(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -951,19 +951,19 @@ s32 menuhandlerSightOnScreen(u32 operation, struct menu_item *item, bool *enable s32 menuhandlerAutoAim(u32 operation, struct menu_item *item, bool *enable) { - u32 optionsindex; + u32 mpchrnum; if (g_Vars.coopplayernum >= 0 || g_Vars.antiplayernum >= 0) { - optionsindex = g_Vars.unk000288->optionsindex; + mpchrnum = g_Vars.unk000288->mpchrnum; } else { - optionsindex = item->right; + mpchrnum = item->param3; } switch (operation) { case MENUOP_GET: - return optionsGetAutoAim(optionsindex); + return optionsGetAutoAim(mpchrnum); case MENUOP_SET: - optionsSetAutoAim(optionsindex, *enable); + optionsSetAutoAim(mpchrnum, *enable); g_Vars.unk000458 |= 1; } @@ -1744,7 +1744,7 @@ s32 menuhandlerSoloDifficulty(u32 operation, struct menu_item *item, s32 *value) switch (operation) { case MENUOP_CHECKPREFOCUSED: if (isStageDifficultyUnlocked(g_MissionConfig.stageindex, item->param)) { - if (item->right == 0) { + if (item->param3 == 0) { return true; } if ((g_SoloSaveFile.unk08 & 7) >= item->param) { diff --git a/src/game/game_107fb0.c b/src/game/game_107fb0.c index 0f9659174..0717f0052 100644 --- a/src/game/game_107fb0.c +++ b/src/game/game_107fb0.c @@ -2006,8 +2006,8 @@ glabel func0f1096a0 .L0f109700: /* f109700: 24100001 */ addiu $s0,$zero,0x1 .L0f109704: -/* f109704: 3c038007 */ lui $v1,%hi(g_MenuStackDepth) -/* f109708: 24631448 */ addiu $v1,$v1,%lo(g_MenuStackDepth) +/* f109704: 3c038007 */ lui $v1,%hi(g_MpPlayerNum) +/* f109708: 24631448 */ addiu $v1,$v1,%lo(g_MpPlayerNum) /* f10970c: 8c790000 */ lw $t9,0x0($v1) /* f109710: 24050e70 */ addiu $a1,$zero,0xe70 /* f109714: 3c02800a */ lui $v0,%hi(var8009e000) @@ -2034,8 +2034,8 @@ glabel func0f1096a0 /* f109768: 10000013 */ beqz $zero,.L0f1097b8 /* f10976c: 8fbf0024 */ lw $ra,0x24($sp) .L0f109770: -/* f109770: 3c11800b */ lui $s1,%hi(g_Options) -/* f109774: 2631c7b8 */ addiu $s1,$s1,%lo(g_Options) +/* f109770: 3c11800b */ lui $s1,%hi(g_MpChrs) +/* f109774: 2631c7b8 */ addiu $s1,$s1,%lo(g_MpChrs) /* f109778: 00008025 */ or $s0,$zero,$zero .L0f10977c: /* f10977c: 8e790000 */ lw $t9,0x0($s3) @@ -2288,8 +2288,8 @@ glabel func0f109a68 /* f109af4: 8fbf001c */ lw $ra,0x1c($sp) /* f109af8: 0007c880 */ sll $t9,$a3,0x2 /* f109afc: 0327c821 */ addu $t9,$t9,$a3 -/* f109b00: 3c08800b */ lui $t0,%hi(g_Options) -/* f109b04: 2508c7b8 */ addiu $t0,$t0,%lo(g_Options) +/* f109b00: 3c08800b */ lui $t0,%hi(g_MpChrs) +/* f109b04: 2508c7b8 */ addiu $t0,$t0,%lo(g_MpChrs) /* f109b08: 0019c940 */ sll $t9,$t9,0x5 /* f109b0c: 03284821 */ addu $t1,$t9,$t0 /* f109b10: 912a0000 */ lbu $t2,0x0($t1) @@ -2309,8 +2309,8 @@ glabel func0f109a68 /* f109b44: a1830000 */ sb $v1,0x0($t4) /* f109b48: 3c0d8007 */ lui $t5,0x8007 /* f109b4c: 8dad1448 */ lw $t5,0x1448($t5) -/* f109b50: 3c18800b */ lui $t8,%hi(g_Options) -/* f109b54: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f109b50: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f109b54: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f109b58: 000d7080 */ sll $t6,$t5,0x2 /* f109b5c: 01cd7021 */ addu $t6,$t6,$t5 /* f109b60: 000e7140 */ sll $t6,$t6,0x5 @@ -2379,8 +2379,8 @@ glabel func0f109bb4 /* f109c3c: 8fbf0014 */ lw $ra,0x14($sp) /* f109c40: 0002c880 */ sll $t9,$v0,0x2 /* f109c44: 0322c821 */ addu $t9,$t9,$v0 -/* f109c48: 3c08800b */ lui $t0,%hi(g_Options) -/* f109c4c: 2508c7b8 */ addiu $t0,$t0,%lo(g_Options) +/* f109c48: 3c08800b */ lui $t0,%hi(g_MpChrs) +/* f109c4c: 2508c7b8 */ addiu $t0,$t0,%lo(g_MpChrs) /* f109c50: 0019c940 */ sll $t9,$t9,0x5 /* f109c54: 3c057f1b */ lui $a1,%hi(var7f1b32d8) /* f109c58: 24a532d8 */ addiu $a1,$a1,%lo(var7f1b32d8) @@ -3406,8 +3406,8 @@ glabel func0f10a97c /* f10aa58: 1000001a */ beqz $zero,.L0f10aac4 /* f10aa5c: 24020001 */ addiu $v0,$zero,0x1 .L0f10aa60: -/* f10aa60: 3c05800b */ lui $a1,%hi(g_Options) -/* f10aa64: 24a5c7b8 */ addiu $a1,$a1,%lo(g_Options) +/* f10aa60: 3c05800b */ lui $a1,%hi(g_MpChrs) +/* f10aa64: 24a5c7b8 */ addiu $a1,$a1,%lo(g_MpChrs) /* f10aa68: 00001025 */ or $v0,$zero,$zero /* f10aa6c: 9484cb9e */ lhu $a0,-0x3462($a0) /* f10aa70: 24180001 */ addiu $t8,$zero,0x1 @@ -3631,8 +3631,8 @@ glabel func0f10aad8 GLOBAL_ASM( glabel menucustomFileToDelete -/* f10ad98: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) -/* f10ad9c: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f10ad98: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) +/* f10ad9c: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f10ada0: 8d0e0000 */ lw $t6,0x0($t0) /* f10ada4: 24090e70 */ addiu $t1,$zero,0xe70 /* f10ada8: 3c07800a */ lui $a3,%hi(var8009e000) @@ -3671,8 +3671,8 @@ glabel menucustomFileToDelete /* f10ae28: afa6001c */ sw $a2,0x1c($sp) /* f10ae2c: 3c038007 */ lui $v1,%hi(var80075bc0) /* f10ae30: 3c07800a */ lui $a3,%hi(var8009e000) -/* f10ae34: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) -/* f10ae38: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f10ae34: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) +/* f10ae38: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f10ae3c: 24e7e000 */ addiu $a3,$a3,%lo(var8009e000) /* f10ae40: 24635bc0 */ addiu $v1,$v1,%lo(var80075bc0) /* f10ae44: 8fa6001c */ lw $a2,0x1c($sp) @@ -5502,10 +5502,10 @@ glabel menudialog0010c804 /* f10c878: 00002825 */ or $a1,$zero,$zero /* f10c87c: 0fc62084 */ jal func0f188210 /* f10c880: 00000000 */ sll $zero,$zero,0x0 -/* f10c884: 3c11800b */ lui $s1,%hi(g_Options) +/* f10c884: 3c11800b */ lui $s1,%hi(g_MpChrs) /* f10c888: 3c127f1b */ lui $s2,%hi(var7f1b3540) /* f10c88c: 26523540 */ addiu $s2,$s2,%lo(var7f1b3540) -/* f10c890: 2631c7b8 */ addiu $s1,$s1,%lo(g_Options) +/* f10c890: 2631c7b8 */ addiu $s1,$s1,%lo(g_MpChrs) /* f10c894: 00008025 */ or $s0,$zero,$zero /* f10c898: 24130004 */ addiu $s3,$zero,0x4 .L0f10c89c: @@ -5575,8 +5575,8 @@ glabel func0f10c900 GLOBAL_ASM( glabel func0f10c970 -/* f10c970: 3c028007 */ lui $v0,%hi(g_MenuStackDepth) -/* f10c974: 24421448 */ addiu $v0,$v0,%lo(g_MenuStackDepth) +/* f10c970: 3c028007 */ lui $v0,%hi(g_MpPlayerNum) +/* f10c974: 24421448 */ addiu $v0,$v0,%lo(g_MpPlayerNum) /* f10c978: 8c4e0000 */ lw $t6,0x0($v0) /* f10c97c: 27bdffe0 */ addiu $sp,$sp,-32 /* f10c980: afbf0014 */ sw $ra,0x14($sp) diff --git a/src/game/game_10ccd0.c b/src/game/game_10ccd0.c index 5224993af..15e8ab3b5 100644 --- a/src/game/game_10ccd0.c +++ b/src/game/game_10ccd0.c @@ -1473,8 +1473,8 @@ glabel menuhandler0010e064 /* f10e074: afa50024 */ sw $a1,0x24($sp) /* f10e078: 14810076 */ bne $a0,$at,.L0f10e254 /* f10e07c: afa60028 */ sw $a2,0x28($sp) -/* f10e080: 3c058007 */ lui $a1,%hi(g_MenuStackDepth) -/* f10e084: 24a51448 */ addiu $a1,$a1,%lo(g_MenuStackDepth) +/* f10e080: 3c058007 */ lui $a1,%hi(g_MpPlayerNum) +/* f10e084: 24a51448 */ addiu $a1,$a1,%lo(g_MpPlayerNum) /* f10e088: 8caf0000 */ lw $t7,0x0($a1) /* f10e08c: 24060e70 */ addiu $a2,$zero,0xe70 /* f10e090: 3c04800a */ lui $a0,%hi(var8009e000) @@ -1599,9 +1599,9 @@ glabel menuhandler0010e064 .L0f10e254: /* f10e254: 8fae0020 */ lw $t6,0x20($sp) /* f10e258: 3c04800a */ lui $a0,%hi(var8009e000) -/* f10e25c: 3c058007 */ lui $a1,%hi(g_MenuStackDepth) +/* f10e25c: 3c058007 */ lui $a1,%hi(g_MpPlayerNum) /* f10e260: 24010018 */ addiu $at,$zero,0x18 -/* f10e264: 24a51448 */ addiu $a1,$a1,%lo(g_MenuStackDepth) +/* f10e264: 24a51448 */ addiu $a1,$a1,%lo(g_MpPlayerNum) /* f10e268: 2484e000 */ addiu $a0,$a0,%lo(var8009e000) /* f10e26c: 15c1005e */ bne $t6,$at,.L0f10e3e8 /* f10e270: 24060e70 */ addiu $a2,$zero,0xe70 @@ -2442,9 +2442,9 @@ GLOBAL_ASM( glabel func0f10ee40 /* f10ee40: 0000c0c0 */ sll $t8,$zero,0x3 /* f10ee44: 0300c023 */ subu $t8,$t8,$zero -/* f10ee48: 3c048007 */ lui $a0,%hi(g_MenuStackDepth) +/* f10ee48: 3c048007 */ lui $a0,%hi(g_MpPlayerNum) /* f10ee4c: 0018c140 */ sll $t8,$t8,0x5 -/* f10ee50: 24841448 */ addiu $a0,$a0,%lo(g_MenuStackDepth) +/* f10ee50: 24841448 */ addiu $a0,$a0,%lo(g_MpPlayerNum) /* f10ee54: 0300c023 */ subu $t8,$t8,$zero /* f10ee58: 8c8e0000 */ lw $t6,0x0($a0) /* f10ee5c: 0018c100 */ sll $t8,$t8,0x4 diff --git a/src/game/game_115ab0.c b/src/game/game_115ab0.c index 2dee00544..c45b1b8b4 100644 --- a/src/game/game_115ab0.c +++ b/src/game/game_115ab0.c @@ -8274,9 +8274,9 @@ glabel func0f11c6d0 /* f11c6e8: afb00014 */ sw $s0,0x14($sp) /* f11c6ec: 3c11800a */ lui $s1,%hi(var800a2380) /* f11c6f0: 3c128007 */ lui $s2,%hi(var80075d10) -/* f11c6f4: 3c138007 */ lui $s3,%hi(g_MenuStackDepth) +/* f11c6f4: 3c138007 */ lui $s3,%hi(g_MpPlayerNum) /* f11c6f8: afbf002c */ sw $ra,0x2c($sp) -/* f11c6fc: 26731448 */ addiu $s3,$s3,%lo(g_MenuStackDepth) +/* f11c6fc: 26731448 */ addiu $s3,$s3,%lo(g_MpPlayerNum) /* f11c700: 26525d10 */ addiu $s2,$s2,%lo(var80075d10) /* f11c704: 26312380 */ addiu $s1,$s1,%lo(var800a2380) /* f11c708: 00008025 */ or $s0,$zero,$zero diff --git a/src/game/game_1668e0.c b/src/game/game_1668e0.c index 64382230e..1d60a0504 100644 --- a/src/game/game_1668e0.c +++ b/src/game/game_1668e0.c @@ -1963,8 +1963,8 @@ glabel func0f167e7c /* f168074: 25859fc0 */ addiu $a1,$t4,-24640 /* f168078: 15400007 */ bnez $t2,.L0f168098 /* f16807c: 00a02025 */ or $a0,$a1,$zero -/* f168080: 3c02800b */ lui $v0,%hi(g_Options) -/* f168084: 2442c7b8 */ addiu $v0,$v0,%lo(g_Options) +/* f168080: 3c02800b */ lui $v0,%hi(g_MpChrs) +/* f168084: 2442c7b8 */ addiu $v0,$v0,%lo(g_MpChrs) /* f168088: 240b0001 */ addiu $t3,$zero,0x1 /* f16808c: ae0600e4 */ sw $a2,0xe4($s0) /* f168090: a04002c5 */ sb $zero,0x2c5($v0) diff --git a/src/game/game_176d70.c b/src/game/game_176d70.c index 5ebe366aa..0cb9b5f2f 100644 --- a/src/game/game_176d70.c +++ b/src/game/game_176d70.c @@ -1700,8 +1700,8 @@ glabel menuhandler00177e00 .L0f177e80: /* f177e80: 3c03800b */ lui $v1,0x800b /* f177e84: 3c0b800b */ lui $t3,%hi(g_MpSimulants) -/* f177e88: 3c09800b */ lui $t1,%hi(g_Options) -/* f177e8c: 2529c7b8 */ addiu $t1,$t1,%lo(g_Options) +/* f177e88: 3c09800b */ lui $t1,%hi(g_MpChrs) +/* f177e8c: 2529c7b8 */ addiu $t1,$t1,%lo(g_MpChrs) /* f177e90: 256bc538 */ addiu $t3,$t3,%lo(g_MpSimulants) /* f177e94: 9463cb9e */ lhu $v1,-0x3462($v1) /* f177e98: 00002825 */ or $a1,$zero,$zero @@ -1741,10 +1741,10 @@ glabel menuhandler00177e00 /* f177f10: 24427e80 */ addiu $v0,$v0,%lo(var7f1b7e80) .L0f177f14: /* f177f14: 3c03800b */ lui $v1,0x800b -/* f177f18: 3c098007 */ lui $t1,%hi(g_MenuStackDepth) +/* f177f18: 3c098007 */ lui $t1,%hi(g_MpPlayerNum) /* f177f1c: 3c07800a */ lui $a3,%hi(var8009deb0) /* f177f20: 24e7deb0 */ addiu $a3,$a3,%lo(var8009deb0) -/* f177f24: 25291448 */ addiu $t1,$t1,%lo(g_MenuStackDepth) +/* f177f24: 25291448 */ addiu $t1,$t1,%lo(g_MpPlayerNum) /* f177f28: 9463cb9e */ lhu $v1,-0x3462($v1) /* f177f2c: 00002825 */ or $a1,$zero,$zero /* f177f30: 2408000c */ addiu $t0,$zero,0xc @@ -2096,8 +2096,8 @@ glabel func0f1783a0 /* f1783c8: 00401825 */ or $v1,$v0,$zero /* f1783cc: 00027880 */ sll $t7,$v0,0x2 /* f1783d0: 01e27821 */ addu $t7,$t7,$v0 -/* f1783d4: 3c18800b */ lui $t8,%hi(g_Options) -/* f1783d8: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f1783d4: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f1783d8: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f1783dc: 000f7940 */ sll $t7,$t7,0x5 /* f1783e0: 1000000a */ beqz $zero,.L0f17840c /* f1783e4: 01f83021 */ addu $a2,$t7,$t8 @@ -2335,8 +2335,8 @@ glabel menuhandler001786d8 /* f178708: 148100d5 */ bne $a0,$at,.L0f178a60 /* f17870c: afa500ac */ sw $a1,0xac($sp) /* f178710: 8cce0000 */ lw $t6,0x0($a2) -/* f178714: 3c1e8007 */ lui $s8,%hi(g_MenuStackDepth) -/* f178718: 3c17800b */ lui $s7,%hi(g_Options) +/* f178714: 3c1e8007 */ lui $s8,%hi(g_MpPlayerNum) +/* f178718: 3c17800b */ lui $s7,%hi(g_MpChrs) /* f17871c: afae00a4 */ sw $t6,0xa4($sp) /* f178720: 8cd50008 */ lw $s5,0x8($a2) /* f178724: 3c14ba00 */ lui $s4,0xba00 @@ -2348,8 +2348,8 @@ glabel menuhandler001786d8 /* f17873c: 01f89021 */ addu $s2,$t7,$t8 /* f178740: 2652fff1 */ addiu $s2,$s2,-15 /* f178744: 36940c02 */ ori $s4,$s4,0xc02 -/* f178748: 26f7c7b8 */ addiu $s7,$s7,%lo(g_Options) -/* f17874c: 27de1448 */ addiu $s8,$s8,%lo(g_MenuStackDepth) +/* f178748: 26f7c7b8 */ addiu $s7,$s7,%lo(g_MpChrs) +/* f17874c: 27de1448 */ addiu $s8,$s8,%lo(g_MpPlayerNum) /* f178750: 00008025 */ or $s0,$zero,$zero /* f178754: 8fb10090 */ lw $s1,0x90($sp) /* f178758: 8fd90000 */ lw $t9,0x0($s8) @@ -2583,8 +2583,8 @@ glabel menuhandler00178a94 /* f178aa8: afa60020 */ sw $a2,0x20($sp) /* f178aac: 3c0e8007 */ lui $t6,0x8007 /* f178ab0: 8dce1448 */ lw $t6,0x1448($t6) -/* f178ab4: 3c18800b */ lui $t8,%hi(g_Options) -/* f178ab8: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f178ab4: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f178ab8: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f178abc: 000e7880 */ sll $t7,$t6,0x2 /* f178ac0: 01ee7821 */ addu $t7,$t7,$t6 /* f178ac4: 000f7940 */ sll $t7,$t7,0x5 @@ -2684,17 +2684,17 @@ glabel menuhandler00178bf4 /* f178c08: 8cca0000 */ lw $t2,0x0($a2) /* f178c0c: 24010011 */ addiu $at,$zero,0x11 /* f178c10: 10810006 */ beq $a0,$at,.L0f178c2c -/* f178c14: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) +/* f178c14: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) /* f178c18: 24010012 */ addiu $at,$zero,0x12 /* f178c1c: 10810033 */ beq $a0,$at,.L0f178cec -/* f178c20: 3c07800b */ lui $a3,%hi(g_Options) +/* f178c20: 3c07800b */ lui $a3,%hi(g_MpChrs) /* f178c24: 10000061 */ beqz $zero,.L0f178dac /* f178c28: 8fbf0014 */ lw $ra,0x14($sp) .L0f178c2c: -/* f178c2c: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f178c2c: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f178c30: 8d020000 */ lw $v0,0x0($t0) -/* f178c34: 3c07800b */ lui $a3,%hi(g_Options) -/* f178c38: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f178c34: 3c07800b */ lui $a3,%hi(g_MpChrs) +/* f178c38: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f178c3c: 00027080 */ sll $t6,$v0,0x2 /* f178c40: 01c27021 */ addu $t6,$t6,$v0 /* f178c44: 000e7140 */ sll $t6,$t6,0x5 @@ -2745,14 +2745,14 @@ glabel menuhandler00178bf4 /* f178ce8: 8fbf0014 */ lw $ra,0x14($sp) .L0f178cec: /* f178cec: 91590000 */ lbu $t9,0x0($t2) -/* f178cf0: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) +/* f178cf0: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) /* f178cf4: 00001825 */ or $v1,$zero,$zero /* f178cf8: 13200014 */ beqz $t9,.L0f178d4c -/* f178cfc: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f178cfc: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f178d00: 3c0b8007 */ lui $t3,0x8007 /* f178d04: 8d6b1448 */ lw $t3,0x1448($t3) -/* f178d08: 3c0e800b */ lui $t6,%hi(g_Options) -/* f178d0c: 25cec7b8 */ addiu $t6,$t6,%lo(g_Options) +/* f178d08: 3c0e800b */ lui $t6,%hi(g_MpChrs) +/* f178d0c: 25cec7b8 */ addiu $t6,$t6,%lo(g_MpChrs) /* f178d10: 000b6080 */ sll $t4,$t3,0x2 /* f178d14: 018b6021 */ addu $t4,$t4,$t3 /* f178d18: 000c6140 */ sll $t4,$t4,0x5 @@ -2771,7 +2771,7 @@ glabel menuhandler00178bf4 /* f178d48: 24630001 */ addiu $v1,$v1,0x1 .L0f178d4c: /* f178d4c: 8d0f0000 */ lw $t7,0x0($t0) -/* f178d50: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f178d50: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f178d54: 240b000a */ addiu $t3,$zero,0xa /* f178d58: 000fc080 */ sll $t8,$t7,0x2 /* f178d5c: 030fc021 */ addu $t8,$t8,$t7 @@ -2808,9 +2808,9 @@ GLOBAL_ASM( glabel func0f178dbc /* f178dbc: 3c04800b */ lui $a0,%hi(g_MpSetup) /* f178dc0: 2484cb88 */ addiu $a0,$a0,%lo(g_MpSetup) -/* f178dc4: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) +/* f178dc4: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) /* f178dc8: 908f001e */ lbu $t7,0x1e($a0) -/* f178dcc: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f178dcc: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) /* f178dd0: 8cce0000 */ lw $t6,0x0($a2) /* f178dd4: 27bdffe0 */ addiu $sp,$sp,-32 /* f178dd8: 24010002 */ addiu $at,$zero,0x2 @@ -2852,15 +2852,15 @@ glabel func0f178dbc /* f178e68: 3c048008 */ lui $a0,%hi(menudialog_2a908) /* f178e6c: 0fc3e0cc */ jal func0f0f8330 /* f178e70: 248448e8 */ addiu $a0,$a0,%lo(menudialog_2a908) -/* f178e74: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) +/* f178e74: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) /* f178e78: 10000017 */ beqz $zero,.L0f178ed8 -/* f178e7c: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f178e7c: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) .L0f178e80: /* f178e80: 0fc3e0cc */ jal func0f0f8330 /* f178e84: 24050004 */ addiu $a1,$zero,0x4 -/* f178e88: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) +/* f178e88: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) /* f178e8c: 10000012 */ beqz $zero,.L0f178ed8 -/* f178e90: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f178e90: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) .L0f178e94: /* f178e94: 0fc54bcd */ jal optionsGetScreenSplit /* f178e98: 00000000 */ sll $zero,$zero,0x0 @@ -2871,15 +2871,15 @@ glabel func0f178dbc /* f178eac: 248436c0 */ addiu $a0,$a0,%lo(menudialog_status) /* f178eb0: 0fc3e0cc */ jal func0f0f8330 /* f178eb4: 24050004 */ addiu $a1,$zero,0x4 -/* f178eb8: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) +/* f178eb8: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) /* f178ebc: 10000006 */ beqz $zero,.L0f178ed8 -/* f178ec0: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f178ec0: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) .L0f178ec4: /* f178ec4: 248436a8 */ addiu $a0,$a0,%lo(menudialog_196c8) /* f178ec8: 0fc3e0cc */ jal func0f0f8330 /* f178ecc: 24050004 */ addiu $a1,$zero,0x4 -/* f178ed0: 3c068007 */ lui $a2,%hi(g_MenuStackDepth) -/* f178ed4: 24c61448 */ addiu $a2,$a2,%lo(g_MenuStackDepth) +/* f178ed0: 3c068007 */ lui $a2,%hi(g_MpPlayerNum) +/* f178ed4: 24c61448 */ addiu $a2,$a2,%lo(g_MpPlayerNum) .L0f178ed8: /* f178ed8: 8fb9001c */ lw $t9,0x1c($sp) .L0f178edc: @@ -2894,9 +2894,9 @@ glabel func0f178dbc GLOBAL_ASM( glabel func0f178ef0 -/* f178ef0: 3c028007 */ lui $v0,%hi(g_MenuStackDepth) +/* f178ef0: 3c028007 */ lui $v0,%hi(g_MpPlayerNum) /* f178ef4: 0005c0c0 */ sll $t8,$a1,0x3 -/* f178ef8: 24421448 */ addiu $v0,$v0,%lo(g_MenuStackDepth) +/* f178ef8: 24421448 */ addiu $v0,$v0,%lo(g_MpPlayerNum) /* f178efc: 0305c023 */ subu $t8,$t8,$a1 /* f178f00: 8c4e0000 */ lw $t6,0x0($v0) /* f178f04: 0018c080 */ sll $t8,$t8,0x2 @@ -2965,8 +2965,8 @@ glabel func0f178ef0 .L0f178fec: /* f178fec: 3c0c8007 */ lui $t4,0x8007 /* f178ff0: 8d8c1448 */ lw $t4,0x1448($t4) -/* f178ff4: 3c0e800b */ lui $t6,%hi(g_Options) -/* f178ff8: 25cec7b8 */ addiu $t6,$t6,%lo(g_Options) +/* f178ff4: 3c0e800b */ lui $t6,%hi(g_MpChrs) +/* f178ff8: 25cec7b8 */ addiu $t6,$t6,%lo(g_MpChrs) /* f178ffc: 000c6880 */ sll $t5,$t4,0x2 /* f179000: 01ac6821 */ addu $t5,$t5,$t4 /* f179004: 000d6940 */ sll $t5,$t5,0x5 @@ -3010,8 +3010,8 @@ GLOBAL_ASM( glabel func0f17909c /* f17909c: 3c0e8007 */ lui $t6,0x8007 /* f1790a0: 8dce1448 */ lw $t6,0x1448($t6) -/* f1790a4: 3c18800b */ lui $t8,%hi(g_Options) -/* f1790a8: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f1790a4: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f1790a8: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f1790ac: 000e7880 */ sll $t7,$t6,0x2 /* f1790b0: 01ee7821 */ addu $t7,$t7,$t6 /* f1790b4: 000f7940 */ sll $t7,$t7,0x5 @@ -3374,10 +3374,10 @@ char *menuhandlerMpWeaponSlot(u32 operation, struct menu_item *item, s32 *value) case MENUOP_GETOPTIONTEXT: return mpGetWeaponLabel(*value); case MENUOP_SET: - mpSetWeaponSlot(item->right, *value); + mpSetWeaponSlot(item->param3, *value); break; case MENUOP_GETOPTIONVALUE: - *value = mpGetWeaponSlot(item->right); + *value = mpGetWeaponSlot(item->param3); } return 0; @@ -3450,20 +3450,20 @@ s32 menuhandlerMpControlCheckbox(u32 operation, struct menu_item *item, s32 *val switch (operation) { case MENUOP_GET: - if (item->right == OPTION_FORWARDPITCH) { - if ((g_Options[g_MenuStackDepth].booleans & item->right) == 0) { + if (item->param3 == OPTION_FORWARDPITCH) { + if ((g_MpChrs[g_MpPlayerNum].options & item->param3) == 0) { return true; } return false; } - if ((g_Options[g_MenuStackDepth].booleans & item->right) == 0) { + if ((g_MpChrs[g_MpPlayerNum].options & item->param3) == 0) { return false; } return true; case MENUOP_SET: val = OPTION_FORWARDPITCH; - if (item->right == val) { + if (item->param3 == val) { if (*value == 0) { *value = val; } else { @@ -3471,10 +3471,10 @@ s32 menuhandlerMpControlCheckbox(u32 operation, struct menu_item *item, s32 *val } } - g_Options[g_MenuStackDepth].booleans &= ~item->right; + g_MpChrs[g_MpPlayerNum].options &= ~item->param3; if (*value) { - g_Options[g_MenuStackDepth].booleans |= item->right; + g_MpChrs[g_MpPlayerNum].options |= item->param3; } } @@ -3542,14 +3542,14 @@ s32 menuhandlerMpCheckboxOption(u32 operation, struct menu_item *item, s32 *valu { switch (operation) { case MENUOP_GET: - if ((g_MpSetup.options & item->right) == 0) { + if ((g_MpSetup.options & item->param3) == 0) { return false; } return true; case MENUOP_SET: - g_MpSetup.options = g_MpSetup.options & ~item->right; + g_MpSetup.options = g_MpSetup.options & ~item->param3; if (*value) { - g_MpSetup.options = g_MpSetup.options | item->right; + g_MpSetup.options = g_MpSetup.options | item->param3; } } @@ -3596,8 +3596,8 @@ glabel menuhandler00179968 /* f1799b8: 24020001 */ addiu $v0,$zero,0x1 .L0f1799bc: /* f1799bc: 8d291448 */ lw $t1,0x1448($t1) -/* f1799c0: 3c0b800b */ lui $t3,%hi(g_Options) -/* f1799c4: 256bc7b8 */ addiu $t3,$t3,%lo(g_Options) +/* f1799c0: 3c0b800b */ lui $t3,%hi(g_MpChrs) +/* f1799c4: 256bc7b8 */ addiu $t3,$t3,%lo(g_MpChrs) /* f1799c8: 00095080 */ sll $t2,$t1,0x2 /* f1799cc: 01495021 */ addu $t2,$t2,$t1 /* f1799d0: 000a5140 */ sll $t2,$t2,0x5 @@ -4031,24 +4031,24 @@ s32 menuhandlerMpCharacterBody(u32 operation, struct menu_item *item, struct num { switch (operation) { case MENUOP_SET: - if (g_Options[g_MenuStackDepth].mphead < mpGetNumHeads()) { + if (g_MpChrs[g_MpPlayerNum].headnum < mpGetNumHeads()) { if (!value->text) { - g_Options[g_MenuStackDepth].mphead = func0f18bc9c(value->num); + g_MpChrs[g_MpPlayerNum].headnum = func0f18bc9c(value->num); } } - g_Options[g_MenuStackDepth].mpbody = value->num; + g_MpChrs[g_MpPlayerNum].bodynum = value->num; func0f17b8f0(); break; case MENUOP_CHECKPREFOCUSED: func0f179da4(operation, item, &value->num, - g_Options[g_MenuStackDepth].mpbody, - g_Options[g_MenuStackDepth].mphead, 1); + g_MpChrs[g_MpPlayerNum].bodynum, + g_MpChrs[g_MpPlayerNum].headnum, 1); return true; } return func0f179da4(operation, item, &value->num, - g_Options[g_MenuStackDepth].mpbody, - g_Options[g_MenuStackDepth].mphead, 1); + g_MpChrs[g_MpPlayerNum].bodynum, + g_MpChrs[g_MpPlayerNum].headnum, 1); } GLOBAL_ASM( @@ -5343,8 +5343,8 @@ glabel func0f17b360 /* f17b370: 24045091 */ addiu $a0,$zero,0x5091 /* f17b374: 3c0e8007 */ lui $t6,0x8007 /* f17b378: 8dce1448 */ lw $t6,0x1448($t6) -/* f17b37c: 3c18800b */ lui $t8,%hi(g_Options) -/* f17b380: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f17b37c: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f17b380: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f17b384: 000e7880 */ sll $t7,$t6,0x2 /* f17b388: 01ee7821 */ addu $t7,$t7,$t6 /* f17b38c: 000f7940 */ sll $t7,$t7,0x5 @@ -5363,7 +5363,7 @@ glabel func0f17b360 s32 menuhandlerMpUsernamePassword(u32 operation, struct menu_item *item, s32 *value) { if (operation == MENUOP_CHECKHIDDEN) { - if (g_Options[g_MenuStackDepth].mptitle != MPPLAYERTITLE_PERFECT) { + if (g_MpChrs[g_MpPlayerNum].title != MPPLAYERTITLE_PERFECT) { return true; } } @@ -5660,10 +5660,10 @@ glabel func0f17b4f8 s32 menuhandlerMpCharacterHead(u32 operation, struct menu_item *item, s32 *value) { if (operation == MENUOP_SET) { - g_Options[g_MenuStackDepth].mphead = *value; + g_MpChrs[g_MpPlayerNum].headnum = *value; } - return func0f17b4f8(operation, item, value, g_Options[g_MenuStackDepth].mphead, 1); + return func0f17b4f8(operation, item, value, g_MpChrs[g_MpPlayerNum].headnum, 1); } GLOBAL_ASM( @@ -5709,15 +5709,15 @@ glabel menuhandler0017b91c /* f17b928: 8cc20000 */ lw $v0,0x0($a2) /* f17b92c: 24010012 */ addiu $at,$zero,0x12 /* f17b930: 10810034 */ beq $a0,$at,.L0f17ba04 -/* f17b934: 3c07800b */ lui $a3,%hi(g_Options) +/* f17b934: 3c07800b */ lui $a3,%hi(g_MpChrs) /* f17b938: 03e00008 */ jr $ra /* f17b93c: 00001025 */ or $v0,$zero,$zero .L0f17b940: -/* f17b940: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) -/* f17b944: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f17b940: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) +/* f17b944: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f17b948: 8d040000 */ lw $a0,0x0($t0) -/* f17b94c: 3c07800b */ lui $a3,%hi(g_Options) -/* f17b950: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f17b94c: 3c07800b */ lui $a3,%hi(g_MpChrs) +/* f17b950: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f17b954: 00047080 */ sll $t6,$a0,0x2 /* f17b958: 01c47021 */ addu $t6,$t6,$a0 /* f17b95c: 000e7140 */ sll $t6,$t6,0x5 @@ -5768,14 +5768,14 @@ glabel menuhandler0017b91c /* f17ba00: 00001025 */ or $v0,$zero,$zero .L0f17ba04: /* f17ba04: 90590000 */ lbu $t9,0x0($v0) -/* f17ba08: 3c088007 */ lui $t0,%hi(g_MenuStackDepth) +/* f17ba08: 3c088007 */ lui $t0,%hi(g_MpPlayerNum) /* f17ba0c: 00001825 */ or $v1,$zero,$zero /* f17ba10: 13200014 */ beqz $t9,.L0f17ba64 -/* f17ba14: 25081448 */ addiu $t0,$t0,%lo(g_MenuStackDepth) +/* f17ba14: 25081448 */ addiu $t0,$t0,%lo(g_MpPlayerNum) /* f17ba18: 3c0b8007 */ lui $t3,0x8007 /* f17ba1c: 8d6b1448 */ lw $t3,0x1448($t3) -/* f17ba20: 3c0e800b */ lui $t6,%hi(g_Options) -/* f17ba24: 25cec7b8 */ addiu $t6,$t6,%lo(g_Options) +/* f17ba20: 3c0e800b */ lui $t6,%hi(g_MpChrs) +/* f17ba24: 25cec7b8 */ addiu $t6,$t6,%lo(g_MpChrs) /* f17ba28: 000b6080 */ sll $t4,$t3,0x2 /* f17ba2c: 018b6021 */ addu $t4,$t4,$t3 /* f17ba30: 000c6140 */ sll $t4,$t4,0x5 @@ -5794,7 +5794,7 @@ glabel menuhandler0017b91c /* f17ba60: 24630001 */ addiu $v1,$v1,0x1 .L0f17ba64: /* f17ba64: 8d0f0000 */ lw $t7,0x0($t0) -/* f17ba68: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f17ba68: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f17ba6c: 240b000a */ addiu $t3,$zero,0xa /* f17ba70: 000fc080 */ sll $t8,$t7,0x2 /* f17ba74: 030fc021 */ addu $t8,$t8,$t7 @@ -6210,13 +6210,13 @@ glabel menuhandler0017bfc0 /* f17c060: 8e020000 */ lw $v0,0x0($s0) /* f17c064: 8e680000 */ lw $t0,0x0($s3) /* f17c068: 3c13800b */ lui $s3,%hi(g_MpSetup) -/* f17c06c: 3c11800b */ lui $s1,%hi(g_Options) +/* f17c06c: 3c11800b */ lui $s1,%hi(g_MpChrs) /* f17c070: 00084880 */ sll $t1,$t0,0x2 /* f17c074: 01284823 */ subu $t1,$t1,$t0 /* f17c078: 000948c0 */ sll $t1,$t1,0x3 /* f17c07c: 00499021 */ addu $s2,$v0,$t1 /* f17c080: 24150001 */ addiu $s5,$zero,0x1 -/* f17c084: 2631c7b8 */ addiu $s1,$s1,%lo(g_Options) +/* f17c084: 2631c7b8 */ addiu $s1,$s1,%lo(g_MpChrs) /* f17c088: 2673cb88 */ addiu $s3,$s3,%lo(g_MpSetup) /* f17c08c: 00008025 */ or $s0,$zero,$zero /* f17c090: 24140004 */ addiu $s4,$zero,0x4 @@ -6452,8 +6452,8 @@ glabel func0f17c524 /* f17c540: 3c027f1c */ lui $v0,0x7f1c /* f17c544: 00034080 */ sll $t0,$v1,0x2 /* f17c548: 01034021 */ addu $t0,$t0,$v1 -/* f17c54c: 3c09800b */ lui $t1,%hi(g_Options) -/* f17c550: 2529c7b8 */ addiu $t1,$t1,%lo(g_Options) +/* f17c54c: 3c09800b */ lui $t1,%hi(g_MpChrs) +/* f17c550: 2529c7b8 */ addiu $t1,$t1,%lo(g_MpChrs) /* f17c554: 00084140 */ sll $t0,$t0,0x5 /* f17c558: 03e00008 */ jr $ra /* f17c55c: 01091021 */ addu $v0,$t0,$t1 @@ -6469,10 +6469,10 @@ glabel menuhandlerMpRestoreHandicapDefaults /* f17c570: afa50004 */ sw $a1,0x4($sp) /* f17c574: 14810009 */ bne $a0,$at,.L0f17c59c /* f17c578: afa60008 */ sw $a2,0x8($sp) -/* f17c57c: 3c03800b */ lui $v1,%hi(g_Options) +/* f17c57c: 3c03800b */ lui $v1,%hi(g_MpChrs) /* f17c580: 3c04800b */ lui $a0,%hi(var800aca38) /* f17c584: 2484ca38 */ addiu $a0,$a0,%lo(var800aca38) -/* f17c588: 2463c7b8 */ addiu $v1,$v1,%lo(g_Options) +/* f17c588: 2463c7b8 */ addiu $v1,$v1,%lo(g_MpChrs) /* f17c58c: 24020080 */ addiu $v0,$zero,0x80 .L0f17c590: /* f17c590: 246300a0 */ addiu $v1,$v1,0xa0 @@ -6493,8 +6493,8 @@ glabel menudialog0017c5a4 /* f17c5b8: afa60020 */ sw $a2,0x20($sp) /* f17c5bc: 3c038007 */ lui $v1,0x8007 /* f17c5c0: 8c631448 */ lw $v1,0x1448($v1) -/* f17c5c4: 3c0f800b */ lui $t7,%hi(g_Options) -/* f17c5c8: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f17c5c4: 3c0f800b */ lui $t7,%hi(g_MpChrs) +/* f17c5c8: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f17c5cc: 00037080 */ sll $t6,$v1,0x2 /* f17c5d0: 01c37021 */ addu $t6,$t6,$v1 /* f17c5d4: 000e7140 */ sll $t6,$t6,0x5 @@ -6843,7 +6843,7 @@ s32 menuhandlerMpSimulantHead(u32 operation, struct menu_item *item, s32 *value) { s32 start = 0; - if (item->left == 1) { + if (item->param2 == 1) { start = mpGetNumHeads(); } @@ -6854,26 +6854,26 @@ s32 menuhandlerMpSimulantHead(u32 operation, struct menu_item *item, s32 *value) */ switch (operation) { case MENUOP_SET: - g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].headnum = start + *value; + g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].headnum = start + *value; case MENUOP_13: - if (operation == MENUOP_13 && item->left == 1 && g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].headnum < start) { - g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].headnum = start; + if (operation == MENUOP_13 && item->param2 == 1 && g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].headnum < start) { + g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].headnum = start; } break; } - return func0f17b4f8(operation, item, value, g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].headnum, 0); + return func0f17b4f8(operation, item, value, g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].headnum, 0); } s32 menuhandlerMpSimulantBody(u32 operation, struct menu_item *item, s32 *value) { if (operation == MENUOP_SET) { - g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].bodynum = *value; + g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].bodynum = *value; } return func0f179da4(operation, item, value, - g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].bodynum, - g_MpSimulants[g_MenuStack[g_MenuStackDepth].slotindex].headnum, + g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].bodynum, + g_MpSimulants[g_MenuStack[g_MpPlayerNum].slotindex].headnum, 0); } @@ -7054,7 +7054,7 @@ glabel menuhandlerMpSimulantDifficulty s32 menuhandlerMpDeleteSimulant(u32 operation, struct menu_item *item, s32 *value) { if (operation == MENUOP_SET) { - mpRemoveSimulant(g_MenuStack[g_MenuStackDepth].slotindex); + mpRemoveSimulant(g_MenuStack[g_MpPlayerNum].slotindex); menuPopDialog(); } @@ -7192,7 +7192,7 @@ s32 menuhandlerMpAddSimulant(u32 operation, struct menu_item *item, s32 *value) { switch (operation) { case MENUOP_SET: - g_MenuStack[g_MenuStackDepth].slotindex = -1; + g_MenuStack[g_MpPlayerNum].slotindex = -1; menuPushDialog(&g_MpAddSimulantMenuDialog); break; case MENUOP_CHECKDISABLED: @@ -7208,7 +7208,7 @@ s32 menuhandlerMpSimulantSlot(u32 operation, struct menu_item *item, s32 *value) { switch (operation) { case MENUOP_SET: - g_MenuStack[g_MenuStackDepth].slotindex = item->param; + g_MenuStack[g_MpPlayerNum].slotindex = item->param; if ((g_MpSetup.simslots & (1 << (item->param + 4))) == 0) { menuPushDialog(&g_MpAddSimulantMenuDialog); @@ -7556,11 +7556,11 @@ glabel menuhandlerMpMaximumTeams /* f17d7f0: 1481002b */ bne $a0,$at,.L0f17d8a0 /* f17d7f4: afa60040 */ sw $a2,0x40($sp) /* f17d7f8: 3c16800b */ lui $s6,%hi(g_MpSimulants) -/* f17d7fc: 3c13800b */ lui $s3,%hi(g_Options) +/* f17d7fc: 3c13800b */ lui $s3,%hi(g_MpChrs) /* f17d800: 3c12800b */ lui $s2,%hi(g_MpSetup) /* f17d804: 00008825 */ or $s1,$zero,$zero /* f17d808: 2652cb88 */ addiu $s2,$s2,%lo(g_MpSetup) -/* f17d80c: 2673c7b8 */ addiu $s3,$s3,%lo(g_Options) +/* f17d80c: 2673c7b8 */ addiu $s3,$s3,%lo(g_MpChrs) /* f17d810: 26d6c538 */ addiu $s6,$s6,%lo(g_MpSimulants) /* f17d814: 00008025 */ or $s0,$zero,$zero /* f17d818: 2417004c */ addiu $s7,$zero,0x4c @@ -7626,10 +7626,10 @@ glabel menuhandlerMpHumansVsSimulants /* f17d8e0: 14810028 */ bne $a0,$at,.L0f17d984 /* f17d8e4: afa60020 */ sw $a2,0x20($sp) /* f17d8e8: 3c09800b */ lui $t1,%hi(g_MpSimulants) -/* f17d8ec: 3c05800b */ lui $a1,%hi(g_Options) +/* f17d8ec: 3c05800b */ lui $a1,%hi(g_MpChrs) /* f17d8f0: 3c04800b */ lui $a0,%hi(g_MpSetup) /* f17d8f4: 2484cb88 */ addiu $a0,$a0,%lo(g_MpSetup) -/* f17d8f8: 24a5c7b8 */ addiu $a1,$a1,%lo(g_Options) +/* f17d8f8: 24a5c7b8 */ addiu $a1,$a1,%lo(g_MpChrs) /* f17d8fc: 2529c538 */ addiu $t1,$t1,%lo(g_MpSimulants) /* f17d900: 00001025 */ or $v0,$zero,$zero /* f17d904: 240a004c */ addiu $t2,$zero,0x4c @@ -7689,12 +7689,12 @@ glabel menuhandlerMpHumanSimulantPairs /* f17d9b8: 8dc10000 */ lw $at,0x0($t6) /* f17d9bc: 27a6002c */ addiu $a2,$sp,0x2c /* f17d9c0: 3c0b800b */ lui $t3,%hi(g_MpSimulants) -/* f17d9c4: 3c08800b */ lui $t0,%hi(g_Options) +/* f17d9c4: 3c08800b */ lui $t0,%hi(g_MpChrs) /* f17d9c8: 3c07800b */ lui $a3,%hi(g_MpSetup) /* f17d9cc: 00002825 */ or $a1,$zero,$zero /* f17d9d0: 00002025 */ or $a0,$zero,$zero /* f17d9d4: 24e7cb88 */ addiu $a3,$a3,%lo(g_MpSetup) -/* f17d9d8: 2508c7b8 */ addiu $t0,$t0,%lo(g_Options) +/* f17d9d8: 2508c7b8 */ addiu $t0,$t0,%lo(g_MpChrs) /* f17d9dc: 256bc538 */ addiu $t3,$t3,%lo(g_MpSimulants) /* f17d9e0: 00001025 */ or $v0,$zero,$zero /* f17d9e4: 240c004c */ addiu $t4,$zero,0x4c @@ -8185,12 +8185,12 @@ glabel menuhandler0017e06c /* f17e078: 8cc20000 */ lw $v0,0x0($a2) /* f17e07c: 24010012 */ addiu $at,$zero,0x12 /* f17e080: 1081003f */ beq $a0,$at,.L0f17e180 -/* f17e084: 3c098007 */ lui $t1,%hi(g_MenuStackDepth) +/* f17e084: 3c098007 */ lui $t1,%hi(g_MpPlayerNum) /* f17e088: 03e00008 */ jr $ra /* f17e08c: 00001025 */ or $v0,$zero,$zero .L0f17e090: -/* f17e090: 3c098007 */ lui $t1,%hi(g_MenuStackDepth) -/* f17e094: 25291448 */ addiu $t1,$t1,%lo(g_MenuStackDepth) +/* f17e090: 3c098007 */ lui $t1,%hi(g_MpPlayerNum) +/* f17e094: 25291448 */ addiu $t1,$t1,%lo(g_MpPlayerNum) /* f17e098: 8d2e0000 */ lw $t6,0x0($t1) /* f17e09c: 240a0e70 */ addiu $t2,$zero,0xe70 /* f17e0a0: 3c08800a */ lui $t0,%hi(var8009e000) @@ -8258,7 +8258,7 @@ glabel menuhandler0017e06c /* f17e184: 00001825 */ or $v1,$zero,$zero /* f17e188: 3c188007 */ lui $t8,0x8007 /* f17e18c: 11e0001d */ beqz $t7,.L0f17e204 -/* f17e190: 25291448 */ addiu $t1,$t1,%lo(g_MenuStackDepth) +/* f17e190: 25291448 */ addiu $t1,$t1,%lo(g_MpPlayerNum) /* f17e194: 8f181448 */ lw $t8,0x1448($t8) /* f17e198: 3c0d800a */ lui $t5,0x800a /* f17e19c: 00403021 */ addu $a2,$v0,$zero @@ -8343,7 +8343,7 @@ glabel func0f17e288 s32 menuhandlerMpTeamNameSlot(u32 operation, struct menu_item *item, s32 *value) { if (operation == MENUOP_SET) { - g_MenuStack[g_MenuStackDepth].slotindex = item->left - 0x5608; + g_MenuStack[g_MpPlayerNum].slotindex = item->param2 - 0x5608; menuPushDialog(&g_MpChangeTeamNameMenuDialog); } @@ -9074,8 +9074,8 @@ glabel menuhandlerMpLock /* f17edb4: 00000000 */ sll $zero,$zero,0x0 /* f17edb8: 00026080 */ sll $t4,$v0,0x2 /* f17edbc: 01826021 */ addu $t4,$t4,$v0 -/* f17edc0: 3c0d800b */ lui $t5,%hi(g_Options) -/* f17edc4: 25adc7b8 */ addiu $t5,$t5,%lo(g_Options) +/* f17edc0: 3c0d800b */ lui $t5,%hi(g_MpChrs) +/* f17edc4: 25adc7b8 */ addiu $t5,$t5,%lo(g_MpChrs) /* f17edc8: 000c6140 */ sll $t4,$t4,0x5 /* f17edcc: 10000020 */ beqz $zero,.L0f17ee50 /* f17edd0: 018d1021 */ addu $v0,$t4,$t5 @@ -9366,14 +9366,14 @@ glabel func0f17f100 /* f17f198: 3c04800b */ lui $a0,%hi(g_MpSetup) /* f17f19c: 2484cb88 */ addiu $a0,$a0,%lo(g_MpSetup) /* f17f1a0: 8c8a000c */ lw $t2,0xc($a0) -/* f17f1a4: 3c02800b */ lui $v0,%hi(g_Options) +/* f17f1a4: 3c02800b */ lui $v0,%hi(g_MpChrs) /* f17f1a8: 3c03800a */ lui $v1,%hi(g_Vars) /* f17f1ac: 354b0002 */ ori $t3,$t2,0x2 /* f17f1b0: ac8b000c */ sw $t3,0xc($a0) /* f17f1b4: 3c04800a */ lui $a0,0x800a /* f17f1b8: 24849fc4 */ addiu $a0,$a0,-24636 /* f17f1bc: 24639fc0 */ addiu $v1,$v1,%lo(g_Vars) -/* f17f1c0: 2442c7b8 */ addiu $v0,$v0,%lo(g_Options) +/* f17f1c0: 2442c7b8 */ addiu $v0,$v0,%lo(g_MpChrs) .L0f17f1c4: /* f17f1c4: 806c04ac */ lb $t4,0x4ac($v1) /* f17f1c8: 24630001 */ addiu $v1,$v1,0x1 @@ -9385,12 +9385,12 @@ glabel func0f17f100 /* f17f1e0: 3c04800b */ lui $a0,%hi(g_MpSetup) /* f17f1e4: 2484cb88 */ addiu $a0,$a0,%lo(g_MpSetup) /* f17f1e8: 8c8d000c */ lw $t5,0xc($a0) -/* f17f1ec: 3c02800b */ lui $v0,%hi(g_Options) +/* f17f1ec: 3c02800b */ lui $v0,%hi(g_MpChrs) /* f17f1f0: 3c03800b */ lui $v1,%hi(var800aca38) /* f17f1f4: 35ae0002 */ ori $t6,$t5,0x2 /* f17f1f8: ac8e000c */ sw $t6,0xc($a0) /* f17f1fc: 2463ca38 */ addiu $v1,$v1,%lo(var800aca38) -/* f17f200: 2442c7b8 */ addiu $v0,$v0,%lo(g_Options) +/* f17f200: 2442c7b8 */ addiu $v0,$v0,%lo(g_MpChrs) .L0f17f204: /* f17f204: 244200a0 */ addiu $v0,$v0,0xa0 /* f17f208: 1443fffe */ bne $v0,$v1,.L0f17f204 @@ -9400,8 +9400,8 @@ glabel func0f17f100 /* f17f218: 3c04800b */ lui $a0,%hi(g_MpSetup) /* f17f21c: 2484cb88 */ addiu $a0,$a0,%lo(g_MpSetup) /* f17f220: 8c8f000c */ lw $t7,0xc($a0) -/* f17f224: 3c02800b */ lui $v0,%hi(g_Options) -/* f17f228: 2442c7b8 */ addiu $v0,$v0,%lo(g_Options) +/* f17f224: 3c02800b */ lui $v0,%hi(g_MpChrs) +/* f17f228: 2442c7b8 */ addiu $v0,$v0,%lo(g_MpChrs) /* f17f22c: 35f80002 */ ori $t8,$t7,0x2 /* f17f230: ac98000c */ sw $t8,0xc($a0) /* f17f234: 00008025 */ or $s0,$zero,$zero @@ -11060,8 +11060,8 @@ glabel func0f180960 /* f180988: 13000033 */ beqz $t8,.L0f180a58 /* f18098c: 240d004c */ addiu $t5,$zero,0x4c /* f180990: 3c0c800b */ lui $t4,%hi(g_MpSimulants) -/* f180994: 3c0a800b */ lui $t2,%hi(g_Options) -/* f180998: 254ac7b8 */ addiu $t2,$t2,%lo(g_Options) +/* f180994: 3c0a800b */ lui $t2,%hi(g_MpChrs) +/* f180998: 254ac7b8 */ addiu $t2,$t2,%lo(g_MpChrs) /* f18099c: 258cc538 */ addiu $t4,$t4,%lo(g_MpSimulants) /* f1809a0: 240b00a0 */ addiu $t3,$zero,0xa0 /* f1809a4: 2409000c */ addiu $t1,$zero,0xc @@ -11330,8 +11330,8 @@ glabel func0f180c98 /* f180d38: 1443fffd */ bne $v0,$v1,.L0f180d30 /* f180d3c: a4450006 */ sh $a1,0x6($v0) /* f180d40: 3c15800b */ lui $s5,%hi(g_MpSimulants) -/* f180d44: 3c12800b */ lui $s2,%hi(g_Options) -/* f180d48: 2652c7b8 */ addiu $s2,$s2,%lo(g_Options) +/* f180d44: 3c12800b */ lui $s2,%hi(g_MpChrs) +/* f180d48: 2652c7b8 */ addiu $s2,$s2,%lo(g_MpChrs) /* f180d4c: 26b5c538 */ addiu $s5,$s5,%lo(g_MpSimulants) /* f180d50: 00008825 */ or $s1,$zero,$zero /* f180d54: 2416004c */ addiu $s6,$zero,0x4c @@ -11494,8 +11494,8 @@ glabel func0f180e34 /* f180f64: 00116080 */ sll $t4,$s1,0x2 /* f180f68: 00115080 */ sll $t2,$s1,0x2 /* f180f6c: 01515021 */ addu $t2,$t2,$s1 -/* f180f70: 3c0b800b */ lui $t3,%hi(g_Options) -/* f180f74: 256bc7b8 */ addiu $t3,$t3,%lo(g_Options) +/* f180f70: 3c0b800b */ lui $t3,%hi(g_MpChrs) +/* f180f74: 256bc7b8 */ addiu $t3,$t3,%lo(g_MpChrs) /* f180f78: 000a5140 */ sll $t2,$t2,0x5 /* f180f7c: 10000009 */ beqz $zero,.L0f180fa4 /* f180f80: 014b8021 */ addu $s0,$t2,$t3 @@ -11817,8 +11817,8 @@ glabel func0f1813d8 /* f181404: 33190400 */ andi $t9,$t8,0x400 /* f181408: 13200028 */ beqz $t9,.L0f1814ac /* f18140c: 3c0b800b */ lui $t3,%hi(g_MpSimulants) -/* f181410: 3c09800b */ lui $t1,%hi(g_Options) -/* f181414: 2529c7b8 */ addiu $t1,$t1,%lo(g_Options) +/* f181410: 3c09800b */ lui $t1,%hi(g_MpChrs) +/* f181414: 2529c7b8 */ addiu $t1,$t1,%lo(g_MpChrs) /* f181418: 256bc538 */ addiu $t3,$t3,%lo(g_MpSimulants) /* f18141c: 240a00a0 */ addiu $t2,$zero,0xa0 /* f181420: 2408000c */ addiu $t0,$zero,0xc @@ -13344,8 +13344,8 @@ glabel func0f182908 /* f18292c: 31f80400 */ andi $t8,$t7,0x400 /* f182930: 13000028 */ beqz $t8,.L0f1829d4 /* f182934: 3c0b800b */ lui $t3,%hi(g_MpSimulants) -/* f182938: 3c09800b */ lui $t1,%hi(g_Options) -/* f18293c: 2529c7b8 */ addiu $t1,$t1,%lo(g_Options) +/* f182938: 3c09800b */ lui $t1,%hi(g_MpChrs) +/* f18293c: 2529c7b8 */ addiu $t1,$t1,%lo(g_MpChrs) /* f182940: 256bc538 */ addiu $t3,$t3,%lo(g_MpSimulants) /* f182944: 240a00a0 */ addiu $t2,$zero,0xa0 /* f182948: 2408000c */ addiu $t0,$zero,0xc @@ -14706,8 +14706,8 @@ glabel func0f183bb4 /* f183c20: 11e00033 */ beqz $t7,.L0f183cf0 /* f183c24: 240a004c */ addiu $t2,$zero,0x4c /* f183c28: 3c09800b */ lui $t1,%hi(g_MpSimulants) -/* f183c2c: 3c07800b */ lui $a3,%hi(g_Options) -/* f183c30: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f183c2c: 3c07800b */ lui $a3,%hi(g_MpChrs) +/* f183c30: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f183c34: 2529c538 */ addiu $t1,$t1,%lo(g_MpSimulants) /* f183c38: 240800a0 */ addiu $t0,$zero,0xa0 /* f183c3c: 2405000c */ addiu $a1,$zero,0xc @@ -15902,8 +15902,8 @@ glabel func0f184c18 /* f184c94: 11800033 */ beqz $t4,.L0f184d64 /* f184c98: 240a004c */ addiu $t2,$zero,0x4c /* f184c9c: 3c09800b */ lui $t1,%hi(g_MpSimulants) -/* f184ca0: 3c07800b */ lui $a3,%hi(g_Options) -/* f184ca4: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f184ca0: 3c07800b */ lui $a3,%hi(g_MpChrs) +/* f184ca4: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f184ca8: 2529c538 */ addiu $t1,$t1,%lo(g_MpSimulants) /* f184cac: 240800a0 */ addiu $t0,$zero,0xa0 /* f184cb0: 2405000c */ addiu $a1,$zero,0xc @@ -17033,9 +17033,9 @@ glabel func0f185c14 /* f185c64: 8fbf001c */ lw $ra,0x1c($sp) .L0f185c68: /* f185c68: 3c09800b */ lui $t1,%hi(g_MpSimulants) -/* f185c6c: 3c07800b */ lui $a3,%hi(g_Options) +/* f185c6c: 3c07800b */ lui $a3,%hi(g_MpChrs) /* f185c70: acc00000 */ sw $zero,0x0($a2) -/* f185c74: 24e7c7b8 */ addiu $a3,$a3,%lo(g_Options) +/* f185c74: 24e7c7b8 */ addiu $a3,$a3,%lo(g_MpChrs) /* f185c78: 2529c538 */ addiu $t1,$t1,%lo(g_MpSimulants) /* f185c7c: 00001025 */ or $v0,$zero,$zero /* f185c80: 02001825 */ or $v1,$s0,$zero @@ -17867,8 +17867,8 @@ glabel func0f186780 /* f1867d8: 00034080 */ sll $t0,$v1,0x2 /* f1867dc: 0003c080 */ sll $t8,$v1,0x2 /* f1867e0: 0303c021 */ addu $t8,$t8,$v1 -/* f1867e4: 3c19800b */ lui $t9,%hi(g_Options) -/* f1867e8: 2739c7b8 */ addiu $t9,$t9,%lo(g_Options) +/* f1867e4: 3c19800b */ lui $t9,%hi(g_MpChrs) +/* f1867e8: 2739c7b8 */ addiu $t9,$t9,%lo(g_MpChrs) /* f1867ec: 0018c140 */ sll $t8,$t8,0x5 /* f1867f0: 10000009 */ beqz $zero,.L0f186818 /* f1867f4: 03192021 */ addu $a0,$t8,$t9 @@ -17887,8 +17887,8 @@ glabel func0f186780 /* f186820: 00026880 */ sll $t5,$v0,0x2 /* f186824: 00025880 */ sll $t3,$v0,0x2 /* f186828: 01625821 */ addu $t3,$t3,$v0 -/* f18682c: 3c0c800b */ lui $t4,%hi(g_Options) -/* f186830: 258cc7b8 */ addiu $t4,$t4,%lo(g_Options) +/* f18682c: 3c0c800b */ lui $t4,%hi(g_MpChrs) +/* f186830: 258cc7b8 */ addiu $t4,$t4,%lo(g_MpChrs) /* f186834: 000b5940 */ sll $t3,$t3,0x5 /* f186838: 10000009 */ beqz $zero,.L0f186860 /* f18683c: 016c1821 */ addu $v1,$t3,$t4 @@ -17967,8 +17967,8 @@ glabel func0f186898 /* f18693c: 26319fc0 */ addiu $s1,$s1,%lo(g_Vars) /* f186940: 8e39028c */ lw $t9,0x28c($s1) .L0f186944: -/* f186944: 3c0c800b */ lui $t4,%hi(g_Options) -/* f186948: 258cc7b8 */ addiu $t4,$t4,%lo(g_Options) +/* f186944: 3c0c800b */ lui $t4,%hi(g_MpChrs) +/* f186948: 258cc7b8 */ addiu $t4,$t4,%lo(g_MpChrs) /* f18694c: 001979c0 */ sll $t7,$t9,0x7 /* f186950: 022f5021 */ addu $t2,$s1,$t7 /* f186954: 8d4200e4 */ lw $v0,0xe4($t2) @@ -18143,8 +18143,8 @@ glabel func0f186898 /* f186bac: 8da302d4 */ lw $v1,0x2d4($t5) /* f186bb0: 8e2e028c */ lw $t6,0x28c($s1) .L0f186bb4: -/* f186bb4: 3c0a800b */ lui $t2,%hi(g_Options) -/* f186bb8: 254ac7b8 */ addiu $t2,$t2,%lo(g_Options) +/* f186bb4: 3c0a800b */ lui $t2,%hi(g_MpChrs) +/* f186bb8: 254ac7b8 */ addiu $t2,$t2,%lo(g_MpChrs) /* f186bbc: 000ec1c0 */ sll $t8,$t6,0x7 /* f186bc0: 0238c821 */ addu $t9,$s1,$t8 /* f186bc4: 8f2200e4 */ lw $v0,0xe4($t9) @@ -18767,8 +18767,8 @@ glabel func0f187410 /* f187478: 8e10c500 */ lw $s0,-0x3b00($s0) /* f18747c: 8d4d028c */ lw $t5,0x28c($t2) .L0f187480: -/* f187480: 3c19800b */ lui $t9,%hi(g_Options) -/* f187484: 2739c7b8 */ addiu $t9,$t9,%lo(g_Options) +/* f187480: 3c19800b */ lui $t9,%hi(g_MpChrs) +/* f187484: 2739c7b8 */ addiu $t9,$t9,%lo(g_MpChrs) /* f187488: 000d71c0 */ sll $t6,$t5,0x7 /* f18748c: 014e7821 */ addu $t7,$t2,$t6 /* f187490: 8de200e4 */ lw $v0,0xe4($t7) diff --git a/src/game/game_187770.c b/src/game/game_187770.c index 8ad8d3c78..d56e27336 100644 --- a/src/game/game_187770.c +++ b/src/game/game_187770.c @@ -412,10 +412,10 @@ glabel func0f187944 /* f1879d8: 0500008d */ bltz $t0,.L0f187c10 .L0f1879dc: /* f1879dc: 3c05800b */ lui $a1,%hi(var800acad8) -/* f1879e0: 3c06800b */ lui $a2,%hi(var800ac858) -/* f1879e4: 3c14800b */ lui $s4,%hi(g_Options) -/* f1879e8: 2694c7b8 */ addiu $s4,$s4,%lo(g_Options) -/* f1879ec: 24c6c858 */ addiu $a2,$a2,%lo(var800ac858) +/* f1879e0: 3c06800b */ lui $a2,0x800b +/* f1879e4: 3c14800b */ lui $s4,%hi(g_MpChrs) +/* f1879e8: 2694c7b8 */ addiu $s4,$s4,%lo(g_MpChrs) +/* f1879ec: 24c6c858 */ addiu $a2,$a2,-14248 /* f1879f0: 24a5cad8 */ addiu $a1,$a1,%lo(var800acad8) /* f1879f4: 24070002 */ addiu $a3,$zero,0x2 /* f1879f8: 00805825 */ or $t3,$a0,$zero @@ -567,8 +567,8 @@ glabel func0f187944 /* f187c08: 10000022 */ beqz $zero,.L0f187c94 /* f187c0c: ac670000 */ sw $a3,0x0($v1) .L0f187c10: -/* f187c10: 3c14800b */ lui $s4,%hi(g_Options) -/* f187c14: 2694c7b8 */ addiu $s4,$s4,%lo(g_Options) +/* f187c10: 3c14800b */ lui $s4,%hi(g_MpChrs) +/* f187c14: 2694c7b8 */ addiu $s4,$s4,%lo(g_MpChrs) /* f187c18: 00008025 */ or $s0,$zero,$zero /* f187c1c: 241300a0 */ addiu $s3,$zero,0xa0 .L0f187c20: @@ -836,8 +836,8 @@ GLOBAL_ASM( glabel func0f187fbc /* f187fbc: 00047080 */ sll $t6,$a0,0x2 /* f187fc0: 01c47021 */ addu $t6,$t6,$a0 -/* f187fc4: 3c0f800b */ lui $t7,%hi(g_Options) -/* f187fc8: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f187fc4: 3c0f800b */ lui $t7,%hi(g_MpChrs) +/* f187fc8: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f187fcc: 000e7140 */ sll $t6,$t6,0x5 /* f187fd0: 01cf1021 */ addu $v0,$t6,$t7 /* f187fd4: 24030050 */ addiu $v1,$zero,0x50 @@ -874,8 +874,8 @@ glabel func0f18800c /* f188030: afb00018 */ sw $s0,0x18($sp) /* f188034: 00137080 */ sll $t6,$s3,0x2 /* f188038: 01d37021 */ addu $t6,$t6,$s3 -/* f18803c: 3c0f800b */ lui $t7,%hi(g_Options) -/* f188040: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f18803c: 3c0f800b */ lui $t7,%hi(g_MpChrs) +/* f188040: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f188044: 000e7140 */ sll $t6,$t6,0x5 /* f188048: 01cf8021 */ addu $s0,$t6,$t7 /* f18804c: 241807ee */ addiu $t8,$zero,0x7ee @@ -968,8 +968,8 @@ glabel func0f18800c .L0f188184: /* f188184: 00136880 */ sll $t5,$s3,0x2 /* f188188: 01b36821 */ addu $t5,$t5,$s3 -/* f18818c: 3c0e800b */ lui $t6,%hi(g_Options) -/* f188190: 25cec7b8 */ addiu $t6,$t6,%lo(g_Options) +/* f18818c: 3c0e800b */ lui $t6,%hi(g_MpChrs) +/* f188190: 25cec7b8 */ addiu $t6,$t6,%lo(g_MpChrs) /* f188194: 000d6940 */ sll $t5,$t5,0x5 /* f188198: 01ae1021 */ addu $v0,$t5,$t6 /* f18819c: 00008825 */ or $s1,$zero,$zero @@ -1081,10 +1081,10 @@ glabel func0f188210 /* f188310: a0430003 */ sb $v1,0x3($v0) /* f188314: 0fc66fe8 */ jal func0f19bfa0 /* f188318: ac430004 */ sw $v1,0x4($v0) -/* f18831c: 3c05800b */ lui $a1,%hi(g_Options) +/* f18831c: 3c05800b */ lui $a1,%hi(g_MpChrs) /* f188320: 3c06800b */ lui $a2,%hi(var800acb78) /* f188324: 24c6cb78 */ addiu $a2,$a2,%lo(var800acb78) -/* f188328: 24a5c7b8 */ addiu $a1,$a1,%lo(g_Options) +/* f188328: 24a5c7b8 */ addiu $a1,$a1,%lo(g_MpChrs) /* f18832c: 24040006 */ addiu $a0,$zero,0x6 /* f188330: 00001025 */ or $v0,$zero,$zero .L0f188334: @@ -1140,10 +1140,10 @@ glabel func0f18836c /* f1883d8: 2a010008 */ slti $at,$s0,0x8 /* f1883dc: 1420fff5 */ bnez $at,.L0f1883b4 /* f1883e0: 2631000c */ addiu $s1,$s1,0xc -/* f1883e4: 3c11800b */ lui $s1,%hi(g_Options) +/* f1883e4: 3c11800b */ lui $s1,%hi(g_MpChrs) /* f1883e8: 3c127f1c */ lui $s2,0x7f1c /* f1883ec: 26528a50 */ addiu $s2,$s2,-30128 -/* f1883f0: 2631c7b8 */ addiu $s1,$s1,%lo(g_Options) +/* f1883f0: 2631c7b8 */ addiu $s1,$s1,%lo(g_MpChrs) /* f1883f4: 00008025 */ or $s0,$zero,$zero /* f1883f8: 24130004 */ addiu $s3,$zero,0x4 .L0f1883fc: @@ -1329,8 +1329,8 @@ glabel func0f1885e4 /* f188654: 00001825 */ or $v1,$zero,$zero /* f188658: 0011c880 */ sll $t9,$s1,0x2 /* f18865c: 0331c821 */ addu $t9,$t9,$s1 -/* f188660: 3c18800b */ lui $t8,%hi(g_Options) -/* f188664: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f188660: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f188664: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f188668: 0019c940 */ sll $t9,$t9,0x5 /* f18866c: 1000000a */ beqz $zero,.L0f188698 /* f188670: 03389021 */ addu $s2,$t9,$t8 @@ -1542,14 +1542,14 @@ glabel func0f188930 /* f188950: afb1001c */ sw $s1,0x1c($sp) /* f188954: afb00018 */ sw $s0,0x18($sp) /* f188958: 3c14800b */ lui $s4,%hi(g_MpSetup) -/* f18895c: 3c15800b */ lui $s5,%hi(g_Options) +/* f18895c: 3c15800b */ lui $s5,%hi(g_MpChrs) /* f188960: 00809825 */ or $s3,$a0,$zero /* f188964: afbf003c */ sw $ra,0x3c($sp) /* f188968: afa50064 */ sw $a1,0x64($sp) /* f18896c: 00008825 */ or $s1,$zero,$zero /* f188970: 00009025 */ or $s2,$zero,$zero /* f188974: afa00050 */ sw $zero,0x50($sp) -/* f188978: 26b5c7b8 */ addiu $s5,$s5,%lo(g_Options) +/* f188978: 26b5c7b8 */ addiu $s5,$s5,%lo(g_MpChrs) /* f18897c: 2694cb88 */ addiu $s4,$s4,%lo(g_MpSetup) /* f188980: 00008025 */ or $s0,$zero,$zero /* f188984: 241600a0 */ addiu $s6,$zero,0xa0 @@ -3697,9 +3697,9 @@ glabel func0f18a56c /* f18a680: 25cf0001 */ addiu $t7,$t6,0x1 /* f18a684: 448f2000 */ mtc1 $t7,$f4 /* f18a688: 3c14800a */ lui $s4,%hi(g_Vars) -/* f18a68c: 3c1e800b */ lui $s8,%hi(g_Options) +/* f18a68c: 3c1e800b */ lui $s8,%hi(g_MpChrs) /* f18a690: 468021a0 */ cvt.s.w $f6,$f4 -/* f18a694: 27dec7b8 */ addiu $s8,$s8,%lo(g_Options) +/* f18a694: 27dec7b8 */ addiu $s8,$s8,%lo(g_MpChrs) /* f18a698: 26949fc0 */ addiu $s4,$s4,%lo(g_Vars) /* f18a69c: 27b301fc */ addiu $s3,$sp,0x1fc /* f18a6a0: 2417000c */ addiu $s7,$zero,0xc @@ -4284,8 +4284,8 @@ glabel func0f18a56c /* f18aef8: 16cffdec */ bne $s6,$t7,.L0f18a6ac /* f18aefc: 26940080 */ addiu $s4,$s4,0x80 .L0f18af00: -/* f18af00: 3c1e800b */ lui $s8,%hi(g_Options) -/* f18af04: 27dec7b8 */ addiu $s8,$s8,%lo(g_Options) +/* f18af00: 3c1e800b */ lui $s8,%hi(g_MpChrs) +/* f18af04: 27dec7b8 */ addiu $s8,$s8,%lo(g_MpChrs) /* f18af08: 2417000c */ addiu $s7,$zero,0xc /* f18af0c: 0fc4a24b */ jal setCurrentPlayerNum /* f18af10: 8fa402f0 */ lw $a0,0x2f0($sp) @@ -5365,7 +5365,7 @@ glabel func0f18bc9c /* f18bda0: afb6002c */ sw $s6,0x2c($sp) /* f18bda4: afb40024 */ sw $s4,0x24($sp) /* f18bda8: afb30020 */ sw $s3,0x20($sp) -/* f18bdac: 3c12800b */ lui $s2,%hi(g_Options) +/* f18bdac: 3c12800b */ lui $s2,%hi(g_MpChrs) /* f18bdb0: 3c15800b */ lui $s5,%hi(g_MpSimulants) /* f18bdb4: afbf0034 */ sw $ra,0x34($sp) /* f18bdb8: afb10018 */ sw $s1,0x18($sp) @@ -5373,7 +5373,7 @@ glabel func0f18bc9c /* f18bdc0: afa40038 */ sw $a0,0x38($sp) /* f18bdc4: afa5003c */ sw $a1,0x3c($sp) /* f18bdc8: 26b5c538 */ addiu $s5,$s5,%lo(g_MpSimulants) -/* f18bdcc: 2652c7b8 */ addiu $s2,$s2,%lo(g_Options) +/* f18bdcc: 2652c7b8 */ addiu $s2,$s2,%lo(g_MpChrs) /* f18bdd0: 241300a0 */ addiu $s3,$zero,0xa0 /* f18bdd4: 2414000c */ addiu $s4,$zero,0xc /* f18bdd8: 2416004c */ addiu $s6,$zero,0x4c @@ -6174,8 +6174,8 @@ glabel func0f18c794 /* f18c7cc: 00054880 */ sll $t1,$a1,0x2 /* f18c7d0: 0005c880 */ sll $t9,$a1,0x2 /* f18c7d4: 0325c821 */ addu $t9,$t9,$a1 -/* f18c7d8: 3c08800b */ lui $t0,%hi(g_Options) -/* f18c7dc: 2508c7b8 */ addiu $t0,$t0,%lo(g_Options) +/* f18c7d8: 3c08800b */ lui $t0,%hi(g_MpChrs) +/* f18c7dc: 2508c7b8 */ addiu $t0,$t0,%lo(g_MpChrs) /* f18c7e0: 0019c940 */ sll $t9,$t9,0x5 /* f18c7e4: 03e00008 */ jr $ra /* f18c7e8: 03281021 */ addu $v0,$t9,$t0 @@ -6252,9 +6252,9 @@ GLOBAL_ASM( glabel func0f18c8b8 /* f18c8b8: 3c05800b */ lui $a1,0x800b /* f18c8bc: 3c0b800b */ lui $t3,%hi(g_MpSimulants) -/* f18c8c0: 3c08800b */ lui $t0,%hi(g_Options) +/* f18c8c0: 3c08800b */ lui $t0,%hi(g_MpChrs) /* f18c8c4: 00001825 */ or $v1,$zero,$zero -/* f18c8c8: 2508c7b8 */ addiu $t0,$t0,%lo(g_Options) +/* f18c8c8: 2508c7b8 */ addiu $t0,$t0,%lo(g_MpChrs) /* f18c8cc: 256bc538 */ addiu $t3,$t3,%lo(g_MpSimulants) /* f18c8d0: 94a5cb9e */ lhu $a1,-0x3462($a1) /* f18c8d4: 240c004c */ addiu $t4,$zero,0x4c @@ -6373,10 +6373,10 @@ glabel func0f18c984 /* f18ca60: 0c004c4c */ jal strcpy /* f18ca64: afa70040 */ sw $a3,0x40($sp) /* f18ca68: a3d10011 */ sb $s1,0x11($s8) -/* f18ca6c: 3c11800b */ lui $s1,%hi(g_Options) +/* f18ca6c: 3c11800b */ lui $s1,%hi(g_MpChrs) /* f18ca70: 3c168008 */ lui $s6,%hi(table_0x2d678) /* f18ca74: 26d67658 */ addiu $s6,$s6,%lo(table_0x2d678) -/* f18ca78: 2631c7b8 */ addiu $s1,$s1,%lo(g_Options) +/* f18ca78: 2631c7b8 */ addiu $s1,$s1,%lo(g_MpChrs) /* f18ca7c: 24170035 */ addiu $s7,$zero,0x35 /* f18ca80: 2413000c */ addiu $s3,$zero,0xc /* f18ca84: 241200a0 */ addiu $s2,$zero,0xa0 @@ -6846,8 +6846,8 @@ glabel func0f18d074 /* f18d074: 00047080 */ sll $t6,$a0,0x2 /* f18d078: 3c05800b */ lui $a1,0x800b /* f18d07c: 00ae2821 */ addu $a1,$a1,$t6 -/* f18d080: 3c02800b */ lui $v0,%hi(g_Options) -/* f18d084: 2442c7b8 */ addiu $v0,$v0,%lo(g_Options) +/* f18d080: 3c02800b */ lui $v0,%hi(g_MpChrs) +/* f18d084: 2442c7b8 */ addiu $v0,$v0,%lo(g_MpChrs) /* f18d088: 8ca5c500 */ lw $a1,-0x3b00($a1) /* f18d08c: 00001825 */ or $v1,$zero,$zero .L0f18d090: @@ -6891,8 +6891,8 @@ glabel func0f18d0e8 /* f18d108: 00001825 */ or $v1,$zero,$zero /* f18d10c: 00047080 */ sll $t6,$a0,0x2 /* f18d110: 01c47021 */ addu $t6,$t6,$a0 -/* f18d114: 3c0f800b */ lui $t7,%hi(g_Options) -/* f18d118: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f18d114: 3c0f800b */ lui $t7,%hi(g_MpChrs) +/* f18d118: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f18d11c: 000e7140 */ sll $t6,$t6,0x5 /* f18d120: 01cf3021 */ addu $a2,$t6,$t7 .L0f18d124: @@ -6946,12 +6946,12 @@ glabel func0f18d1b8 /* f18d1b8: 27bdffd8 */ addiu $sp,$sp,-40 /* f18d1bc: 00057080 */ sll $t6,$a1,0x2 /* f18d1c0: 01c57021 */ addu $t6,$t6,$a1 -/* f18d1c4: 3c0f800b */ lui $t7,%hi(g_Options) +/* f18d1c4: 3c0f800b */ lui $t7,%hi(g_MpChrs) /* f18d1c8: afb30020 */ sw $s3,0x20($sp) /* f18d1cc: afb2001c */ sw $s2,0x1c($sp) /* f18d1d0: afb10018 */ sw $s1,0x18($sp) /* f18d1d4: afb00014 */ sw $s0,0x14($sp) -/* f18d1d8: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f18d1d8: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f18d1dc: 000e7140 */ sll $t6,$t6,0x5 /* f18d1e0: 00809025 */ or $s2,$a0,$zero /* f18d1e4: afbf0024 */ sw $ra,0x24($sp) @@ -6984,12 +6984,12 @@ glabel func0f18d238 /* f18d238: 27bdffd8 */ addiu $sp,$sp,-40 /* f18d23c: 00057080 */ sll $t6,$a1,0x2 /* f18d240: 01c57021 */ addu $t6,$t6,$a1 -/* f18d244: 3c0f800b */ lui $t7,%hi(g_Options) +/* f18d244: 3c0f800b */ lui $t7,%hi(g_MpChrs) /* f18d248: afb30020 */ sw $s3,0x20($sp) /* f18d24c: afb2001c */ sw $s2,0x1c($sp) /* f18d250: afb10018 */ sw $s1,0x18($sp) /* f18d254: afb00014 */ sw $s0,0x14($sp) -/* f18d258: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f18d258: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f18d25c: 000e7140 */ sll $t6,$t6,0x5 /* f18d260: 00809025 */ or $s2,$a0,$zero /* f18d264: afbf0024 */ sw $ra,0x24($sp) @@ -7024,11 +7024,11 @@ glabel func0f18d2b8 /* f18d2c0: 0080a025 */ or $s4,$a0,$zero /* f18d2c4: 00147080 */ sll $t6,$s4,0x2 /* f18d2c8: 01d47021 */ addu $t6,$t6,$s4 -/* f18d2cc: 3c0f800b */ lui $t7,%hi(g_Options) +/* f18d2cc: 3c0f800b */ lui $t7,%hi(g_MpChrs) /* f18d2d0: afb50028 */ sw $s5,0x28($sp) /* f18d2d4: afb30020 */ sw $s3,0x20($sp) /* f18d2d8: afb00014 */ sw $s0,0x14($sp) -/* f18d2dc: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f18d2dc: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f18d2e0: 000e7140 */ sll $t6,$t6,0x5 /* f18d2e4: 00c08025 */ or $s0,$a2,$zero /* f18d2e8: 00a09825 */ or $s3,$a1,$zero @@ -7229,10 +7229,10 @@ glabel func0f18d5c4 /* f18d5cc: 0080a025 */ or $s4,$a0,$zero /* f18d5d0: 00147080 */ sll $t6,$s4,0x2 /* f18d5d4: 01d47021 */ addu $t6,$t6,$s4 -/* f18d5d8: 3c0f800b */ lui $t7,%hi(g_Options) +/* f18d5d8: 3c0f800b */ lui $t7,%hi(g_MpChrs) /* f18d5dc: afb30024 */ sw $s3,0x24($sp) /* f18d5e0: afb00018 */ sw $s0,0x18($sp) -/* f18d5e4: 25efc7b8 */ addiu $t7,$t7,%lo(g_Options) +/* f18d5e4: 25efc7b8 */ addiu $t7,$t7,%lo(g_MpChrs) /* f18d5e8: 000e7140 */ sll $t6,$t6,0x5 /* f18d5ec: 00a09825 */ or $s3,$a1,$zero /* f18d5f0: afbf002c */ sw $ra,0x2c($sp) @@ -7550,13 +7550,13 @@ glabel func0f18d9fc /* f18da60: 1440000e */ bnez $v0,.L0f18da9c /* f18da64: 00401825 */ or $v1,$v0,$zero /* f18da68: 8fb90108 */ lw $t9,0x108($sp) -/* f18da6c: 3c09800b */ lui $t1,%hi(g_Options) +/* f18da6c: 3c09800b */ lui $t1,%hi(g_MpChrs) /* f18da70: 8faa0100 */ lw $t2,0x100($sp) /* f18da74: 00194080 */ sll $t0,$t9,0x2 /* f18da78: 01194021 */ addu $t0,$t0,$t9 /* f18da7c: 97ab0116 */ lhu $t3,0x116($sp) /* f18da80: 00084140 */ sll $t0,$t0,0x5 -/* f18da84: 2529c7b8 */ addiu $t1,$t1,%lo(g_Options) +/* f18da84: 2529c7b8 */ addiu $t1,$t1,%lo(g_MpChrs) /* f18da88: 01091821 */ addu $v1,$t0,$t1 /* f18da8c: 00001025 */ or $v0,$zero,$zero /* f18da90: ac6a004c */ sw $t2,0x4c($v1) @@ -7595,8 +7595,8 @@ glabel func0f18dac0 /* f18daf8: 14400017 */ bnez $v0,.L0f18db58 /* f18dafc: 00401825 */ or $v1,$v0,$zero /* f18db00: 8fa40100 */ lw $a0,0x100($sp) -/* f18db04: 3c18800b */ lui $t8,%hi(g_Options) -/* f18db08: 2718c7b8 */ addiu $t8,$t8,%lo(g_Options) +/* f18db04: 3c18800b */ lui $t8,%hi(g_MpChrs) +/* f18db08: 2718c7b8 */ addiu $t8,$t8,%lo(g_MpChrs) /* f18db0c: 00047880 */ sll $t7,$a0,0x2 /* f18db10: 01e47821 */ addu $t7,$t7,$a0 /* f18db14: 000f7940 */ sll $t7,$t7,0x5 @@ -8037,11 +8037,11 @@ glabel func0f18df5c /* f18e104: 02602025 */ or $a0,$s3,$zero /* f18e108: 0fc354fe */ jal func0f0d53f8 /* f18e10c: 24050009 */ addiu $a1,$zero,0x9 -/* f18e110: 3c10800b */ lui $s0,%hi(g_Options) +/* f18e110: 3c10800b */ lui $s0,%hi(g_MpChrs) /* f18e114: 3c11800b */ lui $s1,%hi(var800aca38) /* f18e118: a6a20014 */ sh $v0,0x14($s5) /* f18e11c: 2631ca38 */ addiu $s1,$s1,%lo(var800aca38) -/* f18e120: 2610c7b8 */ addiu $s0,$s0,%lo(g_Options) +/* f18e120: 2610c7b8 */ addiu $s0,$s0,%lo(g_MpChrs) .L0f18e124: /* f18e124: 02602025 */ or $a0,$s3,$zero /* f18e128: 0fc354fe */ jal func0f0d53f8 @@ -8196,10 +8196,10 @@ glabel func0f18e16c /* f18e348: 96650014 */ lhu $a1,0x14($s3) /* f18e34c: 0fc354be */ jal func0f0d52f8 /* f18e350: 24060009 */ addiu $a2,$zero,0x9 -/* f18e354: 3c10800b */ lui $s0,%hi(g_Options) +/* f18e354: 3c10800b */ lui $s0,%hi(g_MpChrs) /* f18e358: 3c11800b */ lui $s1,%hi(var800aca38) /* f18e35c: 2631ca38 */ addiu $s1,$s1,%lo(var800aca38) -/* f18e360: 2610c7b8 */ addiu $s0,$s0,%lo(g_Options) +/* f18e360: 2610c7b8 */ addiu $s0,$s0,%lo(g_MpChrs) /* f18e364: 02402025 */ or $a0,$s2,$zero .L0f18e368: /* f18e368: 92050011 */ lbu $a1,0x11($s0) @@ -15465,10 +15465,10 @@ glabel func0f194990 /* f194a34: 1940002b */ blez $t2,.L0f194ae4 /* f194a38: 2417004c */ addiu $s7,$zero,0x4c /* f194a3c: 3c16800b */ lui $s6,%hi(g_MpSimulants) -/* f194a40: 3c14800b */ lui $s4,%hi(g_Options) +/* f194a40: 3c14800b */ lui $s4,%hi(g_MpChrs) /* f194a44: 3c13800b */ lui $s3,%hi(var800ac110) /* f194a48: 2673c110 */ addiu $s3,$s3,%lo(var800ac110) -/* f194a4c: 2694c7b8 */ addiu $s4,$s4,%lo(g_Options) +/* f194a4c: 2694c7b8 */ addiu $s4,$s4,%lo(g_MpChrs) /* f194a50: 26d6c538 */ addiu $s6,$s6,%lo(g_MpSimulants) /* f194a54: 241500a0 */ addiu $s5,$zero,0xa0 /* f194a58: 8e2b0000 */ lw $t3,0x0($s1) diff --git a/src/game/game_1999b0.c b/src/game/game_1999b0.c index cfdf69807..d6cc8f2ad 100644 --- a/src/game/game_1999b0.c +++ b/src/game/game_1999b0.c @@ -2081,9 +2081,9 @@ glabel func0f19b540 /* f19b550: 15c10038 */ bne $t6,$at,.L0f19b634 /* f19b554: afbf0014 */ sw $ra,0x14($sp) /* f19b558: 3c07800b */ lui $a3,0x800b -/* f19b55c: 3c03800b */ lui $v1,%hi(g_Options) +/* f19b55c: 3c03800b */ lui $v1,%hi(g_MpChrs) /* f19b560: 00002825 */ or $a1,$zero,$zero -/* f19b564: 2463c7b8 */ addiu $v1,$v1,%lo(g_Options) +/* f19b564: 2463c7b8 */ addiu $v1,$v1,%lo(g_MpChrs) /* f19b568: 94e7cb9e */ lhu $a3,-0x3462($a3) /* f19b56c: 00001025 */ or $v0,$zero,$zero /* f19b570: 24060080 */ addiu $a2,$zero,0x80 @@ -3023,10 +3023,10 @@ glabel func0f19c1cc /* f19c1e8: 24040005 */ addiu $a0,$zero,0x5 /* f19c1ec: 0fc62fdc */ jal func0f18bf70 /* f19c1f0: 24050005 */ addiu $a1,$zero,0x5 -/* f19c1f4: 3c03800b */ lui $v1,%hi(g_Options) +/* f19c1f4: 3c03800b */ lui $v1,%hi(g_MpChrs) /* f19c1f8: 3c02800b */ lui $v0,%hi(var800aca38) /* f19c1fc: 2442ca38 */ addiu $v0,$v0,%lo(var800aca38) -/* f19c200: 2463c7b8 */ addiu $v1,$v1,%lo(g_Options) +/* f19c200: 2463c7b8 */ addiu $v1,$v1,%lo(g_MpChrs) .L0f19c204: /* f19c204: 246300a0 */ addiu $v1,$v1,0xa0 /* f19c208: 1462fffe */ bne $v1,$v0,.L0f19c204 diff --git a/src/game/pdoptions.c b/src/game/pdoptions.c index 1640f46f6..6aa029161 100644 --- a/src/game/pdoptions.c +++ b/src/game/pdoptions.c @@ -7,79 +7,79 @@ #include "types.h" #include "game/game_16cfa0.h" -s32 optionsGetControlMode(s32 optionsindex) +s32 optionsGetControlMode(s32 mpchrnum) { - return g_Options[optionsindex].controlmode; + return g_MpChrs[mpchrnum].controlmode; } -void optionsSetControlMode(s32 optionsindex, s32 mode) +void optionsSetControlMode(s32 mpchrnum, s32 mode) { - g_Options[optionsindex].controlmode = mode; + g_MpChrs[mpchrnum].controlmode = mode; } -s32 optionsGetUnk45(s32 optionsindex) +s32 optionsGetUnk45(s32 mpchrnum) { - return g_Options[optionsindex].unk45; + return g_MpChrs[mpchrnum].unk45; } -s32 optionsGetUnk46(s32 optionsindex) +s32 optionsGetUnk46(s32 mpchrnum) { - return g_Options[optionsindex].unk46; + return g_MpChrs[mpchrnum].unk46; } -s32 optionsGetForwardPitch(s32 optionsindex) +s32 optionsGetForwardPitch(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_FORWARDPITCH) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_FORWARDPITCH) != 0; } -s32 optionsGetAutoAim(s32 optionsindex) +s32 optionsGetAutoAim(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_AUTOAIM) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_AUTOAIM) != 0; } -s32 optionsGetLookAhead(s32 optionsindex) +s32 optionsGetLookAhead(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_LOOKAHEAD) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_LOOKAHEAD) != 0; } -s32 optionsGetAimControl(s32 optionsindex) +s32 optionsGetAimControl(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_AIMCONTROL) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_AIMCONTROL) != 0; } -s32 optionsGetSightOnScreen(s32 optionsindex) +s32 optionsGetSightOnScreen(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_SIGHTONSCREEN) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_SIGHTONSCREEN) != 0; } -s32 optionsGetAmmoOnScreen(s32 optionsindex) +s32 optionsGetAmmoOnScreen(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_AMMOONSCREEN) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_AMMOONSCREEN) != 0; } -s32 optionsGetShowGunFunction(s32 optionsindex) +s32 optionsGetShowGunFunction(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_SHOWGUNFUNCTION) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_SHOWGUNFUNCTION) != 0; } -s32 optionsGetAlwaysShowTarget(s32 optionsindex) +s32 optionsGetAlwaysShowTarget(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_ALWAYSSHOWTARGET) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_ALWAYSSHOWTARGET) != 0; } -s32 optionsGetShowZoomRange(s32 optionsindex) +s32 optionsGetShowZoomRange(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_SHOWZOOMRANGE) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_SHOWZOOMRANGE) != 0; } -s32 optionsGetPaintball(s32 optionsindex) +s32 optionsGetPaintball(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_PAINTBALL) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_PAINTBALL) != 0; } -s32 optionsGetShowMissionTime(s32 optionsindex) +s32 optionsGetShowMissionTime(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_SHOWMISSIONTIME) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_SHOWMISSIONTIME) != 0; } u8 optionsGetInGameSubtitles(void) @@ -92,107 +92,107 @@ u8 optionsGetCutsceneSubtitles(void) return g_CutsceneSubtitles; } -s32 optionsGetHeadRoll(s32 optionsindex) +s32 optionsGetHeadRoll(s32 mpchrnum) { - return (g_Options[optionsindex].booleans & OPTION_HEADROLL) != 0; + return (g_MpChrs[mpchrnum].options & OPTION_HEADROLL) != 0; } -void optionsSetForwardPitch(s32 optionsindex, bool enable) +void optionsSetForwardPitch(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_FORWARDPITCH; + g_MpChrs[mpchrnum].options |= OPTION_FORWARDPITCH; } else { - g_Options[optionsindex].booleans &= ~OPTION_FORWARDPITCH; + g_MpChrs[mpchrnum].options &= ~OPTION_FORWARDPITCH; } } -void optionsSetAutoAim(s32 optionsindex, bool enable) +void optionsSetAutoAim(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_AUTOAIM; + g_MpChrs[mpchrnum].options |= OPTION_AUTOAIM; } else { - g_Options[optionsindex].booleans &= ~OPTION_AUTOAIM; + g_MpChrs[mpchrnum].options &= ~OPTION_AUTOAIM; } } -void optionsSetLookAhead(s32 optionsindex, bool enable) +void optionsSetLookAhead(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_LOOKAHEAD; + g_MpChrs[mpchrnum].options |= OPTION_LOOKAHEAD; } else { - g_Options[optionsindex].booleans &= ~OPTION_LOOKAHEAD; + g_MpChrs[mpchrnum].options &= ~OPTION_LOOKAHEAD; } } -void optionsSetAimControl(s32 optionsindex, s32 index) +void optionsSetAimControl(s32 mpchrnum, s32 index) { if (index) { - g_Options[optionsindex].booleans |= OPTION_AIMCONTROL; + g_MpChrs[mpchrnum].options |= OPTION_AIMCONTROL; } else { - g_Options[optionsindex].booleans &= ~OPTION_AIMCONTROL; + g_MpChrs[mpchrnum].options &= ~OPTION_AIMCONTROL; } } -void optionsSetSightOnScreen(s32 optionsindex, bool enable) +void optionsSetSightOnScreen(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_SIGHTONSCREEN; + g_MpChrs[mpchrnum].options |= OPTION_SIGHTONSCREEN; } else { - g_Options[optionsindex].booleans &= ~OPTION_SIGHTONSCREEN; + g_MpChrs[mpchrnum].options &= ~OPTION_SIGHTONSCREEN; } } -void optionsSetAmmoOnScreen(s32 optionsindex, bool enable) +void optionsSetAmmoOnScreen(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_AMMOONSCREEN; + g_MpChrs[mpchrnum].options |= OPTION_AMMOONSCREEN; } else { - g_Options[optionsindex].booleans &= ~OPTION_AMMOONSCREEN; + g_MpChrs[mpchrnum].options &= ~OPTION_AMMOONSCREEN; } } -void optionsSetShowGunFunction(s32 optionsindex, bool enable) +void optionsSetShowGunFunction(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_SHOWGUNFUNCTION; + g_MpChrs[mpchrnum].options |= OPTION_SHOWGUNFUNCTION; } else { - g_Options[optionsindex].booleans &= ~OPTION_SHOWGUNFUNCTION; + g_MpChrs[mpchrnum].options &= ~OPTION_SHOWGUNFUNCTION; } } -void optionsSetAlwaysShowTarget(s32 optionsindex, bool enable) +void optionsSetAlwaysShowTarget(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_ALWAYSSHOWTARGET; + g_MpChrs[mpchrnum].options |= OPTION_ALWAYSSHOWTARGET; } else { - g_Options[optionsindex].booleans &= ~OPTION_ALWAYSSHOWTARGET; + g_MpChrs[mpchrnum].options &= ~OPTION_ALWAYSSHOWTARGET; } } -void optionsSetShowZoomRange(s32 optionsindex, bool enable) +void optionsSetShowZoomRange(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_SHOWZOOMRANGE; + g_MpChrs[mpchrnum].options |= OPTION_SHOWZOOMRANGE; } else { - g_Options[optionsindex].booleans &= ~OPTION_SHOWZOOMRANGE; + g_MpChrs[mpchrnum].options &= ~OPTION_SHOWZOOMRANGE; } } -void optionsSetPaintball(s32 optionsindex, bool enable) +void optionsSetPaintball(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_PAINTBALL; + g_MpChrs[mpchrnum].options |= OPTION_PAINTBALL; } else { - g_Options[optionsindex].booleans &= ~OPTION_PAINTBALL; + g_MpChrs[mpchrnum].options &= ~OPTION_PAINTBALL; } } -void optionsSetShowMissionTime(s32 optionsindex, bool enable) +void optionsSetShowMissionTime(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_SHOWMISSIONTIME; + g_MpChrs[mpchrnum].options |= OPTION_SHOWMISSIONTIME; } else { - g_Options[optionsindex].booleans &= ~OPTION_SHOWMISSIONTIME; + g_MpChrs[mpchrnum].options &= ~OPTION_SHOWMISSIONTIME; } } @@ -206,12 +206,12 @@ void optionsSetCutsceneSubtitles(s32 enable) g_CutsceneSubtitles = enable; } -void optionsSetHeadRoll(s32 optionsindex, bool enable) +void optionsSetHeadRoll(s32 mpchrnum, bool enable) { if (enable) { - g_Options[optionsindex].booleans |= OPTION_HEADROLL; + g_MpChrs[mpchrnum].options |= OPTION_HEADROLL; } else { - g_Options[optionsindex].booleans &= ~OPTION_HEADROLL; + g_MpChrs[mpchrnum].options &= ~OPTION_HEADROLL; } } @@ -222,17 +222,17 @@ s32 optionsGetEffectiveScreenSize(void) } if (var800a19c4 == 13) { - g_MenuStackDepth = 0; + g_MpPlayerNum = 0; - if (g_MenuStack[g_MenuStackDepth].unk00 && var8009dfc0) { + if (g_MenuStack[g_MpPlayerNum].unk00 && var8009dfc0) { return SCREENSIZE_FULL; } } - if (g_MenuStack[g_MenuStackDepth].unk00 && ( - g_MenuStack[g_MenuStackDepth].unk00->dialog == &menudialog_control4 || - g_MenuStack[g_MenuStackDepth].unk00->dialog == &menudialog_control3 || - g_MenuStack[g_MenuStackDepth].unk00->dialog == &g_ControlStyleSingleMenuDialog)) { + if (g_MenuStack[g_MpPlayerNum].unk00 && ( + g_MenuStack[g_MpPlayerNum].unk00->dialog == &menudialog_control4 || + g_MenuStack[g_MpPlayerNum].unk00->dialog == &menudialog_control3 || + g_MenuStack[g_MpPlayerNum].unk00->dialog == &g_ControlStyleSingleMenuDialog)) { return SCREENSIZE_FULL; } diff --git a/src/gvars/gvars.c b/src/gvars/gvars.c index 2b93622ed..46b58cf3c 100644 --- a/src/gvars/gvars.c +++ b/src/gvars/gvars.c @@ -30645,127 +30645,7 @@ u32 var800ac7a8 = 0; u32 var800ac7ac = 0; u32 var800ac7b0 = 0; u32 var800ac7b4 = 0; -struct options g_Options[1] = {0}; // count unknown -u32 var800ac858 = 0; -u32 var800ac85c = 0; -u32 var800ac860 = 0; -u32 var800ac864 = 0; -u32 var800ac868 = 0; -u32 var800ac86c = 0; -u32 var800ac870 = 0; -u32 var800ac874 = 0; -u32 var800ac878 = 0; -u32 var800ac87c = 0; -u32 var800ac880 = 0; -u32 var800ac884 = 0; -u32 var800ac888 = 0; -u32 var800ac88c = 0; -u32 var800ac890 = 0; -u32 var800ac894 = 0; -u32 var800ac898 = 0; -u32 var800ac89c = 0; -u32 var800ac8a0 = 0; -u32 var800ac8a4 = 0; -u32 var800ac8a8 = 0; -u32 var800ac8ac = 0; -u32 var800ac8b0 = 0; -u32 var800ac8b4 = 0; -u32 var800ac8b8 = 0; -u32 var800ac8bc = 0; -u32 var800ac8c0 = 0; -u32 var800ac8c4 = 0; -u32 var800ac8c8 = 0; -u32 var800ac8cc = 0; -u32 var800ac8d0 = 0; -u32 var800ac8d4 = 0; -u32 var800ac8d8 = 0; -u32 var800ac8dc = 0; -u32 var800ac8e0 = 0; -u32 var800ac8e4 = 0; -u32 var800ac8e8 = 0; -u32 var800ac8ec = 0; -u32 var800ac8f0 = 0; -u32 var800ac8f4 = 0; -u32 var800ac8f8 = 0; -u32 var800ac8fc = 0; -u32 var800ac900 = 0; -u32 var800ac904 = 0; -u32 var800ac908 = 0; -u32 var800ac90c = 0; -u32 var800ac910 = 0; -u32 var800ac914 = 0; -u32 var800ac918 = 0; -u32 var800ac91c = 0; -u32 var800ac920 = 0; -u32 var800ac924 = 0; -u32 var800ac928 = 0; -u32 var800ac92c = 0; -u32 var800ac930 = 0; -u32 var800ac934 = 0; -u32 var800ac938 = 0; -u32 var800ac93c = 0; -u32 var800ac940 = 0; -u32 var800ac944 = 0; -u32 var800ac948 = 0; -u32 var800ac94c = 0; -u32 var800ac950 = 0; -u32 var800ac954 = 0; -u32 var800ac958 = 0; -u32 var800ac95c = 0; -u32 var800ac960 = 0; -u32 var800ac964 = 0; -u32 var800ac968 = 0; -u32 var800ac96c = 0; -u32 var800ac970 = 0; -u32 var800ac974 = 0; -u32 var800ac978 = 0; -u32 var800ac97c = 0; -u32 var800ac980 = 0; -u32 var800ac984 = 0; -u32 var800ac988 = 0; -u32 var800ac98c = 0; -u32 var800ac990 = 0; -u32 var800ac994 = 0; -u32 var800ac998 = 0; -u32 var800ac99c = 0; -u32 var800ac9a0 = 0; -u32 var800ac9a4 = 0; -u32 var800ac9a8 = 0; -u32 var800ac9ac = 0; -u32 var800ac9b0 = 0; -u32 var800ac9b4 = 0; -u32 var800ac9b8 = 0; -u32 var800ac9bc = 0; -u32 var800ac9c0 = 0; -u32 var800ac9c4 = 0; -u32 var800ac9c8 = 0; -u32 var800ac9cc = 0; -u32 var800ac9d0 = 0; -u32 var800ac9d4 = 0; -u32 var800ac9d8 = 0; -u32 var800ac9dc = 0; -u32 var800ac9e0 = 0; -u32 var800ac9e4 = 0; -u32 var800ac9e8 = 0; -u32 var800ac9ec = 0; -u32 var800ac9f0 = 0; -u32 var800ac9f4 = 0; -u32 var800ac9f8 = 0; -u32 var800ac9fc = 0; -u32 var800aca00 = 0; -u32 var800aca04 = 0; -u32 var800aca08 = 0; -u32 var800aca0c = 0; -u32 var800aca10 = 0; -u32 var800aca14 = 0; -u32 var800aca18 = 0; -u32 var800aca1c = 0; -u32 var800aca20 = 0; -u32 var800aca24 = 0; -u32 var800aca28 = 0; -u32 var800aca2c = 0; -u32 var800aca30 = 0; -u32 var800aca34 = 0; +struct mpchr g_MpChrs[4] = {0}; u32 var800aca38 = 0; u32 var800aca3c = 0; u32 var800aca40 = 0; diff --git a/src/include/game/pdoptions.h b/src/include/game/pdoptions.h index 4e40029a7..b309d277a 100644 --- a/src/include/game/pdoptions.h +++ b/src/include/game/pdoptions.h @@ -3,39 +3,39 @@ #include #include "types.h" -s32 optionsGetControlMode(s32 optionsindex); -void optionsSetControlMode(s32 optionsindex, s32 mode); -s32 optionsGetUnk45(s32 optionsindex); -s32 optionsGetUnk46(s32 optionsindex); -s32 optionsGetForwardPitch(s32 optionsindex); -s32 optionsGetAutoAim(s32 optionsindex); -s32 optionsGetLookAhead(s32 optionsindex); -s32 optionsGetAimControl(s32 optionsindex); -s32 optionsGetSightOnScreen(s32 optionsindex); -s32 optionsGetAmmoOnScreen(s32 optionsindex); -s32 optionsGetShowGunFunction(s32 optionsindex); -s32 optionsGetAlwaysShowTarget(s32 optionsindex); -s32 optionsGetShowZoomRange(s32 optionsindex); -s32 optionsGetPaintball(s32 optionsindex); -s32 optionsGetShowMissionTime(s32 optionsindex); +s32 optionsGetControlMode(s32 mpchrnum); +void optionsSetControlMode(s32 mpchrnum, s32 mode); +s32 optionsGetUnk45(s32 mpchrnum); +s32 optionsGetUnk46(s32 mpchrnum); +s32 optionsGetForwardPitch(s32 mpchrnum); +s32 optionsGetAutoAim(s32 mpchrnum); +s32 optionsGetLookAhead(s32 mpchrnum); +s32 optionsGetAimControl(s32 mpchrnum); +s32 optionsGetSightOnScreen(s32 mpchrnum); +s32 optionsGetAmmoOnScreen(s32 mpchrnum); +s32 optionsGetShowGunFunction(s32 mpchrnum); +s32 optionsGetAlwaysShowTarget(s32 mpchrnum); +s32 optionsGetShowZoomRange(s32 mpchrnum); +s32 optionsGetPaintball(s32 mpchrnum); +s32 optionsGetShowMissionTime(s32 mpchrnum); u8 optionsGetInGameSubtitles(void); u8 optionsGetCutsceneSubtitles(void); -s32 optionsGetHeadRoll(s32 optionsindex); +s32 optionsGetHeadRoll(s32 mpchrnum); -void optionsSetForwardPitch(s32 optionsindex, bool enable); -void optionsSetAutoAim(s32 optionsindex, bool enable); -void optionsSetLookAhead(s32 optionsindex, bool enable); -void optionsSetAimControl(s32 optionsindex, s32 index); -void optionsSetSightOnScreen(s32 optionsindex, bool enable); -void optionsSetAmmoOnScreen(s32 optionsindex, bool enable); -void optionsSetShowGunFunction(s32 optionsindex, bool enable); -void optionsSetAlwaysShowTarget(s32 optionsindex, bool enable); -void optionsSetShowZoomRange(s32 optionsindex, bool enable); -void optionsSetPaintball(s32 optionsindex, bool enable); -void optionsSetShowMissionTime(s32 optionsindex, bool enable); +void optionsSetForwardPitch(s32 mpchrnum, bool enable); +void optionsSetAutoAim(s32 mpchrnum, bool enable); +void optionsSetLookAhead(s32 mpchrnum, bool enable); +void optionsSetAimControl(s32 mpchrnum, s32 index); +void optionsSetSightOnScreen(s32 mpchrnum, bool enable); +void optionsSetAmmoOnScreen(s32 mpchrnum, bool enable); +void optionsSetShowGunFunction(s32 mpchrnum, bool enable); +void optionsSetAlwaysShowTarget(s32 mpchrnum, bool enable); +void optionsSetShowZoomRange(s32 mpchrnum, bool enable); +void optionsSetPaintball(s32 mpchrnum, bool enable); +void optionsSetShowMissionTime(s32 mpchrnum, bool enable); void optionsSetInGameSubtitles(s32 enable); void optionsSetCutsceneSubtitles(s32 enable); -void optionsSetHeadRoll(s32 optionsindex, bool enable); +void optionsSetHeadRoll(s32 mpchrnum, bool enable); s32 optionsGetEffectiveScreenSize(void); s32 optionsGetScreenSize(void); void optionsSetScreenSize(s32 size); diff --git a/src/include/gvars/gvars.h b/src/include/gvars/gvars.h index 404c8fa5e..144900dd5 100644 --- a/src/include/gvars/gvars.h +++ b/src/include/gvars/gvars.h @@ -845,8 +845,7 @@ extern u32 var800ac500; extern u32 var800ac530; extern struct mpsim g_MpSimulants[8]; extern u32 var800ac798; -extern struct options g_Options[]; -extern u32 var800ac858; +extern struct mpchr g_MpChrs[]; extern u32 var800aca38; extern u32 var800acad8; extern u32 var800acb78; diff --git a/src/include/setup/setup_0160b0.h b/src/include/setup/setup_0160b0.h index 69505b9db..647693156 100644 --- a/src/include/setup/setup_0160b0.h +++ b/src/include/setup/setup_0160b0.h @@ -143,7 +143,7 @@ extern u32 var800711e8; extern u32 var800711f4; extern u32 var8007142c; extern u32 var80071440; -extern u32 g_MenuStackDepth; +extern u32 g_MpPlayerNum; extern u32 var8007144c; extern u32 var80071468; extern u32 var80071470; diff --git a/src/include/setup/setup_020df0.h b/src/include/setup/setup_020df0.h index c6b895325..f84b9449d 100644 --- a/src/include/setup/setup_020df0.h +++ b/src/include/setup/setup_020df0.h @@ -301,7 +301,7 @@ extern struct mpheadentry mpheadstable[]; extern u32 table_0x2d678[]; extern struct mpsimulant mpgeneralsimulants[]; extern struct mpsimulant mpspecialsimulants[]; -extern struct mpbody mpbodytable[]; +extern struct bodynum mpbodytable[]; extern u32 mppresets[]; extern u32 mpteamcolors[]; extern u32 var80087d10; diff --git a/src/include/types.h b/src/include/types.h index 09e6c8407..c9b27f9ad 100644 --- a/src/include/types.h +++ b/src/include/types.h @@ -2678,7 +2678,7 @@ struct mpsimulant { u8 unlockvalue; }; -struct mpbody { +struct bodynum { u16 slot; u16 name; u16 unk04; @@ -2811,8 +2811,8 @@ struct menu_item { u8 type; u8 param; u32 flags; - u32 left; - u32 right; + u32 param2; + u32 param3; void *handler; }; @@ -2895,7 +2895,7 @@ struct gvars74 { /*0x64*/ u32 unk64; /*0x68*/ u32 unk68; /*0x6c*/ u32 unk6c; - /*0x70*/ u32 optionsindex; + /*0x70*/ u32 mpchrnum; /*0x74*/ u32 unk74; /*0x78*/ u32 unk78; /*0x7c*/ u32 unk7c; @@ -3941,15 +3941,15 @@ struct propstate { /*0x18*/ u32 lastupdateframe; }; -struct options { +struct mpchr { /*0x00*/ u16 unk00; /*0x04*/ u32 unk04; /*0x08*/ u32 unk08; /*0x0c*/ u8 unk0c; /*0x0d*/ u8 unk0d; /*0x0e*/ u8 unk0e; - /*0x0f*/ u8 mphead; - /*0x10*/ u8 mpbody; + /*0x0f*/ u8 headnum; + /*0x10*/ u8 bodynum; /*0x14*/ u32 unk14; /*0x18*/ u32 unk18; /*0x1c*/ u32 unk1c; @@ -3966,7 +3966,7 @@ struct options { /*0x45*/ s8 unk45; /*0x46*/ s8 unk46; /*0x47*/ u8 unk47; - /*0x48*/ u16 booleans; + /*0x48*/ u16 options; /*0x4c*/ u32 unk4c; /*0x50*/ u32 unk50; /*0x54*/ u32 unk54; @@ -3986,7 +3986,7 @@ struct options { /*0x8c*/ u32 unk8c; /*0x90*/ u32 unk90; /*0x94*/ u8 unk94; - /*0x95*/ u8 mptitle; + /*0x95*/ u8 title; /*0x98*/ u32 unk98; /*0x9c*/ u32 unk9c; }; diff --git a/src/setup/setup_0160b0.c b/src/setup/setup_0160b0.c index 4360a4d3d..ff3eb6eed 100644 --- a/src/setup/setup_0160b0.c +++ b/src/setup/setup_0160b0.c @@ -1278,7 +1278,7 @@ u32 var80071438 = 0x54bf54c0; u32 var8007143c = 0x54c10000; u32 var80071440 = (u32) &g_CheatMarqueeString; u32 var80071444 = 0x8009df3d; -u32 g_MenuStackDepth = 0; +u32 g_MpPlayerNum = 0; u32 var8007144c = 0x51e451e5; u32 var80071450 = 0x51e651e7; u32 var80071454 = 0x51e851e9; diff --git a/src/setup/setup_020df0.c b/src/setup/setup_020df0.c index 5585cbbdc..79d4b95cb 100644 --- a/src/setup/setup_020df0.c +++ b/src/setup/setup_020df0.c @@ -12051,7 +12051,7 @@ struct mpsimulant mpspecialsimulants[] = { }; // 2d7dc -struct mpbody mpbodytable[] = { +struct bodynum mpbodytable[] = { // slot, name, unk04, unk06 /*0x00*/ { 0x0056, 0x5610, 0x0004, 0x00 }, /*0x01*/ { 0x0062, 0x5611, 0x0004, 0x46 },