From d587580bd53da416d46bd9ad58c6ac533db8273c Mon Sep 17 00:00:00 2001 From: Tyler McGavran Date: Tue, 14 Dec 2021 22:40:38 -0500 Subject: [PATCH] Rename a couple variables (#93) * Rename a couple variables Co-authored-by: MegaMech --- asm/bss_80005FD0.s | 2 +- asm/bss_8001C4D0.s | 6 +- asm/bss_MainSeg.s | 2 +- .../code_80005FD0/func_800070F4.s | 16 +-- .../code_80005FD0/func_800074D4.s | 40 +++--- .../code_80005FD0/func_80008F38.s | 4 +- .../code_80005FD0/func_80009B60.s | 4 +- .../code_80005FD0/func_8000F628.s | 4 +- .../code_80005FD0/func_80014DE4.s | 4 +- asm/non_matchings/code_80005FD0/set_places.s | 52 ++++---- .../code_800393C0/func_8003A9F0.s | 4 +- .../code_80091750/func_80091EE4.s | 4 +- .../code_80091750/func_8009CE64.s | 8 +- .../code_80091750/func_8009E650.s | 20 +-- .../code_80091750/func_800A15EC.s | 4 +- .../code_80091750/func_800A1924.s | 4 +- .../code_80091750/func_800A1A20.s | 4 +- .../code_80091750/func_800A1FB0.s | 12 +- .../code_80091750/func_800A2EB8.s | 4 +- .../code_80091750/func_800A34A8.s | 8 +- .../code_80091750/func_800A3A10.s | 4 +- .../code_80091750/func_800A3ADC.s | 8 +- .../code_80091750/func_800A3C84.s | 8 +- .../code_80091750/func_800A3E60.s | 12 +- .../code_80091750/func_800A4BC8.s | 8 +- .../code_80091750/func_800A5084.s | 8 +- .../code_80091750/func_800A5738.s | 12 +- .../code_80091750/func_800A8A98.s | 4 +- .../code_80091750/func_800A8F48.s | 4 +- .../code_80091750/func_800AB290.s | 4 +- .../code_80091750/func_800AB314.s | 4 +- .../code_80091750/func_800AC458.s | 12 +- .../code_80091750/func_800AD2E8.s | 12 +- .../code_80091750/func_800AE218.s | 12 +- .../code_80091750/func_800AEDBC.s | 4 +- .../code_800AF9B0/func_800B3B58.s | 28 ++-- .../code_800AF9B0/func_800B3F74.s | 16 +-- .../code_800AF9B0/func_800B5020.s | 4 +- .../code_800AF9B0/func_800B5218.s | 4 +- .../code_800AF9B0/func_800B6178.s | 4 +- .../code_800AF9B0/func_800B63F0.s | 4 +- data/data_0DD0A0_3.s | 2 +- include/defines.h | 6 + include/variables.h | 21 ++- src/code_800029B0.c | 4 +- src/code_80005FD0.c | 120 +++++++++--------- src/code_800393C0.c | 14 +- src/code_80091750.c | 112 ++++++++-------- src/code_800AF9B0.c | 46 +++---- src/code_80281780.c | 4 +- src/code_8028DF00.c | 8 +- src/data_0DD0A0_3.inc.c | 2 +- 52 files changed, 362 insertions(+), 359 deletions(-) diff --git a/asm/bss_80005FD0.s b/asm/bss_80005FD0.s index 596806574..39fb81d4b 100644 --- a/asm/bss_80005FD0.s +++ b/asm/bss_80005FD0.s @@ -48,7 +48,7 @@ glabel D_80162FCE glabel D_80162FD0 .skip 8 -glabel gTrackCompletionPercentByRank +glabel gCourseCompletionPercentByRank .skip 32 glabel D_80162FF8 diff --git a/asm/bss_8001C4D0.s b/asm/bss_8001C4D0.s index 1ca50207e..ab7bff767 100644 --- a/asm/bss_8001C4D0.s +++ b/asm/bss_8001C4D0.s @@ -1746,12 +1746,12 @@ glabel D_8018D9C0 # List of bytes indexed by character ID # Indicates number of Grand Prix points that character # has scored -glabel gGPCharacterPoints +glabel gGPPointsByCharacterId .skip 8 # List of character IDs indicating where each character # is in the Grand Prix standings -glabel gGPOverallRanks +glabel gCharacterIdByGPOverallRank .skip 1 glabel D_8018D9D1 @@ -2135,7 +2135,7 @@ glabel gCupSelection # 0x8018EE09 glabel D_8018EE0A .skip 1 -glabel gCourseSelection # 0x8018EE0B +glabel gCupCourseSelection # 0x8018EE0B .skip 1 glabel D_8018EE0C diff --git a/asm/bss_MainSeg.s b/asm/bss_MainSeg.s index 3c47b6f3e..6b00b7e62 100644 --- a/asm/bss_MainSeg.s +++ b/asm/bss_MainSeg.s @@ -241,7 +241,7 @@ glabel D_80164498 glabel D_801644A8 .skip 40 -glabel gTrackCompletionPercentByPlayerId +glabel gCourseCompletionPercentByPlayerId .skip 40 glabel D_801644F8 diff --git a/asm/non_matchings/code_80005FD0/func_800070F4.s b/asm/non_matchings/code_80005FD0/func_800070F4.s index 176a2b007..5b032a431 100644 --- a/asm/non_matchings/code_80005FD0/func_800070F4.s +++ b/asm/non_matchings/code_80005FD0/func_800070F4.s @@ -27,8 +27,8 @@ glabel func_800070F4 /* 007D4C 8000714C 01404825 */ move $t1, $t2 /* 007D50 80007150 3C0F8016 */ lui $t7, %hi(D_80164360) # $t7, 0x8016 /* 007D54 80007154 00002080 */ sll $a0, $zero, 2 -/* 007D58 80007158 3C198016 */ lui $t9, %hi(gTrackCompletionPercentByRank) # $t9, 0x8016 -/* 007D5C 8000715C 27392FD8 */ addiu $t9, %lo(gTrackCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 +/* 007D58 80007158 3C198016 */ lui $t9, %hi(gCourseCompletionPercentByRank) # $t9, 0x8016 +/* 007D5C 8000715C 27392FD8 */ addiu $t9, %lo(gCourseCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 /* 007D60 80007160 25EF4360 */ addiu $t7, %lo(D_80164360) # addiu $t7, $t7, 0x4360 /* 007D64 80007164 00007040 */ sll $t6, $zero, 1 /* 007D68 80007168 27B80050 */ addiu $t8, $sp, 0x50 @@ -57,8 +57,8 @@ glabel func_800070F4 /* 007DBC 800071BC 3C198016 */ lui $t9, %hi(D_80164360) # $t9, 0x8016 /* 007DC0 800071C0 27394360 */ addiu $t9, %lo(D_80164360) # addiu $t9, $t9, 0x4360 /* 007DC4 800071C4 0007C040 */ sll $t8, $a3, 1 -/* 007DC8 800071C8 3C0F8016 */ lui $t7, %hi(gTrackCompletionPercentByRank) # $t7, 0x8016 -/* 007DCC 800071CC 25EF2FD8 */ addiu $t7, %lo(gTrackCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 +/* 007DC8 800071C8 3C0F8016 */ lui $t7, %hi(gCourseCompletionPercentByRank) # $t7, 0x8016 +/* 007DCC 800071CC 25EF2FD8 */ addiu $t7, %lo(gCourseCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 /* 007DD0 800071D0 03194021 */ addu $t0, $t8, $t9 /* 007DD4 800071D4 00072080 */ sll $a0, $a3, 2 /* 007DD8 800071D8 0006C080 */ sll $t8, $a2, 2 @@ -112,10 +112,10 @@ glabel func_800070F4 /* 007E88 80007288 10200040 */ beqz $at, .L8000738C /* 007E8C 8000728C 00A01025 */ move $v0, $a1 /* 007E90 80007290 00072080 */ sll $a0, $a3, 2 -/* 007E94 80007294 3C198016 */ lui $t9, %hi(gTrackCompletionPercentByRank) # $t9, 0x8016 +/* 007E94 80007294 3C198016 */ lui $t9, %hi(gCourseCompletionPercentByRank) # $t9, 0x8016 /* 007E98 80007298 00C54823 */ subu $t1, $a2, $a1 /* 007E9C 8000729C 31270001 */ andi $a3, $t1, 1 -/* 007EA0 800072A0 27392FD8 */ addiu $t9, %lo(gTrackCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 +/* 007EA0 800072A0 27392FD8 */ addiu $t9, %lo(gCourseCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 /* 007EA4 800072A4 10E00013 */ beqz $a3, .L800072F4 /* 007EA8 800072A8 00991821 */ addu $v1, $a0, $t9 /* 007EAC 800072AC 00053880 */ sll $a3, $a1, 2 @@ -138,8 +138,8 @@ glabel func_800070F4 .L800072F0: /* 007EF0 800072F0 10460026 */ beq $v0, $a2, .L8000738C .L800072F4: -/* 007EF4 800072F4 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByRank) # $t8, 0x8016 -/* 007EF8 800072F8 27182FD8 */ addiu $t8, %lo(gTrackCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 +/* 007EF4 800072F4 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByRank) # $t8, 0x8016 +/* 007EF8 800072F8 27182FD8 */ addiu $t8, %lo(gCourseCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 /* 007EFC 800072FC 00023880 */ sll $a3, $v0, 2 /* 007F00 80007300 00067880 */ sll $t7, $a2, 2 /* 007F04 80007304 01F86021 */ addu $t4, $t7, $t8 diff --git a/asm/non_matchings/code_80005FD0/func_800074D4.s b/asm/non_matchings/code_80005FD0/func_800074D4.s index dd43a09f4..d3e411a78 100644 --- a/asm/non_matchings/code_80005FD0/func_800074D4.s +++ b/asm/non_matchings/code_80005FD0/func_800074D4.s @@ -1,11 +1,11 @@ glabel func_800074D4 /* 0080D4 800074D4 27BDFF70 */ addiu $sp, $sp, -0x90 -/* 0080D8 800074D8 3C048016 */ lui $a0, %hi(gTrackCompletionPercentByRank) # $a0, 0x8016 +/* 0080D8 800074D8 3C048016 */ lui $a0, %hi(gCourseCompletionPercentByRank) # $a0, 0x8016 /* 0080DC 800074DC 44800000 */ mtc1 $zero, $f0 /* 0080E0 800074E0 AFB1000C */ sw $s1, 0xc($sp) /* 0080E4 800074E4 AFB00008 */ sw $s0, 8($sp) /* 0080E8 800074E8 240A0008 */ li $t2, 8 -/* 0080EC 800074EC 24842FD8 */ addiu $a0, %lo(gTrackCompletionPercentByRank) # addiu $a0, $a0, 0x2fd8 +/* 0080EC 800074EC 24842FD8 */ addiu $a0, %lo(gCourseCompletionPercentByRank) # addiu $a0, $a0, 0x2fd8 /* 0080F0 800074F0 24070001 */ li $a3, 1 /* 0080F4 800074F4 24020009 */ li $v0, 9 .L800074F8: @@ -26,10 +26,10 @@ glabel func_800074D4 /* 008130 80007530 3C0F800F */ lui $t7, %hi(gPlayers) # $t7, 0x800f /* 008134 80007534 25EF6990 */ addiu $t7, %lo(gPlayers) # addiu $t7, $t7, 0x6990 /* 008138 80007538 000E70C0 */ sll $t6, $t6, 3 -/* 00813C 8000753C 3C0C8016 */ lui $t4, %hi(gTrackCompletionPercentByRank) # $t4, 0x8016 +/* 00813C 8000753C 3C0C8016 */ lui $t4, %hi(gCourseCompletionPercentByRank) # $t4, 0x8016 /* 008140 80007540 3C098016 */ lui $t1, %hi(gTimePlayerLastTouchedFinishLine) # $t1, 0x8016 /* 008144 80007544 2529F898 */ addiu $t1, %lo(gTimePlayerLastTouchedFinishLine) # addiu $t1, $t1, -0x768 -/* 008148 80007548 258C2FD8 */ addiu $t4, %lo(gTrackCompletionPercentByRank) # addiu $t4, $t4, 0x2fd8 +/* 008148 80007548 258C2FD8 */ addiu $t4, %lo(gCourseCompletionPercentByRank) # addiu $t4, $t4, 0x2fd8 /* 00814C 8000754C 01CF2021 */ addu $a0, $t6, $t7 /* 008150 80007550 00002825 */ move $a1, $zero /* 008154 80007554 24070001 */ li $a3, 1 @@ -66,8 +66,8 @@ glabel func_800074D4 /* 0081C4 800075C4 25EF6990 */ addiu $t7, %lo(gPlayers) # addiu $t7, $t7, 0x6990 /* 0081C8 800075C8 000E70C0 */ sll $t6, $t6, 3 /* 0081CC 800075CC 3C098016 */ lui $t1, %hi(gTimePlayerLastTouchedFinishLine) # $t1, 0x8016 -/* 0081D0 800075D0 3C0C8016 */ lui $t4, %hi(gTrackCompletionPercentByRank) # $t4, 0x8016 -/* 0081D4 800075D4 258C2FD8 */ addiu $t4, %lo(gTrackCompletionPercentByRank) # addiu $t4, $t4, 0x2fd8 +/* 0081D0 800075D0 3C0C8016 */ lui $t4, %hi(gCourseCompletionPercentByRank) # $t4, 0x8016 +/* 0081D4 800075D4 258C2FD8 */ addiu $t4, %lo(gCourseCompletionPercentByRank) # addiu $t4, $t4, 0x2fd8 /* 0081D8 800075D8 2529F898 */ addiu $t1, %lo(gTimePlayerLastTouchedFinishLine) # addiu $t1, $t1, -0x768 /* 0081DC 800075DC 01CF2021 */ addu $a0, $t6, $t7 /* 0081E0 800075E0 27A60068 */ addiu $a2, $sp, 0x68 @@ -135,8 +135,8 @@ glabel func_800074D4 /* 0082C4 800076C4 150AFFC7 */ bne $t0, $t2, .L800075E4 /* 0082C8 800076C8 24843760 */ addiu $a0, $a0, 0x3760 .L800076CC: -/* 0082CC 800076CC 3C0C8016 */ lui $t4, %hi(gTrackCompletionPercentByRank) # $t4, 0x8016 -/* 0082D0 800076D0 258C2FD8 */ addiu $t4, %lo(gTrackCompletionPercentByRank) # addiu $t4, $t4, 0x2fd8 +/* 0082CC 800076CC 3C0C8016 */ lui $t4, %hi(gCourseCompletionPercentByRank) # $t4, 0x8016 +/* 0082D0 800076D0 258C2FD8 */ addiu $t4, %lo(gCourseCompletionPercentByRank) # addiu $t4, $t4, 0x2fd8 /* 0082D4 800076D4 00004025 */ move $t0, $zero /* 0082D8 800076D8 27A60068 */ addiu $a2, $sp, 0x68 /* 0082DC 800076DC 240B0008 */ li $t3, 8 @@ -151,8 +151,8 @@ glabel func_800074D4 /* 008300 80007700 3C18800F */ lui $t8, %hi(gPlayers) # $t8, 0x800f /* 008304 80007704 27186990 */ addiu $t8, %lo(gPlayers) # addiu $t8, $t8, 0x6990 /* 008308 80007708 000F78C0 */ sll $t7, $t7, 3 -/* 00830C 8000770C 3C0D8016 */ lui $t5, %hi(gTrackCompletionPercentByPlayerId) # $t5, 0x8016 -/* 008310 80007710 25AD44D0 */ addiu $t5, %lo(gTrackCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 +/* 00830C 8000770C 3C0D8016 */ lui $t5, %hi(gCourseCompletionPercentByPlayerId) # $t5, 0x8016 +/* 008310 80007710 25AD44D0 */ addiu $t5, %lo(gCourseCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 /* 008314 80007714 01F82021 */ addu $a0, $t7, $t8 /* 008318 80007718 00002825 */ move $a1, $zero /* 00831C 8000771C 24070001 */ li $a3, 1 @@ -185,8 +185,8 @@ glabel func_800074D4 /* 00837C 8000777C 3C18800F */ lui $t8, %hi(gPlayers) # $t8, 0x800f /* 008380 80007780 27186990 */ addiu $t8, %lo(gPlayers) # addiu $t8, $t8, 0x6990 /* 008384 80007784 000F78C0 */ sll $t7, $t7, 3 -/* 008388 80007788 3C0D8016 */ lui $t5, %hi(gTrackCompletionPercentByPlayerId) # $t5, 0x8016 -/* 00838C 8000778C 25AD44D0 */ addiu $t5, %lo(gTrackCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 +/* 008388 80007788 3C0D8016 */ lui $t5, %hi(gCourseCompletionPercentByPlayerId) # $t5, 0x8016 +/* 00838C 8000778C 25AD44D0 */ addiu $t5, %lo(gCourseCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 /* 008390 80007790 01F82021 */ addu $a0, $t7, $t8 .L80007794: /* 008394 80007794 94990000 */ lhu $t9, ($a0) @@ -256,10 +256,10 @@ glabel func_800074D4 /* 00847C 8000787C 00E9082A */ slt $at, $a3, $t1 /* 008480 80007880 10200040 */ beqz $at, .L80007984 /* 008484 80007884 00E01025 */ move $v0, $a3 -/* 008488 80007888 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByRank) # $t8, 0x8016 +/* 008488 80007888 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByRank) # $t8, 0x8016 /* 00848C 8000788C 01276023 */ subu $t4, $t1, $a3 /* 008490 80007890 31830001 */ andi $v1, $t4, 1 -/* 008494 80007894 27182FD8 */ addiu $t8, %lo(gTrackCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 +/* 008494 80007894 27182FD8 */ addiu $t8, %lo(gCourseCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 /* 008498 80007898 00082880 */ sll $a1, $t0, 2 /* 00849C 8000789C 10600013 */ beqz $v1, .L800078EC /* 0084A0 800078A0 00B82021 */ addu $a0, $a1, $t8 @@ -283,8 +283,8 @@ glabel func_800074D4 .L800078E8: /* 0084E8 800078E8 10490026 */ beq $v0, $t1, .L80007984 .L800078EC: -/* 0084EC 800078EC 3C0E8016 */ lui $t6, %hi(gTrackCompletionPercentByRank) # $t6, 0x8016 -/* 0084F0 800078F0 25CE2FD8 */ addiu $t6, %lo(gTrackCompletionPercentByRank) # addiu $t6, $t6, 0x2fd8 +/* 0084EC 800078EC 3C0E8016 */ lui $t6, %hi(gCourseCompletionPercentByRank) # $t6, 0x8016 +/* 0084F0 800078F0 25CE2FD8 */ addiu $t6, %lo(gCourseCompletionPercentByRank) # addiu $t6, $t6, 0x2fd8 /* 0084F4 800078F4 00021880 */ sll $v1, $v0, 2 /* 0084F8 800078F8 00097880 */ sll $t7, $t1, 2 /* 0084FC 800078FC 01EE8821 */ addu $s1, $t7, $t6 @@ -340,8 +340,8 @@ glabel func_800074D4 /* 0085AC 800079AC 00E01025 */ move $v0, $a3 /* 0085B0 800079B0 240E0008 */ li $t6, 8 /* 0085B4 800079B4 01C76023 */ subu $t4, $t6, $a3 -/* 0085B8 800079B8 3C0F8016 */ lui $t7, %hi(gTrackCompletionPercentByRank) # $t7, 0x8016 -/* 0085BC 800079BC 25EF2FD8 */ addiu $t7, %lo(gTrackCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 +/* 0085B8 800079B8 3C0F8016 */ lui $t7, %hi(gCourseCompletionPercentByRank) # $t7, 0x8016 +/* 0085BC 800079BC 25EF2FD8 */ addiu $t7, %lo(gCourseCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 /* 0085C0 800079C0 31830001 */ andi $v1, $t4, 1 /* 0085C4 800079C4 00082880 */ sll $a1, $t0, 2 /* 0085C8 800079C8 10600013 */ beqz $v1, .L80007A18 @@ -366,8 +366,8 @@ glabel func_800074D4 .L80007A14: /* 008614 80007A14 104B0026 */ beq $v0, $t3, .L80007AB0 .L80007A18: -/* 008618 80007A18 3C198016 */ lui $t9, %hi(gTrackCompletionPercentByRank) # $t9, 0x8016 -/* 00861C 80007A1C 27392FD8 */ addiu $t9, %lo(gTrackCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 +/* 008618 80007A18 3C198016 */ lui $t9, %hi(gCourseCompletionPercentByRank) # $t9, 0x8016 +/* 00861C 80007A1C 27392FD8 */ addiu $t9, %lo(gCourseCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 /* 008620 80007A20 00021880 */ sll $v1, $v0, 2 /* 008624 80007A24 000A7080 */ sll $t6, $t2, 2 /* 008628 80007A28 01D96821 */ addu $t5, $t6, $t9 diff --git a/asm/non_matchings/code_80005FD0/func_80008F38.s b/asm/non_matchings/code_80005FD0/func_80008F38.s index 03801075b..966d144cf 100644 --- a/asm/non_matchings/code_80005FD0/func_80008F38.s +++ b/asm/non_matchings/code_80005FD0/func_80008F38.s @@ -47,7 +47,7 @@ glabel func_80008F38 /* 009BE4 80008FE4 46802220 */ cvt.s.w $f8, $f4 /* 009BE8 80008FE8 46080280 */ add.s $f10, $f0, $f8 /* 009BEC 80008FEC E42044A8 */ swc1 $f0, %lo(D_801644A8)($at) -/* 009BF0 80008FF0 3C018016 */ lui $at, %hi(gTrackCompletionPercentByPlayerId) +/* 009BF0 80008FF0 3C018016 */ lui $at, %hi(gCourseCompletionPercentByPlayerId) /* 009BF4 80008FF4 00220821 */ addu $at, $at, $v0 /* 009BF8 80008FF8 03E00008 */ jr $ra -/* 009BFC 80008FFC E42A44D0 */ swc1 $f10, %lo(gTrackCompletionPercentByPlayerId)($at) +/* 009BFC 80008FFC E42A44D0 */ swc1 $f10, %lo(gCourseCompletionPercentByPlayerId)($at) diff --git a/asm/non_matchings/code_80005FD0/func_80009B60.s b/asm/non_matchings/code_80005FD0/func_80009B60.s index 2eeb89f2d..77a668f4f 100644 --- a/asm/non_matchings/code_80005FD0/func_80009B60.s +++ b/asm/non_matchings/code_80005FD0/func_80009B60.s @@ -55,9 +55,9 @@ glabel func_80009B60 /* 00A830 80009C30 00270821 */ addu $at, $at, $a3 /* 00A834 80009C34 240FFFEC */ li $t7, -20 /* 00A838 80009C38 AC2F4450 */ sw $t7, %lo(D_80164450)($at) # 0x4450($at) -/* 00A83C 80009C3C 3C018016 */ lui $at, %hi(gTrackCompletionPercentByPlayerId) +/* 00A83C 80009C3C 3C018016 */ lui $at, %hi(gCourseCompletionPercentByPlayerId) /* 00A840 80009C40 00270821 */ addu $at, $at, $a3 -/* 00A844 80009C44 E42044D0 */ swc1 $f0, %lo(gTrackCompletionPercentByPlayerId)($at) +/* 00A844 80009C44 E42044D0 */ swc1 $f0, %lo(gCourseCompletionPercentByPlayerId)($at) /* 00A848 80009C48 3C018016 */ lui $at, %hi(D_801644A8) /* 00A84C 80009C4C 00270821 */ addu $at, $at, $a3 /* 00A850 80009C50 10000537 */ b .L8000B130 diff --git a/asm/non_matchings/code_80005FD0/func_8000F628.s b/asm/non_matchings/code_80005FD0/func_8000F628.s index f8cbd2564..195833f85 100644 --- a/asm/non_matchings/code_80005FD0/func_8000F628.s +++ b/asm/non_matchings/code_80005FD0/func_8000F628.s @@ -8,10 +8,10 @@ glabel func_8000F628 /* 010240 8000F640 AFAF00D0 */ sw $t7, 0xd0($sp) /* 010244 8000F644 3C0F8016 */ lui $t7, %hi(D_80163258) # $t7, 0x8016 /* 010248 8000F648 3C0E8016 */ lui $t6, %hi(D_80164408) # $t6, 0x8016 -/* 01024C 8000F64C 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByPlayerId) # $t8, 0x8016 +/* 01024C 8000F64C 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByPlayerId) # $t8, 0x8016 /* 010250 8000F650 3C198016 */ lui $t9, %hi(gTimePlayerLastTouchedFinishLine) # $t9, 0x8016 /* 010254 8000F654 2739F898 */ addiu $t9, %lo(gTimePlayerLastTouchedFinishLine) # addiu $t9, $t9, -0x768 -/* 010258 8000F658 271844D0 */ addiu $t8, %lo(gTrackCompletionPercentByPlayerId) # addiu $t8, $t8, 0x44d0 +/* 010258 8000F658 271844D0 */ addiu $t8, %lo(gCourseCompletionPercentByPlayerId) # addiu $t8, $t8, 0x44d0 /* 01025C 8000F65C 25CE4408 */ addiu $t6, %lo(D_80164408) # addiu $t6, $t6, 0x4408 /* 010260 8000F660 25EF3258 */ addiu $t7, %lo(D_80163258) # addiu $t7, $t7, 0x3258 /* 010264 8000F664 AFAF00B8 */ sw $t7, 0xb8($sp) diff --git a/asm/non_matchings/code_80005FD0/func_80014DE4.s b/asm/non_matchings/code_80005FD0/func_80014DE4.s index a88a21e21..18880ee9a 100644 --- a/asm/non_matchings/code_80005FD0/func_80014DE4.s +++ b/asm/non_matchings/code_80005FD0/func_80014DE4.s @@ -15,8 +15,8 @@ glabel func_80014DE4 /* 015A18 80014E18 2408FFFF */ li $t0, -1 /* 015A1C 80014E1C 10E5000B */ beq $a3, $a1, .L80014E4C /* 015A20 80014E20 000448C0 */ sll $t1, $a0, 3 -/* 015A24 80014E24 3C188019 */ lui $t8, %hi(gCourseSelection) # $t8, 0x8019 -/* 015A28 80014E28 8318EE0B */ lb $t8, %lo(gCourseSelection)($t8) +/* 015A24 80014E24 3C188019 */ lui $t8, %hi(gCupCourseSelection) # $t8, 0x8019 +/* 015A28 80014E28 8318EE0B */ lb $t8, %lo(gCupCourseSelection)($t8) /* 015A2C 80014E2C 3C19800E */ lui $t9, %hi(D_800DC51C) /* 015A30 80014E30 13000004 */ beqz $t8, .L80014E44 /* 015A34 80014E34 00000000 */ nop diff --git a/asm/non_matchings/code_80005FD0/set_places.s b/asm/non_matchings/code_80005FD0/set_places.s index bb78402bf..8eecdfcfa 100644 --- a/asm/non_matchings/code_80005FD0/set_places.s +++ b/asm/non_matchings/code_80005FD0/set_places.s @@ -34,13 +34,13 @@ glabel set_places /* 007438 80006838 01003025 */ move $a2, $t0 /* 00743C 8000683C 3C188016 */ lui $t8, %hi(D_80164360) # $t8, 0x8016 /* 007440 80006840 00002880 */ sll $a1, $zero, 2 -/* 007444 80006844 3C0E8016 */ lui $t6, %hi(gTrackCompletionPercentByRank) # $t6, 0x8016 -/* 007448 80006848 25CE2FD8 */ addiu $t6, %lo(gTrackCompletionPercentByRank) # addiu $t6, $t6, 0x2fd8 +/* 007444 80006844 3C0E8016 */ lui $t6, %hi(gCourseCompletionPercentByRank) # $t6, 0x8016 +/* 007448 80006848 25CE2FD8 */ addiu $t6, %lo(gCourseCompletionPercentByRank) # addiu $t6, $t6, 0x2fd8 /* 00744C 8000684C 27184360 */ addiu $t8, %lo(D_80164360) # addiu $t8, $t8, 0x4360 /* 007450 80006850 00007840 */ sll $t7, $zero, 1 /* 007454 80006854 27B90080 */ addiu $t9, $sp, 0x80 -/* 007458 80006858 3C0D8016 */ lui $t5, %hi(gTrackCompletionPercentByPlayerId) # $t5, 0x8016 -/* 00745C 8000685C 25AD44D0 */ addiu $t5, %lo(gTrackCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 +/* 007458 80006858 3C0D8016 */ lui $t5, %hi(gCourseCompletionPercentByPlayerId) # $t5, 0x8016 +/* 00745C 8000685C 25AD44D0 */ addiu $t5, %lo(gCourseCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 /* 007460 80006860 00B91021 */ addu $v0, $a1, $t9 /* 007464 80006864 01F85021 */ addu $t2, $t7, $t8 /* 007468 80006868 00AE1821 */ addu $v1, $a1, $t6 @@ -63,15 +63,15 @@ glabel set_places /* 0074A4 800068A4 3C0E8016 */ lui $t6, %hi(D_80164360) # $t6, 0x8016 /* 0074A8 800068A8 25CE4360 */ addiu $t6, %lo(D_80164360) # addiu $t6, $t6, 0x4360 /* 0074AC 800068AC 000BC840 */ sll $t9, $t3, 1 -/* 0074B0 800068B0 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByRank) # $t8, 0x8016 -/* 0074B4 800068B4 27182FD8 */ addiu $t8, %lo(gTrackCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 +/* 0074B0 800068B0 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByRank) # $t8, 0x8016 +/* 0074B4 800068B4 27182FD8 */ addiu $t8, %lo(gCourseCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 /* 0074B8 800068B8 032E5021 */ addu $t2, $t9, $t6 /* 0074BC 800068BC 000B2880 */ sll $a1, $t3, 2 /* 0074C0 800068C0 000CC880 */ sll $t9, $t4, 2 -/* 0074C4 800068C4 3C0D8016 */ lui $t5, %hi(gTrackCompletionPercentByPlayerId) # $t5, 0x8016 +/* 0074C4 800068C4 3C0D8016 */ lui $t5, %hi(gCourseCompletionPercentByPlayerId) # $t5, 0x8016 /* 0074C8 800068C8 27AF0080 */ addiu $t7, $sp, 0x80 /* 0074CC 800068CC 00AF1021 */ addu $v0, $a1, $t7 -/* 0074D0 800068D0 25AD44D0 */ addiu $t5, %lo(gTrackCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 +/* 0074D0 800068D0 25AD44D0 */ addiu $t5, %lo(gCourseCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 /* 0074D4 800068D4 03383021 */ addu $a2, $t9, $t8 /* 0074D8 800068D8 00B81821 */ addu $v1, $a1, $t8 .L800068DC: @@ -116,8 +116,8 @@ glabel set_places /* 007568 80006968 01003025 */ move $a2, $t0 /* 00756C 8000696C 3C0F8016 */ lui $t7, %hi(D_80164360) # $t7, 0x8016 /* 007570 80006970 00002880 */ sll $a1, $zero, 2 -/* 007574 80006974 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByRank) # $t8, 0x8016 -/* 007578 80006978 27182FD8 */ addiu $t8, %lo(gTrackCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 +/* 007574 80006974 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByRank) # $t8, 0x8016 +/* 007578 80006978 27182FD8 */ addiu $t8, %lo(gCourseCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 /* 00757C 8000697C 25EF4360 */ addiu $t7, %lo(D_80164360) # addiu $t7, $t7, 0x4360 /* 007580 80006980 00007040 */ sll $t6, $zero, 1 /* 007584 80006984 27B90080 */ addiu $t9, $sp, 0x80 @@ -146,8 +146,8 @@ glabel set_places /* 0075D8 800069D8 3C188016 */ lui $t8, %hi(D_80164360) # $t8, 0x8016 /* 0075DC 800069DC 27184360 */ addiu $t8, %lo(D_80164360) # addiu $t8, $t8, 0x4360 /* 0075E0 800069E0 000BC840 */ sll $t9, $t3, 1 -/* 0075E4 800069E4 3C0F8016 */ lui $t7, %hi(gTrackCompletionPercentByRank) # $t7, 0x8016 -/* 0075E8 800069E8 25EF2FD8 */ addiu $t7, %lo(gTrackCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 +/* 0075E4 800069E4 3C0F8016 */ lui $t7, %hi(gCourseCompletionPercentByRank) # $t7, 0x8016 +/* 0075E8 800069E8 25EF2FD8 */ addiu $t7, %lo(gCourseCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 /* 0075EC 800069EC 03385021 */ addu $t2, $t9, $t8 /* 0075F0 800069F0 000B2880 */ sll $a1, $t3, 2 /* 0075F4 800069F4 000CC880 */ sll $t9, $t4, 2 @@ -193,9 +193,9 @@ glabel set_places .L80006A90: /* 007690 80006A90 00005825 */ move $t3, $zero .L80006A94: -/* 007694 80006A94 3C0D8016 */ lui $t5, %hi(gTrackCompletionPercentByPlayerId) # $t5, 0x8016 +/* 007694 80006A94 3C0D8016 */ lui $t5, %hi(gCourseCompletionPercentByPlayerId) # $t5, 0x8016 /* 007698 80006A98 2598FFFF */ addiu $t8, $t4, -1 -/* 00769C 80006A9C 25AD44D0 */ addiu $t5, %lo(gTrackCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 +/* 00769C 80006A9C 25AD44D0 */ addiu $t5, %lo(gCourseCompletionPercentByPlayerId) # addiu $t5, $t5, 0x44d0 /* 0076A0 80006AA0 1B000076 */ blez $t8, .L80006C7C /* 0076A4 80006AA4 AFB80030 */ sw $t8, 0x30($sp) /* 0076A8 80006AA8 3C0A8016 */ lui $t2, %hi(D_80164360) # $t2, 0x8016 @@ -219,10 +219,10 @@ glabel set_places /* 0076EC 80006AEC 8FAE0030 */ lw $t6, 0x30($sp) /* 0076F0 80006AF0 1020005D */ beqz $at, .L80006C68 /* 0076F4 80006AF4 01208025 */ move $s0, $t1 -/* 0076F8 80006AF8 3C0F8016 */ lui $t7, %hi(gTrackCompletionPercentByRank) # $t7, 0x8016 +/* 0076F8 80006AF8 3C0F8016 */ lui $t7, %hi(gCourseCompletionPercentByRank) # $t7, 0x8016 /* 0076FC 80006AFC 01898823 */ subu $s1, $t4, $t1 /* 007700 80006B00 32220001 */ andi $v0, $s1, 1 -/* 007704 80006B04 25EF2FD8 */ addiu $t7, %lo(gTrackCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 +/* 007704 80006B04 25EF2FD8 */ addiu $t7, %lo(gCourseCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 /* 007708 80006B08 000B2880 */ sll $a1, $t3, 2 /* 00770C 80006B0C 1040001D */ beqz $v0, .L80006B84 /* 007710 80006B10 00AF1821 */ addu $v1, $a1, $t7 @@ -256,8 +256,8 @@ glabel set_places .L80006B80: /* 007780 80006B80 120C0039 */ beq $s0, $t4, .L80006C68 .L80006B84: -/* 007784 80006B84 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByRank) # $t8, 0x8016 -/* 007788 80006B88 27182FD8 */ addiu $t8, %lo(gTrackCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 +/* 007784 80006B84 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByRank) # $t8, 0x8016 +/* 007788 80006B88 27182FD8 */ addiu $t8, %lo(gCourseCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 /* 00778C 80006B8C 00105880 */ sll $t3, $s0, 2 /* 007790 80006B90 01788821 */ addu $s1, $t3, $t8 .L80006B94: @@ -412,10 +412,10 @@ glabel set_places /* 0079B8 80006DB8 11000018 */ beqz $t0, .L80006E1C /* 0079BC 80006DBC 01003825 */ move $a3, $t0 /* 0079C0 80006DC0 000B2880 */ sll $a1, $t3, 2 -/* 0079C4 80006DC4 3C0E8016 */ lui $t6, %hi(gTrackCompletionPercentByRank) # $t6, 0x8016 +/* 0079C4 80006DC4 3C0E8016 */ lui $t6, %hi(gCourseCompletionPercentByRank) # $t6, 0x8016 /* 0079C8 80006DC8 3C198016 */ lui $t9, %hi(D_80164378) # $t9, 0x8016 /* 0079CC 80006DCC 27394378 */ addiu $t9, %lo(D_80164378) # addiu $t9, $t9, 0x4378 -/* 0079D0 80006DD0 25CE2FD8 */ addiu $t6, %lo(gTrackCompletionPercentByRank) # addiu $t6, $t6, 0x2fd8 +/* 0079D0 80006DD0 25CE2FD8 */ addiu $t6, %lo(gCourseCompletionPercentByRank) # addiu $t6, $t6, 0x2fd8 /* 0079D4 80006DD4 000BC040 */ sll $t8, $t3, 1 /* 0079D8 80006DD8 03193021 */ addu $a2, $t8, $t9 /* 0079DC 80006DDC 00AE1821 */ addu $v1, $a1, $t6 @@ -439,8 +439,8 @@ glabel set_places /* 007A1C 80006E1C 3C0F8016 */ lui $t7, %hi(D_80164378) # $t7, 0x8016 /* 007A20 80006E20 25EF4378 */ addiu $t7, %lo(D_80164378) # addiu $t7, $t7, 0x4378 /* 007A24 80006E24 000B2880 */ sll $a1, $t3, 2 -/* 007A28 80006E28 3C188016 */ lui $t8, %hi(gTrackCompletionPercentByRank) # $t8, 0x8016 -/* 007A2C 80006E2C 27182FD8 */ addiu $t8, %lo(gTrackCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 +/* 007A28 80006E28 3C188016 */ lui $t8, %hi(gCourseCompletionPercentByRank) # $t8, 0x8016 +/* 007A2C 80006E2C 27182FD8 */ addiu $t8, %lo(gCourseCompletionPercentByRank) # addiu $t8, $t8, 0x2fd8 /* 007A30 80006E30 000BC840 */ sll $t9, $t3, 1 /* 007A34 80006E34 000C7040 */ sll $t6, $t4, 1 /* 007A38 80006E38 01CF3821 */ addu $a3, $t6, $t7 @@ -486,10 +486,10 @@ glabel set_places /* 007AC8 80006EC8 012C082A */ slt $at, $t1, $t4 /* 007ACC 80006ECC 10200040 */ beqz $at, .L80006FD0 /* 007AD0 80006ED0 01208025 */ move $s0, $t1 -/* 007AD4 80006ED4 3C198016 */ lui $t9, %hi(gTrackCompletionPercentByRank) # $t9, 0x8016 +/* 007AD4 80006ED4 3C198016 */ lui $t9, %hi(gCourseCompletionPercentByRank) # $t9, 0x8016 /* 007AD8 80006ED8 01898823 */ subu $s1, $t4, $t1 /* 007ADC 80006EDC 32220001 */ andi $v0, $s1, 1 -/* 007AE0 80006EE0 27392FD8 */ addiu $t9, %lo(gTrackCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 +/* 007AE0 80006EE0 27392FD8 */ addiu $t9, %lo(gCourseCompletionPercentByRank) # addiu $t9, $t9, 0x2fd8 /* 007AE4 80006EE4 000B2880 */ sll $a1, $t3, 2 /* 007AE8 80006EE8 10400013 */ beqz $v0, .L80006F38 /* 007AEC 80006EEC 00B91821 */ addu $v1, $a1, $t9 @@ -513,8 +513,8 @@ glabel set_places .L80006F34: /* 007B34 80006F34 120C0026 */ beq $s0, $t4, .L80006FD0 .L80006F38: -/* 007B38 80006F38 3C0F8016 */ lui $t7, %hi(gTrackCompletionPercentByRank) # $t7, 0x8016 -/* 007B3C 80006F3C 25EF2FD8 */ addiu $t7, %lo(gTrackCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 +/* 007B38 80006F38 3C0F8016 */ lui $t7, %hi(gCourseCompletionPercentByRank) # $t7, 0x8016 +/* 007B3C 80006F3C 25EF2FD8 */ addiu $t7, %lo(gCourseCompletionPercentByRank) # addiu $t7, $t7, 0x2fd8 /* 007B40 80006F40 00105880 */ sll $t3, $s0, 2 /* 007B44 80006F44 000CC080 */ sll $t8, $t4, 2 /* 007B48 80006F48 030F3021 */ addu $a2, $t8, $t7 diff --git a/asm/non_matchings/code_800393C0/func_8003A9F0.s b/asm/non_matchings/code_800393C0/func_8003A9F0.s index 11f7fa6b0..0fc1d8777 100644 --- a/asm/non_matchings/code_800393C0/func_8003A9F0.s +++ b/asm/non_matchings/code_800393C0/func_8003A9F0.s @@ -12,8 +12,8 @@ glabel func_8003A9F0 /* 03B618 8003AA18 AFB00038 */ sw $s0, 0x38($sp) /* 03B61C 8003AA1C 0C00E769 */ jal func_80039DA4 /* 03B620 8003AA20 F7B40028 */ sdc1 $f20, 0x28($sp) -/* 03B624 8003AA24 3C0E8019 */ lui $t6, %hi(gCourseSelection) # $t6, 0x8019 -/* 03B628 8003AA28 81CEEE0B */ lb $t6, %lo(gCourseSelection)($t6) +/* 03B624 8003AA24 3C0E8019 */ lui $t6, %hi(gCupCourseSelection) # $t6, 0x8019 +/* 03B628 8003AA28 81CEEE0B */ lb $t6, %lo(gCupCourseSelection)($t6) /* 03B62C 8003AA2C 3C0F800E */ lui $t7, %hi(D_800DC51C) # $t7, 0x800e /* 03B630 8003AA30 11C00009 */ beqz $t6, .L8003AA58 /* 03B634 8003AA34 00000000 */ nop diff --git a/asm/non_matchings/code_80091750/func_80091EE4.s b/asm/non_matchings/code_80091750/func_80091EE4.s index 648e85f57..f09c6d2be 100644 --- a/asm/non_matchings/code_80091750/func_80091EE4.s +++ b/asm/non_matchings/code_80091750/func_80091EE4.s @@ -16,8 +16,8 @@ glabel func_80091EE4 /* 092B1C 80091F1C 1440001A */ bnez $v0, .L80091F88 /* 092B20 80091F20 3C0F8019 */ lui $t7, %hi(gCupSelection) # $t7, 0x8019 /* 092B24 80091F24 81EFEE09 */ lb $t7, %lo(gCupSelection)($t7) -/* 092B28 80091F28 3C198019 */ lui $t9, %hi(gCourseSelection) # $t9, 0x8019 -/* 092B2C 80091F2C 8339EE0B */ lb $t9, %lo(gCourseSelection)($t9) +/* 092B28 80091F28 3C198019 */ lui $t9, %hi(gCupCourseSelection) # $t9, 0x8019 +/* 092B2C 80091F2C 8339EE0B */ lb $t9, %lo(gCupCourseSelection)($t9) /* 092B30 80091F30 000FC080 */ sll $t8, $t7, 2 /* 092B34 80091F34 0C02D9C2 */ jal func_800B6708 /* 092B38 80091F38 03199021 */ addu $s2, $t8, $t9 diff --git a/asm/non_matchings/code_80091750/func_8009CE64.s b/asm/non_matchings/code_80091750/func_8009CE64.s index 485ef8f80..c97bf4985 100644 --- a/asm/non_matchings/code_80091750/func_8009CE64.s +++ b/asm/non_matchings/code_80091750/func_8009CE64.s @@ -449,9 +449,9 @@ glabel L8009D414 /* 09E0C0 8009D4C0 0324C821 */ addu $t9, $t9, $a0 /* 09E0C4 8009D4C4 8339FD50 */ lb $t9, %lo(gPerCupIndexByCourseId)($t9) /* 09E0C8 8009D4C8 AC38C540 */ sw $t8, %lo(D_800DC540)($at) -/* 09E0CC 8009D4CC 3C018019 */ lui $at, %hi(gCourseSelection) # $at, 0x8019 +/* 09E0CC 8009D4CC 3C018019 */ lui $at, %hi(gCupCourseSelection) # $at, 0x8019 /* 09E0D0 8009D4D0 1000001A */ b .L8009D53C -/* 09E0D4 8009D4D4 A039EE0B */ sb $t9, %lo(gCourseSelection)($at) +/* 09E0D4 8009D4D4 A039EE0B */ sb $t9, %lo(gCupCourseSelection)($at) glabel L8009D4D8 /* 09E0D8 8009D4D8 3C04800F */ lui $a0, %hi(D_800E86A0) # $a0, 0x800f /* 09E0DC 8009D4DC 248486A0 */ addiu $a0, %lo(D_800E86A0) # addiu $a0, $a0, -0x7960 @@ -614,9 +614,9 @@ glabel L8009D50C /* 09E30C 8009D70C 01E47821 */ addu $t7, $t7, $a0 /* 09E310 8009D710 81EFFD50 */ lb $t7, %lo(gPerCupIndexByCourseId)($t7) /* 09E314 8009D714 AC2EC540 */ sw $t6, %lo(D_800DC540)($at) -/* 09E318 8009D718 3C018019 */ lui $at, %hi(gCourseSelection) # $at, 0x8019 +/* 09E318 8009D718 3C018019 */ lui $at, %hi(gCupCourseSelection) # $at, 0x8019 /* 09E31C 8009D71C 10650013 */ beq $v1, $a1, .L8009D76C -/* 09E320 8009D720 A02FEE0B */ sb $t7, %lo(gCourseSelection)($at) +/* 09E320 8009D720 A02FEE0B */ sb $t7, %lo(gCupCourseSelection)($at) /* 09E324 8009D724 10660005 */ beq $v1, $a2, .L8009D73C /* 09E328 8009D728 3C01800E */ lui $at, %hi(gCCSelection) /* 09E32C 8009D72C 10670005 */ beq $v1, $a3, .L8009D744 diff --git a/asm/non_matchings/code_80091750/func_8009E650.s b/asm/non_matchings/code_80091750/func_8009E650.s index c90bc9d59..dcd068859 100644 --- a/asm/non_matchings/code_80091750/func_8009E650.s +++ b/asm/non_matchings/code_80091750/func_8009E650.s @@ -602,11 +602,11 @@ glabel L8009EF08 /* 09FB30 8009EF30 8FBF001C */ lw $ra, 0x1c($sp) glabel L8009EF34 /* 09FB34 8009EF34 8FF90000 */ lw $t9, ($ra) -/* 09FB38 8009EF38 3C0F800F */ lui $t7, %hi(gCupTrackOrder-0xBE) # 0x800f +/* 09FB38 8009EF38 3C0F800F */ lui $t7, %hi(gCupCourseOrder-0xBE) # 0x800f /* 09FB3C 8009EF3C 3C04800E */ lui $a0, %hi(D_800E7E34) /* 09FB40 8009EF40 00197040 */ sll $t6, $t9, 1 /* 09FB44 8009EF44 01EE7821 */ addu $t7, $t7, $t6 -/* 09FB48 8009EF48 85EF2AF6 */ lh $t7, %lo(gCupTrackOrder-0xBE)($t7) # 0x2af6($t7) +/* 09FB48 8009EF48 85EF2AF6 */ lh $t7, %lo(gCupCourseOrder-0xBE)($t7) # 0x2af6($t7) /* 09FB4C 8009EF4C AFBF007C */ sw $ra, 0x7c($sp) /* 09FB50 8009EF50 000FC080 */ sll $t8, $t7, 2 /* 09FB54 8009EF54 00982021 */ addu $a0, $a0, $t8 @@ -775,9 +775,9 @@ glabel L8009F174 .L8009F1AC: /* 09FDAC 8009F1AC 00197040 */ sll $t6, $t9, 1 /* 09FDB0 8009F1B0 01EEC021 */ addu $t8, $t7, $t6 -/* 09FDB4 8009F1B4 3C19800F */ lui $t9, %hi(gCupTrackOrder) +/* 09FDB4 8009F1B4 3C19800F */ lui $t9, %hi(gCupCourseOrder) /* 09FDB8 8009F1B8 0338C821 */ addu $t9, $t9, $t8 -/* 09FDBC 8009F1BC 87392BB4 */ lh $t9, %lo(gCupTrackOrder)($t9) +/* 09FDBC 8009F1BC 87392BB4 */ lh $t9, %lo(gCupCourseOrder)($t9) /* 09FDC0 8009F1C0 00197880 */ sll $t7, $t9, 2 /* 09FDC4 8009F1C4 008F2021 */ addu $a0, $a0, $t7 /* 09FDC8 8009F1C8 0C026449 */ jal segmented_to_virtual @@ -803,9 +803,9 @@ glabel L8009F174 .L8009F214: /* 09FE14 8009F214 00197840 */ sll $t7, $t9, 1 /* 09FE18 8009F218 030F7021 */ addu $t6, $t8, $t7 -/* 09FE1C 8009F21C 3C19800F */ lui $t9, %hi(gCupTrackOrder) +/* 09FE1C 8009F21C 3C19800F */ lui $t9, %hi(gCupCourseOrder) /* 09FE20 8009F220 032EC821 */ addu $t9, $t9, $t6 -/* 09FE24 8009F224 87392BB4 */ lh $t9, %lo(gCupTrackOrder)($t9) +/* 09FE24 8009F224 87392BB4 */ lh $t9, %lo(gCupCourseOrder)($t9) /* 09FE28 8009F228 0019C080 */ sll $t8, $t9, 2 /* 09FE2C 8009F22C 00982021 */ addu $a0, $a0, $t8 /* 09FE30 8009F230 0C026449 */ jal segmented_to_virtual @@ -939,8 +939,8 @@ glabel L8009F388 /* 0A000C 8009F40C 8FBF001C */ lw $ra, 0x1c($sp) /* 0A0010 8009F410 804F0000 */ lb $t7, ($v0) .L8009F414: -/* 0A0014 8009F414 3C198019 */ lui $t9, %hi(gCourseSelection) # $t9, 0x8019 -/* 0A0018 8009F418 8339EE0B */ lb $t9, %lo(gCourseSelection)($t9) +/* 0A0014 8009F414 3C198019 */ lui $t9, %hi(gCupCourseSelection) # $t9, 0x8019 +/* 0A0018 8009F418 8339EE0B */ lb $t9, %lo(gCupCourseSelection)($t9) /* 0A001C 8009F41C 000F7080 */ sll $t6, $t7, 2 /* 0A0020 8009F420 0C02D567 */ jal func_800B559C /* 0A0024 8009F424 01D92021 */ addu $a0, $t6, $t9 @@ -965,9 +965,9 @@ glabel L8009F430 .L8009F468: /* 0A0068 8009F468 000EC840 */ sll $t9, $t6, 1 /* 0A006C 8009F46C 01F9C021 */ addu $t8, $t7, $t9 -/* 0A0070 8009F470 3C0E800F */ lui $t6, %hi(gCupTrackOrder) +/* 0A0070 8009F470 3C0E800F */ lui $t6, %hi(gCupCourseOrder) /* 0A0074 8009F474 01D87021 */ addu $t6, $t6, $t8 -/* 0A0078 8009F478 85CE2BB4 */ lh $t6, %lo(gCupTrackOrder)($t6) +/* 0A0078 8009F478 85CE2BB4 */ lh $t6, %lo(gCupCourseOrder)($t6) /* 0A007C 8009F47C 000E7880 */ sll $t7, $t6, 2 /* 0A0080 8009F480 008F2021 */ addu $a0, $a0, $t7 /* 0A0084 8009F484 0C026455 */ jal segmented_to_virtual_dupe diff --git a/asm/non_matchings/code_80091750/func_800A15EC.s b/asm/non_matchings/code_80091750/func_800A15EC.s index 3f6c965eb..a4bd2d715 100644 --- a/asm/non_matchings/code_80091750/func_800A15EC.s +++ b/asm/non_matchings/code_80091750/func_800A15EC.s @@ -5,7 +5,7 @@ glabel func_800A15EC /* 0A21F8 800A15F8 AFB10034 */ sw $s1, 0x34($sp) /* 0A21FC 800A15FC AFB00030 */ sw $s0, 0x30($sp) /* 0A2200 800A1600 8C820000 */ lw $v0, ($a0) -/* 0A2204 800A1604 3C03800F */ lui $v1, %hi(gCupTrackOrder) +/* 0A2204 800A1604 3C03800F */ lui $v1, %hi(gCupCourseOrder) /* 0A2208 800A1608 00808025 */ move $s0, $a0 /* 0A220C 800A160C 2442FF84 */ addiu $v0, $v0, -0x7c /* 0A2210 800A1610 04410003 */ bgez $v0, .L800A1620 @@ -23,7 +23,7 @@ glabel func_800A15EC /* 0A2238 800A1638 0018C840 */ sll $t9, $t8, 1 /* 0A223C 800A163C 01F94021 */ addu $t0, $t7, $t9 /* 0A2240 800A1640 00681821 */ addu $v1, $v1, $t0 -/* 0A2244 800A1644 84632BB4 */ lh $v1, %lo(gCupTrackOrder)($v1) +/* 0A2244 800A1644 84632BB4 */ lh $v1, %lo(gCupCourseOrder)($v1) /* 0A2248 800A1648 3C04800E */ lui $a0, %hi(D_800E7D74) /* 0A224C 800A164C 00032880 */ sll $a1, $v1, 2 /* 0A2250 800A1650 00852021 */ addu $a0, $a0, $a1 diff --git a/asm/non_matchings/code_80091750/func_800A1924.s b/asm/non_matchings/code_80091750/func_800A1924.s index 9bc9b976e..f8a4b9037 100644 --- a/asm/non_matchings/code_80091750/func_800A1924.s +++ b/asm/non_matchings/code_80091750/func_800A1924.s @@ -33,7 +33,7 @@ glabel func_800A1924 .L800A19A0: /* 0A25A0 800A19A0 3C028019 */ lui $v0, %hi(D_8018EDF7) # $v0, 0x8019 /* 0A25A4 800A19A4 8042EDF7 */ lb $v0, %lo(D_8018EDF7)($v0) -/* 0A25A8 800A19A8 3C04800F */ lui $a0, %hi(gCupTrackOrder) +/* 0A25A8 800A19A8 3C04800F */ lui $a0, %hi(gCupCourseOrder) /* 0A25AC 800A19AC 04410003 */ bgez $v0, .L800A19BC /* 0A25B0 800A19B0 0002C083 */ sra $t8, $v0, 2 /* 0A25B4 800A19B4 24410003 */ addiu $at, $v0, 3 @@ -50,7 +50,7 @@ glabel func_800A1924 /* 0A25D8 800A19D8 03295021 */ addu $t2, $t9, $t1 /* 0A25DC 800A19DC 008A2021 */ addu $a0, $a0, $t2 /* 0A25E0 800A19E0 0C013BE7 */ jal func_8004EF9C -/* 0A25E4 800A19E4 84842BB4 */ lh $a0, %lo(gCupTrackOrder)($a0) +/* 0A25E4 800A19E4 84842BB4 */ lh $a0, %lo(gCupCourseOrder)($a0) /* 0A25E8 800A19E8 3C048015 */ lui $a0, %hi(gDisplayListHead) # $a0, 0x8015 /* 0A25EC 800A19EC 24840298 */ addiu $a0, %lo(gDisplayListHead) # addiu $a0, $a0, 0x298 /* 0A25F0 800A19F0 8C820000 */ lw $v0, ($a0) diff --git a/asm/non_matchings/code_80091750/func_800A1A20.s b/asm/non_matchings/code_80091750/func_800A1A20.s index feaeaffab..25e3acaa3 100644 --- a/asm/non_matchings/code_80091750/func_800A1A20.s +++ b/asm/non_matchings/code_80091750/func_800A1A20.s @@ -3,7 +3,7 @@ glabel func_800A1A20 /* 0A2624 800A1A24 8042EDF7 */ lb $v0, %lo(D_8018EDF7)($v0) /* 0A2628 800A1A28 27BDFFC8 */ addiu $sp, $sp, -0x38 /* 0A262C 800A1A2C AFB10028 */ sw $s1, 0x28($sp) -/* 0A2630 800A1A30 3C11800F */ lui $s1, %hi(gCupTrackOrder) +/* 0A2630 800A1A30 3C11800F */ lui $s1, %hi(gCupCourseOrder) /* 0A2634 800A1A34 AFB30030 */ sw $s3, 0x30($sp) /* 0A2638 800A1A38 00809825 */ move $s3, $a0 /* 0A263C 800A1A3C AFBF0034 */ sw $ra, 0x34($sp) @@ -25,7 +25,7 @@ glabel func_800A1A20 /* 0A2674 800A1A74 0018C840 */ sll $t9, $t8, 1 /* 0A2678 800A1A78 01F94021 */ addu $t0, $t7, $t9 /* 0A267C 800A1A7C 02288821 */ addu $s1, $s1, $t0 -/* 0A2680 800A1A80 86312BB4 */ lh $s1, %lo(gCupTrackOrder)($s1) +/* 0A2680 800A1A80 86312BB4 */ lh $s1, %lo(gCupCourseOrder)($s1) /* 0A2684 800A1A84 24090014 */ li $t1, 20 /* 0A2688 800A1A88 AE69000C */ sw $t1, 0xc($s3) /* 0A268C 800A1A8C 0C024C36 */ jal set_text_color diff --git a/asm/non_matchings/code_80091750/func_800A1FB0.s b/asm/non_matchings/code_80091750/func_800A1FB0.s index ad588d163..8f0379588 100644 --- a/asm/non_matchings/code_80091750/func_800A1FB0.s +++ b/asm/non_matchings/code_80091750/func_800A1FB0.s @@ -425,7 +425,7 @@ glabel L800A23DC /* 0A31D0 800A25D0 02602025 */ move $a0, $s3 /* 0A31D4 800A25D4 02402825 */ move $a1, $s2 /* 0A31D8 800A25D8 1720000B */ bnez $t9, .L800A2608 -/* 0A31DC 800A25DC 3C0D800F */ lui $t5, %hi(gCupTrackOrder) +/* 0A31DC 800A25DC 3C0D800F */ lui $t5, %hi(gCupCourseOrder) /* 0A31E0 800A25E0 3C06800E */ lui $a2, %hi(D_800E7A44) # $a2, 0x800e /* 0A31E4 800A25E4 8CC67A44 */ lw $a2, %lo(D_800E7A44)($a2) /* 0A31E8 800A25E8 02602025 */ move $a0, $s3 @@ -455,7 +455,7 @@ glabel L800A23DC /* 0A323C 800A263C 000A5840 */ sll $t3, $t2, 1 /* 0A3240 800A2640 012B6021 */ addu $t4, $t1, $t3 /* 0A3244 800A2644 01AC6821 */ addu $t5, $t5, $t4 -/* 0A3248 800A2648 85AD2BB4 */ lh $t5, %lo(gCupTrackOrder)($t5) +/* 0A3248 800A2648 85AD2BB4 */ lh $t5, %lo(gCupCourseOrder)($t5) /* 0A324C 800A264C E7B40010 */ swc1 $f20, 0x10($sp) /* 0A3250 800A2650 00003825 */ move $a3, $zero /* 0A3254 800A2654 000D7080 */ sll $t6, $t5, 2 @@ -618,7 +618,7 @@ glabel L800A26A8 /* 0A348C 800A288C 02602025 */ move $a0, $s3 /* 0A3490 800A2890 02402825 */ move $a1, $s2 /* 0A3494 800A2894 1580000B */ bnez $t4, .L800A28C4 -/* 0A3498 800A2898 3C08800F */ lui $t0, %hi(gCupTrackOrder) +/* 0A3498 800A2898 3C08800F */ lui $t0, %hi(gCupCourseOrder) /* 0A349C 800A289C 3C06800E */ lui $a2, %hi(D_800E7A44) # $a2, 0x800e /* 0A34A0 800A28A0 8CC67A44 */ lw $a2, %lo(D_800E7A44)($a2) /* 0A34A4 800A28A4 02602025 */ move $a0, $s3 @@ -648,7 +648,7 @@ glabel L800A26A8 /* 0A34F8 800A28F8 000FC040 */ sll $t8, $t7, 1 /* 0A34FC 800A28FC 01D8C821 */ addu $t9, $t6, $t8 /* 0A3500 800A2900 01194021 */ addu $t0, $t0, $t9 -/* 0A3504 800A2904 85082BB4 */ lh $t0, %lo(gCupTrackOrder)($t0) +/* 0A3504 800A2904 85082BB4 */ lh $t0, %lo(gCupCourseOrder)($t0) /* 0A3508 800A2908 E7B40010 */ swc1 $f20, 0x10($sp) /* 0A350C 800A290C 00003825 */ move $a3, $zero /* 0A3510 800A2910 00085080 */ sll $t2, $t0, 2 @@ -836,7 +836,7 @@ glabel L800A29D0 /* 0A37A8 800A2BA8 02602025 */ move $a0, $s3 /* 0A37AC 800A2BAC 02402825 */ move $a1, $s2 /* 0A37B0 800A2BB0 1560000B */ bnez $t3, .L800A2BE0 -/* 0A37B4 800A2BB4 3C19800F */ lui $t9, %hi(gCupTrackOrder) +/* 0A37B4 800A2BB4 3C19800F */ lui $t9, %hi(gCupCourseOrder) /* 0A37B8 800A2BB8 3C06800E */ lui $a2, %hi(D_800E7A44) # $a2, 0x800e /* 0A37BC 800A2BBC 8CC67A44 */ lw $a2, %lo(D_800E7A44)($a2) /* 0A37C0 800A2BC0 02602025 */ move $a0, $s3 @@ -866,7 +866,7 @@ glabel L800A29D0 /* 0A3814 800A2C14 000F7040 */ sll $t6, $t7, 1 /* 0A3818 800A2C18 01AEC021 */ addu $t8, $t5, $t6 /* 0A381C 800A2C1C 0338C821 */ addu $t9, $t9, $t8 -/* 0A3820 800A2C20 87392BB4 */ lh $t9, %lo(gCupTrackOrder)($t9) +/* 0A3820 800A2C20 87392BB4 */ lh $t9, %lo(gCupCourseOrder)($t9) /* 0A3824 800A2C24 E7B40010 */ swc1 $f20, 0x10($sp) /* 0A3828 800A2C28 00003825 */ move $a3, $zero /* 0A382C 800A2C2C 00194080 */ sll $t0, $t9, 2 diff --git a/asm/non_matchings/code_80091750/func_800A2EB8.s b/asm/non_matchings/code_80091750/func_800A2EB8.s index b409f44bc..c27678971 100644 --- a/asm/non_matchings/code_80091750/func_800A2EB8.s +++ b/asm/non_matchings/code_80091750/func_800A2EB8.s @@ -58,8 +58,8 @@ glabel func_800A2EB8 /* 0A3B94 800A2F94 2484002C */ addiu $a0, $a0, 0x2c /* 0A3B98 800A2F98 0C024CC9 */ jal func_80093324 /* 0A3B9C 800A2F9C 24A50028 */ addiu $a1, $a1, 0x28 -/* 0A3BA0 800A2FA0 3C048019 */ lui $a0, %hi(gCourseSelection) # $a0, 0x8019 -/* 0A3BA4 800A2FA4 8084EE0B */ lb $a0, %lo(gCourseSelection)($a0) +/* 0A3BA0 800A2FA0 3C048019 */ lui $a0, %hi(gCupCourseSelection) # $a0, 0x8019 +/* 0A3BA4 800A2FA4 8084EE0B */ lb $a0, %lo(gCupCourseSelection)($a0) /* 0A3BA8 800A2FA8 27A50068 */ addiu $a1, $sp, 0x68 /* 0A3BAC 800A2FAC 0C029E25 */ jal convert_number_to_ascii /* 0A3BB0 800A2FB0 24840001 */ addiu $a0, $a0, 1 diff --git a/asm/non_matchings/code_80091750/func_800A34A8.s b/asm/non_matchings/code_80091750/func_800A34A8.s index 468c2e845..935e767e5 100644 --- a/asm/non_matchings/code_80091750/func_800A34A8.s +++ b/asm/non_matchings/code_80091750/func_800A34A8.s @@ -56,9 +56,9 @@ glabel func_800A34A8 .L800A357C: /* 0A417C 800A357C 0C028E84 */ jal func_800A3A10 /* 0A4180 800A3580 27A40080 */ addiu $a0, $sp, 0x80 -/* 0A4184 800A3584 3C048019 */ lui $a0, %hi(gGPOverallRanks) # $a0, 0x8019 +/* 0A4184 800A3584 3C048019 */ lui $a0, %hi(gCharacterIdByGPOverallRank) # $a0, 0x8019 /* 0A4188 800A3588 0C028E84 */ jal func_800A3A10 -/* 0A418C 800A358C 2484D9D0 */ addiu $a0, %lo(gGPOverallRanks) # addiu $a0, $a0, -0x2630 +/* 0A418C 800A358C 2484D9D0 */ addiu $a0, %lo(gCharacterIdByGPOverallRank) # addiu $a0, $a0, -0x2630 .L800A3590: /* 0A4190 800A3590 0C024C36 */ jal set_text_color /* 0A4194 800A3594 24040004 */ li $a0, 4 @@ -90,8 +90,8 @@ glabel func_800A34A8 /* 0A41FC 800A35FC 24840036 */ addiu $a0, $a0, 0x36 /* 0A4200 800A3600 0C024CC9 */ jal func_80093324 /* 0A4204 800A3604 01AC2823 */ subu $a1, $t5, $t4 -/* 0A4208 800A3608 3C048019 */ lui $a0, %hi(gCourseSelection) # $a0, 0x8019 -/* 0A420C 800A360C 8084EE0B */ lb $a0, %lo(gCourseSelection)($a0) +/* 0A4208 800A3608 3C048019 */ lui $a0, %hi(gCupCourseSelection) # $a0, 0x8019 +/* 0A420C 800A360C 8084EE0B */ lb $a0, %lo(gCupCourseSelection)($a0) /* 0A4210 800A3610 27A50078 */ addiu $a1, $sp, 0x78 /* 0A4214 800A3614 0C029E25 */ jal convert_number_to_ascii /* 0A4218 800A3618 24840001 */ addiu $a0, $a0, 1 diff --git a/asm/non_matchings/code_80091750/func_800A3A10.s b/asm/non_matchings/code_80091750/func_800A3A10.s index c8d9ca6e8..586a32152 100644 --- a/asm/non_matchings/code_80091750/func_800A3A10.s +++ b/asm/non_matchings/code_80091750/func_800A3A10.s @@ -3,8 +3,8 @@ glabel func_800A3A10 /* 0A4614 800A3A14 AFB00004 */ sw $s0, 4($sp) /* 0A4618 800A3A18 3C108019 */ lui $s0, %hi(D_8018EDF3) # $s0, 0x8019 /* 0A461C 800A3A1C 3C0D8016 */ lui $t5, %hi(D_80164478) # $t5, 0x8016 -/* 0A4620 800A3A20 3C0B8019 */ lui $t3, %hi(gGPCharacterPoints) # $t3, 0x8019 -/* 0A4624 800A3A24 256BD9C8 */ addiu $t3, %lo(gGPCharacterPoints) # addiu $t3, $t3, -0x2638 +/* 0A4620 800A3A20 3C0B8019 */ lui $t3, %hi(gGPPointsByCharacterId) # $t3, 0x8019 +/* 0A4624 800A3A24 256BD9C8 */ addiu $t3, %lo(gGPPointsByCharacterId) # addiu $t3, $t3, -0x2638 /* 0A4628 800A3A28 25AD4478 */ addiu $t5, %lo(D_80164478) # addiu $t5, $t5, 0x4478 /* 0A462C 800A3A2C 2610EDF3 */ addiu $s0, %lo(D_8018EDF3) # addiu $s0, $s0, -0x120d /* 0A4630 800A3A30 00001025 */ move $v0, $zero diff --git a/asm/non_matchings/code_80091750/func_800A3ADC.s b/asm/non_matchings/code_80091750/func_800A3ADC.s index 8b1e509b3..b780fa1ba 100644 --- a/asm/non_matchings/code_80091750/func_800A3ADC.s +++ b/asm/non_matchings/code_80091750/func_800A3ADC.s @@ -21,8 +21,8 @@ glabel func_800A3ADC /* 0A4724 800A3B24 1B000010 */ blez $t8, .L800A3B68 /* 0A4728 800A3B28 03001825 */ move $v1, $t8 /* 0A472C 800A3B2C 8FB90054 */ lw $t9, 0x54($sp) -/* 0A4730 800A3B30 3C088019 */ lui $t0, %hi(gGPCharacterPoints) # $t0, 0x8019 -/* 0A4734 800A3B34 2508D9C8 */ addiu $t0, %lo(gGPCharacterPoints) # addiu $t0, $t0, -0x2638 +/* 0A4730 800A3B30 3C088019 */ lui $t0, %hi(gGPPointsByCharacterId) # $t0, 0x8019 +/* 0A4734 800A3B34 2508D9C8 */ addiu $t0, %lo(gGPPointsByCharacterId) # addiu $t0, $t0, -0x2638 /* 0A4738 800A3B38 03381021 */ addu $v0, $t9, $t8 .L800A3B3C: /* 0A473C 800A3B3C 80490000 */ lb $t1, ($v0) @@ -65,8 +65,8 @@ glabel func_800A3ADC /* 0A47C8 800A3BC8 0C024CC9 */ jal func_80093324 /* 0A47CC 800A3BCC 2484000A */ addiu $a0, $a0, 0xa /* 0A47D0 800A3BD0 8FA9004C */ lw $t1, 0x4c($sp) -/* 0A47D4 800A3BD4 3C088019 */ lui $t0, %hi(gGPCharacterPoints) # $t0, 0x8019 -/* 0A47D8 800A3BD8 2508D9C8 */ addiu $t0, %lo(gGPCharacterPoints) # addiu $t0, $t0, -0x2638 +/* 0A47D4 800A3BD4 3C088019 */ lui $t0, %hi(gGPPointsByCharacterId) # $t0, 0x8019 +/* 0A47D8 800A3BD8 2508D9C8 */ addiu $t0, %lo(gGPPointsByCharacterId) # addiu $t0, $t0, -0x2638 /* 0A47DC 800A3BDC 01095021 */ addu $t2, $t0, $t1 /* 0A47E0 800A3BE0 81440000 */ lb $a0, ($t2) /* 0A47E4 800A3BE4 0C029E25 */ jal convert_number_to_ascii diff --git a/asm/non_matchings/code_80091750/func_800A3C84.s b/asm/non_matchings/code_80091750/func_800A3C84.s index 79579faa0..0db05b953 100644 --- a/asm/non_matchings/code_80091750/func_800A3C84.s +++ b/asm/non_matchings/code_80091750/func_800A3C84.s @@ -11,15 +11,15 @@ glabel func_800A3C84 /* 0A48A8 800A3CA8 0C024C36 */ jal set_text_color /* 0A48AC 800A3CAC 24040004 */ li $a0, 4 /* 0A48B0 800A3CB0 3C0E8019 */ lui $t6, %hi(gCupSelection) # $t6, 0x8019 -/* 0A48B4 800A3CB4 3C188019 */ lui $t8, %hi(gCourseSelection) # $t8, 0x8019 -/* 0A48B8 800A3CB8 8318EE0B */ lb $t8, %lo(gCourseSelection)($t8) +/* 0A48B4 800A3CB4 3C188019 */ lui $t8, %hi(gCupCourseSelection) # $t8, 0x8019 +/* 0A48B8 800A3CB8 8318EE0B */ lb $t8, %lo(gCupCourseSelection)($t8) /* 0A48BC 800A3CBC 81CEEE09 */ lb $t6, %lo(gCupSelection)($t6) -/* 0A48C0 800A3CC0 3C09800F */ lui $t1, %hi(gCupTrackOrder) +/* 0A48C0 800A3CC0 3C09800F */ lui $t1, %hi(gCupCourseOrder) /* 0A48C4 800A3CC4 0018C840 */ sll $t9, $t8, 1 /* 0A48C8 800A3CC8 000E78C0 */ sll $t7, $t6, 3 /* 0A48CC 800A3CCC 01F94021 */ addu $t0, $t7, $t9 /* 0A48D0 800A3CD0 01284821 */ addu $t1, $t1, $t0 -/* 0A48D4 800A3CD4 85292BB4 */ lh $t1, %lo(gCupTrackOrder)($t1) +/* 0A48D4 800A3CD4 85292BB4 */ lh $t1, %lo(gCupCourseOrder)($t1) /* 0A48D8 800A3CD8 3C01800F */ lui $at, %hi(D_800F1CC8) # $at, 0x800f /* 0A48DC 800A3CDC C4201CC8 */ lwc1 $f0, %lo(D_800F1CC8)($at) /* 0A48E0 800A3CE0 8E44000C */ lw $a0, 0xc($s2) diff --git a/asm/non_matchings/code_80091750/func_800A3E60.s b/asm/non_matchings/code_80091750/func_800A3E60.s index 2506fbc5b..4b6bfb27b 100644 --- a/asm/non_matchings/code_80091750/func_800A3E60.s +++ b/asm/non_matchings/code_80091750/func_800A3E60.s @@ -18,15 +18,15 @@ glabel func_800A3E60 /* 0A4AA0 800A3EA0 0C024C36 */ jal set_text_color /* 0A4AA4 800A3EA4 24040004 */ li $a0, 4 /* 0A4AA8 800A3EA8 3C188019 */ lui $t8, %hi(gCupSelection) # $t8, 0x8019 -/* 0A4AAC 800A3EAC 3C098019 */ lui $t1, %hi(gCourseSelection) # $t1, 0x8019 -/* 0A4AB0 800A3EB0 8129EE0B */ lb $t1, %lo(gCourseSelection)($t1) +/* 0A4AAC 800A3EAC 3C098019 */ lui $t1, %hi(gCupCourseSelection) # $t1, 0x8019 +/* 0A4AB0 800A3EB0 8129EE0B */ lb $t1, %lo(gCupCourseSelection)($t1) /* 0A4AB4 800A3EB4 8318EE09 */ lb $t8, %lo(gCupSelection)($t8) -/* 0A4AB8 800A3EB8 3C0C800F */ lui $t4, %hi(gCupTrackOrder) +/* 0A4AB8 800A3EB8 3C0C800F */ lui $t4, %hi(gCupCourseOrder) /* 0A4ABC 800A3EBC 00095040 */ sll $t2, $t1, 1 /* 0A4AC0 800A3EC0 0018C8C0 */ sll $t9, $t8, 3 /* 0A4AC4 800A3EC4 032A5821 */ addu $t3, $t9, $t2 /* 0A4AC8 800A3EC8 018B6021 */ addu $t4, $t4, $t3 -/* 0A4ACC 800A3ECC 858C2BB4 */ lh $t4, %lo(gCupTrackOrder)($t4) +/* 0A4ACC 800A3ECC 858C2BB4 */ lh $t4, %lo(gCupCourseOrder)($t4) /* 0A4AD0 800A3ED0 3C01800F */ lui $at, %hi(D_800F1CCC) # $at, 0x800f /* 0A4AD4 800A3ED4 C4381CCC */ lwc1 $f24, %lo(D_800F1CCC)($at) /* 0A4AD8 800A3ED8 8E64000C */ lw $a0, 0xc($s3) @@ -241,7 +241,7 @@ glabel L800A412C /* 0A4DE8 800A41E8 240C00BB */ li $t4, 187 /* 0A4DEC 800A41EC 02002825 */ move $a1, $s0 /* 0A4DF0 800A41F0 1720000D */ bnez $t9, .L800A4228 -/* 0A4DF4 800A41F4 3C0A800F */ lui $t2, %hi(gCupTrackOrder) +/* 0A4DF4 800A41F4 3C0A800F */ lui $t2, %hi(gCupCourseOrder) /* 0A4DF8 800A41F8 8E69000C */ lw $t1, 0xc($s3) /* 0A4DFC 800A41FC 240A00BB */ li $t2, 187 /* 0A4E00 800A4200 3C06800E */ lui $a2, %hi(D_800E7A44) # $a2, 0x800e @@ -277,7 +277,7 @@ glabel L800A412C /* 0A4E6C 800A426C 00187040 */ sll $t6, $t8, 1 /* 0A4E70 800A4270 01EEC821 */ addu $t9, $t7, $t6 /* 0A4E74 800A4274 01595021 */ addu $t2, $t2, $t9 -/* 0A4E78 800A4278 854A2BB4 */ lh $t2, %lo(gCupTrackOrder)($t2) +/* 0A4E78 800A4278 854A2BB4 */ lh $t2, %lo(gCupCourseOrder)($t2) /* 0A4E7C 800A427C 000A4880 */ sll $t1, $t2, 2 /* 0A4E80 800A4280 00C93021 */ addu $a2, $a2, $t1 /* 0A4E84 800A4284 0C024CC9 */ jal func_80093324 diff --git a/asm/non_matchings/code_80091750/func_800A4BC8.s b/asm/non_matchings/code_80091750/func_800A4BC8.s index 34a220cc8..0e636b854 100644 --- a/asm/non_matchings/code_80091750/func_800A4BC8.s +++ b/asm/non_matchings/code_80091750/func_800A4BC8.s @@ -26,15 +26,15 @@ glabel func_800A4BC8 /* 0A5828 800A4C28 0C024C36 */ jal set_text_color /* 0A582C 800A4C2C 24040003 */ li $a0, 3 /* 0A5830 800A4C30 3C188019 */ lui $t8, %hi(gCupSelection) # $t8, 0x8019 -/* 0A5834 800A4C34 3C088019 */ lui $t0, %hi(gCourseSelection) # $t0, 0x8019 -/* 0A5838 800A4C38 8108EE0B */ lb $t0, %lo(gCourseSelection)($t0) +/* 0A5834 800A4C34 3C088019 */ lui $t0, %hi(gCupCourseSelection) # $t0, 0x8019 +/* 0A5838 800A4C38 8108EE0B */ lb $t0, %lo(gCupCourseSelection)($t0) /* 0A583C 800A4C3C 8318EE09 */ lb $t8, %lo(gCupSelection)($t8) -/* 0A5840 800A4C40 3C0B800F */ lui $t3, %hi(gCupTrackOrder) +/* 0A5840 800A4C40 3C0B800F */ lui $t3, %hi(gCupCourseOrder) /* 0A5844 800A4C44 00084840 */ sll $t1, $t0, 1 /* 0A5848 800A4C48 0018C8C0 */ sll $t9, $t8, 3 /* 0A584C 800A4C4C 03295021 */ addu $t2, $t9, $t1 /* 0A5850 800A4C50 016A5821 */ addu $t3, $t3, $t2 -/* 0A5854 800A4C54 856B2BB4 */ lh $t3, %lo(gCupTrackOrder)($t3) +/* 0A5854 800A4C54 856B2BB4 */ lh $t3, %lo(gCupCourseOrder)($t3) /* 0A5858 800A4C58 3C013F80 */ li $at, 0x3F800000 # 1.000000 /* 0A585C 800A4C5C 44810000 */ mtc1 $at, $f0 /* 0A5860 800A4C60 3C06800E */ lui $a2, %hi(D_800E7574) diff --git a/asm/non_matchings/code_80091750/func_800A5084.s b/asm/non_matchings/code_80091750/func_800A5084.s index 4733c252d..ba6fabe6b 100644 --- a/asm/non_matchings/code_80091750/func_800A5084.s +++ b/asm/non_matchings/code_80091750/func_800A5084.s @@ -130,15 +130,15 @@ glabel func_800A5084 /* 0A5E7C 800A527C 24A5FFCE */ addiu $a1, $a1, -0x32 /* 0A5E80 800A5280 0C024C36 */ jal set_text_color /* 0A5E84 800A5284 24040003 */ li $a0, 3 -/* 0A5E88 800A5288 3C0B8019 */ lui $t3, %hi(gCourseSelection) # $t3, 0x8019 -/* 0A5E8C 800A528C 816BEE0B */ lb $t3, %lo(gCourseSelection)($t3) +/* 0A5E88 800A5288 3C0B8019 */ lui $t3, %hi(gCupCourseSelection) # $t3, 0x8019 +/* 0A5E8C 800A528C 816BEE0B */ lb $t3, %lo(gCupCourseSelection)($t3) /* 0A5E90 800A5290 824F0000 */ lb $t7, ($s2) -/* 0A5E94 800A5294 3C0D800F */ lui $t5, %hi(gCupTrackOrder) +/* 0A5E94 800A5294 3C0D800F */ lui $t5, %hi(gCupCourseOrder) /* 0A5E98 800A5298 000BC840 */ sll $t9, $t3, 1 /* 0A5E9C 800A529C 000FC0C0 */ sll $t8, $t7, 3 /* 0A5EA0 800A52A0 03196021 */ addu $t4, $t8, $t9 /* 0A5EA4 800A52A4 01AC6821 */ addu $t5, $t5, $t4 -/* 0A5EA8 800A52A8 85AD2BB4 */ lh $t5, %lo(gCupTrackOrder)($t5) +/* 0A5EA8 800A52A8 85AD2BB4 */ lh $t5, %lo(gCupCourseOrder)($t5) /* 0A5EAC 800A52AC 86650002 */ lh $a1, 2($s3) /* 0A5EB0 800A52B0 3C06800E */ lui $a2, %hi(D_800E7574) /* 0A5EB4 800A52B4 000D7080 */ sll $t6, $t5, 2 diff --git a/asm/non_matchings/code_80091750/func_800A5738.s b/asm/non_matchings/code_80091750/func_800A5738.s index 17ad583c0..226f93a5d 100644 --- a/asm/non_matchings/code_80091750/func_800A5738.s +++ b/asm/non_matchings/code_80091750/func_800A5738.s @@ -103,15 +103,15 @@ glabel func_800A5738 /* 0A64B8 800A58B8 0C024C36 */ jal set_text_color /* 0A64BC 800A58BC 24040003 */ li $a0, 3 /* 0A64C0 800A58C0 3C188019 */ lui $t8, %hi(gCupSelection) # $t8, 0x8019 -/* 0A64C4 800A58C4 3C088019 */ lui $t0, %hi(gCourseSelection) # $t0, 0x8019 -/* 0A64C8 800A58C8 8108EE0B */ lb $t0, %lo(gCourseSelection)($t0) +/* 0A64C4 800A58C4 3C088019 */ lui $t0, %hi(gCupCourseSelection) # $t0, 0x8019 +/* 0A64C8 800A58C8 8108EE0B */ lb $t0, %lo(gCupCourseSelection)($t0) /* 0A64CC 800A58CC 8318EE09 */ lb $t8, %lo(gCupSelection)($t8) -/* 0A64D0 800A58D0 3C0B800F */ lui $t3, %hi(gCupTrackOrder) +/* 0A64D0 800A58D0 3C0B800F */ lui $t3, %hi(gCupCourseOrder) /* 0A64D4 800A58D4 00084840 */ sll $t1, $t0, 1 /* 0A64D8 800A58D8 0018C8C0 */ sll $t9, $t8, 3 /* 0A64DC 800A58DC 03295021 */ addu $t2, $t9, $t1 /* 0A64E0 800A58E0 016A5821 */ addu $t3, $t3, $t2 -/* 0A64E4 800A58E4 856B2BB4 */ lh $t3, %lo(gCupTrackOrder)($t3) +/* 0A64E4 800A58E4 856B2BB4 */ lh $t3, %lo(gCupCourseOrder)($t3) /* 0A64E8 800A58E8 3C013F80 */ li $at, 0x3F800000 # 1.000000 /* 0A64EC 800A58EC 44810000 */ mtc1 $at, $f0 /* 0A64F0 800A58F0 3C06800E */ lui $a2, %hi(D_800E7574) @@ -391,7 +391,7 @@ glabel L800A5C18 /* 0A691C 800A5D1C 8FB10054 */ lw $s1, 0x54($sp) .L800A5D20: /* 0A6920 800A5D20 82420005 */ lb $v0, 5($s2) -/* 0A6924 800A5D24 3C0B800F */ lui $t3, %hi(gCupTrackOrder) +/* 0A6924 800A5D24 3C0B800F */ lui $t3, %hi(gCupCourseOrder) /* 0A6928 800A5D28 8E6E000C */ lw $t6, 0xc($s3) /* 0A692C 800A5D2C E7B40014 */ swc1 $f20, 0x14($sp) /* 0A6930 800A5D30 E7B40010 */ swc1 $f20, 0x10($sp) @@ -412,7 +412,7 @@ glabel L800A5C18 /* 0A6964 800A5D64 00195040 */ sll $t2, $t9, 1 /* 0A6968 800A5D68 010A4821 */ addu $t1, $t0, $t2 /* 0A696C 800A5D6C 01695821 */ addu $t3, $t3, $t1 -/* 0A6970 800A5D70 856B2BB4 */ lh $t3, %lo(gCupTrackOrder)($t3) +/* 0A6970 800A5D70 856B2BB4 */ lh $t3, %lo(gCupCourseOrder)($t3) /* 0A6974 800A5D74 000B6880 */ sll $t5, $t3, 2 /* 0A6978 800A5D78 00CD3021 */ addu $a2, $a2, $t5 /* 0A697C 800A5D7C 0C024CC9 */ jal func_80093324 diff --git a/asm/non_matchings/code_80091750/func_800A8A98.s b/asm/non_matchings/code_80091750/func_800A8A98.s index 0e3fcb493..1abd98ea4 100644 --- a/asm/non_matchings/code_80091750/func_800A8A98.s +++ b/asm/non_matchings/code_80091750/func_800A8A98.s @@ -37,12 +37,12 @@ glabel func_800A8A98 /* 0A9724 800A8B24 356BF279 */ ori $t3, (0xFFFCF279 & 0xFFFF) # ori $t3, $t3, 0xf279 /* 0A9728 800A8B28 354AFFFF */ ori $t2, (0xFCFFFFFF & 0xFFFF) # ori $t2, $t2, 0xffff /* 0A972C 800A8B2C 3C10800E */ lui $s0, %hi(D_800E7208) # $s0, 0x800e -/* 0A9730 800A8B30 3C168019 */ lui $s6, %hi(gCourseSelection) # $s6, 0x8019 +/* 0A9730 800A8B30 3C168019 */ lui $s6, %hi(gCupCourseSelection) # $s6, 0x8019 /* 0A9734 800A8B34 3C178019 */ lui $s7, %hi(D_8018EDEC) # $s7, 0x8019 /* 0A9738 800A8B38 3C1E800E */ lui $fp, %hi(gModeSelection) # $fp, 0x800e /* 0A973C 800A8B3C 27DEC53C */ addiu $fp, %lo(gModeSelection) # addiu $fp, $fp, -0x3ac4 /* 0A9740 800A8B40 26F7EDEC */ addiu $s7, %lo(D_8018EDEC) # addiu $s7, $s7, -0x1214 -/* 0A9744 800A8B44 26D6EE0B */ addiu $s6, %lo(gCourseSelection) # addiu $s6, $s6, -0x11f5 +/* 0A9744 800A8B44 26D6EE0B */ addiu $s6, %lo(gCupCourseSelection) # addiu $s6, $s6, -0x11f5 /* 0A9748 800A8B48 26107208 */ addiu $s0, %lo(D_800E7208) # addiu $s0, $s0, 0x7208 /* 0A974C 800A8B4C 0000A025 */ move $s4, $zero /* 0A9750 800A8B50 24150004 */ li $s5, 4 diff --git a/asm/non_matchings/code_80091750/func_800A8F48.s b/asm/non_matchings/code_80091750/func_800A8F48.s index 18b1e4a22..09675f5bb 100644 --- a/asm/non_matchings/code_80091750/func_800A8F48.s +++ b/asm/non_matchings/code_80091750/func_800A8F48.s @@ -68,8 +68,8 @@ glabel func_800A8F48 .L800A9044: /* 0A9C44 800A9044 2694EE09 */ addiu $s4, $s4, %lo(gCupSelection) # -0x11f7 /* 0A9C48 800A9048 82890000 */ lb $t1, ($s4) -/* 0A9C4C 800A904C 3C0B8019 */ lui $t3, %hi(gCourseSelection) # $t3, 0x8019 -/* 0A9C50 800A9050 816BEE0B */ lb $t3, %lo(gCourseSelection)($t3) +/* 0A9C4C 800A904C 3C0B8019 */ lui $t3, %hi(gCupCourseSelection) # $t3, 0x8019 +/* 0A9C50 800A9050 816BEE0B */ lb $t3, %lo(gCupCourseSelection)($t3) /* 0A9C54 800A9054 00095080 */ sll $t2, $t1, 2 /* 0A9C58 800A9058 0C02D8E7 */ jal func_800B639C /* 0A9C5C 800A905C 014B2021 */ addu $a0, $t2, $t3 diff --git a/asm/non_matchings/code_80091750/func_800AB290.s b/asm/non_matchings/code_80091750/func_800AB290.s index a2d35678e..0b5374f9a 100644 --- a/asm/non_matchings/code_80091750/func_800AB290.s +++ b/asm/non_matchings/code_80091750/func_800AB290.s @@ -11,12 +11,12 @@ glabel func_800AB290 /* 0ABEB4 800AB2B4 AC82001C */ sw $v0, 0x1c($a0) /* 0ABEB8 800AB2B8 806F0000 */ lb $t7, ($v1) /* 0ABEBC 800AB2BC 8C990000 */ lw $t9, ($a0) -/* 0ABEC0 800AB2C0 3C0A800F */ lui $t2, %hi(gCupTrackOrder-0xBE) # 0x800f +/* 0ABEC0 800AB2C0 3C0A800F */ lui $t2, %hi(gCupCourseOrder-0xBE) # 0x800f /* 0ABEC4 800AB2C4 000FC0C0 */ sll $t8, $t7, 3 /* 0ABEC8 800AB2C8 00194040 */ sll $t0, $t9, 1 /* 0ABECC 800AB2CC 03084821 */ addu $t1, $t8, $t0 /* 0ABED0 800AB2D0 01495021 */ addu $t2, $t2, $t1 -/* 0ABED4 800AB2D4 854A2AF6 */ lh $t2, %lo(gCupTrackOrder-0xBE)($t2) # 0x2af6($t2) +/* 0ABED4 800AB2D4 854A2AF6 */ lh $t2, %lo(gCupCourseOrder-0xBE)($t2) # 0x2af6($t2) /* 0ABED8 800AB2D8 3C04800E */ lui $a0, %hi(D_800E7E34) /* 0ABEDC 800AB2DC AFA70018 */ sw $a3, 0x18($sp) /* 0ABEE0 800AB2E0 000A5880 */ sll $t3, $t2, 2 diff --git a/asm/non_matchings/code_80091750/func_800AB314.s b/asm/non_matchings/code_80091750/func_800AB314.s index 658dc9d8d..7b2eeead1 100644 --- a/asm/non_matchings/code_80091750/func_800AB314.s +++ b/asm/non_matchings/code_80091750/func_800AB314.s @@ -27,10 +27,10 @@ glabel func_800AB314 /* 0ABF74 800AB374 24040001 */ li $a0, 1 /* 0ABF78 800AB378 24030003 */ li $v1, 3 /* 0ABF7C 800AB37C 108F003A */ beq $a0, $t7, .L800AB468 -/* 0ABF80 800AB380 3C028019 */ lui $v0, %hi(gCourseSelection) # $v0, 0x8019 +/* 0ABF80 800AB380 3C028019 */ lui $v0, %hi(gCupCourseSelection) # $v0, 0x8019 /* 0ABF84 800AB384 ACC00004 */ sw $zero, 4($a2) /* 0ABF88 800AB388 ACC00020 */ sw $zero, 0x20($a2) -/* 0ABF8C 800AB38C 2442EE0B */ addiu $v0, %lo(gCourseSelection) # addiu $v0, $v0, -0x11f5 +/* 0ABF8C 800AB38C 2442EE0B */ addiu $v0, %lo(gCupCourseSelection) # addiu $v0, $v0, -0x11f5 /* 0ABF90 800AB390 80580000 */ lb $t8, ($v0) /* 0ABF94 800AB394 8FB90024 */ lw $t9, 0x24($sp) /* 0ABF98 800AB398 8FAB0024 */ lw $t3, 0x24($sp) diff --git a/asm/non_matchings/code_80091750/func_800AC458.s b/asm/non_matchings/code_80091750/func_800AC458.s index 6493f8d3f..cdb59e810 100644 --- a/asm/non_matchings/code_80091750/func_800AC458.s +++ b/asm/non_matchings/code_80091750/func_800AC458.s @@ -126,8 +126,8 @@ glabel L800AC5D0 /* 0AD228 800AC628 2518FFFF */ addiu $t8, $t0, -1 /* 0AD22C 800AC62C A0D80000 */ sb $t8, ($a2) /* 0AD230 800AC630 854A4360 */ lh $t2, %lo(D_80164360)($t2) # 0x4360($t2) -/* 0AD234 800AC634 3C0D8019 */ lui $t5, %hi(gGPCharacterPoints) # $t5, 0x8019 -/* 0AD238 800AC638 25ADD9C8 */ addiu $t5, %lo(gGPCharacterPoints) # addiu $t5, $t5, -0x2638 +/* 0AD234 800AC634 3C0D8019 */ lui $t5, %hi(gGPPointsByCharacterId) # $t5, 0x8019 +/* 0AD238 800AC638 25ADD9C8 */ addiu $t5, %lo(gGPPointsByCharacterId) # addiu $t5, $t5, -0x2638 /* 0AD23C 800AC63C 000A58C0 */ sll $t3, $t2, 3 /* 0AD240 800AC640 016A5823 */ subu $t3, $t3, $t2 /* 0AD244 800AC644 000B5900 */ sll $t3, $t3, 4 @@ -245,7 +245,7 @@ glabel L800AC7CC /* 0AD3DC 800AC7DC ACEF001C */ sw $t7, 0x1c($a3) /* 0AD3E0 800AC7E0 8318D9D8 */ lb $t8, %lo(D_8018D9D8)($t8) /* 0AD3E4 800AC7E4 25EAFFFB */ addiu $t2, $t7, -5 -/* 0AD3E8 800AC7E8 3C0D8019 */ lui $t5, %hi(gCourseSelection) # $t5, 0x8019 +/* 0AD3E8 800AC7E8 3C0D8019 */ lui $t5, %hi(gCupCourseSelection) # $t5, 0x8019 /* 0AD3EC 800AC7EC 53000003 */ beql $t8, $zero, .L800AC7FC /* 0AD3F0 800AC7F0 8CEB001C */ lw $t3, 0x1c($a3) /* 0AD3F4 800AC7F4 ACEA001C */ sw $t2, 0x1c($a3) @@ -255,16 +255,16 @@ glabel L800AC7CC /* 0AD400 800AC800 8FBF0014 */ lw $ra, 0x14($sp) /* 0AD404 800AC804 ACEC0004 */ sw $t4, 4($a3) /* 0AD408 800AC808 ACE0001C */ sw $zero, 0x1c($a3) -/* 0AD40C 800AC80C 81ADEE0B */ lb $t5, %lo(gCourseSelection)($t5) +/* 0AD40C 800AC80C 81ADEE0B */ lb $t5, %lo(gCupCourseSelection)($t5) /* 0AD410 800AC810 24010003 */ li $at, 3 /* 0AD414 800AC814 00002825 */ move $a1, $zero /* 0AD418 800AC818 15A10053 */ bne $t5, $at, .L800AC968 -/* 0AD41C 800AC81C 3C028019 */ lui $v0, %hi(gGPOverallRanks) # $v0, 0x8019 +/* 0AD41C 800AC81C 3C028019 */ lui $v0, %hi(gCharacterIdByGPOverallRank) # $v0, 0x8019 /* 0AD420 800AC820 3C038019 */ lui $v1, %hi(D_8018EDF3) # $v1, 0x8019 /* 0AD424 800AC824 3C048016 */ lui $a0, %hi(D_80164478) # $a0, 0x8016 /* 0AD428 800AC828 24844478 */ addiu $a0, %lo(D_80164478) # addiu $a0, $a0, 0x4478 /* 0AD42C 800AC82C 8063EDF3 */ lb $v1, %lo(D_8018EDF3)($v1) -/* 0AD430 800AC830 2442D9D0 */ addiu $v0, %lo(gGPOverallRanks) # addiu $v0, $v0, -0x2630 +/* 0AD430 800AC830 2442D9D0 */ addiu $v0, %lo(gCharacterIdByGPOverallRank) # addiu $v0, $v0, -0x2630 /* 0AD434 800AC834 24060008 */ li $a2, 8 .L800AC838: /* 0AD438 800AC838 804E0000 */ lb $t6, ($v0) diff --git a/asm/non_matchings/code_80091750/func_800AD2E8.s b/asm/non_matchings/code_80091750/func_800AD2E8.s index b0bd03498..98443d9c1 100644 --- a/asm/non_matchings/code_80091750/func_800AD2E8.s +++ b/asm/non_matchings/code_80091750/func_800AD2E8.s @@ -251,8 +251,8 @@ glabel L800AD438 /* 0AE288 800AD688 00000000 */ nop /* 0AE28C 800AD68C 3C098019 */ lui $t1, %hi(gCupSelection) # $t1, 0x8019 /* 0AE290 800AD690 8129EE09 */ lb $t1, %lo(gCupSelection)($t1) -/* 0AE294 800AD694 3C0B8019 */ lui $t3, %hi(gCourseSelection) # $t3, 0x8019 -/* 0AE298 800AD698 816BEE0B */ lb $t3, %lo(gCourseSelection)($t3) +/* 0AE294 800AD694 3C0B8019 */ lui $t3, %hi(gCupCourseSelection) # $t3, 0x8019 +/* 0AE298 800AD698 816BEE0B */ lb $t3, %lo(gCupCourseSelection)($t3) /* 0AE29C 800AD69C 00095080 */ sll $t2, $t1, 2 /* 0AE2A0 800AD6A0 0C02D8D2 */ jal func_800B6348 /* 0AE2A4 800AD6A4 014B2021 */ addu $a0, $t2, $t3 @@ -341,8 +341,8 @@ glabel L800AD764 /* 0AE3C4 800AD7C4 00000000 */ nop /* 0AE3C8 800AD7C8 3C0C8019 */ lui $t4, %hi(gCupSelection) # $t4, 0x8019 /* 0AE3CC 800AD7CC 818CEE09 */ lb $t4, %lo(gCupSelection)($t4) -/* 0AE3D0 800AD7D0 3C0E8019 */ lui $t6, %hi(gCourseSelection) # $t6, 0x8019 -/* 0AE3D4 800AD7D4 81CEEE0B */ lb $t6, %lo(gCourseSelection)($t6) +/* 0AE3D0 800AD7D0 3C0E8019 */ lui $t6, %hi(gCupCourseSelection) # $t6, 0x8019 +/* 0AE3D4 800AD7D4 81CEEE0B */ lb $t6, %lo(gCupCourseSelection)($t6) /* 0AE3D8 800AD7D8 000C6880 */ sll $t5, $t4, 2 /* 0AE3DC 800AD7DC 0C02D8D2 */ jal func_800B6348 /* 0AE3E0 800AD7E0 01AE2021 */ addu $a0, $t5, $t6 @@ -448,8 +448,8 @@ glabel L800AD954 /* 0AE558 800AD958 AE080020 */ sw $t0, 0x20($s0) /* 0AE55C 800AD95C 3C098019 */ lui $t1, %hi(gCupSelection) # $t1, 0x8019 /* 0AE560 800AD960 8129EE09 */ lb $t1, %lo(gCupSelection)($t1) -/* 0AE564 800AD964 3C0B8019 */ lui $t3, %hi(gCourseSelection) # $t3, 0x8019 -/* 0AE568 800AD968 816BEE0B */ lb $t3, %lo(gCourseSelection)($t3) +/* 0AE564 800AD964 3C0B8019 */ lui $t3, %hi(gCupCourseSelection) # $t3, 0x8019 +/* 0AE568 800AD968 816BEE0B */ lb $t3, %lo(gCupCourseSelection)($t3) /* 0AE56C 800AD96C 00095080 */ sll $t2, $t1, 2 /* 0AE570 800AD970 0C02D8E7 */ jal func_800B639C /* 0AE574 800AD974 014B2021 */ addu $a0, $t2, $t3 diff --git a/asm/non_matchings/code_80091750/func_800AE218.s b/asm/non_matchings/code_80091750/func_800AE218.s index 4da001380..069830981 100644 --- a/asm/non_matchings/code_80091750/func_800AE218.s +++ b/asm/non_matchings/code_80091750/func_800AE218.s @@ -186,8 +186,8 @@ glabel L800AE2E8 /* 0AF0C0 800AE4C0 00000000 */ nop /* 0AF0C4 800AE4C4 3C0B8019 */ lui $t3, %hi(gCupSelection) # $t3, 0x8019 /* 0AF0C8 800AE4C8 816BEE09 */ lb $t3, %lo(gCupSelection)($t3) -/* 0AF0CC 800AE4CC 3C0D8019 */ lui $t5, %hi(gCourseSelection) # $t5, 0x8019 -/* 0AF0D0 800AE4D0 81ADEE0B */ lb $t5, %lo(gCourseSelection)($t5) +/* 0AF0CC 800AE4CC 3C0D8019 */ lui $t5, %hi(gCupCourseSelection) # $t5, 0x8019 +/* 0AF0D0 800AE4D0 81ADEE0B */ lb $t5, %lo(gCupCourseSelection)($t5) /* 0AF0D4 800AE4D4 000B6080 */ sll $t4, $t3, 2 /* 0AF0D8 800AE4D8 0C02D8D2 */ jal func_800B6348 /* 0AF0DC 800AE4DC 018D2021 */ addu $a0, $t4, $t5 @@ -277,8 +277,8 @@ glabel L800AE59C /* 0AF1FC 800AE5FC 00000000 */ nop /* 0AF200 800AE600 3C0E8019 */ lui $t6, %hi(gCupSelection) # $t6, 0x8019 /* 0AF204 800AE604 81CEEE09 */ lb $t6, %lo(gCupSelection)($t6) -/* 0AF208 800AE608 3C188019 */ lui $t8, %hi(gCourseSelection) # $t8, 0x8019 -/* 0AF20C 800AE60C 8318EE0B */ lb $t8, %lo(gCourseSelection)($t8) +/* 0AF208 800AE608 3C188019 */ lui $t8, %hi(gCupCourseSelection) # $t8, 0x8019 +/* 0AF20C 800AE60C 8318EE0B */ lb $t8, %lo(gCupCourseSelection)($t8) /* 0AF210 800AE610 000E7880 */ sll $t7, $t6, 2 /* 0AF214 800AE614 0C02D8D2 */ jal func_800B6348 /* 0AF218 800AE618 01F82021 */ addu $a0, $t7, $t8 @@ -383,8 +383,8 @@ glabel L800AE788 /* 0AF38C 800AE78C AE080020 */ sw $t0, 0x20($s0) /* 0AF390 800AE790 3C098019 */ lui $t1, %hi(gCupSelection) # $t1, 0x8019 /* 0AF394 800AE794 8129EE09 */ lb $t1, %lo(gCupSelection)($t1) -/* 0AF398 800AE798 3C0B8019 */ lui $t3, %hi(gCourseSelection) # $t3, 0x8019 -/* 0AF39C 800AE79C 816BEE0B */ lb $t3, %lo(gCourseSelection)($t3) +/* 0AF398 800AE798 3C0B8019 */ lui $t3, %hi(gCupCourseSelection) # $t3, 0x8019 +/* 0AF39C 800AE79C 816BEE0B */ lb $t3, %lo(gCupCourseSelection)($t3) /* 0AF3A0 800AE7A0 00095080 */ sll $t2, $t1, 2 /* 0AF3A4 800AE7A4 0C02D8E7 */ jal func_800B639C /* 0AF3A8 800AE7A8 014B2021 */ addu $a0, $t2, $t3 diff --git a/asm/non_matchings/code_80091750/func_800AEDBC.s b/asm/non_matchings/code_80091750/func_800AEDBC.s index e392aa3a3..0709eeb00 100644 --- a/asm/non_matchings/code_80091750/func_800AEDBC.s +++ b/asm/non_matchings/code_80091750/func_800AEDBC.s @@ -10,7 +10,7 @@ glabel func_800AEDBC /* 0AF9DC 800AEDDC 8FBF0014 */ lw $ra, 0x14($sp) /* 0AF9E0 800AEDE0 AC82001C */ sw $v0, 0x1c($a0) /* 0AF9E4 800AEDE4 80620000 */ lb $v0, ($v1) -/* 0AF9E8 800AEDE8 3C0A800F */ lui $t2, %hi(gCupTrackOrder) +/* 0AF9E8 800AEDE8 3C0A800F */ lui $t2, %hi(gCupCourseOrder) /* 0AF9EC 800AEDEC 3C04800E */ lui $a0, %hi(D_800E7E34) /* 0AF9F0 800AEDF0 04410003 */ bgez $v0, .L800AEE00 /* 0AF9F4 800AEDF4 00027883 */ sra $t7, $v0, 2 @@ -27,7 +27,7 @@ glabel func_800AEDBC /* 0AFA18 800AEE18 00194040 */ sll $t0, $t9, 1 /* 0AFA1C 800AEE1C 03084821 */ addu $t1, $t8, $t0 /* 0AFA20 800AEE20 01495021 */ addu $t2, $t2, $t1 -/* 0AFA24 800AEE24 854A2BB4 */ lh $t2, %lo(gCupTrackOrder)($t2) +/* 0AFA24 800AEE24 854A2BB4 */ lh $t2, %lo(gCupCourseOrder)($t2) /* 0AFA28 800AEE28 AFA70018 */ sw $a3, 0x18($sp) /* 0AFA2C 800AEE2C 000A5880 */ sll $t3, $t2, 2 /* 0AFA30 800AEE30 008B2021 */ addu $a0, $a0, $t3 diff --git a/asm/non_matchings/code_800AF9B0/func_800B3B58.s b/asm/non_matchings/code_800AF9B0/func_800B3B58.s index 1fc6445eb..b53ab6664 100644 --- a/asm/non_matchings/code_800AF9B0/func_800B3B58.s +++ b/asm/non_matchings/code_800AF9B0/func_800B3B58.s @@ -80,15 +80,15 @@ glabel func_800B3B58 /* 0B4884 800B3C84 8042EE09 */ lb $v0, %lo(gCupSelection)($v0) /* 0B4888 800B3C88 8FA3001C */ lw $v1, 0x1c($sp) .L800B3C8C: -/* 0B488C 800B3C8C 3C0F8019 */ lui $t7, %hi(gCourseSelection) # $t7, 0x8019 -/* 0B4890 800B3C90 81EFEE0B */ lb $t7, %lo(gCourseSelection)($t7) +/* 0B488C 800B3C8C 3C0F8019 */ lui $t7, %hi(gCupCourseSelection) # $t7, 0x8019 +/* 0B4890 800B3C90 81EFEE0B */ lb $t7, %lo(gCupCourseSelection)($t7) /* 0B4894 800B3C94 000270C0 */ sll $t6, $v0, 3 -/* 0B4898 800B3C98 3C08800F */ lui $t0, %hi(gCupTrackOrder) # 0x800f +/* 0B4898 800B3C98 3C08800F */ lui $t0, %hi(gCupCourseOrder) # 0x800f /* 0B489C 800B3C9C 000FC040 */ sll $t8, $t7, 1 /* 0B48A0 800B3CA0 01D8C821 */ addu $t9, $t6, $t8 /* 0B48A4 800B3CA4 3C01800E */ lui $at, %hi(D_800DC540) # $at, 0x800e /* 0B48A8 800B3CA8 01194021 */ addu $t0, $t0, $t9 -/* 0B48AC 800B3CAC 85082BB4 */ lh $t0, %lo(gCupTrackOrder)($t0) # 0x2bb4($t0) +/* 0B48AC 800B3CAC 85082BB4 */ lh $t0, %lo(gCupCourseOrder)($t0) # 0x2bb4($t0) /* 0B48B0 800B3CB0 AC22C540 */ sw $v0, %lo(D_800DC540)($at) /* 0B48B4 800B3CB4 3C01800E */ lui $at, %hi(gCurrentCourseId) # $at, 0x800e /* 0B48B8 800B3CB8 30694000 */ andi $t1, $v1, 0x4000 @@ -122,11 +122,11 @@ glabel func_800B3B58 /* 0B4920 800B3D20 A0AD0000 */ sb $t5, ($a1) /* 0B4924 800B3D24 3C0F8019 */ lui $t7, %hi(gCupSelection) # $t7, 0x8019 /* 0B4928 800B3D28 81EFEE09 */ lb $t7, %lo(gCupSelection)($t7) -/* 0B492C 800B3D2C 3C18800F */ lui $t8, %hi(gCupTrackOrder) # 0x800f +/* 0B492C 800B3D2C 3C18800F */ lui $t8, %hi(gCupCourseOrder) # 0x800f /* 0B4930 800B3D30 3C048019 */ lui $a0, %hi(D_8018EE00) # $a0, 0x8019 /* 0B4934 800B3D34 000F70C0 */ sll $t6, $t7, 3 /* 0B4938 800B3D38 030EC021 */ addu $t8, $t8, $t6 -/* 0B493C 800B3D3C 87182BB4 */ lh $t8, %lo(gCupTrackOrder)($t8) # 0x2bb4($t8) +/* 0B493C 800B3D3C 87182BB4 */ lh $t8, %lo(gCupCourseOrder)($t8) # 0x2bb4($t8) /* 0B4940 800B3D40 3C01800E */ lui $at, %hi(gCurrentCourseId) # $at, 0x800e /* 0B4944 800B3D44 2484EE00 */ addiu $a0, %lo(D_8018EE00) # addiu $a0, $a0, -0x1200 /* 0B4948 800B3D48 A438C5A0 */ sh $t8, %lo(gCurrentCourseId)($at) @@ -139,8 +139,8 @@ glabel func_800B3B58 .L800B3D60: /* 0B4960 800B3D60 13200010 */ beqz $t9, .L800B3DA4 /* 0B4964 800B3D64 00C01825 */ move $v1, $a2 -/* 0B4968 800B3D68 3C048019 */ lui $a0, %hi(gCourseSelection) # $a0, 0x8019 -/* 0B496C 800B3D6C 2484EE0B */ addiu $a0, %lo(gCourseSelection) # addiu $a0, $a0, -0x11f5 +/* 0B4968 800B3D68 3C048019 */ lui $a0, %hi(gCupCourseSelection) # $a0, 0x8019 +/* 0B496C 800B3D6C 2484EE0B */ addiu $a0, %lo(gCupCourseSelection) # addiu $a0, $a0, -0x11f5 /* 0B4970 800B3D70 80820000 */ lb $v0, ($a0) /* 0B4974 800B3D74 28410003 */ slti $at, $v0, 3 /* 0B4978 800B3D78 1020000A */ beqz $at, .L800B3DA4 @@ -155,8 +155,8 @@ glabel func_800B3B58 /* 0B499C 800B3D9C 24A5EDEC */ addiu $a1, %lo(D_8018EDEC) # addiu $a1, $a1, -0x1214 /* 0B49A0 800B3DA0 8FA3001C */ lw $v1, 0x1c($sp) .L800B3DA4: -/* 0B49A4 800B3DA4 3C048019 */ lui $a0, %hi(gCourseSelection) # $a0, 0x8019 -/* 0B49A8 800B3DA8 2484EE0B */ addiu $a0, %lo(gCourseSelection) # addiu $a0, $a0, -0x11f5 +/* 0B49A4 800B3DA4 3C048019 */ lui $a0, %hi(gCupCourseSelection) # $a0, 0x8019 +/* 0B49A8 800B3DA8 2484EE0B */ addiu $a0, %lo(gCupCourseSelection) # addiu $a0, $a0, -0x11f5 /* 0B49AC 800B3DAC 30690800 */ andi $t1, $v1, 0x800 /* 0B49B0 800B3DB0 1120000E */ beqz $t1, .L800B3DEC /* 0B49B4 800B3DB4 80820000 */ lb $v0, ($a0) @@ -168,20 +168,20 @@ glabel func_800B3B58 /* 0B49CC 800B3DCC 3C044900 */ lui $a0, (0x49008000 >> 16) # lui $a0, 0x4900 /* 0B49D0 800B3DD0 0C032384 */ jal play_sound2 /* 0B49D4 800B3DD4 34848000 */ ori $a0, (0x49008000 & 0xFFFF) # ori $a0, $a0, 0x8000 -/* 0B49D8 800B3DD8 3C028019 */ lui $v0, %hi(gCourseSelection) # $v0, 0x8019 +/* 0B49D8 800B3DD8 3C028019 */ lui $v0, %hi(gCupCourseSelection) # $v0, 0x8019 /* 0B49DC 800B3DDC 3C058019 */ lui $a1, %hi(D_8018EDEC) # $a1, 0x8019 /* 0B49E0 800B3DE0 24A5EDEC */ addiu $a1, %lo(D_8018EDEC) # addiu $a1, $a1, -0x1214 -/* 0B49E4 800B3DE4 8042EE0B */ lb $v0, %lo(gCourseSelection)($v0) +/* 0B49E4 800B3DE4 8042EE0B */ lb $v0, %lo(gCupCourseSelection)($v0) /* 0B49E8 800B3DE8 8FA3001C */ lw $v1, 0x1c($sp) .L800B3DEC: /* 0B49EC 800B3DEC 3C0B8019 */ lui $t3, %hi(gCupSelection) # $t3, 0x8019 /* 0B49F0 800B3DF0 816BEE09 */ lb $t3, %lo(gCupSelection)($t3) /* 0B49F4 800B3DF4 00026840 */ sll $t5, $v0, 1 -/* 0B49F8 800B3DF8 3C0E800F */ lui $t6, %hi(gCupTrackOrder) # 0x800f +/* 0B49F8 800B3DF8 3C0E800F */ lui $t6, %hi(gCupCourseOrder) # 0x800f /* 0B49FC 800B3DFC 000B60C0 */ sll $t4, $t3, 3 /* 0B4A00 800B3E00 018D7821 */ addu $t7, $t4, $t5 /* 0B4A04 800B3E04 01CF7021 */ addu $t6, $t6, $t7 -/* 0B4A08 800B3E08 85CE2BB4 */ lh $t6, %lo(gCupTrackOrder)($t6) # 0x2bb4($t6) +/* 0B4A08 800B3E08 85CE2BB4 */ lh $t6, %lo(gCupCourseOrder)($t6) # 0x2bb4($t6) /* 0B4A0C 800B3E0C 3C01800E */ lui $at, %hi(gCurrentCourseId) # $at, 0x800e /* 0B4A10 800B3E10 30784000 */ andi $t8, $v1, 0x4000 /* 0B4A14 800B3E14 13000011 */ beqz $t8, .L800B3E5C diff --git a/asm/non_matchings/code_800AF9B0/func_800B3F74.s b/asm/non_matchings/code_800AF9B0/func_800B3F74.s index 3fb35a140..25e2d2285 100644 --- a/asm/non_matchings/code_800AF9B0/func_800B3F74.s +++ b/asm/non_matchings/code_800AF9B0/func_800B3F74.s @@ -75,8 +75,8 @@ glabel L800B4070 /* 0B4C80 800B4080 A420C520 */ sh $zero, %lo(gEnableDebugMode)($at) /* 0B4C84 800B4084 2442EE09 */ addiu $v0, %lo(gCupSelection) # addiu $v0, $v0, -0x11f7 /* 0B4C88 800B4088 A0400000 */ sb $zero, ($v0) -/* 0B4C8C 800B408C 3C018019 */ lui $at, %hi(gCourseSelection) # $at, 0x8019 -/* 0B4C90 800B4090 A020EE0B */ sb $zero, %lo(gCourseSelection)($at) +/* 0B4C8C 800B408C 3C018019 */ lui $at, %hi(gCupCourseSelection) # $at, 0x8019 +/* 0B4C90 800B4090 A020EE0B */ sb $zero, %lo(gCupCourseSelection)($at) /* 0B4C94 800B4094 3C048019 */ lui $a0, %hi(D_8018EDF3) # $a0, 0x8019 /* 0B4C98 800B4098 3C018019 */ lui $at, %hi(D_8018EDF7) # $at, 0x8019 /* 0B4C9C 800B409C 2484EDF3 */ addiu $a0, %lo(D_8018EDF3) # addiu $a0, $a0, -0x120d @@ -350,13 +350,13 @@ glabel L800B43B0 /* 0B5058 800B4458 3C018019 */ lui $at, %hi(D_8018EE0A) # $at, 0x8019 /* 0B505C 800B445C A020EE0A */ sb $zero, %lo(D_8018EE0A)($at) /* 0B5060 800B4460 15C00003 */ bnez $t6, .L800B4470 -/* 0B5064 800B4464 3C028019 */ lui $v0, %hi(gGPCharacterPoints) # $v0, 0x8019 -/* 0B5068 800B4468 3C018019 */ lui $at, %hi(gCourseSelection) # $at, 0x8019 -/* 0B506C 800B446C A020EE0B */ sb $zero, %lo(gCourseSelection)($at) +/* 0B5064 800B4464 3C028019 */ lui $v0, %hi(gGPPointsByCharacterId) # $v0, 0x8019 +/* 0B5068 800B4468 3C018019 */ lui $at, %hi(gCupCourseSelection) # $at, 0x8019 +/* 0B506C 800B446C A020EE0B */ sb $zero, %lo(gCupCourseSelection)($at) .L800B4470: -/* 0B5070 800B4470 3C038019 */ lui $v1, %hi(gGPOverallRanks) # $v1, 0x8019 -/* 0B5074 800B4474 2463D9D0 */ addiu $v1, %lo(gGPOverallRanks) # addiu $v1, $v1, -0x2630 -/* 0B5078 800B4478 2442D9C8 */ addiu $v0, %lo(gGPCharacterPoints) # addiu $v0, $v0, -0x2638 +/* 0B5070 800B4470 3C038019 */ lui $v1, %hi(gCharacterIdByGPOverallRank) # $v1, 0x8019 +/* 0B5074 800B4474 2463D9D0 */ addiu $v1, %lo(gCharacterIdByGPOverallRank) # addiu $v1, $v1, -0x2630 +/* 0B5078 800B4478 2442D9C8 */ addiu $v0, %lo(gGPPointsByCharacterId) # addiu $v0, $v0, -0x2638 .L800B447C: /* 0B507C 800B447C 24420004 */ addiu $v0, $v0, 4 /* 0B5080 800B4480 A040FFFD */ sb $zero, -3($v0) diff --git a/asm/non_matchings/code_800AF9B0/func_800B5020.s b/asm/non_matchings/code_800AF9B0/func_800B5020.s index 71c1328df..abeb2b230 100644 --- a/asm/non_matchings/code_800AF9B0/func_800B5020.s +++ b/asm/non_matchings/code_800AF9B0/func_800B5020.s @@ -1,8 +1,8 @@ glabel func_800B5020 /* 0B5C20 800B5020 3C0E8019 */ lui $t6, %hi(gCupSelection) # $t6, 0x8019 /* 0B5C24 800B5024 81CEEE09 */ lb $t6, %lo(gCupSelection)($t6) -/* 0B5C28 800B5028 3C188019 */ lui $t8, %hi(gCourseSelection) # $t8, 0x8019 -/* 0B5C2C 800B502C 8318EE0B */ lb $t8, %lo(gCourseSelection)($t8) +/* 0B5C28 800B5028 3C188019 */ lui $t8, %hi(gCupCourseSelection) # $t8, 0x8019 +/* 0B5C2C 800B502C 8318EE0B */ lb $t8, %lo(gCupCourseSelection)($t8) /* 0B5C30 800B5030 000E7880 */ sll $t7, $t6, 2 /* 0B5C34 800B5034 27BDFFC0 */ addiu $sp, $sp, -0x40 /* 0B5C38 800B5038 01F81021 */ addu $v0, $t7, $t8 diff --git a/asm/non_matchings/code_800AF9B0/func_800B5218.s b/asm/non_matchings/code_800AF9B0/func_800B5218.s index 6de4c8041..642fc4f93 100644 --- a/asm/non_matchings/code_800AF9B0/func_800B5218.s +++ b/asm/non_matchings/code_800AF9B0/func_800B5218.s @@ -1,8 +1,8 @@ glabel func_800B5218 /* 0B5E18 800B5218 3C0E8019 */ lui $t6, %hi(gCupSelection) # $t6, 0x8019 /* 0B5E1C 800B521C 81CEEE09 */ lb $t6, %lo(gCupSelection)($t6) -/* 0B5E20 800B5220 3C188019 */ lui $t8, %hi(gCourseSelection) # $t8, 0x8019 -/* 0B5E24 800B5224 8318EE0B */ lb $t8, %lo(gCourseSelection)($t8) +/* 0B5E20 800B5220 3C188019 */ lui $t8, %hi(gCupCourseSelection) # $t8, 0x8019 +/* 0B5E24 800B5224 8318EE0B */ lb $t8, %lo(gCupCourseSelection)($t8) /* 0B5E28 800B5228 3C09800F */ lui $t1, %hi(D_800E86A8) # $t1, 0x800f /* 0B5E2C 800B522C 812986A8 */ lb $t1, %lo(D_800E86A8)($t1) /* 0B5E30 800B5230 27BDFFB8 */ addiu $sp, $sp, -0x48 diff --git a/asm/non_matchings/code_800AF9B0/func_800B6178.s b/asm/non_matchings/code_800AF9B0/func_800B6178.s index c95e795cb..f542cad2c 100644 --- a/asm/non_matchings/code_800AF9B0/func_800B6178.s +++ b/asm/non_matchings/code_800AF9B0/func_800B6178.s @@ -71,11 +71,11 @@ glabel func_800B6178 /* 0B6E7C 800B627C A26D0004 */ sb $t5, 4($s3) /* 0B6E80 800B6280 8E2E0000 */ lw $t6, ($s1) /* 0B6E84 800B6284 3C0F8019 */ lui $t7, %hi(gCupSelection) # $t7, 0x8019 -/* 0B6E88 800B6288 3C198019 */ lui $t9, %hi(gCourseSelection) # $t9, 0x8019 +/* 0B6E88 800B6288 3C198019 */ lui $t9, %hi(gCupCourseSelection) # $t9, 0x8019 /* 0B6E8C 800B628C 160E0006 */ bne $s0, $t6, .L800B62A8 /* 0B6E90 800B6290 3C098016 */ lui $t1, %hi(D_80162DFC) # $t1, 0x8016 /* 0B6E94 800B6294 81EFEE09 */ lb $t7, %lo(gCupSelection)($t7) -/* 0B6E98 800B6298 8339EE0B */ lb $t9, %lo(gCourseSelection)($t9) +/* 0B6E98 800B6298 8339EE0B */ lb $t9, %lo(gCupCourseSelection)($t9) /* 0B6E9C 800B629C 000FC080 */ sll $t8, $t7, 2 /* 0B6EA0 800B62A0 03194021 */ addu $t0, $t8, $t9 /* 0B6EA4 800B62A4 A2680005 */ sb $t0, 5($s3) diff --git a/asm/non_matchings/code_800AF9B0/func_800B63F0.s b/asm/non_matchings/code_800AF9B0/func_800B63F0.s index d220ce1e5..de89b6bf1 100644 --- a/asm/non_matchings/code_800AF9B0/func_800B63F0.s +++ b/asm/non_matchings/code_800AF9B0/func_800B63F0.s @@ -18,8 +18,8 @@ glabel func_800B63F0 /* 0B7030 800B6430 8339EE09 */ lb $t9, %lo(gCupSelection)($t9) /* 0B7034 800B6434 2718EE10 */ addiu $t8, %lo(D_8018EE10) # addiu $t8, $t8, -0x11f0 /* 0B7038 800B6438 001079C0 */ sll $t7, $s0, 7 -/* 0B703C 800B643C 3C098019 */ lui $t1, %hi(gCourseSelection) # $t1, 0x8019 -/* 0B7040 800B6440 8129EE0B */ lb $t1, %lo(gCourseSelection)($t1) +/* 0B703C 800B643C 3C098019 */ lui $t1, %hi(gCupCourseSelection) # $t1, 0x8019 +/* 0B7040 800B6440 8129EE0B */ lb $t1, %lo(gCupCourseSelection)($t1) /* 0B7044 800B6444 01F81021 */ addu $v0, $t7, $t8 /* 0B7048 800B6448 804B0005 */ lb $t3, 5($v0) /* 0B704C 800B644C 00194080 */ sll $t0, $t9, 2 diff --git a/data/data_0DD0A0_3.s b/data/data_0DD0A0_3.s index 2cae50ef3..0b7af68c6 100644 --- a/data/data_0DD0A0_3.s +++ b/data/data_0DD0A0_3.s @@ -6651,7 +6651,7 @@ glabel D_800F2BAB .byte 0x00, 0x00, 0x01, 0x06, 0x03 .byte 0x02, 0x04, 0x05, 0x07 -glabel gCupTrackOrder +glabel gCupCourseOrder .hword 0x0008, 0x0009, 0x0006, 0x000b # mushroom cup: LR, MMF, KTB, KD .hword 0x000a, 0x0005, 0x0001, 0x0000 # flower cup: TT, FS, CM, MR .hword 0x000e, 0x000c, 0x0007, 0x0002 # star cup: WS, SL, RRy, BC diff --git a/include/defines.h b/include/defines.h index 6248e07de..f48a6e253 100644 --- a/include/defines.h +++ b/include/defines.h @@ -119,4 +119,10 @@ #define DEMO_SIX 5 // Mario Luigi Peach Toad, Sherbert Land, Versus #define NUM_DEMOS 6 +#define CUP_COURSE_ONE 0 +#define CUP_COURSE_TWO 1 +#define CUP_COURSE_THREE 2 +#define CUP_COURSE_FOUR 3 +#define NUM_COURSES_PER_CUP 4 + #endif // DEFINES_H diff --git a/include/variables.h b/include/variables.h index 6ca304c59..ba04dbd98 100644 --- a/include/variables.h +++ b/include/variables.h @@ -6,25 +6,26 @@ #include "common_structs.h" extern s32 gCCSelection; -extern s8 gCourseSelection; +extern s8 gCharacterIdByGPOverallRank[8]; // D_8018D9D0 +extern f32 gCourseCompletionPercentByPlayerId[8]; // D_801644D0 +extern f32 gCourseCompletionPercentByRank[8]; // D_80162FD8 +extern s8 gCupCourseSelection; // D_8018EE0B extern char *gCupNames[]; // D_800E7500 extern s8 gCupSelection; -// Maps course IDs (as defined in the COURSES enum) to the -// cup they belong to +// Maps course IDs (as defined in the COURSES enum) to the cup they belong to extern u8 gCupSelectionByCourseId[NUM_COURSES]; // D_800E7664 extern s16 gCurrentCourseId; extern char *gDebugSoundModeNames[NUM_SOUND_MODES]; // D_800E7700 +extern s8 gGPPointsByCharacterId[8]; // D_8018D9C8 extern s16 gGPCurrentRacePlayerIdByRank[8]; // D_80164360 extern s8 gHumanPlayerCount; extern f32 gKartFrictionTable[]; extern f32 gKartBoundingBoxTable[]; extern f32 gKartGravityTable[]; -extern s8 gGPOverallRanks[8]; extern s32 gModeSelection; // Indicates the ID of the next title screen demo that will be played -extern u8 gNextDemoId; // D_800E86BC -// Maps course IDs (as defined in the COURSES enum) to an index -// in a given cup's track order +extern u8 gNextDemoId; // D_800E86BC +// Maps course IDs (as defined in the COURSES enum) to an index in a given cup's track order extern u8 gPerCupIndexByCourseId[NUM_COURSES]; // D_800EFD50 extern s32 gPlayerCountSelection1; extern u8 gSaveDataSoundMode; // D_8018ED14 @@ -32,11 +33,7 @@ extern u8 gSaveDataSoundModeBackup; // D_8018ED8C extern u8 gSoundMode; // D_8018EDF2 extern char *gSoundModeNames[NUM_SOUND_MODES]; // D_800E7710 // Indexed by Player ID. Track time in seconds since player has last crossed the finish line -extern f32 gTimePlayerLastTouchedFinishLine[8]; // D_8015F898 -// Indexed by Player ID. Tracks the percentage of the track has been completed -extern f32 gTrackCompletionPercentByPlayerId[8]; // D_801644D0 -// Indexed by Rank. Tracks the percentage of the track has been completed -extern f32 gTrackCompletionPercentByRank[8]; // D_80162FD8 +extern f32 gTimePlayerLastTouchedFinishLine[8]; // D_8015F898 extern struct_D_802874D8 D_802874D8; extern s16 D_801650D0[4][8]; diff --git a/src/code_800029B0.c b/src/code_800029B0.c index e83c773cc..99145952e 100644 --- a/src/code_800029B0.c +++ b/src/code_800029B0.c @@ -46,7 +46,7 @@ extern u32 D_8015F730; extern u32 D_8015F734; extern u32 gPrevLoadedAddress; extern s32 D_80150120; -extern s16 gCupTrackOrder[][4]; +extern s16 gCupCourseOrder[][4]; void func_800CA008(u8, u8); @@ -141,7 +141,7 @@ void func_80002A18(void) { gCourseDirection = 1.0f; } if (gModeSelection == GRAND_PRIX) { - gCurrentCourseId = gCupTrackOrder[gCupSelection][gCourseSelection]; + gCurrentCourseId = gCupCourseOrder[gCupSelection][gCupCourseSelection]; } D_800DC52C = D_800DC530; if (gCurrentCourseId != gCurrentlyLoadedCourseId) { diff --git a/src/code_80005FD0.c b/src/code_80005FD0.c index 6fd824e73..36d579da5 100644 --- a/src/code_80005FD0.c +++ b/src/code_80005FD0.c @@ -272,14 +272,14 @@ GLOBAL_ASM("asm/non_matchings/code_80005FD0/func_800065D0.s") #ifdef MIPS_TO_C //generated by mips_to_c commit 3c3b0cede1a99430bfd3edf8d385802b94f91307 extern ? gTimePlayerLastTouchedFinishLine; -extern ? gTrackCompletionPercentByRank; +extern ? gCourseCompletionPercentByRank; extern s16 D_8016348C; extern s16 D_80164360; extern ? D_80164378; extern ? D_801643D8; extern ? D_801643E0; extern ? D_80164408; -extern ? gTrackCompletionPercentByPlayerId; +extern ? gCourseCompletionPercentByPlayerId; extern ? gPlayers; void set_places(void) { @@ -474,14 +474,14 @@ block_7: temp_a1 = 0 * 4; phi_t2 = (0 * 2) + &D_80164360; phi_v0 = temp_a1 + &sp80; - phi_v1 = temp_a1 + &gTrackCompletionPercentByRank; + phi_v1 = temp_a1 + &gCourseCompletionPercentByRank; phi_t1 = 1; do { temp_a0 = *phi_t2; temp_v0_2 = phi_v0 + 4; temp_v1 = phi_v1 + 4; temp_v0_2->unk-4 = temp_a0; - temp_v1->unk-4 = *(&gTrackCompletionPercentByPlayerId + (temp_a0 * 4)); + temp_v1->unk-4 = *(&gCourseCompletionPercentByPlayerId + (temp_a0 * 4)); phi_t2 += 2; phi_v0 = temp_v0_2; phi_v1 = temp_v1; @@ -496,7 +496,7 @@ block_13: temp_a1_2 = phi_t3_9 * 4; phi_t2_2 = (phi_t3_9 * 2) + &D_80164360; phi_v0_2 = temp_a1_2 + &sp80; - phi_v1_2 = temp_a1_2 + &gTrackCompletionPercentByRank; + phi_v1_2 = temp_a1_2 + &gCourseCompletionPercentByRank; do { temp_a0_2 = *phi_t2_2; temp_v1_2 = phi_v1_2 + 0x10; @@ -507,16 +507,16 @@ block_13: temp_a0_4 = temp_t2->unk-4; phi_v0_2->unk8 = temp_a0_4; temp_a0_5 = temp_t2->unk-2; - temp_v1_2->unk-10 = *(&gTrackCompletionPercentByPlayerId + (temp_a0_2 * 4)); + temp_v1_2->unk-10 = *(&gCourseCompletionPercentByPlayerId + (temp_a0_2 * 4)); temp_v0_3 = phi_v0_2 + 0x10; - temp_v1_2->unk-C = *(&gTrackCompletionPercentByPlayerId + (temp_a0_3 * 4)); + temp_v1_2->unk-C = *(&gCourseCompletionPercentByPlayerId + (temp_a0_3 * 4)); temp_v0_3->unk-4 = temp_a0_5; - temp_v1_2->unk-4 = *(&gTrackCompletionPercentByPlayerId + (temp_a0_5 * 4)); - temp_v1_2->unk-8 = *(&gTrackCompletionPercentByPlayerId + (temp_a0_4 * 4)); + temp_v1_2->unk-4 = *(&gCourseCompletionPercentByPlayerId + (temp_a0_5 * 4)); + temp_v1_2->unk-8 = *(&gCourseCompletionPercentByPlayerId + (temp_a0_4 * 4)); phi_t2_2 = temp_t2; phi_v0_2 = temp_v0_3; phi_v1_2 = temp_v1_2; - } while (temp_v1_2 != ((phi_t4 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_v1_2 != ((phi_t4 * 4) + &gCourseCompletionPercentByRank)); } } phi_t3 = 0; @@ -529,7 +529,7 @@ block_13: temp_a1_3 = 0 * 4; phi_t2_3 = (0 * 2) + &D_80164360; phi_v0_3 = temp_a1_3 + &sp80; - phi_v1_3 = temp_a1_3 + &gTrackCompletionPercentByRank; + phi_v1_3 = temp_a1_3 + &gCourseCompletionPercentByRank; phi_t1_2 = 1; do { temp_a0_6 = *phi_t2_3; @@ -551,7 +551,7 @@ block_22: temp_a1_4 = phi_t3_10 * 4; phi_t2_4 = (phi_t3_10 * 2) + &D_80164360; phi_v0_4 = temp_a1_4 + &sp80; - phi_v1_4 = temp_a1_4 + &gTrackCompletionPercentByRank; + phi_v1_4 = temp_a1_4 + &gCourseCompletionPercentByRank; do { temp_a0_7 = *phi_t2_4; temp_v1_4 = phi_v1_4 + 0x10; @@ -571,7 +571,7 @@ block_22: phi_t2_4 = temp_t2_2; phi_v0_4 = temp_v0_5; phi_v1_4 = temp_v1_4; - } while (temp_v1_4 != ((phi_t4 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_v1_4 != ((phi_t4 * 4) + &gCourseCompletionPercentByRank)); } } } @@ -585,10 +585,10 @@ block_22: phi_s0_2 = phi_t1_3; if (phi_t1_3 < phi_t4) { temp_a1_5 = phi_t3 * 4; - temp_v1_5 = temp_a1_5 + &gTrackCompletionPercentByRank; + temp_v1_5 = temp_a1_5 + &gCourseCompletionPercentByRank; if (((phi_t4 - phi_t1_3) & 1) != 0) { temp_t3 = phi_t1_3 * 4; - temp_s1 = temp_t3 + &gTrackCompletionPercentByRank; + temp_s1 = temp_t3 + &gCourseCompletionPercentByRank; temp_f2 = *temp_s1; temp_f0 = *temp_v1_5; if (temp_f0 < temp_f2) { @@ -610,7 +610,7 @@ block_22: } else { block_34: temp_t3_2 = phi_s0_2 * 4; - phi_s1 = temp_t3_2 + &gTrackCompletionPercentByRank; + phi_s1 = temp_t3_2 + &gCourseCompletionPercentByRank; phi_s0 = phi_s0_2; phi_t3_2 = temp_t3_2; do { @@ -724,14 +724,14 @@ block_50: temp_a1_7 = 0 * 4; phi_a2 = (0 * 2) + &D_80164378; phi_v0_8 = &sp80 + temp_a1_7; - phi_v1_6 = temp_a1_7 + &gTrackCompletionPercentByRank; + phi_v1_6 = temp_a1_7 + &gCourseCompletionPercentByRank; phi_t1_6 = 0 + 1; do { temp_a1_8 = *phi_a2; temp_v0_11 = phi_v0_8 + 4; temp_v1_9 = phi_v1_6 + 4; temp_v0_11->unk-4 = temp_a1_8; - temp_v1_9->unk-4 = *(&gTrackCompletionPercentByPlayerId + (temp_a1_8 * 4)); + temp_v1_9->unk-4 = *(&gCourseCompletionPercentByPlayerId + (temp_a1_8 * 4)); phi_a2 += 2; phi_v0_8 = temp_v0_11; phi_v1_6 = temp_v1_9; @@ -746,7 +746,7 @@ block_58: temp_a1_9 = phi_t3_12 * 4; phi_a2_2 = (phi_t3_12 * 2) + &D_80164378; phi_v0_9 = &sp80 + temp_a1_9; - phi_v1_7 = temp_a1_9 + &gTrackCompletionPercentByRank; + phi_v1_7 = temp_a1_9 + &gCourseCompletionPercentByRank; do { temp_a1_10 = *phi_a2_2; temp_a2 = phi_a2_2 + 8; @@ -757,12 +757,12 @@ block_58: temp_a1_12 = temp_a2->unk-4; temp_v0_12->unk-8 = temp_a1_12; temp_a1_13 = temp_a2->unk-2; - *phi_v1_7 = *(&gTrackCompletionPercentByPlayerId + (temp_a1_10 * 4)); + *phi_v1_7 = *(&gCourseCompletionPercentByPlayerId + (temp_a1_10 * 4)); temp_v1_10 = phi_v1_7 + 0x10; - temp_v1_10->unk-C = *(&gTrackCompletionPercentByPlayerId + (temp_a1_11 * 4)); + temp_v1_10->unk-C = *(&gCourseCompletionPercentByPlayerId + (temp_a1_11 * 4)); temp_v0_12->unk-4 = temp_a1_13; - temp_v1_10->unk-4 = *(&gTrackCompletionPercentByPlayerId + (temp_a1_13 * 4)); - temp_v1_10->unk-8 = *(&gTrackCompletionPercentByPlayerId + (temp_a1_12 * 4)); + temp_v1_10->unk-4 = *(&gCourseCompletionPercentByPlayerId + (temp_a1_13 * 4)); + temp_v1_10->unk-8 = *(&gCourseCompletionPercentByPlayerId + (temp_a1_12 * 4)); phi_a2_2 = temp_a2; phi_v0_9 = temp_v0_12; phi_v1_7 = temp_v1_10; @@ -776,10 +776,10 @@ block_58: phi_s0_3 = phi_t1_7; if (phi_t1_7 < phi_t4) { temp_a1_14 = phi_t3_5 * 4; - temp_v1_11 = temp_a1_14 + &gTrackCompletionPercentByRank; + temp_v1_11 = temp_a1_14 + &gCourseCompletionPercentByRank; if (((phi_t4 - phi_t1_7) & 1) != 0) { temp_t3_4 = phi_t1_7 * 4; - temp_s1_2 = temp_t3_4 + &gTrackCompletionPercentByRank; + temp_s1_2 = temp_t3_4 + &gCourseCompletionPercentByRank; temp_f2_4 = *temp_s1_2; temp_f0_3 = *temp_v1_11; temp_s0_4 = &sp80 + temp_t3_4; @@ -799,7 +799,7 @@ block_58: } else { block_67: temp_t3_5 = phi_s0_3 * 4; - phi_s1_2 = temp_t3_5 + &gTrackCompletionPercentByRank; + phi_s1_2 = temp_t3_5 + &gCourseCompletionPercentByRank; phi_t3_6 = temp_t3_5; do { temp_f0_4 = *temp_v1_11; @@ -827,7 +827,7 @@ block_67: temp_s1_3 = phi_s1_2 + 8; phi_s1_2 = temp_s1_3; phi_t3_6 += 8; - } while (temp_s1_3 != ((phi_t4 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_s1_3 != ((phi_t4 * 4) + &gCourseCompletionPercentByRank)); } } phi_t1_7 += 1; @@ -893,7 +893,7 @@ GLOBAL_ASM("asm/non_matchings/code_80005FD0/set_places.s") #ifdef MIPS_TO_C //generated by mips_to_c commit 3c3b0cede1a99430bfd3edf8d385802b94f91307 extern ? gTimePlayerLastTouchedFinishLine; -extern ? gTrackCompletionPercentByRank; +extern ? gCourseCompletionPercentByRank; extern ? D_80164360; extern ? D_801643D8; extern ? D_801643E0; @@ -998,7 +998,7 @@ block_7: temp_a0 = 0 * 4; phi_t0 = (0 * 2) + &D_80164360; phi_v0 = temp_a0 + &sp50; - phi_v1 = temp_a0 + &gTrackCompletionPercentByRank; + phi_v1 = temp_a0 + &gCourseCompletionPercentByRank; phi_a1 = 1; do { temp_a0_2 = *phi_t0; @@ -1020,7 +1020,7 @@ block_12: temp_a0_3 = phi_a3_5 * 4; phi_t0_2 = (phi_a3_5 * 2) + &D_80164360; phi_v0_2 = temp_a0_3 + &sp50; - phi_v1_2 = temp_a0_3 + &gTrackCompletionPercentByRank; + phi_v1_2 = temp_a0_3 + &gCourseCompletionPercentByRank; do { temp_a0_4 = *phi_t0_2; temp_v1_2 = phi_v1_2 + 0x10; @@ -1040,7 +1040,7 @@ block_12: phi_t0_2 = temp_t0; phi_v0_2 = temp_v0_3; phi_v1_2 = temp_v1_2; - } while (temp_v1_2 != ((phi_a2 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_v1_2 != ((phi_a2 * 4) + &gCourseCompletionPercentByRank)); } } temp_t0_2 = phi_a2 - 1; @@ -1052,10 +1052,10 @@ block_12: phi_v0_6 = phi_a1_2; if (phi_a1_2 < phi_a2) { temp_a0_8 = phi_a3 * 4; - temp_v1_3 = temp_a0_8 + &gTrackCompletionPercentByRank; + temp_v1_3 = temp_a0_8 + &gCourseCompletionPercentByRank; if (((phi_a2 - phi_a1_2) & 1) != 0) { temp_a3 = phi_a1_2 * 4; - temp_t3 = temp_a3 + &gTrackCompletionPercentByRank; + temp_t3 = temp_a3 + &gCourseCompletionPercentByRank; temp_f2 = *temp_t3; temp_f0 = *temp_v1_3; temp_t1 = &sp50 + temp_a3; @@ -1075,7 +1075,7 @@ block_12: } else { block_21: temp_a3_2 = phi_v0_6 * 4; - phi_t1 = temp_a3_2 + &gTrackCompletionPercentByRank; + phi_t1 = temp_a3_2 + &gCourseCompletionPercentByRank; phi_a3_2 = temp_a3_2; do { temp_f0_2 = *temp_v1_3; @@ -1103,7 +1103,7 @@ block_21: temp_t1_2 = phi_t1 + 8; phi_t1 = temp_t1_2; phi_a3_2 += 8; - } while (temp_t1_2 != ((phi_a2 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_t1_2 != ((phi_a2 * 4) + &gCourseCompletionPercentByRank)); } } phi_a1_2 += 1; @@ -1175,11 +1175,11 @@ GLOBAL_ASM("asm/non_matchings/code_80005FD0/func_800070F4.s") #ifdef MIPS_TO_C //generated by mips_to_c commit 3c3b0cede1a99430bfd3edf8d385802b94f91307 extern ? gTimePlayerLastTouchedFinishLine; -extern f32 gTrackCompletionPercentByRank; +extern f32 gCourseCompletionPercentByRank; extern ? D_80164360; extern ? D_801643D8; extern ? D_801643E0; -extern ? gTrackCompletionPercentByPlayerId; +extern ? gCourseCompletionPercentByPlayerId; extern ? gPlayers; void func_800074D4(void) { @@ -1281,7 +1281,7 @@ void func_800074D4(void) { s32 phi_v0_12; s32 phi_v0_13; - phi_a0 = &gTrackCompletionPercentByRank; + phi_a0 = &gCourseCompletionPercentByRank; phi_a3 = 1; phi_a3_2 = 1; phi_a3_4 = 1; @@ -1302,28 +1302,28 @@ void func_800074D4(void) { phi_v0_2 = phi_v0; if ((phi_a0_2->unk0 & 0x800) != 0) { *(&sp68 + temp_v1) = phi_t0; - *(&gTrackCompletionPercentByRank + temp_v1) = -*(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4)); + *(&gCourseCompletionPercentByRank + temp_v1) = -*(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4)); phi_v0_2 = phi_v0 + 1; } temp_v1_2 = phi_v0_2 * 4; phi_v0_3 = phi_v0_2; if ((phi_a0_2->unkDD8 & 0x800) != 0) { *(&sp68 + temp_v1_2) = phi_t0 + 1; - *(&gTrackCompletionPercentByRank + temp_v1_2) = -(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4))->unk4; + *(&gCourseCompletionPercentByRank + temp_v1_2) = -(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4))->unk4; phi_v0_3 = phi_v0_2 + 1; } temp_v1_3 = phi_v0_3 * 4; phi_v0_4 = phi_v0_3; if ((phi_a0_2->unk1BB0 & 0x800) != 0) { *(&sp68 + temp_v1_3) = phi_t0 + 2; - *(&gTrackCompletionPercentByRank + temp_v1_3) = -(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4))->unk8; + *(&gCourseCompletionPercentByRank + temp_v1_3) = -(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4))->unk8; phi_v0_4 = phi_v0_3 + 1; } temp_v1_4 = phi_v0_4 * 4; phi_v0_9 = phi_v0_4; if ((phi_a0_2->unk2988 & 0x800) != 0) { *(&sp68 + temp_v1_4) = phi_t0 + 3; - *(&gTrackCompletionPercentByRank + temp_v1_4) = -(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4))->unkC; + *(&gCourseCompletionPercentByRank + temp_v1_4) = -(&gTimePlayerLastTouchedFinishLine + (phi_t0 * 4))->unkC; phi_v0_9 = phi_v0_4 + 1; } temp_t0 = phi_t0 + 4; @@ -1338,28 +1338,28 @@ void func_800074D4(void) { phi_v0_6 = phi_v0_5; if ((phi_a0_3->unk0 & 0x800) == 0) { *(&sp68 + temp_v1_5) = phi_t0_2; - *(&gTrackCompletionPercentByRank + temp_v1_5) = *(&gTrackCompletionPercentByPlayerId + (phi_t0_2 * 4)); + *(&gCourseCompletionPercentByRank + temp_v1_5) = *(&gCourseCompletionPercentByPlayerId + (phi_t0_2 * 4)); phi_v0_6 = phi_v0_5 + 1; } temp_v1_6 = phi_v0_6 * 4; phi_v0_7 = phi_v0_6; if ((phi_a0_3->unkDD8 & 0x800) == 0) { *(&sp68 + temp_v1_6) = phi_t0_2 + 1; - *(&gTrackCompletionPercentByRank + temp_v1_6) = (&gTrackCompletionPercentByPlayerId + (phi_t0_2 * 4))->unk4; + *(&gCourseCompletionPercentByRank + temp_v1_6) = (&gCourseCompletionPercentByPlayerId + (phi_t0_2 * 4))->unk4; phi_v0_7 = phi_v0_6 + 1; } temp_v1_7 = phi_v0_7 * 4; phi_v0_8 = phi_v0_7; if ((phi_a0_3->unk1BB0 & 0x800) == 0) { *(&sp68 + temp_v1_7) = phi_t0_2 + 2; - *(&gTrackCompletionPercentByRank + temp_v1_7) = (&gTrackCompletionPercentByPlayerId + (phi_t0_2 * 4))->unk8; + *(&gCourseCompletionPercentByRank + temp_v1_7) = (&gCourseCompletionPercentByPlayerId + (phi_t0_2 * 4))->unk8; phi_v0_8 = phi_v0_7 + 1; } temp_v1_8 = phi_v0_8 * 4; phi_v0_5 = phi_v0_8; if ((phi_a0_3->unk2988 & 0x800) == 0) { *(&sp68 + temp_v1_8) = phi_t0_2 + 3; - *(&gTrackCompletionPercentByRank + temp_v1_8) = (&gTrackCompletionPercentByPlayerId + (phi_t0_2 * 4))->unkC; + *(&gCourseCompletionPercentByRank + temp_v1_8) = (&gCourseCompletionPercentByPlayerId + (phi_t0_2 * 4))->unkC; phi_v0_5 = phi_v0_8 + 1; } temp_t0_2 = phi_t0_2 + 4; @@ -1372,10 +1372,10 @@ void func_800074D4(void) { phi_v0_12 = phi_a3_2; if (phi_a3_2 < phi_v0_9) { temp_a1 = phi_t0_3 * 4; - temp_a0 = temp_a1 + &gTrackCompletionPercentByRank; + temp_a0 = temp_a1 + &gCourseCompletionPercentByRank; if (((phi_v0_9 - phi_a3_2) & 1) != 0) { temp_v1_9 = phi_a3_2 * 4; - temp_t4 = temp_v1_9 + &gTrackCompletionPercentByRank; + temp_t4 = temp_v1_9 + &gCourseCompletionPercentByRank; temp_f2 = *temp_t4; temp_f0 = *temp_a0; temp_t0_3 = &sp68 + temp_v1_9; @@ -1395,7 +1395,7 @@ void func_800074D4(void) { } else { block_41: temp_v1_10 = phi_v0_12 * 4; - phi_t4 = temp_v1_10 + &gTrackCompletionPercentByRank; + phi_t4 = temp_v1_10 + &gCourseCompletionPercentByRank; phi_v1 = temp_v1_10; do { temp_f0_2 = *temp_a0; @@ -1423,7 +1423,7 @@ block_41: temp_t4_2 = phi_t4 + 8; phi_t4 = temp_t4_2; phi_v1 += 8; - } while (temp_t4_2 != ((phi_v0_9 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_t4_2 != ((phi_v0_9 * 4) + &gCourseCompletionPercentByRank)); } } phi_a3_2 += 1; @@ -1437,10 +1437,10 @@ block_41: phi_v0_13 = phi_a3_3; if (phi_a3_3 < 8) { temp_a1_2 = phi_t0_4 * 4; - temp_a0_2 = temp_a1_2 + &gTrackCompletionPercentByRank; + temp_a0_2 = temp_a1_2 + &gCourseCompletionPercentByRank; if (((8 - phi_a3_3) & 1) != 0) { temp_v1_11 = phi_a3_3 * 4; - temp_t4_3 = temp_v1_11 + &gTrackCompletionPercentByRank; + temp_t4_3 = temp_v1_11 + &gCourseCompletionPercentByRank; temp_f2_4 = *temp_t4_3; temp_f0_3 = *temp_a0_2; temp_t0_6 = &sp68 + temp_v1_11; @@ -1460,7 +1460,7 @@ block_41: } else { block_55: temp_v1_12 = phi_v0_13 * 4; - phi_t4_2 = temp_v1_12 + &gTrackCompletionPercentByRank; + phi_t4_2 = temp_v1_12 + &gCourseCompletionPercentByRank; phi_v1_2 = temp_v1_12; do { temp_f0_4 = *temp_a0_2; @@ -1488,7 +1488,7 @@ block_55: temp_t4_4 = phi_t4_2 + 8; phi_t4_2 = temp_t4_4; phi_v1_2 += 8; - } while (temp_t4_4 != ((8 * 4) + &gTrackCompletionPercentByRank)); + } while (temp_t4_4 != ((8 * 4) + &gCourseCompletionPercentByRank)); } } phi_a3_3 += 1; @@ -2228,7 +2228,7 @@ extern s16 D_80162FCE; extern ? D_80164438; extern ? D_80164450; extern ? D_801644A8; -extern ? gTrackCompletionPercentByPlayerId; +extern ? gCourseCompletionPercentByPlayerId; extern ? D_801645B0; extern u16 D_801645C8; extern ? lapCount; @@ -2263,7 +2263,7 @@ void func_80008F38(s32 arg0) { } temp_f0 = phi_f6 / phi_f16; *(&D_801644A8 + temp_v0) = temp_f0; - *(&gTrackCompletionPercentByPlayerId + temp_v0) = temp_f0 + temp_v1; + *(&gCourseCompletionPercentByPlayerId + temp_v0) = temp_f0 + temp_v1; } #else GLOBAL_ASM("asm/non_matchings/code_80005FD0/func_80008F38.s") @@ -2967,7 +2967,7 @@ void func_80009B60(s32 arg0) { temp_a2 = temp_a1 * 2; if ((temp_v1->unk0 & 0x8000) == 0) { *(&D_80164450 + temp_a3) = -0x14; - *(&gTrackCompletionPercentByPlayerId + temp_a3) = -1000.0f; + *(&gCourseCompletionPercentByPlayerId + temp_a3) = -1000.0f; *(&D_801644A8 + temp_a3) = -1000.0f; return; } @@ -6359,7 +6359,7 @@ extern ? D_80164438; extern ? D_80164448; extern s32 D_80164450; extern ? D_80164478; -extern f32 gTrackCompletionPercentByPlayerId; +extern f32 gCourseCompletionPercentByPlayerId; extern s16 D_801644F8; extern ? D_80164538; extern ? D_801645B0; @@ -6484,7 +6484,7 @@ void func_8000F628(void) { spD0 = &lapCount; spB8 = &D_80163258; spBC = &D_80164408; - spCC = &gTrackCompletionPercentByPlayerId; + spCC = &gCourseCompletionPercentByPlayerId; spC8 = &gTimePlayerLastTouchedFinishLine; spB0 = &D_801631E0; spB4 = &D_80163270; @@ -9943,7 +9943,7 @@ void func_80014DE4(s32 arg0) { temp_v1 = temp_v0 + &D_80164678; *temp_v1 = *(&D_80164670 + temp_v0); temp_a1 = gModeSelection; - if ((temp_a1 != TIME_TRIALS) && ((gCourseSelection == 0) || (D_800DC51C == 1))) { + if ((temp_a1 != TIME_TRIALS) && ((gCupCourseSelection == CUP_COURSE_ONE) || (D_800DC51C == 1))) { goto block_8; } temp_a2 = *temp_v1; diff --git a/src/code_800393C0.c b/src/code_800393C0.c index d2809b7b5..28eae48a7 100644 --- a/src/code_800393C0.c +++ b/src/code_800393C0.c @@ -406,7 +406,7 @@ void func_80039DA4(void) { temp_80039DA4 sp2C = D_800E4360; temp_80039DA4 spC = D_800E4380; - if (((gCourseSelection == 0) && (D_8016556E == 0)) || + if (((gCupCourseSelection == CUP_COURSE_ONE) && (D_8016556E == 0)) || (D_800DC51C == 1) || (D_8018EDEF == 0x40)) { for (i = 0; i < 8; i++) { @@ -421,7 +421,7 @@ void func_80039DA4(void) { void func_80039F44(f32 *arg0, f32 *arg1, f32 arg2) { func_80039DA4(); - if (((gCourseSelection == 0) && (D_8016556E == 0)) || + if (((gCupCourseSelection == CUP_COURSE_ONE) && (D_8016556E == 0)) || (D_800DC51C == 1) || (D_8018EDEF == 0x40)) { s16 rand; @@ -509,7 +509,7 @@ void func_8003A59C(f32 *arg0, f32 *arg1, f32 arg2) { void func_8003A9F0(f32* arg0, f32* arg1, f32 arg2) { func_80039DA4(); - if ((gCourseSelection == 0) || (D_800DC51C == 1) || (D_8018EDEF == 0x40)) { + if ((gCupCourseSelection == CUP_COURSE_ONE) || (D_800DC51C == 1) || (D_8018EDEF == 0x40)) { s16 rand; s16 i; @@ -689,13 +689,13 @@ extern f32 D_800EDE58; extern f32 D_800EDE5C; void func_8003BE30(void) { - spawn_player(D_800DC4DC, 0, -2770.774f, -345.187f, D_800EDE20, 0.0f, gGPOverallRanks[0], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); - spawn_player(D_800DC4E0, 1, -3691.506f, -6.822f, D_800EDE24, D_800EDE28, gGPOverallRanks[1], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); - spawn_player(D_800DC4E4, 2, -3475.028f, -998.485f, D_800EDE2C, D_800EDE30, gGPOverallRanks[2], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); + spawn_player(D_800DC4DC, 0, -2770.774f, -345.187f, D_800EDE20, 0.0f, gCharacterIdByGPOverallRank[0], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); + spawn_player(D_800DC4E0, 1, -3691.506f, -6.822f, D_800EDE24, D_800EDE28, gCharacterIdByGPOverallRank[1], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); + spawn_player(D_800DC4E4, 2, -3475.028f, -998.485f, D_800EDE2C, D_800EDE30, gCharacterIdByGPOverallRank[2], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); if (D_802874D8.unk_1D >= 3) { spawn_player(D_800DC4E8, 3, -3025.772f, 110.039f, D_800EDE34, D_800EDE38, D_802874D8.unk_1E, PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); } else { - spawn_player(D_800DC4E8, 3, -3025.772f, 110.039f, D_800EDE3C, D_800EDE40, gGPOverallRanks[3], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); + spawn_player(D_800DC4E8, 3, -3025.772f, 110.039f, D_800EDE3C, D_800EDE40, gCharacterIdByGPOverallRank[3], PLAYER_EXISTS | PLAYER_CPU | PLAYER_START_SEQUENCE); } spawn_player(D_800DC4EC, 4, -2770.774f, -345.187f, D_800EDE44, 0.0f, 0, 0x7000); spawn_player(D_800DC4F0, 5, -3691.506f, -6.822f, D_800EDE48, D_800EDE4C, 0, 0x7000); diff --git a/src/code_80091750.c b/src/code_80091750.c index 5407c41d9..abb639f96 100644 --- a/src/code_80091750.c +++ b/src/code_80091750.c @@ -408,7 +408,7 @@ void func_80091EE4(void) { D_800E86F8 = 0; if ((D_8018EDFB != 0) && (func_800B5F30() == 0)) { - temp_s2 = (gCupSelection * 4) + gCourseSelection; + temp_s2 = (gCupSelection * 4) + gCupCourseSelection; func_800B6708(); phi_s0 = 0; do { @@ -6755,7 +6755,7 @@ block_74: } gCupSelection = gCupSelectionByCourseId[gCurrentCourseId]; D_800DC540 = gCupSelection; - gCourseSelection = gPerCupIndexByCourseId[gCurrentCourseId]; + gCupCourseSelection = gPerCupIndexByCourseId[gCurrentCourseId]; phi_a0 = gCurrentCourseId; break; case 3: /* switch 3 */ @@ -6835,7 +6835,7 @@ block_74: gCupSelection = gCupSelectionByCourseId[gCurrentCourseId]; temp_v1_9 = D_8018EDFA; D_800DC540 = gCupSelection; - gCourseSelection = gPerCupIndexByCourseId[gCurrentCourseId]; + gCupCourseSelection = gPerCupIndexByCourseId[gCurrentCourseId]; if (temp_v1_9 != 1) { if (temp_v1_9 != 2) { if (temp_v1_9 != 3) { @@ -7940,7 +7940,7 @@ static ? D_800E8420; /* unable to generate initia static ? D_800E85F7; /* unable to generate initializer; const */ static s8 D_800E86A8 = 0; /* const */ static ? D_800EFD64; /* unable to generate initializer; const */ -static ? gCupTrackOrder; /* unable to generate initializer; const */ +static ? gCupCourseOrder; /* unable to generate initializer; const */ void func_8009E650(s32 arg0, s32 arg1, s32 arg2, s8 arg3) { void *sp7C; @@ -8204,7 +8204,7 @@ loop_3: case 0x61: /* switch 2 */ case 0x62: /* switch 2 */ sp7C = phi_ra; - phi_ra->unk18 = func_8009A374(segmented_to_virtual_dupe(*(&D_800E7E34 + (*(&gCupTrackOrder - 0xBE + (phi_ra->unk0 * 2)) * 4)), arg3)); + phi_ra->unk18 = func_8009A374(segmented_to_virtual_dupe(*(&D_800E7E34 + (*(&gCupCourseOrder - 0xBE + (phi_ra->unk0 * 2)) * 4)), arg3)); return; case 0x5E: /* switch 2 */ sp7C = phi_ra; @@ -8277,9 +8277,9 @@ loop_3: case 0x8B: /* switch 2 */ sp7C = phi_ra; temp_v0_5 = phi_ra->unk0 - 0x7C; - func_800996BC(segmented_to_virtual(*(&D_800E7D74 + (*(&gCupTrackOrder + (((temp_v0_5 / 4) * 8) + ((temp_v0_5 % 4) * 2))) * 4)), arg3), -1); + func_800996BC(segmented_to_virtual(*(&D_800E7D74 + (*(&gCupCourseOrder + (((temp_v0_5 / 4) * 8) + ((temp_v0_5 % 4) * 2))) * 4)), arg3), -1); temp_v0_6 = phi_ra->unk0 - 0x7C; - func_800996BC(segmented_to_virtual(*(&D_800E7DC4 + (*(&gCupTrackOrder + (((temp_v0_6 / 4) * 8) + ((temp_v0_6 % 4) * 2))) * 4))), 0); + func_800996BC(segmented_to_virtual(*(&D_800E7DC4 + (*(&gCupCourseOrder + (((temp_v0_6 / 4) * 8) + ((temp_v0_6 % 4) * 2))) * 4))), 0); func_800996BC(segmented_to_virtual(&D_02004A0C), 0); return; case 0xB1: /* switch 2 */ @@ -8337,7 +8337,7 @@ block_63: } } if ((phi_ra->unk1C == 0) || (phi_ra->unk20 != 0)) { - func_800B559C((gCupSelection * 4) + gCourseSelection); + func_800B559C((gCupSelection * 4) + gCupCourseSelection); return; } /* Duplicate return node #87. Try simplifying control flow for better match */ @@ -8345,7 +8345,7 @@ block_63: case 0xE6: /* switch 2 */ temp_v0_8 = D_8018EDF7; sp7C = phi_ra; - phi_ra->unk18 = func_8009A374(segmented_to_virtual_dupe(*(&D_800E7E34 + (*(&gCupTrackOrder + (((temp_v0_8 / 4) * 8) + ((temp_v0_8 % 4) * 2))) * 4)), arg3)); + phi_ra->unk18 = func_8009A374(segmented_to_virtual_dupe(*(&D_800E7E34 + (*(&gCupCourseOrder + (((temp_v0_8 / 4) * 8) + ((temp_v0_8 % 4) * 2))) * 4)), arg3)); phi_ra->unk1C = D_8018EDF7; func_800996BC(segmented_to_virtual(&D_02004A0C), 0); func_8006EF60(); @@ -9629,7 +9629,7 @@ s32 segmented_to_virtual(? *, s32); // extern extern ? D_02004A0C; extern ? D_800E7D74; extern ? D_800E7DC4; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; extern s32 gDisplayListHead; void func_800A15EC(void *arg0) { @@ -9643,7 +9643,7 @@ void func_800A15EC(void *arg0) { s32 temp_v1_2; temp_v0 = arg0->unk0 - 0x7C; - temp_a1 = *(&gCupTrackOrder + (((temp_v0 / 4) * 8) + ((temp_v0 % 4) * 2))) * 4; + temp_a1 = *(&gCupCourseOrder + (((temp_v0 / 4) * 8) + ((temp_v0 % 4) * 2))) * 4; sp44 = temp_a1; temp_v0_2 = func_8009C204(gDisplayListHead, segmented_to_virtual(*(&D_800E7D74 + temp_a1), temp_a1), arg0->unkC, arg0->unk10, 2); gDisplayListHead = temp_v0_2; @@ -9702,7 +9702,7 @@ void *func_8009BA74(void *, ? *, ?, ?); // extern s32 func_800B639C(s8); // extern extern ? D_02004A0C; extern s8 D_8018EDF7; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; extern void *gDisplayListHead; void func_800A1924(void *arg0) { @@ -9717,7 +9717,7 @@ void func_800A1924(void *arg0) { gDisplayListHead = func_8009BA74(temp_v0, &D_02004A0C, 0x57, 0x84); } temp_v0_2 = D_8018EDF7; - func_8004EF9C(*(&gCupTrackOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2)))); + func_8004EF9C(*(&gCupCourseOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2)))); temp_v0_3 = gDisplayListHead; gDisplayListHead = temp_v0_3 + 8; temp_v0_3->unk4 = 0x2000; @@ -9740,7 +9740,7 @@ extern ? *D_800E772C; extern ? D_800E77D8; extern ? D_800E77E4; extern s8 D_8018EDF7; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; void func_800A1A20(void *arg0) { s16 temp_s1; @@ -9751,7 +9751,7 @@ void func_800A1A20(void *arg0) { s32 phi_s1; temp_v0 = D_8018EDF7; - temp_s1 = *(&gCupTrackOrder + (((temp_v0 / 4) * 8) + ((temp_v0 % 4) * 2))); + temp_s1 = *(&gCupCourseOrder + (((temp_v0 / 4) * 8) + ((temp_v0 % 4) * 2))); arg0->unkC = 0x14; set_text_color(TEXT_BLUE_GREEN_RED_CYCLE_1); temp_s0 = temp_s1 * 4; @@ -9966,7 +9966,7 @@ static ? D_800E7938; /* unable to generate initia static ? *D_800E7A44 = "NO DATA"; /* const */ static ? *D_800E7A48[3] = { "CREATING ", "MARIO KART 64 ", "GAME DATA" }; /* const */ static ? D_800E7A54; /* unable to generate initializer; const */ -static ? gCupTrackOrder; /* unable to generate initializer; const */ +static ? gCupCourseOrder; /* unable to generate initializer; const */ void func_800A1FB0(void *arg0) { s16 spE2; @@ -10225,7 +10225,7 @@ loop_38: func_80093324(phi_s3, phi_s2_3, D_800E7A44, 0, 0.5f, 0.5f); } else { temp_v0 = phi_v1->unk5; - func_80093324(phi_s3, phi_s2_3, *(&D_800E75C4 + (*(&gCupTrackOrder + (((temp_v0 / 4) * 8) + ((temp_v0 % 4) * 2))) * 4)), 0, 0.5f, 0.5f); + func_80093324(phi_s3, phi_s2_3, *(&D_800E75C4 + (*(&gCupCourseOrder + (((temp_v0 / 4) * 8) + ((temp_v0 % 4) * 2))) * 4)), 0, 0.5f, 0.5f); } phi_s0_9 = temp_s1_4; phi_s2_3 += 0x1E; @@ -10283,7 +10283,7 @@ loop_58: func_80093324(phi_s3_2, phi_s2_4, D_800E7A44, 0, 0.5f, 0.5f); } else { temp_v0_2 = phi_v1_2->unk5; - func_80093324(phi_s3_2, phi_s2_4, *(&D_800E75C4 + (*(&gCupTrackOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2))) * 4)), 0, 0.5f, 0.5f); + func_80093324(phi_s3_2, phi_s2_4, *(&D_800E75C4 + (*(&gCupCourseOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2))) * 4)), 0, 0.5f, 0.5f); } phi_s0_11 = temp_s1_5; phi_s2_4 += 0x1E; @@ -10357,7 +10357,7 @@ loop_80: func_80093324(phi_s3_4, phi_s2_6, D_800E7A44, 0, 0.5f, 0.5f); } else { temp_v0_4 = phi_v1_3->unk5; - func_80093324(phi_s3_4, phi_s2_6, *(&D_800E75C4 + (*(&gCupTrackOrder + (((temp_v0_4 / 4) * 8) + ((temp_v0_4 % 4) * 2))) * 4)), 0, 0.5f, 0.5f); + func_80093324(phi_s3_4, phi_s2_6, *(&D_800E75C4 + (*(&gCupCourseOrder + (((temp_v0_4 / 4) * 8) + ((temp_v0_4 % 4) * 2))) * 4)), 0, 0.5f, 0.5f); } phi_s0_12 = temp_s1_6; phi_s2_6 += 0x1E; @@ -10516,7 +10516,7 @@ void func_800A2EB8(void *arg0) { temp_f0 = D_800F1C90; func_80093324(arg0->unkC + 0x2C, arg0->unk10 + 0x28, &D_800F0C24, 0, temp_f0, temp_f0); // Convert index of current course in the cup order into a round number - convert_number_to_ascii(gCourseSelection + 1, &sp68); + convert_number_to_ascii(gCupCourseSelection + 1, &sp68); // Print previously converted round number temp_f0_2 = D_800F1C94; func_80093324(arg0->unkC + 0x57, arg0->unk10 + 0x28, &sp69, 0, temp_f0_2, temp_f0_2); @@ -10693,7 +10693,7 @@ void func_800A34A8(void *arg0) { } while (temp_a0 != &D_80164370); } else { func_800A3A10(&sp80); - func_800A3A10(gGPOverallRanks); + func_800A3A10(gCharacterIdByGPOverallRank); } // "Driver's Points" set_text_color(TEXT_BLUE_GREEN_RED_CYCLE_1); @@ -10702,7 +10702,7 @@ void func_800A34A8(void *arg0) { set_text_color(5); func_80093324(arg0->unkC + 0x36, 0x28 - arg0->unk10, "round", 0, 0.7f, 0.7f); // Convert course index to a round number - convert_number_to_ascii(gCourseSelection + 1, &sp78); + convert_number_to_ascii(gCupCourseSelection + 1, &sp78); // Print round number func_80093324(arg0->unkC + 0x61, 0x28 - arg0->unk10, &sp79, 0, 0.7f, 0.7f); phi_s1 = 0; @@ -10806,8 +10806,8 @@ loop_3: temp_a3 = phi_a2->unk-1; temp_t1 = phi_a2->unk0; temp_a1 = phi_a1 - 1; - temp_t2 = gGPCharacterPoints[temp_t1]; - temp_t0 = gGPCharacterPoints[temp_a3]; + temp_t2 = gGPPointsByCharacterId[temp_t1]; + temp_t0 = gGPPointsByCharacterId[temp_a3]; phi_a1 = temp_a1; if (temp_t0 < temp_t2) { phi_a2->unk0 = temp_a3; @@ -10862,7 +10862,7 @@ void func_800A3ADC(void *arg0, s32 arg1, s32 arg2, s32 arg3, s32 arg4, s32 arg5) phi_v0 = arg5 + arg4; loop_4: phi_v1_2 = phi_v1; - if (gGPCharacterPoints[phi_v0->unk0] == gGPCharacterPoints[phi_v0->unk-1]) { + if (gGPPointsByCharacterId[phi_v0->unk0] == gGPPointsByCharacterId[phi_v0->unk-1]) { temp_v1 = phi_v1 - 1; phi_v0 += -1; phi_v1 = temp_v1; @@ -10881,7 +10881,7 @@ loop_4: // Print character name func_80093324(arg1 + 0xA, arg2, *(&D_800E76A8 + (arg3 * 4)), 0, 0.7f, 0.7f); // Print character's current point count - convert_number_to_ascii(gGPCharacterPoints[arg3], &sp34); + convert_number_to_ascii(gGPPointsByCharacterId[arg3], &sp34); func_800939C8(arg1 + 0x47, arg2, &sp34, 0, 0.7f, 0.7f); // Print "+" + points left to be allocated // Only done for rank 1, 2, 3 and 4 @@ -10909,7 +10909,7 @@ extern s32 D_800E772C; extern s32 D_800E7730; extern f32 D_800F1CC8; extern s8 gCupSelection; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; void func_800A3C84(void *arg0) { f32 temp_f0; @@ -10922,7 +10922,7 @@ void func_800A3C84(void *arg0) { set_text_color(TEXT_BLUE_GREEN_RED_CYCLE_1); temp_f0 = D_800F1CC8; - draw_text(arg0->unkC + 0x43, arg0->unk10 + 0x19, *(&D_800E7574 + (*(&gCupTrackOrder + ((gCupSelection * 8) + (gCourseSelection * 2))) * 4)), 0, temp_f0, temp_f0); + draw_text(arg0->unkC + 0x43, arg0->unk10 + 0x19, *(&D_800E7574 + (*(&gCupCourseOrder + ((gCupSelection * 8) + (gCupCourseSelection * 2))) * 4)), 0, temp_f0, temp_f0); set_text_color(TEXT_YELLOW); draw_text(arg0->unkC + 0x46, arg0->unk10 + 0x28, D_800E7730, 0, 0.75f, 0.75f); phi_s0 = 0; @@ -10980,7 +10980,7 @@ static ? *D_800E7A6C[2] = { "QUIT", "SAVE" }; /* const */ static ? *D_800E7A74[3] = { "SAVING GHOST DATA", "", "PLEASE WAIT" }; /* const */ static ? *D_800E7A80[2] = { "UNABLE TO SAVE ", "THE GHOST" }; /* const */ static ? D_800E7A88; /* unable to generate initializer; const */ -static ? gCupTrackOrder; /* unable to generate initializer; const */ +static ? gCupCourseOrder; /* unable to generate initializer; const */ void func_800A3E60(void *arg0) { s16 sp86; @@ -11034,7 +11034,7 @@ void func_800A3E60(void *arg0) { temp_v0 = arg0->unk4; if ((temp_v0 != 0) && (temp_v0 != 0x1F)) { set_text_color(TEXT_BLUE_GREEN_RED_CYCLE_1); - draw_text(arg0->unkC + 0x55, 0x19 - arg0->unk10, *(&D_800E7574 + (*(&gCupTrackOrder + ((gCupSelection * 8) + (gCourseSelection * 2))) * 4)), 0, 0.6f, 0.6f); + draw_text(arg0->unkC + 0x55, 0x19 - arg0->unk10, *(&D_800E7574 + (*(&gCupCourseOrder + ((gCupSelection * 8) + (gCupCourseSelection * 2))) * 4)), 0, 0.6f, 0.6f); set_text_color(TEXT_YELLOW); draw_text(arg0->unkC + 0x55, 0x28 - arg0->unk10, D_800E7730, 0, 0.75f, 0.75f); phi_s1 = 0; @@ -11130,7 +11130,7 @@ block_43: func_80093324(0xBB - arg0->unkC, phi_s0_5, D_800E7A44, 0, 0.45f, 0.45f); } else { temp_v0_2 = phi_s2_3->unk5; - func_80093324(0xBB - arg0->unkC, phi_s0_5, *(&D_800E75C4 + (*(&gCupTrackOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2))) * 4)), 0, 0.45f, 0.45f); + func_80093324(0xBB - arg0->unkC, phi_s0_5, *(&D_800E75C4 + (*(&gCupCourseOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2))) * 4)), 0, 0.45f, 0.45f); } phi_s1_3 = sp54; phi_s0_5 += 0x1E; @@ -11505,7 +11505,7 @@ extern ? D_800F0C64; extern ? D_800F0C68; extern f32 D_800F1DD4; extern s8 gCupSelection; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; extern s32 gDisplayListHead; void func_800A4BC8(void *arg0) { @@ -11522,7 +11522,7 @@ void func_800A4BC8(void *arg0) { gDisplayListHead = draw_box(gDisplayListHead, 0, 0, 0x13F, 0xEF, 0, 0, 0, 0x8C); set_text_color(TEXT_YELLOW); - draw_text(0xA0, 0x50, *(&D_800E7574 + (*(&gCupTrackOrder + ((gCupSelection * 8) + (gCourseSelection * 2))) * 4)), 0, 1.0f, 1.0f); + draw_text(0xA0, 0x50, *(&D_800E7574 + (*(&gCupCourseOrder + ((gCupSelection * 8) + (gCupCourseSelection * 2))) * 4)), 0, 1.0f, 1.0f); set_text_color(TEXT_RED); temp_f20 = D_800F1DD4; // "Best Records" @@ -11643,7 +11643,7 @@ extern s32 D_800E775C; extern ? D_800E85C0; extern ? D_8015F480; extern s8 gCupSelection; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; extern s32 gDisplayListHead; void func_800A5084(void *arg0) { @@ -11674,7 +11674,7 @@ void func_800A5084(void *arg0) { set_text_color(TEXT_YELLOW); draw_text(temp_s0 + 0xA0, temp_s3->unk2 - 0x32, *(&D_800E76CC + (gCCSelection * 4)), 0, 1.0f, 1.0f); set_text_color(TEXT_YELLOW); - draw_text(0xA0, temp_s3->unk2 - 0x1E, *(&D_800E7574 + (*(&gCupTrackOrder + ((gCupSelection * 8) + (gCourseSelection * 2))) * 4)), 0, 1.0f, 1.0f); + draw_text(0xA0, temp_s3->unk2 - 0x1E, *(&D_800E7574 + (*(&gCupCourseOrder + ((gCupSelection * 8) + (gCupCourseSelection * 2))) * 4)), 0, 1.0f, 1.0f); phi_s0 = 0; phi_s1 = 0; phi_s2 = &D_800E775C; @@ -11852,7 +11852,7 @@ static ? *D_800E7A80[2] = { "UNABLE TO SAVE ", "THE GHOST" }; /* const */ static ? D_800E7A88; /* unable to generate initializer; const */ static s16 D_800E8538; /* type too large by 2; unable to generate initializer; const */ static s16 D_800E853A; /* type too large by 2; unable to generate initializer; const */ -static ? gCupTrackOrder; /* unable to generate initializer; const */ +static ? gCupCourseOrder; /* unable to generate initializer; const */ void func_800A5738(void *arg0) { s16 sp9A; @@ -11931,7 +11931,7 @@ void func_800A5738(void *arg0) { temp_v0->words.w1 = phi_s2 & 0xFF; temp_v0->words.w0 = 0xFA000000; set_text_color(TEXT_YELLOW); - func_80093754(0xA0, 0x50, *(&D_800E7574 + (*(&gCupTrackOrder + ((gCupSelection * 8) + (gCourseSelection * 2))) * 4)), 0, 1.0f, 1.0f); + func_80093754(0xA0, 0x50, *(&D_800E7574 + (*(&gCupCourseOrder + ((gCupSelection * 8) + (gCupCourseSelection * 2))) * 4)), 0, 1.0f, 1.0f); temp_v1_2 = arg0->unk4; switch (temp_v1_2) { /* switch 1 */ case 1: /* switch 1 */ @@ -12020,7 +12020,7 @@ block_36: func_80093324(0x69 - arg0->unkC, phi_s0_4, D_800E7A44, 0, 0.75f, 0.75f); } else { temp_v0_3 = phi_s2_2->unk5; - func_80093324(0x69 - arg0->unkC, phi_s0_4, *(&D_800E75C4 + (*(&gCupTrackOrder + (((temp_v0_3 / 4) * 8) + ((temp_v0_3 % 4) * 2))) * 4)), 0, 0.75f, 0.75f); + func_80093324(0x69 - arg0->unkC, phi_s0_4, *(&D_800E75C4 + (*(&gCupCourseOrder + (((temp_v0_3 / 4) * 8) + ((temp_v0_3 % 4) * 2))) * 4)), 0, 0.75f, 0.75f); } phi_s1_3 = sp54; phi_s0_4 += 0x14; @@ -13769,7 +13769,7 @@ void func_800A8A98(void *arg0) { phi_s4 = 0; phi_s0 = &D_800E7208; do { - if ((phi_s4 == gCourseSelection) && (temp_v0_4 = D_8018EDEC, ((temp_v0_4 < 2) == 0)) && (gModeSelection != GRAND_PRIX)) { + if ((phi_s4 == gCupCourseSelection) && (temp_v0_4 = D_8018EDEC, ((temp_v0_4 < 2) == 0)) && (gModeSelection != GRAND_PRIX)) { if ((temp_v0_4 == 2) || (temp_v0_4 == 4)) { phi_v0 = func_800959A0(gDisplayListHead, phi_s0->unk0 + temp_s2, phi_s0->unk2 + temp_s3, phi_s0->unk8 + temp_s2, phi_s0->unkA + temp_s3); } else { @@ -13919,7 +13919,7 @@ void func_800A8F48(s32 arg0) { if (temp_v0 != 2) { } - if (func_800B639C((gCupSelection * 4) + gCourseSelection) >= 0) { + if (func_800B639C((gCupSelection * 4) + gCupCourseSelection) >= 0) { temp_v0_2 = func_80098FC8(gDisplayListHead, 0x57, 0x70, 0x96, 0x81); gDisplayListHead = temp_v0_2; gDisplayListHead = func_8009BA74(temp_v0_2, 0x2004A0C, 0x57, 0x70); @@ -15591,7 +15591,7 @@ GLOBAL_ASM("asm/non_matchings/code_80091750/func_800AB260.s") s32 segmented_to_virtual_dupe(s32, void *); // extern extern ? D_800E7E34; extern s8 gCupSelection; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; void func_800AB290(void *arg0) { s16 temp_t2; @@ -15602,7 +15602,7 @@ void func_800AB290(void *arg0) { temp_a3 = arg0; if (temp_v0 != arg0->unk1C) { arg0->unk1C = temp_v0; - temp_t2 = *(&gCupTrackOrder - 0xBE + ((gCupSelection * 8) + (arg0->unk0 * 2))); + temp_t2 = *(&gCupCourseOrder - 0xBE + ((gCupSelection * 8) + (arg0->unk0 * 2))); arg0 = temp_a3; func_8009A594(arg0->unk18, 0, segmented_to_virtual_dupe(*(&D_800E7E34 + (temp_t2 * 4)), temp_a3), arg0); } @@ -15652,7 +15652,7 @@ void func_800AB314(void *arg0) { if (D_8018EDEC != 1) { arg0->unk4 = 0; arg0->unk20 = 0; - if (gCourseSelection == 0) { + if (gCupCourseSelection == CUP_COURSE_ONE) { sp24->unk15 = 1; if (arg0->unk1C != 0) { arg0->unk1C = 0; @@ -15660,7 +15660,7 @@ void func_800AB314(void *arg0) { } else { sp24->unk15 = 0; } - if (gCourseSelection == 1) { + if (gCupCourseSelection == CUP_COURSE_TWO) { sp28->unk15 = 1; if (arg0->unk1C != 1) { arg0->unk1C = 1; @@ -15668,7 +15668,7 @@ void func_800AB314(void *arg0) { } else { sp28->unk15 = 0; } - if (gCourseSelection == 2) { + if (gCupCourseSelection == CUP_COURSE_THREE) { sp2C->unk15 = 1; if (arg0->unk1C != 2) { arg0->unk1C = 2; @@ -15676,7 +15676,7 @@ void func_800AB314(void *arg0) { } else { sp2C->unk15 = 0; } - if (gCourseSelection == 3) { + if (gCupCourseSelection == CUP_COURSE_FOUR) { sp30->unk15 = 1; if (arg0->unk1C != 3) { arg0->unk1C = 3; @@ -16372,7 +16372,7 @@ s8 *func_800AC458(void *arg0) { temp_t4 = *(&gPlayers->characterId + (*(&D_80164360 + (temp_a1_2 * 2)) * 0xDD8)); sp18 = 0; arg0 = temp_a3; - gGPCharacterPoints[temp_t4] += 1; + gGPPointsByCharacterId[temp_t4] += 1; place = temp_a1_2; play_sound2(0x49008017, temp_a1_2, temp_a2_2, temp_a3); phi_a3 = arg0; @@ -16429,8 +16429,8 @@ s8 *func_800AC458(void *arg0) { if (D_8018D9D8 != 0) { temp_a3->unk1C = temp_t7 - 5; } - if ((temp_a3->unk1C <= 0) && (temp_a3->unk4 = 0xA, temp_a3->unk1C = 0, phi_a1 = 0, phi_v0_2 = gGPOverallRanks, (gCourseSelection == COURSE_BANSHEE_BOARDWALK))) { - phi_v0 = gGPOverallRanks; + if ((temp_a3->unk1C <= 0) && (temp_a3->unk4 = 0xA, temp_a3->unk1C = 0, phi_a1 = 0, phi_v0_2 = gCharacterIdByGPOverallRank, (gCupCourseSelection == CUP_COURSE_FOUR))) { + phi_v0 = gCharacterIdByGPOverallRank; loop_41: if (*(&D_80164478 + (*phi_v0 * 2)) < D_8018EDF3) { return func_800B536C(phi_a1, phi_a1, 8, temp_a3); @@ -17127,7 +17127,7 @@ block_42: } } else { func_800B6708(); - arg0->unk4 = func_800B6348((gCupSelection * 4) + gCourseSelection) + 0x11; + arg0->unk4 = func_800B6348((gCupSelection * 4) + gCupCourseSelection) + 0x11; sp28 = 1; play_sound2(0x49008001); phi_v1 = 1; @@ -17168,7 +17168,7 @@ block_42: } if (osPfsFindFile(&D_8018E868, D_800E86F0, D_800E86F4, &D_800F2E64, &D_800F2E74, &D_8018EB84) == 0) { func_800B6708(); - arg0->unk4 = func_800B6348((gCupSelection * 4) + gCourseSelection) + 0x11; + arg0->unk4 = func_800B6348((gCupSelection * 4) + gCupCourseSelection) + 0x11; play_sound2(0x49008001); return; } @@ -17512,7 +17512,7 @@ block_34: } } else { func_800B6708(); - arg0->unk4 = func_800B6348((gCupSelection * 4) + gCourseSelection) + 0x1E; + arg0->unk4 = func_800B6348((gCupSelection * 4) + gCupCourseSelection) + 0x1E; phi_v1 = 1; } } @@ -17554,7 +17554,7 @@ block_34: } if (osPfsFindFile(&D_8018E868, D_800E86F0, D_800E86F4, &D_800F2E64, &D_800F2E74, &D_8018EB84) == 0) { func_800B6708(); - arg0->unk4 = func_800B6348((gCupSelection * 4) + gCourseSelection) + 0x1E; + arg0->unk4 = func_800B6348((gCupSelection * 4) + gCupCourseSelection) + 0x1E; play_sound2(0x49008001); return; } @@ -17609,7 +17609,7 @@ block_49: case 30: /* switch 1 */ case 31: /* switch 1 */ arg0->unk20 = arg0->unk4 - 0x1E; - if (func_800B639C((gCupSelection * 4) + gCourseSelection) != arg0->unk20) { + if (func_800B639C((gCupSelection * 4) + gCupCourseSelection) != arg0->unk20) { temp_v0_5 = D_800DC4BC; temp_a1_2 = temp_v0_5->unk6 | temp_v0_5->unkC; phi_a1_2 = temp_a1_2; @@ -17833,7 +17833,7 @@ s32 segmented_to_virtual_dupe(s32, void *); // extern extern ? D_800E7E34; extern s8 D_8018EDF7; extern ? D_8018EE10; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; void func_800AEDBC(void *arg0) { s8 temp_v0; @@ -17846,7 +17846,7 @@ void func_800AEDBC(void *arg0) { arg0->unk1C = temp_v0; temp_v0_2 = D_8018EDF7; arg0 = temp_a3; - func_8009A594(arg0->unk18, 0, segmented_to_virtual_dupe(*(&D_800E7E34 + (*(&gCupTrackOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2))) * 4)), temp_a3), arg0); + func_8009A594(arg0->unk18, 0, segmented_to_virtual_dupe(*(&D_800E7E34 + (*(&gCupCourseOrder + (((temp_v0_2 / 4) * 8) + ((temp_v0_2 % 4) * 2))) * 4)), temp_a3), arg0); if (func_800B5B94() == 0) { func_800B6708(); return; diff --git a/src/code_800AF9B0.c b/src/code_800AF9B0.c index e35f3a6db..1a08180ce 100644 --- a/src/code_800AF9B0.c +++ b/src/code_800AF9B0.c @@ -2358,7 +2358,7 @@ extern s8 D_8018EDEC; extern s32 D_8018EE00; extern s8 D_8018EE0A; extern s8 gCupSelection; -extern ? gCupTrackOrder; +extern ? gCupCourseOrder; void func_800B3B58(void *arg0, u16 arg1) { u16 sp26; @@ -2425,27 +2425,27 @@ void func_800B3B58(void *arg0, u16 arg1) { block_22: phi_v1 = phi_a2; if ((phi_a2 & 0x400) != 0) { - temp_v0_3 = gCourseSelection; + temp_v0_3 = gCupCourseSelection; if (temp_v0_3 < 3) { - gCourseSelection = temp_v0_3 + 1; + gCupCourseSelection = temp_v0_3 + 1; sp1C = phi_a2; - func_800B44AC(&gCourseSelection, &D_8018EDEC, phi_a2); + func_800B44AC(&gCupCourseSelection, &D_8018EDEC, phi_a2); play_sound2(0x49008000); phi_v1 = sp1C; } } - temp_v0_4 = gCourseSelection; + temp_v0_4 = gCupCourseSelection; phi_v0 = temp_v0_4; phi_a1 = &D_8018EDEC; if (((phi_v1 & 0x800) != 0) && (temp_v0_4 > 0)) { - gCourseSelection = temp_v0_4 - 1; + gCupCourseSelection = temp_v0_4 - 1; sp1C = phi_v1; - func_800B44AC(&gCourseSelection, &D_8018EDEC); + func_800B44AC(&gCupCourseSelection, &D_8018EDEC); play_sound2(0x49008000); - phi_v0 = gCourseSelection; + phi_v0 = gCupCourseSelection; phi_a1 = &D_8018EDEC; } - gCurrentCourseId = *(&gCupTrackOrder + ((gCupSelection * 8) + (phi_v0 * 2))); + gCurrentCourseId = *(&gCupCourseOrder + ((gCupSelection * 8) + (phi_v0 * 2))); if ((phi_v1 & 0x4000) != 0) { if (*phi_a1 == 2) { *phi_a1 = 1; @@ -2491,7 +2491,7 @@ block_22: phi_a1_2 = &D_8018EDEC; } D_800DC540 = phi_v0_2; - gCurrentCourseId = *(&gCupTrackOrder + ((phi_v0_2 * 8) + (gCourseSelection * 2))); + gCurrentCourseId = *(&gCupCourseOrder + ((phi_v0_2 * 8) + (gCupCourseSelection * 2))); if ((phi_v1_2 & 0x4000) != 0) { func_8009E208(); play_sound2(0x49008002); @@ -2504,7 +2504,7 @@ block_22: } else { *phi_a1_2 = 3; play_sound2(0x49008001, phi_a1_2); - gCurrentCourseId = *(&gCupTrackOrder + (gCupSelection * 8)); + gCurrentCourseId = *(&gCupCourseOrder + (gCupSelection * 8)); D_8018EE00 = 0; } func_800B44AC(); @@ -2617,7 +2617,7 @@ void func_800B3F74(u32 arg0) { gIsMirrorMode = 0; gEnableDebugMode = 0; gCupSelection = MUSHROOM_CUP; - gCourseSelection = COURSE_MARIO_RACEWAY; + gCupCourseSelection = CUP_COURSE_ONE; D_8018EDF7 = 0; if (D_8018EDF3 <= 0) { D_8018EDF3 = 1; @@ -2768,9 +2768,9 @@ void func_800B3F74(u32 arg0) { play_sound2(0x49009013); D_8018EE0A = 0; if (gModeSelection == GRAND_PRIX) { - gCourseSelection = COURSE_MARIO_RACEWAY; + gCupCourseSelection = CUP_COURSE_ONE; } - phi_v0_2 = gGPCharacterPoints; + phi_v0_2 = gGPPointsByCharacterId; do { temp_v0_5 = phi_v0_2 + 4; temp_v0_5->unk-3 = 0; @@ -2778,7 +2778,7 @@ void func_800B3F74(u32 arg0) { temp_v0_5->unk-1 = 0; temp_v0_5->unk-4 = 0; phi_v0_2 = temp_v0_5; - } while (temp_v0_5 != gGPOverallRanks); + } while (temp_v0_5 != gCharacterIdByGPOverallRank); break; } func_800B44AC(); @@ -3217,8 +3217,8 @@ GLOBAL_ASM("asm/non_matchings/code_800AF9B0/func_800B4DF4.s") s32 func_800B4E24(s32 recordIndex) { return func_800B4DF4( D_8018EB90.allCourseTimeTrialRecords \ - .cupRecords[(((gCupSelection * 4) + gCourseSelection) / 4)] \ - .courseRecords[(((gCupSelection * 4) + gCourseSelection) % 4)] \ + .cupRecords[(((gCupSelection * 4) + gCupCourseSelection) / 4)] \ + .courseRecords[(((gCupSelection * 4) + gCupCourseSelection) % 4)] \ .records[recordIndex] ); } @@ -3237,8 +3237,8 @@ s32 func_800B4EB4(s32 recordIndex, s32 courseIndex) { s32 func_800B4F2C(void) { return func_800B4DF4( D_8018EB90.allCourseTimeTrialRecords \ - .cupRecords[(((gCupSelection * 4) + gCourseSelection) / 4)] \ - .courseRecords[(((gCupSelection * 4) + gCourseSelection) % 4)] \ + .cupRecords[(((gCupSelection * 4) + gCupCourseSelection) / 4)] \ + .courseRecords[(((gCupSelection * 4) + gCupCourseSelection) % 4)] \ .records[TIME_TRIAL_1LAP_RECORD] ); } @@ -3285,7 +3285,7 @@ s32 func_800B5020(u32 arg0, s32 arg1) { s32 phi_s0_2; s32 phi_a0_2; - temp_v0 = (gCupSelection * 4) + gCourseSelection; + temp_v0 = (gCupSelection * 4) + gCupCourseSelection; temp_s2 = ((temp_v0 / 4) * 0x60) + ((temp_v0 % 4) * 0x18) + &D_8018EB90; sp30 = temp_v0; phi_s0 = 0; @@ -3391,7 +3391,7 @@ s32 func_800B5218(void) { s32 phi_v0_2; s32 phi_a3_2; - sp38 = (gCupSelection * 4) + gCourseSelection; + sp38 = (gCupSelection * 4) + gCupCourseSelection; sp28 = *D_800E86A8; phi_a1 = &D_8018CA74; phi_a2 = &D_8018CA70; @@ -4184,7 +4184,7 @@ s32 func_800B6178(s32 arg0) { if (temp_v0_2 == 0) { temp_s3->unk4 = 1; if (D_800DC50C == 4) { - temp_s3->unk5 = (gCupSelection * 4) + gCourseSelection; + temp_s3->unk5 = (gCupSelection * 4) + gCupCourseSelection; } temp_s3->unk0 = D_80162DFC; temp_s3->unk6 = D_80162DE0; @@ -4278,7 +4278,7 @@ extern s8 gCupSelection; func_80005AE8(D_800DC4E4); temp_v0 = (arg0 << 7) + &D_8018EE10; phi_s3 = 0; - if (((gCupSelection * 4) + gCourseSelection) != temp_v0->unk5) { + if (((gCupSelection * 4) + gCupCourseSelection) != temp_v0->unk5) { phi_s3 = 2; } else if (D_80162DFC != temp_v0->unk0) { phi_s3 = 3; diff --git a/src/code_80281780.c b/src/code_80281780.c index d6f82242f..a6d02223f 100644 --- a/src/code_80281780.c +++ b/src/code_80281780.c @@ -37,7 +37,7 @@ void func_80281780(void) { } else { D_800E86A8[0] = 0; } - bcopy(&D_80284ED0, &gGPOverallRanks, 8); + bcopy(&D_80284ED0, &gCharacterIdByGPOverallRank, 8); } } } @@ -45,7 +45,7 @@ void func_80281780(void) { s32 func_80281880(s32 arg0) { s32 i; for (i = 0; i < 8; i++) { - if (gGPOverallRanks[i] == D_800E86A8[arg0]) break; + if (gCharacterIdByGPOverallRank[i] == D_800E86A8[arg0]) break; } return i; } diff --git a/src/code_8028DF00.c b/src/code_8028DF00.c index 1a83a0217..33779427e 100644 --- a/src/code_8028DF00.c +++ b/src/code_8028DF00.c @@ -39,7 +39,7 @@ extern u8 *D_8015F8CC; extern s16 D_8018D8C0[]; extern s16 D_8016348C; -extern s8 gCourseSelection; +extern s8 gCupCourseSelection; extern s32 D_800DC544; extern Player gPlayers[]; @@ -232,16 +232,16 @@ void func_8028E3A0(void) { if (D_80150120) { - if (gCourseSelection == COURSE_BANSHEE_BOARDWALK) { + if (gCupCourseSelection == CUP_COURSE_FOUR) { D_80150124 = 5; } else { D_800DC544++; - gCourseSelection++; + gCupCourseSelection++; D_80150124 = 4; } } else { D_800DC544++; - gCourseSelection++; + gCupCourseSelection++; D_80150124 = 4; } } diff --git a/src/data_0DD0A0_3.inc.c b/src/data_0DD0A0_3.inc.c index c60719dc1..d54dfcb9e 100644 --- a/src/data_0DD0A0_3.inc.c +++ b/src/data_0DD0A0_3.inc.c @@ -344,7 +344,7 @@ s32 D_800F3B1C[] = { }; -u16 gCupTrackOrder[] = { // ISSUE CHECK WRONG PREVIEW TEXTURES +u16 gCupCourseOrder[] = { // ISSUE CHECK WRONG PREVIEW TEXTURES 0x0008, 0x0009, 0x0006, 0x000b, // mushroom cup: LR, MMF, KTB, KD 0x000a, 0x0005, 0x0001, 0x0000, // flower cup: TT, FS, CM, MR 0x000e, 0x000c, 0x0007, 0x0002, // star cup: WS, SL, RRy, BC