diff --git a/asm/non_matchings/code/z_actor/func_8002FBAC.s b/asm/non_matchings/code/z_actor/func_8002FBAC.s
index 9c9f2d0904..61c0db968d 100644
--- a/asm/non_matchings/code/z_actor/func_8002FBAC.s
+++ b/asm/non_matchings/code/z_actor/func_8002FBAC.s
@@ -529,8 +529,8 @@ glabel func_8002FBAC
/* AA746C 800302CC 0C0346A2 */ jal Matrix_NewMtx
/* AA7470 800302D0 AFA20058 */ sw $v0, 0x58($sp)
/* AA7474 800302D4 8FA30058 */ lw $v1, 0x58($sp)
-/* AA7478 800302D8 3C040401 */ lui $a0, %hi(gGameKeepMoteDL0) # $a0, 0x401
-/* AA747C 800302DC 24840130 */ addiu $a0, %lo(gGameKeepMoteDL0) # addiu $a0, $a0, 0x130
+/* AA7478 800302D8 3C040401 */ lui $a0, %hi(gEffFlash1DL) # $a0, 0x401
+/* AA747C 800302DC 24840130 */ addiu $a0, %lo(gEffFlash1DL) # addiu $a0, $a0, 0x130
/* AA7480 800302E0 AC620004 */ sw $v0, 4($v1)
/* AA7484 800302E4 8FA500EC */ lw $a1, 0xec($sp)
/* AA7488 800302E8 3C18DE00 */ li $t8, 0xDE000000 # 0.000000
diff --git a/asm/non_matchings/code/z_kankyo/func_800730DC.s b/asm/non_matchings/code/z_kankyo/func_800730DC.s
index d49dcff59e..820b014715 100644
--- a/asm/non_matchings/code/z_kankyo/func_800730DC.s
+++ b/asm/non_matchings/code/z_kankyo/func_800730DC.s
@@ -446,7 +446,7 @@ glabel func_800730DC
/* AEA8B0 80073710 3C0E0405 */ li $t6, 0x04050000 # 0.000000
/* AEA8B4 80073714 244C0008 */ addiu $t4, $v0, 8
/* AEA8B8 80073718 AE0C02C0 */ sw $t4, 0x2c0($s0)
-/* AEA8BC 8007371C 25CED1C0 */ addiu $t6, %lo(D_0404D1C0) # addiu $t6, $t6, -0x2e40
+/* AEA8BC 8007371C 25CED1C0 */ addiu $t6, %lo(gSunDL) # addiu $t6, $t6, -0x2e40
/* AEA8C0 80073720 3C18DE00 */ li $t8, 0xDE000000 # 0.000000
/* AEA8C4 80073724 AC580000 */ sw $t8, ($v0)
/* AEA8C8 80073728 AC4E0004 */ sw $t6, 4($v0)
@@ -587,11 +587,11 @@ glabel func_800730DC
/* AEAAD0 80073930 AC4F0000 */ sw $t7, ($v0)
/* AEAAD4 80073934 AC4D0004 */ sw $t5, 4($v0)
/* AEAAD8 80073938 8E0202C0 */ lw $v0, 0x2c0($s0)
-/* AEAADC 8007393C 3C0A0404 */ lui $t2, %hi(D_04038F00) # $t2, 0x404
+/* AEAADC 8007393C 3C0A0404 */ lui $t2, %hi(gMoonDL) # $t2, 0x404
/* AEAAE0 80073940 44CCF800 */ ctc1 $t4, $31
/* AEAAE4 80073944 24590008 */ addiu $t9, $v0, 8
/* AEAAE8 80073948 AE1902C0 */ sw $t9, 0x2c0($s0)
-/* AEAAEC 8007394C 254A8F00 */ addiu $t2, %lo(D_04038F00) # addiu $t2, $t2, -0x7100
+/* AEAAEC 8007394C 254A8F00 */ addiu $t2, %lo(gMoonDL) # addiu $t2, $t2, -0x7100
/* AEAAF0 80073950 3C09DE00 */ lui $t1, 0xde00
/* AEAAF4 80073954 AC490000 */ sw $t1, ($v0)
/* AEAAF8 80073958 AC4A0004 */ sw $t2, 4($v0)
diff --git a/asm/non_matchings/code/z_kankyo/func_80073A5C.s b/asm/non_matchings/code/z_kankyo/func_80073A5C.s
index 539d611332..0c5b47c24b 100644
--- a/asm/non_matchings/code/z_kankyo/func_80073A5C.s
+++ b/asm/non_matchings/code/z_kankyo/func_80073A5C.s
@@ -600,8 +600,8 @@ glabel func_80073A5C
/* AEB468 800742C8 2A21000A */ slti $at, $s1, 0xa
.L800742CC:
/* AEB46C 800742CC 8E0702D0 */ lw $a3, 0x2d0($s0)
-/* AEB470 800742D0 3C030403 */ lui $v1, %hi(D_04037730) # $v1, 0x403
-/* AEB474 800742D4 24637730 */ addiu $v1, %lo(D_04037730) # addiu $v1, $v1, 0x7730
+/* AEB470 800742D0 3C030403 */ lui $v1, %hi(gEffBurnMark1DL) # $v1, 0x403
+/* AEB474 800742D4 24637730 */ addiu $v1, %lo(gEffBurnMark1DL) # addiu $v1, $v1, 0x7730
/* AEB478 800742D8 24E80008 */ addiu $t0, $a3, 8
/* AEB47C 800742DC AE0802D0 */ sw $t0, 0x2d0($s0)
/* AEB480 800742E0 3C0FDE00 */ lui $t7, 0xde00
diff --git a/asm/non_matchings/code/z_kankyo/func_80074704.s b/asm/non_matchings/code/z_kankyo/func_80074704.s
index 059ce024f7..a70264682c 100644
--- a/asm/non_matchings/code/z_kankyo/func_80074704.s
+++ b/asm/non_matchings/code/z_kankyo/func_80074704.s
@@ -157,8 +157,8 @@ glabel func_80074704
/* AEBA78 800748D8 C43EC7DC */ lwc1 $f30, %lo(D_8013C7DC)($at)
/* AEBA7C 800748DC 3C0142C8 */ li $at, 0x42C80000 # 0.000000
/* AEBA80 800748E0 4481E000 */ mtc1 $at, $f28
-/* AEBA84 800748E4 3C0B0405 */ lui $t3, %hi(D_04048160) # $t3, 0x405
-/* AEBA88 800748E8 256B8160 */ addiu $t3, %lo(D_04048160) # addiu $t3, $t3, -0x7ea0
+/* AEBA84 800748E4 3C0B0405 */ lui $t3, %hi(gRaindropDL) # $t3, 0x405
+/* AEBA88 800748E8 256B8160 */ addiu $t3, %lo(gRaindropDL) # addiu $t3, $t3, -0x7ea0
/* AEBA8C 800748EC 3C018014 */ lui $at, %hi(D_8013C7E0)
/* AEBA90 800748F0 3C130100 */ lui $s3, 0x100
/* AEBA94 800748F4 3C17DA38 */ lui $s7, (0xDA380003 >> 16) # lui $s7, 0xda38
@@ -293,7 +293,7 @@ glabel func_80074704
/* AEBC90 80074AF0 C438C7F0 */ lwc1 $f24, %lo(D_8013C7F0)($at)
/* AEBC94 80074AF4 3C014000 */ lui $at, 0x4000
/* AEBC98 80074AF8 3C0A0402 */ li $t2, 0x04020000 # 0.000000
-/* AEBC9C 80074AFC 254AA0B0 */ addiu $t2, %lo(D_0401A0B0) # addiu $t2, $t2, -0x5f50
+/* AEBC9C 80074AFC 254AA0B0 */ addiu $t2, %lo(gEffShockwaveDL) # addiu $t2, $t2, -0x5f50
/* AEBCA0 80074B00 4481B000 */ mtc1 $at, $f22
/* AEBCA4 80074B04 AFAA007C */ sw $t2, 0x7c($sp)
.L80074B08:
diff --git a/asm/non_matchings/code/z_kankyo/func_8007542C.s b/asm/non_matchings/code/z_kankyo/func_8007542C.s
index 12c8080f26..846c6af305 100644
--- a/asm/non_matchings/code/z_kankyo/func_8007542C.s
+++ b/asm/non_matchings/code/z_kankyo/func_8007542C.s
@@ -195,8 +195,8 @@ glabel func_8007542C
/* AEC850 800756B0 C6060014 */ lwc1 $f6, 0x14($s0)
/* AEC854 800756B4 460A4400 */ add.s $f16, $f8, $f10
/* AEC858 800756B8 3C150100 */ lui $s5, 0x100
-/* AEC85C 800756BC 3C160403 */ lui $s6, %hi(D_0402CF30) # $s6, 0x403
-/* AEC860 800756C0 26D6CF30 */ addiu $s6, %lo(D_0402CF30) # addiu $s6, $s6, -0x30d0
+/* AEC85C 800756BC 3C160403 */ lui $s6, %hi(gEffLightningDL) # $s6, 0x403
+/* AEC860 800756C0 26D6CF30 */ addiu $s6, %lo(gEffLightningDL) # addiu $s6, $s6, -0x30d0
/* AEC864 800756C4 44068000 */ mfc1 $a2, $f16
/* AEC868 800756C8 26B50000 */ addiu $s5, $s5, 0
/* AEC86C 800756CC 0C034261 */ jal Matrix_Translate
diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot00_Hanebasi/func_808AA2B0.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot00_Hanebasi/func_808AA2B0.s
index 565af2454a..a7dc0b2fcd 100644
--- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot00_Hanebasi/func_808AA2B0.s
+++ b/asm/non_matchings/overlays/actors/ovl_Bg_Spot00_Hanebasi/func_808AA2B0.s
@@ -111,14 +111,14 @@ glabel func_808AA2B0
/* 00C74 808AA3F4 3C014300 */ lui $at, 0x4300 ## $at = 43000000
/* 00C78 808AA3F8 4481B000 */ mtc1 $at, $f22 ## $f22 = 128.00
/* 00C7C 808AA3FC 3C014382 */ lui $at, 0x4382 ## $at = 43820000
-/* 00C80 808AA400 3C140405 */ lui $s4, %hi(D_0404D4E0) ## $s4 = 04050000
+/* 00C80 808AA400 3C140405 */ lui $s4, %hi(gEffFire1DL) ## $s4 = 04050000
/* 00C84 808AA404 3C1EDA38 */ lui $s8, 0xDA38 ## $s8 = DA380000
/* 00C88 808AA408 3C16DB06 */ lui $s6, 0xDB06 ## $s6 = DB060000
/* 00C8C 808AA40C 4481A000 */ mtc1 $at, $f20 ## $f20 = 260.00
/* 00C90 808AA410 46062702 */ mul.s $f28, $f4, $f6
/* 00C94 808AA414 36D60020 */ ori $s6, $s6, 0x0020 ## $s6 = DB060020
/* 00C98 808AA418 37DE0003 */ ori $s8, $s8, 0x0003 ## $s8 = DA380003
-/* 00C9C 808AA41C 2694D4E0 */ addiu $s4, $s4, %lo(D_0404D4E0) ## $s4 = 0404D4E0
+/* 00C9C 808AA41C 2694D4E0 */ addiu $s4, $s4, %lo(gEffFire1DL) ## $s4 = 0404D4E0
/* 00CA0 808AA420 00008825 */ or $s1, $zero, $zero ## $s1 = 00000000
/* 00CA4 808AA424 2417FFEC */ addiu $s7, $zero, 0xFFEC ## $s7 = FFFFFFEC
.L808AA428:
diff --git a/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80924228.s b/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80924228.s
index f9ae2a7b3a..8fd622381c 100644
--- a/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80924228.s
+++ b/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80924228.s
@@ -356,8 +356,8 @@ glabel func_80924228
/* 08BD8 809246D8 0C0346A2 */ jal Matrix_NewMtx
/* 08BDC 809246DC AFA20094 */ sw $v0, 0x0094($sp)
/* 08BE0 809246E0 8FA30094 */ lw $v1, 0x0094($sp)
-/* 08BE4 809246E4 3C040405 */ lui $a0, %hi(D_04049210) ## $a0 = 04050000
-/* 08BE8 809246E8 24849210 */ addiu $a0, $a0, %lo(D_04049210) ## $a0 = 04049210
+/* 08BE4 809246E4 3C040405 */ lui $a0, %hi(gCircleShadowDL) ## $a0 = 04050000
+/* 08BE8 809246E8 24849210 */ addiu $a0, $a0, %lo(gCircleShadowDL) ## $a0 = 04049210
/* 08BEC 809246EC AC620004 */ sw $v0, 0x0004($v1) ## 00000004
/* 08BF0 809246F0 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 08BF4 809246F4 00046900 */ sll $t5, $a0, 4
diff --git a/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80925480.s b/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80925480.s
index c4b1743d38..2e9ad07cb9 100644
--- a/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80925480.s
+++ b/asm/non_matchings/overlays/actors/ovl_Boss_Mo/func_80925480.s
@@ -66,11 +66,11 @@ glabel func_80925480
/* 09A08 80925508 24130002 */ addiu $s3, $zero, 0x0002 ## $s3 = 00000002
.L8092550C:
/* 09A0C 8092550C 922F0024 */ lbu $t7, 0x0024($s1) ## 00000024
-/* 09A10 80925510 3C120402 */ lui $s2, %hi(D_040254B0) ## $s2 = 04020000
+/* 09A10 80925510 3C120402 */ lui $s2, %hi(gEffWaterRippleDL) ## $s2 = 04020000
/* 09A14 80925514 566F0035 */ bnel $s3, $t7, .L809255EC
/* 09A18 80925518 26B50001 */ addiu $s5, $s5, 0x0001 ## $s5 = 00000001
/* 09A1C 8092551C 16C0000B */ bne $s6, $zero, .L8092554C
-/* 09A20 80925520 265254B0 */ addiu $s2, $s2, %lo(D_040254B0) ## $s2 = 040254B0
+/* 09A20 80925520 265254B0 */ addiu $s2, $s2, %lo(gEffWaterRippleDL) ## $s2 = 040254B0
/* 09A24 80925524 0C0252F1 */ jal func_80094BC4
/* 09A28 80925528 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
/* 09A2C 8092552C 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
@@ -136,11 +136,11 @@ glabel func_80925480
/* 09B14 80925614 24130001 */ addiu $s3, $zero, 0x0001 ## $s3 = 00000001
.L80925618:
/* 09B18 80925618 92380024 */ lbu $t8, 0x0024($s1) ## 00000064
-/* 09B1C 8092561C 3C120402 */ lui $s2, %hi(D_0401A0B0) ## $s2 = 04020000
+/* 09B1C 8092561C 3C120402 */ lui $s2, %hi(gEffShockwaveDL) ## $s2 = 04020000
/* 09B20 80925620 56780036 */ bnel $s3, $t8, .L809256FC
/* 09B24 80925624 26B50001 */ addiu $s5, $s5, 0x0001 ## $s5 = 00000001
/* 09B28 80925628 16C0000C */ bne $s6, $zero, .L8092565C
-/* 09B2C 8092562C 2652A0B0 */ addiu $s2, $s2, %lo(D_0401A0B0) ## $s2 = 0401A0B0
+/* 09B2C 8092562C 2652A0B0 */ addiu $s2, $s2, %lo(gEffShockwaveDL) ## $s2 = 0401A0B0
/* 09B30 80925630 8FB900F4 */ lw $t9, 0x00F4($sp)
/* 09B34 80925634 0C024F61 */ jal func_80093D84
/* 09B38 80925638 8F240000 */ lw $a0, 0x0000($t9) ## 00000000
@@ -219,8 +219,8 @@ glabel func_80925480
/* 09C4C 8092574C AFA80054 */ sw $t0, 0x0054($sp)
/* 09C50 80925750 16C0002B */ bne $s6, $zero, .L80925800
/* 09C54 80925754 02E1B821 */ addu $s7, $s7, $at
-/* 09C58 80925758 3C020405 */ lui $v0, %hi(D_04051DB0) ## $v0 = 04050000
-/* 09C5C 8092575C 24421DB0 */ addiu $v0, $v0, %lo(D_04051DB0) ## $v0 = 04051DB0
+/* 09C58 80925758 3C020405 */ lui $v0, %hi(gDust1Tex) ## $v0 = 04050000
+/* 09C5C 8092575C 24421DB0 */ addiu $v0, $v0, %lo(gDust1Tex) ## $v0 = 04051DB0
/* 09C60 80925760 00024900 */ sll $t1, $v0, 4
/* 09C64 80925764 00095702 */ srl $t2, $t1, 28
/* 09C68 80925768 3C0C8016 */ lui $t4, %hi(gSegments)
@@ -334,8 +334,8 @@ glabel func_80925480
/* 09E0C 8092590C 26B50001 */ addiu $s5, $s5, 0x0001 ## $s5 = 00000001
/* 09E10 80925910 16C0002A */ bne $s6, $zero, .L809259BC
/* 09E14 80925914 26F70FC8 */ addiu $s7, $s7, 0x0FC8 ## $s7 = 06000FC8
-/* 09E18 80925918 3C020405 */ lui $v0, %hi(D_04051DB0) ## $v0 = 04050000
-/* 09E1C 8092591C 24421DB0 */ addiu $v0, $v0, %lo(D_04051DB0) ## $v0 = 04051DB0
+/* 09E18 80925918 3C020405 */ lui $v0, %hi(gDust1Tex) ## $v0 = 04050000
+/* 09E1C 8092591C 24421DB0 */ addiu $v0, $v0, %lo(gDust1Tex) ## $v0 = 04051DB0
/* 09E20 80925920 0002C900 */ sll $t9, $v0, 4
/* 09E24 80925924 00194F02 */ srl $t1, $t9, 28
/* 09E28 80925928 3C0A8016 */ lui $t2, %hi(gSegments)
diff --git a/asm/non_matchings/overlays/actors/ovl_Boss_Sst/func_8093639C.s b/asm/non_matchings/overlays/actors/ovl_Boss_Sst/func_8093639C.s
index 40ef37ae3d..2111359760 100644
--- a/asm/non_matchings/overlays/actors/ovl_Boss_Sst/func_8093639C.s
+++ b/asm/non_matchings/overlays/actors/ovl_Boss_Sst/func_8093639C.s
@@ -255,12 +255,12 @@ glabel func_8093639C
/* 0A118 809366E8 26700700 */ addiu $s0, $s3, 0x0700 ## $s0 = 00000700
/* 0A11C 809366EC 00003825 */ or $a3, $zero, $zero ## $a3 = 00000000
/* 0A120 809366F0 11E0003E */ beq $t7, $zero, .L809367EC
-/* 0A124 809366F4 3C150402 */ lui $s5, %hi(D_040184B0) ## $s5 = 04020000
+/* 0A124 809366F4 3C150402 */ lui $s5, %hi(gEffFireCircleDL) ## $s5 = 04020000
/* 0A128 809366F8 C60C0000 */ lwc1 $f12, 0x0000($s0) ## 00000700
/* 0A12C 809366FC C60E0004 */ lwc1 $f14, 0x0004($s0) ## 00000704
/* 0A130 80936700 8E060008 */ lw $a2, 0x0008($s0) ## 00000708
/* 0A134 80936704 0C034261 */ jal Matrix_Translate
-/* 0A138 80936708 26B584B0 */ addiu $s5, $s5, %lo(D_040184B0) ## $s5 = 040184B0
+/* 0A138 80936708 26B584B0 */ addiu $s5, $s5, %lo(gEffFireCircleDL) ## $s5 = 040184B0
/* 0A13C 8093670C 9618001E */ lhu $t8, 0x001E($s0) ## 0000071E
/* 0A140 80936710 3C014F80 */ lui $at, 0x4F80 ## $at = 4F800000
/* 0A144 80936714 44988000 */ mtc1 $t8, $f16 ## $f16 = 0.00
diff --git a/asm/non_matchings/overlays/actors/ovl_Boss_Tw/func_80943028.s b/asm/non_matchings/overlays/actors/ovl_Boss_Tw/func_80943028.s
index 50252f60aa..89351d3f53 100644
--- a/asm/non_matchings/overlays/actors/ovl_Boss_Tw/func_80943028.s
+++ b/asm/non_matchings/overlays/actors/ovl_Boss_Tw/func_80943028.s
@@ -130,8 +130,8 @@ glabel func_80943028
/* 0A510 809431E0 0C0346A2 */ jal Matrix_NewMtx
/* 0A514 809431E4 AFA2002C */ sw $v0, 0x002C($sp)
/* 0A518 809431E8 8FA3002C */ lw $v1, 0x002C($sp)
-/* 0A51C 809431EC 3C040405 */ lui $a0, %hi(D_04049210) ## $a0 = 04050000
-/* 0A520 809431F0 24849210 */ addiu $a0, $a0, %lo(D_04049210) ## $a0 = 04049210
+/* 0A51C 809431EC 3C040405 */ lui $a0, %hi(gCircleShadowDL) ## $a0 = 04050000
+/* 0A520 809431F0 24849210 */ addiu $a0, $a0, %lo(gCircleShadowDL) ## $a0 = 04049210
/* 0A524 809431F4 AC620004 */ sw $v0, 0x0004($v1) ## 00000004
/* 0A528 809431F8 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 0A52C 809431FC 00044900 */ sll $t1, $a0, 4
diff --git a/asm/non_matchings/overlays/actors/ovl_Boss_Va/func_8095A188.s b/asm/non_matchings/overlays/actors/ovl_Boss_Va/func_8095A188.s
index 3f98d5a960..4dcd241226 100644
--- a/asm/non_matchings/overlays/actors/ovl_Boss_Va/func_8095A188.s
+++ b/asm/non_matchings/overlays/actors/ovl_Boss_Va/func_8095A188.s
@@ -368,8 +368,8 @@ glabel func_8095A188
/* 0B334 8095A5F4 26730001 */ addiu $s3, $s3, 0x0001 ## $s3 = 00000001
/* 0B338 8095A5F8 16800028 */ bne $s4, $zero, .L8095A69C
/* 0B33C 8095A5FC 26529468 */ addiu $s2, $s2, %lo(D_06009468) ## $s2 = 06009468
-/* 0B340 8095A600 3C020405 */ lui $v0, %hi(D_04055DB0) ## $v0 = 04050000
-/* 0B344 8095A604 24425DB0 */ addiu $v0, $v0, %lo(D_04055DB0) ## $v0 = 04055DB0
+/* 0B340 8095A600 3C020405 */ lui $v0, %hi(gEffBubble1Tex) ## $v0 = 04050000
+/* 0B344 8095A604 24425DB0 */ addiu $v0, $v0, %lo(gEffBubble1Tex) ## $v0 = 04055DB0
/* 0B348 8095A608 00027100 */ sll $t6, $v0, 4
/* 0B34C 8095A60C 000E5702 */ srl $t2, $t6, 28
/* 0B350 8095A610 3C098016 */ lui $t1, %hi(gSegments)
diff --git a/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_8096865C.s b/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_8096865C.s
index c67a2abce1..5f5b3acdfb 100644
--- a/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_8096865C.s
+++ b/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_8096865C.s
@@ -42,12 +42,12 @@ glabel func_8096865C
/* 01D48 80968698 5700007F */ bnel $t8, $zero, .L80968898
/* 01D4C 8096869C 8FAA0064 */ lw $t2, 0x0064($sp)
/* 01D50 809686A0 8459001C */ lh $t9, 0x001C($v0) ## 0000001C
-/* 01D54 809686A4 3C090401 */ lui $t1, %hi(D_040101A8) ## $t1 = 04010000
-/* 01D58 809686A8 3C080401 */ lui $t0, %hi(gGameKeepMoteDL0) ## $t0 = 04010000
+/* 01D54 809686A4 3C090401 */ lui $t1, %hi(gEffFlash2DL) ## $t1 = 04010000
+/* 01D58 809686A8 3C080401 */ lui $t0, %hi(gEffFlash1DL) ## $t0 = 04010000
/* 01D5C 809686AC 2B210009 */ slti $at, $t9, 0x0009
/* 01D60 809686B0 14200004 */ bne $at, $zero, .L809686C4
-/* 01D64 809686B4 252901A8 */ addiu $t1, $t1, %lo(D_040101A8) ## $t1 = 040101A8
-/* 01D68 809686B8 25080130 */ addiu $t0, $t0, %lo(gGameKeepMoteDL0) ## $t0 = 04010130
+/* 01D64 809686B4 252901A8 */ addiu $t1, $t1, %lo(gEffFlash2DL) ## $t1 = 040101A8
+/* 01D68 809686B8 25080130 */ addiu $t0, $t0, %lo(gEffFlash1DL) ## $t0 = 04010130
/* 01D6C 809686BC 10000002 */ beq $zero, $zero, .L809686C8
/* 01D70 809686C0 AFA80054 */ sw $t0, 0x0054($sp)
.L809686C4:
diff --git a/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_809688C4.s b/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_809688C4.s
index aeaa0c2879..96077fed96 100644
--- a/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_809688C4.s
+++ b/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_809688C4.s
@@ -79,10 +79,10 @@ glabel func_809688C4
/* 0205C 809689AC 46083302 */ mul.s $f12, $f6, $f8
/* 02060 809689B0 0C034348 */ jal Matrix_RotateY
/* 02064 809689B4 00000000 */ nop
-/* 02068 809689B8 3C0F0401 */ lui $t7, %hi(gGameKeepMoteDL0) ## $t7 = 04010000
+/* 02068 809689B8 3C0F0401 */ lui $t7, %hi(gEffFlash1DL) ## $t7 = 04010000
/* 0206C 809689BC 3C010001 */ lui $at, 0x0001 ## $at = 00010000
/* 02070 809689C0 34211DA0 */ ori $at, $at, 0x1DA0 ## $at = 00011DA0
-/* 02074 809689C4 25EF0130 */ addiu $t7, $t7, %lo(gGameKeepMoteDL0) ## $t7 = 04010130
+/* 02074 809689C4 25EF0130 */ addiu $t7, $t7, %lo(gEffFlash1DL) ## $t7 = 04010130
/* 02078 809689C8 4480A000 */ mtc1 $zero, $f20 ## $f20 = 0.00
/* 0207C 809689CC AFAF0058 */ sw $t7, 0x0058($sp)
/* 02080 809689D0 02E1F021 */ addu $s8, $s7, $at
diff --git a/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_80968FB0.s b/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_80968FB0.s
index df70409bd4..54de57de17 100644
--- a/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_80968FB0.s
+++ b/asm/non_matchings/overlays/actors/ovl_Demo_6K/func_80968FB0.s
@@ -130,8 +130,8 @@ glabel func_80968FB0
/* 02814 80969164 AC4C0000 */ sw $t4, 0x0000($v0) ## 00000010
/* 02818 80969168 AC4D0004 */ sw $t5, 0x0004($v0) ## 00000014
/* 0281C 8096916C 8D2202D0 */ lw $v0, 0x02D0($t1) ## 000002D0
-/* 02820 80969170 3C180401 */ lui $t8, %hi(D_04015780) ## $t8 = 04010000
-/* 02824 80969174 27185780 */ addiu $t8, $t8, %lo(D_04015780) ## $t8 = 04015780
+/* 02820 80969170 3C180401 */ lui $t8, %hi(gGlowCircleSmallDL) ## $t8 = 04010000
+/* 02824 80969174 27185780 */ addiu $t8, $t8, %lo(gGlowCircleSmallDL) ## $t8 = 04015780
/* 02828 80969178 244E0008 */ addiu $t6, $v0, 0x0008 ## $t6 = 00000018
/* 0282C 8096917C AD2E02D0 */ sw $t6, 0x02D0($t1) ## 000002D0
/* 02830 80969180 3C0FDE00 */ lui $t7, 0xDE00 ## $t7 = DE000000
diff --git a/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098A4F0.s b/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098A4F0.s
index 0f359ac824..21d515c1d1 100644
--- a/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098A4F0.s
+++ b/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098A4F0.s
@@ -39,10 +39,10 @@ glabel func_8098A4F0
/* 016CC 8098A54C 24070591 */ addiu $a3, $zero, 0x0591 ## $a3 = 00000591
/* 016D0 8098A550 0C031AB1 */ jal Graph_OpenDisps
/* 016D4 8098A554 00A08025 */ or $s0, $a1, $zero ## $s0 = 00000000
-/* 016D8 8098A558 3C020405 */ lui $v0, %hi(D_04052DB0) ## $v0 = 04050000
+/* 016D8 8098A558 3C020405 */ lui $v0, %hi(gDust5Tex) ## $v0 = 04050000
/* 016DC 8098A55C 3C0100FF */ lui $at, 0x00FF ## $at = 00FF0000
/* 016E0 8098A560 3421FFFF */ ori $at, $at, 0xFFFF ## $at = 00FFFFFF
-/* 016E4 8098A564 24422DB0 */ addiu $v0, $v0, %lo(D_04052DB0) ## $v0 = 04052DB0
+/* 016E4 8098A564 24422DB0 */ addiu $v0, $v0, %lo(gDust5Tex) ## $v0 = 04052DB0
/* 016E8 8098A568 0041B824 */ and $s7, $v0, $at
/* 016EC 8098A56C 3C0141F0 */ lui $at, 0x41F0 ## $at = 41F00000
/* 016F0 8098A570 4481F000 */ mtc1 $at, $f30 ## $f30 = 30.00
@@ -50,8 +50,8 @@ glabel func_8098A4F0
/* 016F8 8098A578 000E7F02 */ srl $t7, $t6, 28
/* 016FC 8098A57C 3C0142F0 */ lui $at, 0x42F0 ## $at = 42F00000
/* 01700 8098A580 3C198016 */ lui $t9, %hi(gSegments)
-/* 01704 8098A584 3C080401 */ lui $t0, %hi(D_04010050) ## $t0 = 04010000
-/* 01708 8098A588 25080050 */ addiu $t0, $t0, %lo(D_04010050) ## $t0 = 04010050
+/* 01704 8098A584 3C080401 */ lui $t0, %hi(gEffDustDL) ## $t0 = 04010000
+/* 01708 8098A588 25080050 */ addiu $t0, $t0, %lo(gEffDustDL) ## $t0 = 04010050
/* 0170C 8098A58C 27396FA8 */ addiu $t9, %lo(gSegments)
/* 01710 8098A590 000FC080 */ sll $t8, $t7, 2
/* 01714 8098A594 3C1E0100 */ lui $s8, %hi(D_01000000) ## $s8 = 01000000
diff --git a/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098ABC0.s b/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098ABC0.s
index b3664e676e..3183378e51 100644
--- a/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098ABC0.s
+++ b/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098ABC0.s
@@ -390,8 +390,8 @@ glabel func_8098ABC0
/* 02274 8098B0F4 93AF00B7 */ lbu $t7, 0x00B7($sp)
/* 02278 8098B0F8 3C010001 */ lui $at, 0x0001 ## $at = 00010000
/* 0227C 8098B0FC 34211DA0 */ ori $at, $at, 0x1DA0 ## $at = 00011DA0
-/* 02280 8098B100 3C0D0401 */ lui $t5, %hi(gGameKeepMoteDL0) ## $t5 = 04010000
-/* 02284 8098B104 25AD0130 */ addiu $t5, $t5, %lo(gGameKeepMoteDL0) ## $t5 = 04010130
+/* 02280 8098B100 3C0D0401 */ lui $t5, %hi(gEffFlash1DL) ## $t5 = 04010000
+/* 02284 8098B104 25AD0130 */ addiu $t5, $t5, %lo(gEffFlash1DL) ## $t5 = 04010130
/* 02288 8098B108 02417021 */ addu $t6, $s2, $at
/* 0228C 8098B10C AFAE0078 */ sw $t6, 0x0078($sp)
/* 02290 8098B110 11E00007 */ beq $t7, $zero, .L8098B130
diff --git a/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098B354.s b/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098B354.s
index 33db118e8a..23740dae4d 100644
--- a/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098B354.s
+++ b/asm/non_matchings/overlays/actors/ovl_Demo_Kankyo/func_8098B354.s
@@ -309,8 +309,8 @@ glabel func_8098B354
/* 028E4 8098B764 3C010001 */ lui $at, 0x0001 ## $at = 00010000
/* 028E8 8098B768 34211DA0 */ ori $at, $at, 0x1DA0 ## $at = 00011DA0
/* 028EC 8098B76C 44060000 */ mfc1 $a2, $f0
-/* 028F0 8098B770 3C150401 */ lui $s5, %hi(gGameKeepMoteDL0) ## $s5 = 04010000
-/* 028F4 8098B774 26B50130 */ addiu $s5, $s5, %lo(gGameKeepMoteDL0) ## $s5 = 04010130
+/* 028F0 8098B770 3C150401 */ lui $s5, %hi(gEffFlash1DL) ## $s5 = 04010000
+/* 028F4 8098B774 26B50130 */ addiu $s5, $s5, %lo(gEffFlash1DL) ## $s5 = 04010130
/* 028F8 8098B778 02C19021 */ addu $s2, $s6, $at
/* 028FC 8098B77C 0C034261 */ jal Matrix_Translate
/* 02900 8098B780 00003825 */ or $a3, $zero, $zero ## $a3 = 00000000
diff --git a/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E4F4.s b/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E4F4.s
index c6fbe55348..69f67b6249 100644
--- a/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E4F4.s
+++ b/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E4F4.s
@@ -83,9 +83,9 @@ glabel func_8099E4F4
/* 00D2C 8099E5FC C6220550 */ lwc1 $f2, 0x0550($s1) ## 00000550
/* 00D30 8099E600 C6300554 */ lwc1 $f16, 0x0554($s1) ## 00000554
/* 00D34 8099E604 C6320558 */ lwc1 $f18, 0x0558($s1) ## 00000558
-/* 00D38 8099E608 3C020403 */ lui $v0, %hi(D_04037880) ## $v0 = 04030000
+/* 00D38 8099E608 3C020403 */ lui $v0, %hi(gEffFairySparklesDL) ## $v0 = 04030000
/* 00D3C 8099E60C 4602B201 */ sub.s $f8, $f22, $f2
-/* 00D40 8099E610 24427880 */ addiu $v0, $v0, %lo(D_04037880) ## $v0 = 04037880
+/* 00D40 8099E610 24427880 */ addiu $v0, $v0, %lo(gEffFairySparklesDL) ## $v0 = 04037880
/* 00D44 8099E614 3C0100FF */ lui $at, 0x00FF ## $at = 00FF0000
/* 00D48 8099E618 4604B001 */ sub.s $f0, $f22, $f4
/* 00D4C 8099E61C C6440000 */ lwc1 $f4, 0x0000($s2) ## 0000024C
diff --git a/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E784.s b/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E784.s
index 3251ff524a..2953c12e1b 100644
--- a/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E784.s
+++ b/asm/non_matchings/overlays/actors/ovl_Eff_Dust/func_8099E784.s
@@ -116,9 +116,9 @@ glabel func_8099E784
/* 01028 8099E8F8 AC6F0000 */ sw $t7, 0x0000($v1) ## 00000000
/* 0102C 8099E8FC C62A0000 */ lwc1 $f10, 0x0000($s1) ## 0000014C
/* 01030 8099E900 24190001 */ addiu $t9, $zero, 0x0001 ## $t9 = 00000001
-/* 01034 8099E904 3C020403 */ lui $v0, %hi(D_04037880) ## $v0 = 04030000
+/* 01034 8099E904 3C020403 */ lui $v0, %hi(gEffFairySparklesDL) ## $v0 = 04030000
/* 01038 8099E908 46185402 */ mul.s $f16, $f10, $f24
-/* 0103C 8099E90C 24427880 */ addiu $v0, $v0, %lo(D_04037880) ## $v0 = 04037880
+/* 0103C 8099E90C 24427880 */ addiu $v0, $v0, %lo(gEffFairySparklesDL) ## $v0 = 04037880
/* 01040 8099E910 3C0100FF */ lui $at, 0x00FF ## $at = 00FF0000
/* 01044 8099E914 3421FFFF */ ori $at, $at, 0xFFFF ## $at = 00FFFFFF
/* 01048 8099E918 0041B024 */ and $s6, $v0, $at
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Draw.s b/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Draw.s
index ff6aa709a5..5d5bd418e0 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Draw.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Draw.s
@@ -238,10 +238,10 @@ glabel EnArrow_Draw
/* 0137C 809B4C9C AFA20040 */ sw $v0, 0x0040($sp)
/* 01380 809B4CA0 8FA30040 */ lw $v1, 0x0040($sp)
/* 01384 809B4CA4 8FA80064 */ lw $t0, 0x0064($sp)
-/* 01388 809B4CA8 3C0C0403 */ lui $t4, %hi(D_04037880) ## $t4 = 04030000
+/* 01388 809B4CA8 3C0C0403 */ lui $t4, %hi(gEffFairySparklesDL) ## $t4 = 04030000
/* 0138C 809B4CAC AC620004 */ sw $v0, 0x0004($v1) ## 00000004
/* 01390 809B4CB0 8D0202D0 */ lw $v0, 0x02D0($t0) ## 000002D0
-/* 01394 809B4CB4 258C7880 */ addiu $t4, $t4, %lo(D_04037880) ## $t4 = 04037880
+/* 01394 809B4CB4 258C7880 */ addiu $t4, $t4, %lo(gEffFairySparklesDL) ## $t4 = 04037880
/* 01398 809B4CB8 3C0BDE00 */ lui $t3, 0xDE00 ## $t3 = DE000000
/* 0139C 809B4CBC 244A0008 */ addiu $t2, $v0, 0x0008 ## $t2 = 00000008
/* 013A0 809B4CC0 AD0A02D0 */ sw $t2, 0x02D0($t0) ## 000002D0
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Init.s b/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Init.s
index 8bb3bb24ea..bbf52be668 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Init.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Arrow/EnArrow_Init.s
@@ -32,10 +32,10 @@ glabel EnArrow_Init
/* 00050 809B3970 28410009 */ slti $at, $v0, 0x0009
/* 00054 809B3974 1020000B */ beq $at, $zero, .L809B39A4
/* 00058 809B3978 8FA4003C */ lw $a0, 0x003C($sp)
-/* 0005C 809B397C 3C060400 */ lui $a2, %hi(D_04006010) ## $a2 = 04000000
-/* 00060 809B3980 3C070400 */ lui $a3, %hi(D_0400436C) ## $a3 = 04000000
-/* 00064 809B3984 24E7436C */ addiu $a3, $a3, %lo(D_0400436C) ## $a3 = 0400436C
-/* 00068 809B3988 24C66010 */ addiu $a2, $a2, %lo(D_04006010) ## $a2 = 04006010
+/* 0005C 809B397C 3C060400 */ lui $a2, %hi(gArrowSkel) ## $a2 = 04000000
+/* 00060 809B3980 3C070400 */ lui $a3, %hi(gArrow2Anim) ## $a3 = 04000000
+/* 00064 809B3984 24E7436C */ addiu $a3, $a3, %lo(gArrow2Anim) ## $a3 = 0400436C
+/* 00068 809B3988 24C66010 */ addiu $a2, $a2, %lo(gArrowSkel) ## $a2 = 04006010
/* 0006C 809B398C 2605014C */ addiu $a1, $s0, 0x014C ## $a1 = 0000014C
/* 00070 809B3990 AFA00010 */ sw $zero, 0x0010($sp)
/* 00074 809B3994 AFA00014 */ sw $zero, 0x0014($sp)
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3CEC.s b/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3CEC.s
index dd181f2330..384a6363ec 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3CEC.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3CEC.s
@@ -17,8 +17,8 @@ glabel func_809B3CEC
/* 003E4 809B3D04 3C05809B */ lui $a1, %hi(func_809B4640) ## $a1 = 809B0000
/* 003E8 809B3D08 0C26CE48 */ jal func_809B3920
/* 003EC 809B3D0C 24A54640 */ addiu $a1, $a1, %lo(func_809B4640) ## $a1 = 809B4640
-/* 003F0 809B3D10 3C050400 */ lui $a1, %hi(D_04004310) ## $a1 = 04000000
-/* 003F4 809B3D14 24A54310 */ addiu $a1, $a1, %lo(D_04004310) ## $a1 = 04004310
+/* 003F0 809B3D10 3C050400 */ lui $a1, %hi(gArrow1Anim) ## $a1 = 04000000
+/* 003F4 809B3D14 24A54310 */ addiu $a1, $a1, %lo(gArrow1Anim) ## $a1 = 04004310
/* 003F8 809B3D18 0C02947A */ jal Animation_PlayOnce
/* 003FC 809B3D1C 2604014C */ addiu $a0, $s0, 0x014C ## $a0 = 0000014C
/* 00400 809B3D20 0C03F66B */ jal Rand_ZeroOne
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3FDC.s b/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3FDC.s
index 62d5cbe7bf..fa8d455726 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3FDC.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Arrow/func_809B3FDC.s
@@ -226,8 +226,8 @@ glabel func_809B3FDC
/* 009D4 809B42F4 8E02024C */ lw $v0, 0x024C($s0) ## 0000024C
/* 009D8 809B42F8 0C26CE48 */ jal func_809B3920
/* 009DC 809B42FC 24A545E0 */ addiu $a1, $a1, %lo(func_809B45E0) ## $a1 = 809B45E0
-/* 009E0 809B4300 3C050400 */ lui $a1, %hi(D_0400436C) ## $a1 = 04000000
-/* 009E4 809B4304 24A5436C */ addiu $a1, $a1, %lo(D_0400436C) ## $a1 = 0400436C
+/* 009E0 809B4300 3C050400 */ lui $a1, %hi(gArrow2Anim) ## $a1 = 04000000
+/* 009E4 809B4304 24A5436C */ addiu $a1, $a1, %lo(gArrow2Anim) ## $a1 = 0400436C
/* 009E8 809B4308 0C02947A */ jal Animation_PlayOnce
/* 009EC 809B430C 2604014C */ addiu $a0, $s0, 0x014C ## $a0 = 0000014C
/* 009F0 809B4310 8609001C */ lh $t1, 0x001C($s0) ## 0000001C
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Bom_Chu/EnBomChu_Draw.s b/asm/non_matchings/overlays/actors/ovl_En_Bom_Chu/EnBomChu_Draw.s
index c155c64989..6705a2cf23 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Bom_Chu/EnBomChu_Draw.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Bom_Chu/EnBomChu_Draw.s
@@ -227,8 +227,8 @@ glabel EnBomChu_Draw
/* 0147C 809C6CAC 8F040000 */ lw $a0, 0x0000($t8) ## 00000000
/* 01480 809C6CB0 AE020004 */ sw $v0, 0x0004($s0) ## 00000004
/* 01484 809C6CB4 8E2202C0 */ lw $v0, 0x02C0($s1) ## 000002C0
-/* 01488 809C6CB8 3C0A0400 */ lui $t2, %hi(D_04007E10) ## $t2 = 04000000
-/* 0148C 809C6CBC 254A7E10 */ addiu $t2, $t2, %lo(D_04007E10) ## $t2 = 04007E10
+/* 01488 809C6CB8 3C0A0400 */ lui $t2, %hi(gBombchuDL) ## $t2 = 04000000
+/* 0148C 809C6CBC 254A7E10 */ addiu $t2, $t2, %lo(gBombchuDL) ## $t2 = 04007E10
/* 01490 809C6CC0 24480008 */ addiu $t0, $v0, 0x0008 ## $t0 = 00000008
/* 01494 809C6CC4 AE2802C0 */ sw $t0, 0x02C0($s1) ## 000002C0
/* 01498 809C6CC8 3C09DE00 */ lui $t1, 0xDE00 ## $t1 = DE000000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Dekubaba/func_809E8AD8.s b/asm/non_matchings/overlays/actors/ovl_En_Dekubaba/func_809E8AD8.s
index 4ca9e14274..3425702b51 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Dekubaba/func_809E8AD8.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Dekubaba/func_809E8AD8.s
@@ -75,8 +75,8 @@ glabel func_809E8AD8
/* 033E4 809E8BB4 8D840000 */ lw $a0, 0x0000($t4) ## 00000000
/* 033E8 809E8BB8 AE220004 */ sw $v0, 0x0004($s1) ## 00000004
/* 033EC 809E8BBC 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
-/* 033F0 809E8BC0 3C0F0405 */ lui $t7, %hi(D_04049210) ## $t7 = 04050000
-/* 033F4 809E8BC4 25EF9210 */ addiu $t7, $t7, %lo(D_04049210) ## $t7 = 04049210
+/* 033F0 809E8BC0 3C0F0405 */ lui $t7, %hi(gCircleShadowDL) ## $t7 = 04050000
+/* 033F4 809E8BC4 25EF9210 */ addiu $t7, $t7, %lo(gCircleShadowDL) ## $t7 = 04049210
/* 033F8 809E8BC8 244D0008 */ addiu $t5, $v0, 0x0008 ## $t5 = 00000008
/* 033FC 809E8BCC AE0D02D0 */ sw $t5, 0x02D0($s0) ## 000002D0
/* 03400 809E8BD0 3C0EDE00 */ lui $t6, 0xDE00 ## $t6 = DE000000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Fish/EnFish_Init.s b/asm/non_matchings/overlays/actors/ovl_En_Fish/EnFish_Init.s
index b4d537f7e8..3287f94f04 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Fish/EnFish_Init.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Fish/EnFish_Init.s
@@ -17,16 +17,16 @@ glabel EnFish_Init
/* 00208 80A15488 0C01E037 */ jal Actor_ProcessInitChain
/* 0020C 80A1548C A7AE003A */ sh $t6, 0x003A($sp)
-/* 00210 80A15490 3C060402 */ lui $a2, %hi(D_04018FE0) ## $a2 = 04020000
-/* 00214 80A15494 3C070402 */ lui $a3, %hi(D_0401909C) ## $a3 = 04020000
+/* 00210 80A15490 3C060402 */ lui $a2, %hi(gFishSkel) ## $a2 = 04020000
+/* 00214 80A15494 3C070402 */ lui $a3, %hi(gFish2Anim) ## $a3 = 04020000
/* 00218 80A15498 260F01F0 */ addiu $t7, $s0, 0x01F0 ## $t7 = 000001F0
/* 0021C 80A1549C 2618021A */ addiu $t8, $s0, 0x021A ## $t8 = 0000021A
/* 00220 80A154A0 24190007 */ addiu $t9, $zero, 0x0007 ## $t9 = 00000007
/* 00224 80A154A4 AFB90018 */ sw $t9, 0x0018($sp)
/* 00228 80A154A8 AFB80014 */ sw $t8, 0x0014($sp)
/* 0022C 80A154AC AFAF0010 */ sw $t7, 0x0010($sp)
-/* 00230 80A154B0 24E7909C */ addiu $a3, $a3, %lo(D_0401909C) ## $a3 = 0401909C
-/* 00234 80A154B4 24C68FE0 */ addiu $a2, $a2, %lo(D_04018FE0) ## $a2 = 04018FE0
+/* 00230 80A154B0 24E7909C */ addiu $a3, $a3, %lo(gFish2Anim) ## $a3 = 0401909C
+/* 00234 80A154B4 24C68FE0 */ addiu $a2, $a2, %lo(gFishSkel) ## $a2 = 04018FE0
/* 00238 80A154B8 8FA40044 */ lw $a0, 0x0044($sp)
/* 0023C 80A154BC 0C0291BE */ jal SkelAnime_InitFlex
/* 00240 80A154C0 260501AC */ addiu $a1, $s0, 0x01AC ## $a1 = 000001AC
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A152AC.s b/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A152AC.s
index 72c930a26e..b67be2c509 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A152AC.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A152AC.s
@@ -2,19 +2,19 @@ glabel func_80A152AC
/* 0002C 80A152AC 27BDFFD8 */ addiu $sp, $sp, 0xFFD8 ## $sp = FFFFFFD8
/* 00030 80A152B0 AFA40028 */ sw $a0, 0x0028($sp)
/* 00034 80A152B4 AFBF0024 */ sw $ra, 0x0024($sp)
-/* 00038 80A152B8 3C040402 */ lui $a0, %hi(D_0401909C) ## $a0 = 04020000
+/* 00038 80A152B8 3C040402 */ lui $a0, %hi(gFish2Anim) ## $a0 = 04020000
/* 0003C 80A152BC 0C028800 */ jal Animation_GetLastFrame
-/* 00040 80A152C0 2484909C */ addiu $a0, $a0, %lo(D_0401909C) ## $a0 = 0401909C
+/* 00040 80A152C0 2484909C */ addiu $a0, $a0, %lo(gFish2Anim) ## $a0 = 0401909C
/* 00044 80A152C4 44822000 */ mtc1 $v0, $f4 ## $f4 = 0.00
/* 00048 80A152C8 3C014000 */ lui $at, 0x4000 ## $at = 40000000
/* 0004C 80A152CC 44814000 */ mtc1 $at, $f8 ## $f8 = 2.00
/* 00050 80A152D0 468021A0 */ cvt.s.w $f6, $f4
/* 00054 80A152D4 8FA40028 */ lw $a0, 0x0028($sp)
-/* 00058 80A152D8 3C050402 */ lui $a1, %hi(D_0401909C) ## $a1 = 04020000
+/* 00058 80A152D8 3C050402 */ lui $a1, %hi(gFish2Anim) ## $a1 = 04020000
/* 0005C 80A152DC 240E0001 */ addiu $t6, $zero, 0x0001 ## $t6 = 00000001
/* 00060 80A152E0 AFAE0014 */ sw $t6, 0x0014($sp)
-/* 00064 80A152E4 24A5909C */ addiu $a1, $a1, %lo(D_0401909C) ## $a1 = 0401909C
+/* 00064 80A152E4 24A5909C */ addiu $a1, $a1, %lo(gFish2Anim) ## $a1 = 0401909C
/* 00068 80A152E8 E7A60010 */ swc1 $f6, 0x0010($sp)
/* 0006C 80A152EC 3C063F80 */ lui $a2, 0x3F80 ## $a2 = 3F800000
/* 00070 80A152F0 24070000 */ addiu $a3, $zero, 0x0000 ## $a3 = 00000000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A15310.s b/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A15310.s
index c1124f5a98..e7ed43c962 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A15310.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Fish/func_80A15310.s
@@ -2,19 +2,19 @@ glabel func_80A15310
/* 00090 80A15310 27BDFFD8 */ addiu $sp, $sp, 0xFFD8 ## $sp = FFFFFFD8
/* 00094 80A15314 AFA40028 */ sw $a0, 0x0028($sp)
/* 00098 80A15318 AFBF0024 */ sw $ra, 0x0024($sp)
-/* 0009C 80A1531C 3C040402 */ lui $a0, %hi(D_040185FC) ## $a0 = 04020000
+/* 0009C 80A1531C 3C040402 */ lui $a0, %hi(gFish1Anim) ## $a0 = 04020000
/* 000A0 80A15320 0C028800 */ jal Animation_GetLastFrame
-/* 000A4 80A15324 248485FC */ addiu $a0, $a0, %lo(D_040185FC) ## $a0 = 040185FC
+/* 000A4 80A15324 248485FC */ addiu $a0, $a0, %lo(gFish1Anim) ## $a0 = 040185FC
/* 000A8 80A15328 44822000 */ mtc1 $v0, $f4 ## $f4 = 0.00
/* 000AC 80A1532C 3C014000 */ lui $at, 0x4000 ## $at = 40000000
/* 000B0 80A15330 44814000 */ mtc1 $at, $f8 ## $f8 = 2.00
/* 000B4 80A15334 468021A0 */ cvt.s.w $f6, $f4
/* 000B8 80A15338 8FA40028 */ lw $a0, 0x0028($sp)
-/* 000BC 80A1533C 3C050402 */ lui $a1, %hi(D_040185FC) ## $a1 = 04020000
+/* 000BC 80A1533C 3C050402 */ lui $a1, %hi(gFish1Anim) ## $a1 = 04020000
/* 000C0 80A15340 240E0001 */ addiu $t6, $zero, 0x0001 ## $t6 = 00000001
/* 000C4 80A15344 AFAE0014 */ sw $t6, 0x0014($sp)
-/* 000C8 80A15348 24A585FC */ addiu $a1, $a1, %lo(D_040185FC) ## $a1 = 040185FC
+/* 000C8 80A15348 24A585FC */ addiu $a1, $a1, %lo(gFish1Anim) ## $a1 = 040185FC
/* 000CC 80A1534C E7A60010 */ swc1 $f6, 0x0010($sp)
/* 000D0 80A15350 3C063F80 */ lui $a2, 0x3F80 ## $a2 = 3F800000
/* 000D4 80A15354 24070000 */ addiu $a3, $zero, 0x0000 ## $a3 = 00000000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_M_Thunder/EnMThunder_Draw.s b/asm/non_matchings/overlays/actors/ovl_En_M_Thunder/EnMThunder_Draw.s
index 01a93929e3..0159c219d5 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_M_Thunder/EnMThunder_Draw.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_M_Thunder/EnMThunder_Draw.s
@@ -184,16 +184,16 @@ glabel EnMThunder_Draw
/* 00F38 80A9FF18 AC6F0004 */ sw $t7, 0x0004($v1) ## 00000004
/* 00F3C 80A9FF1C 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 00F40 80A9FF20 44D8F800 */ ctc1 $t8, $31
-/* 00F44 80A9FF24 3C190401 */ lui $t9, %hi(D_04012AF0) ## $t9 = 04010000
+/* 00F44 80A9FF24 3C190401 */ lui $t9, %hi(gSpinAttack3DL) ## $t9 = 04010000
/* 00F48 80A9FF28 244E0008 */ addiu $t6, $v0, 0x0008 ## $t6 = 00000008
/* 00F4C 80A9FF2C AE0E02D0 */ sw $t6, 0x02D0($s0) ## 000002D0
-/* 00F50 80A9FF30 27392AF0 */ addiu $t9, $t9, %lo(D_04012AF0) ## $t9 = 04012AF0
+/* 00F50 80A9FF30 27392AF0 */ addiu $t9, $t9, %lo(gSpinAttack3DL) ## $t9 = 04012AF0
/* 00F54 80A9FF34 3C18DE00 */ lui $t8, 0xDE00 ## $t8 = DE000000
/* 00F58 80A9FF38 AC580000 */ sw $t8, 0x0000($v0) ## 00000000
/* 00F5C 80A9FF3C AC590004 */ sw $t9, 0x0004($v0) ## 00000004
/* 00F60 80A9FF40 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
-/* 00F64 80A9FF44 3C0F0401 */ lui $t7, %hi(D_04012C10) ## $t7 = 04010000
-/* 00F68 80A9FF48 25EF2C10 */ addiu $t7, $t7, %lo(D_04012C10) ## $t7 = 04012C10
+/* 00F64 80A9FF44 3C0F0401 */ lui $t7, %hi(gSpinAttack4DL) ## $t7 = 04010000
+/* 00F68 80A9FF48 25EF2C10 */ addiu $t7, $t7, %lo(gSpinAttack4DL) ## $t7 = 04012C10
/* 00F6C 80A9FF4C 244C0008 */ addiu $t4, $v0, 0x0008 ## $t4 = 00000008
/* 00F70 80A9FF50 AE0C02D0 */ sw $t4, 0x02D0($s0) ## 000002D0
/* 00F74 80A9FF54 3C0DDE00 */ lui $t5, 0xDE00 ## $t5 = DE000000
@@ -253,16 +253,16 @@ glabel EnMThunder_Draw
/* 0103C 80AA001C AC6E0004 */ sw $t6, 0x0004($v1) ## 00000004
/* 01040 80AA0020 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 01044 80AA0024 44D9F800 */ ctc1 $t9, $31
-/* 01048 80AA0028 3C0C0401 */ lui $t4, %hi(D_04012570) ## $t4 = 04010000
+/* 01048 80AA0028 3C0C0401 */ lui $t4, %hi(gSpinAttack1DL) ## $t4 = 04010000
/* 0104C 80AA002C 24580008 */ addiu $t8, $v0, 0x0008 ## $t8 = 00000008
/* 01050 80AA0030 AE1802D0 */ sw $t8, 0x02D0($s0) ## 000002D0
-/* 01054 80AA0034 258C2570 */ addiu $t4, $t4, %lo(D_04012570) ## $t4 = 04012570
+/* 01054 80AA0034 258C2570 */ addiu $t4, $t4, %lo(gSpinAttack1DL) ## $t4 = 04012570
/* 01058 80AA0038 3C19DE00 */ lui $t9, 0xDE00 ## $t9 = DE000000
/* 0105C 80AA003C AC590000 */ sw $t9, 0x0000($v0) ## 00000000
/* 01060 80AA0040 AC4C0004 */ sw $t4, 0x0004($v0) ## 00000004
/* 01064 80AA0044 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
-/* 01068 80AA0048 3C0E0401 */ lui $t6, %hi(D_04012690) ## $t6 = 04010000
-/* 0106C 80AA004C 25CE2690 */ addiu $t6, $t6, %lo(D_04012690) ## $t6 = 04012690
+/* 01068 80AA0048 3C0E0401 */ lui $t6, %hi(gSpinAttack2DL) ## $t6 = 04010000
+/* 0106C 80AA004C 25CE2690 */ addiu $t6, $t6, %lo(gSpinAttack2DL) ## $t6 = 04012690
/* 01070 80AA0050 244D0008 */ addiu $t5, $v0, 0x0008 ## $t5 = 00000008
/* 01074 80AA0054 AE0D02D0 */ sw $t5, 0x02D0($s0) ## 000002D0
/* 01078 80AA0058 3C0FDE00 */ lui $t7, 0xDE00 ## $t7 = DE000000
@@ -485,8 +485,8 @@ glabel EnMThunder_Draw
/* 013BC 80AA039C 0C0253D0 */ jal Gfx_TwoTexScroll
/* 013C0 80AA03A0 AFA20050 */ sw $v0, 0x0050($sp)
/* 013C4 80AA03A4 8FA80050 */ lw $t0, 0x0050($sp)
-/* 013C8 80AA03A8 3C0C0401 */ lui $t4, %hi(D_04013610) ## $t4 = 04010000
-/* 013CC 80AA03AC 258C3610 */ addiu $t4, $t4, %lo(D_04013610) ## $t4 = 04013610
+/* 013C8 80AA03A8 3C0C0401 */ lui $t4, %hi(gSpinAttackChargingDL) ## $t4 = 04010000
+/* 013CC 80AA03AC 258C3610 */ addiu $t4, $t4, %lo(gSpinAttackChargingDL) ## $t4 = 04013610
/* 013D0 80AA03B0 AD020004 */ sw $v0, 0x0004($t0) ## 00000004
/* 013D4 80AA03B4 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 013D8 80AA03B8 3C19DE00 */ lui $t9, 0xDE00 ## $t9 = DE000000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC7528.s b/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC7528.s
index 73a25c3f17..631230fdb9 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC7528.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC7528.s
@@ -54,8 +54,8 @@ glabel func_80AC7528
/* 04930 80AC75D0 016E6025 */ or $t4, $t3, $t6 ## $t4 = 00000000
/* 04934 80AC75D4 AC4C0004 */ sw $t4, 0x0004($v0) ## 00000004
/* 04938 80AC75D8 8D0202B0 */ lw $v0, 0x02B0($t0) ## 000002B0
-/* 0493C 80AC75DC 3C090401 */ lui $t1, %hi(D_0400CDC0) ## $t1 = 04010000
-/* 04940 80AC75E0 2529CDC0 */ addiu $t1, $t1, %lo(D_0400CDC0) ## $t1 = 0400CDC0
+/* 0493C 80AC75DC 3C090401 */ lui $t1, %hi(gSelectionCursorTex) ## $t1 = 04010000
+/* 04940 80AC75E0 2529CDC0 */ addiu $t1, $t1, %lo(gSelectionCursorTex) ## $t1 = 0400CDC0
/* 04944 80AC75E4 244F0008 */ addiu $t7, $v0, 0x0008 ## $t7 = 00000008
/* 04948 80AC75E8 AD0F02B0 */ sw $t7, 0x02B0($t0) ## 000002B0
/* 0494C 80AC75EC 3C19FD70 */ lui $t9, 0xFD70 ## $t9 = FD700000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC79C8.s b/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC79C8.s
index 7a77ce1503..643735974a 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC79C8.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Ossan/func_80AC79C8.s
@@ -47,8 +47,8 @@ glabel func_80AC79C8
/* 04DB0 80AC7A50 AC4D0004 */ sw $t5, 0x0004($v0) ## 00000004
/* 04DB4 80AC7A54 AC4C0000 */ sw $t4, 0x0000($v0) ## 00000000
/* 04DB8 80AC7A58 8D0202B0 */ lw $v0, 0x02B0($t0) ## 000002B0
-/* 04DBC 80AC7A5C 3C180401 */ lui $t8, %hi(D_0400CF40) ## $t8 = 04010000
-/* 04DC0 80AC7A60 2718CF40 */ addiu $t8, $t8, %lo(D_0400CF40) ## $t8 = 0400CF40
+/* 04DBC 80AC7A5C 3C180401 */ lui $t8, %hi(gArrowCursorTex) ## $t8 = 04010000
+/* 04DC0 80AC7A60 2718CF40 */ addiu $t8, $t8, %lo(gArrowCursorTex) ## $t8 = 0400CF40
/* 04DC4 80AC7A64 244E0008 */ addiu $t6, $v0, 0x0008 ## $t6 = 00000008
/* 04DC8 80AC7A68 AD0E02B0 */ sw $t6, 0x02B0($t0) ## 000002B0
/* 04DCC 80AC7A6C 3C0FFD70 */ lui $t7, 0xFD70 ## $t7 = FD700000
@@ -151,8 +151,8 @@ glabel func_80AC79C8
/* 04F4C 80AC7BEC 8FA80094 */ lw $t0, 0x0094($sp)
/* 04F50 80AC7BF0 8D0202B0 */ lw $v0, 0x02B0($t0) ## 000002B0
.L80AC7BF4:
-/* 04F54 80AC7BF4 3C0C0401 */ lui $t4, %hi(D_0400CE40) ## $t4 = 04010000
-/* 04F58 80AC7BF8 258CCE40 */ addiu $t4, $t4, %lo(D_0400CE40) ## $t4 = 0400CE40
+/* 04F54 80AC7BF4 3C0C0401 */ lui $t4, %hi(gControlStickTex) ## $t4 = 04010000
+/* 04F58 80AC7BF8 258CCE40 */ addiu $t4, $t4, %lo(gControlStickTex) ## $t4 = 0400CE40
/* 04F5C 80AC7BFC 244A0008 */ addiu $t2, $v0, 0x0008 ## $t2 = 00000008
/* 04F60 80AC7C00 AD0A02B0 */ sw $t2, 0x02B0($t0) ## 000002B0
/* 04F64 80AC7C04 3C0BFD70 */ lui $t3, 0xFD70 ## $t3 = FD700000
diff --git a/asm/non_matchings/overlays/actors/ovl_En_Vb_Ball/EnVbBall_Draw.s b/asm/non_matchings/overlays/actors/ovl_En_Vb_Ball/EnVbBall_Draw.s
index de187fe0be..cde93998d5 100644
--- a/asm/non_matchings/overlays/actors/ovl_En_Vb_Ball/EnVbBall_Draw.s
+++ b/asm/non_matchings/overlays/actors/ovl_En_Vb_Ball/EnVbBall_Draw.s
@@ -136,8 +136,8 @@ glabel EnVbBall_Draw
/* 00FAC 80B29F4C 0C0346A2 */ jal Matrix_NewMtx
/* 00FB0 80B29F50 AFA20028 */ sw $v0, 0x0028($sp)
/* 00FB4 80B29F54 8FA30028 */ lw $v1, 0x0028($sp)
-/* 00FB8 80B29F58 3C040405 */ lui $a0, %hi(D_04049210) ## $a0 = 04050000
-/* 00FBC 80B29F5C 24849210 */ addiu $a0, $a0, %lo(D_04049210) ## $a0 = 04049210
+/* 00FB8 80B29F58 3C040405 */ lui $a0, %hi(gCircleShadowDL) ## $a0 = 04050000
+/* 00FBC 80B29F5C 24849210 */ addiu $a0, $a0, %lo(gCircleShadowDL) ## $a0 = 04049210
/* 00FC0 80B29F60 AC620004 */ sw $v0, 0x0004($v1) ## 00000004
/* 00FC4 80B29F64 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 00FC8 80B29F68 00046900 */ sll $t5, $a0, 4
diff --git a/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA3C94.s b/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA3C94.s
index c648ae22eb..be01e2c02d 100644
--- a/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA3C94.s
+++ b/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA3C94.s
@@ -66,8 +66,8 @@ glabel func_80BA3C94
/* 012A0 80BA3D40 8E4402D0 */ lw $a0, 0x02D0($s2) ## 000002D0
/* 012A4 80BA3D44 0C024DDD */ jal Gfx_CallSetupDL
/* 012A8 80BA3D48 24050014 */ addiu $a1, $zero, 0x0014 ## $a1 = 00000014
-/* 012AC 80BA3D4C 3C040405 */ lui $a0, %hi(D_0404C160) ## $a0 = 04050000
-/* 012B0 80BA3D50 2484C160 */ addiu $a0, $a0, %lo(D_0404C160) ## $a0 = 0404C160
+/* 012AC 80BA3D4C 3C040405 */ lui $a0, %hi(gSun1Tex) ## $a0 = 04050000
+/* 012B0 80BA3D50 2484C160 */ addiu $a0, $a0, %lo(gSun1Tex) ## $a0 = 0404C160
/* 012B4 80BA3D54 0004C900 */ sll $t9, $a0, 4
/* 012B8 80BA3D58 AE4202D0 */ sw $v0, 0x02D0($s2) ## 000002D0
/* 012BC 80BA3D5C 00194702 */ srl $t0, $t9, 28
@@ -88,8 +88,8 @@ glabel func_80BA3C94
/* 012F8 80BA3D98 01816821 */ addu $t5, $t4, $at
/* 012FC 80BA3D9C AC4D0004 */ sw $t5, 0x0004($v0) ## 00000004
/* 01300 80BA3DA0 8E4202D0 */ lw $v0, 0x02D0($s2) ## 000002D0
-/* 01304 80BA3DA4 3C180405 */ lui $t8, %hi(D_0404D160) ## $t8 = 04050000
-/* 01308 80BA3DA8 2718D160 */ addiu $t8, $t8, %lo(D_0404D160) ## $t8 = 0404D160
+/* 01304 80BA3DA4 3C180405 */ lui $t8, %hi(gKokiriDustMoteTextureLoadDL ) ## $t8 = 04050000
+/* 01308 80BA3DA8 2718D160 */ addiu $t8, $t8, %lo(gKokiriDustMoteTextureLoadDL ) ## $t8 = 0404D160
/* 0130C 80BA3DAC 244E0008 */ addiu $t6, $v0, 0x0008 ## $t6 = 00000008
/* 01310 80BA3DB0 AE4E02D0 */ sw $t6, 0x02D0($s2) ## 000002D0
/* 01314 80BA3DB4 3C0FDE00 */ lui $t7, 0xDE00 ## $t7 = DE000000
@@ -105,8 +105,8 @@ glabel func_80BA3C94
/* 0133C 80BA3DDC 34211DA0 */ ori $at, $at, 0x1DA0 ## $at = 00011DA0
/* 01340 80BA3DE0 02815021 */ addu $t2, $s4, $at
/* 01344 80BA3DE4 3C013F80 */ lui $at, 0x3F80 ## $at = 3F800000
-/* 01348 80BA3DE8 3C090405 */ lui $t1, %hi(D_0404D1A8) ## $t1 = 04050000
-/* 0134C 80BA3DEC 2529D1A8 */ addiu $t1, $t1, %lo(D_0404D1A8) ## $t1 = 0404D1A8
+/* 01348 80BA3DE8 3C090405 */ lui $t1, %hi(gKokiriDustMoteDL) ## $t1 = 04050000
+/* 0134C 80BA3DEC 2529D1A8 */ addiu $t1, $t1, %lo(gKokiriDustMoteDL) ## $t1 = 0404D1A8
/* 01350 80BA3DF0 4481A000 */ mtc1 $at, $f20 ## $f20 = 1.00
/* 01354 80BA3DF4 AFA90048 */ sw $t1, 0x0048($sp)
/* 01358 80BA3DF8 AFAA0040 */ sw $t2, 0x0040($sp)
diff --git a/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA414C.s b/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA414C.s
index 4dbffea3fe..1a57e684aa 100644
--- a/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA414C.s
+++ b/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA414C.s
@@ -104,8 +104,8 @@ glabel func_80BA414C
/* 017D0 80BA4270 0000A025 */ or $s4, $zero, $zero ## $s4 = 00000000
/* 017D4 80BA4274 3C010001 */ lui $at, 0x0001 ## $at = 00010000
/* 017D8 80BA4278 02015821 */ addu $t3, $s0, $at
-/* 017DC 80BA427C 3C020405 */ lui $v0, %hi(D_04052DB0) ## $v0 = 04050000
-/* 017E0 80BA4280 24422DB0 */ addiu $v0, $v0, %lo(D_04052DB0) ## $v0 = 04052DB0
+/* 017DC 80BA427C 3C020405 */ lui $v0, %hi(gDust5Tex) ## $v0 = 04050000
+/* 017E0 80BA4280 24422DB0 */ addiu $v0, $v0, %lo(gDust5Tex) ## $v0 = 04052DB0
/* 017E4 80BA4284 3C0100FF */ lui $at, 0x00FF ## $at = 00FF0000
/* 017E8 80BA4288 3421FFFF */ ori $at, $at, 0xFFFF ## $at = 00FFFFFF
/* 017EC 80BA428C 0041C824 */ and $t9, $v0, $at
@@ -116,8 +116,8 @@ glabel func_80BA414C
/* 01800 80BA42A0 25EF6FA8 */ addiu $t7, %lo(gSegments)
/* 01804 80BA42A4 000D7080 */ sll $t6, $t5, 2
/* 01808 80BA42A8 3C080100 */ lui $t0, %hi(D_01000000) ## $t0 = 01000000
-/* 0180C 80BA42AC 3C090401 */ lui $t1, %hi(D_04010050) ## $t1 = 04010000
-/* 01810 80BA42B0 25290050 */ addiu $t1, $t1, %lo(D_04010050) ## $t1 = 04010050
+/* 0180C 80BA42AC 3C090401 */ lui $t1, %hi(gEffDustDL) ## $t1 = 04010000
+/* 01810 80BA42B0 25290050 */ addiu $t1, $t1, %lo(gEffDustDL) ## $t1 = 04010050
/* 01814 80BA42B4 25080000 */ addiu $t0, $t0, %lo(D_01000000) ## $t0 = 01000000
/* 01818 80BA42B8 01CFC021 */ addu $t8, $t6, $t7
/* 0181C 80BA42BC 4481F000 */ mtc1 $at, $f30 ## $f30 = 80.00
diff --git a/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA49BC.s b/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA49BC.s
index 9f84e13526..d1d550124c 100644
--- a/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA49BC.s
+++ b/asm/non_matchings/overlays/actors/ovl_Object_Kankyo/func_80BA49BC.s
@@ -135,13 +135,13 @@ glabel func_80BA49BC
/* 020DC 80BA4B7C AC580004 */ sw $t8, 0x0004($v0) ## 00000004
/* 020E0 80BA4B80 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
/* 020E4 80BA4B84 3C04E700 */ lui $a0, 0xE700 ## $a0 = E7000000
-/* 020E8 80BA4B88 3C090403 */ lui $t1, %hi(D_0402CF30) ## $t1 = 04030000
+/* 020E8 80BA4B88 3C090403 */ lui $t1, %hi(gEffLightningDL) ## $t1 = 04030000
/* 020EC 80BA4B8C 24590008 */ addiu $t9, $v0, 0x0008 ## $t9 = 00000008
/* 020F0 80BA4B90 AE1902D0 */ sw $t9, 0x02D0($s0) ## 000002D0
/* 020F4 80BA4B94 AC400004 */ sw $zero, 0x0004($v0) ## 00000004
/* 020F8 80BA4B98 AC440000 */ sw $a0, 0x0000($v0) ## 00000000
/* 020FC 80BA4B9C 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0
-/* 02100 80BA4BA0 2529CF30 */ addiu $t1, $t1, %lo(D_0402CF30) ## $t1 = 0402CF30
+/* 02100 80BA4BA0 2529CF30 */ addiu $t1, $t1, %lo(gEffLightningDL) ## $t1 = 0402CF30
/* 02104 80BA4BA4 3C0FDE00 */ lui $t7, 0xDE00 ## $t7 = DE000000
/* 02108 80BA4BA8 24480008 */ addiu $t0, $v0, 0x0008 ## $t0 = 00000008
/* 0210C 80BA4BAC AE0802D0 */ sw $t0, 0x02D0($s0) ## 000002D0
diff --git a/assets/overlays/ovl_Magic_Dark/.gitkeep b/assets/overlays/ovl_Magic_Dark/.gitkeep
deleted file mode 100644
index e69de29bb2..0000000000
diff --git a/assets/textures/icon_item_24_static/icon_item_24_static.xml b/assets/textures/icon_item_24_static/icon_item_24_static.xml
deleted file mode 100644
index 46e3bafa7a..0000000000
--- a/assets/textures/icon_item_24_static/icon_item_24_static.xml
+++ /dev/null
@@ -1,24 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/assets/textures/icon_item_dungeon_static/icon_item_dungeon_static.xml b/assets/textures/icon_item_dungeon_static/icon_item_dungeon_static.xml
deleted file mode 100644
index a0f1dabaf8..0000000000
--- a/assets/textures/icon_item_dungeon_static/icon_item_dungeon_static.xml
+++ /dev/null
@@ -1,23 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/assets/textures/icon_item_field_static/icon_item_field_static.xml b/assets/textures/icon_item_field_static/icon_item_field_static.xml
deleted file mode 100644
index 91196736b7..0000000000
--- a/assets/textures/icon_item_field_static/icon_item_field_static.xml
+++ /dev/null
@@ -1,32 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/assets/textures/icon_item_gameover_static/icon_item_gameover_static.xml b/assets/textures/icon_item_gameover_static/icon_item_gameover_static.xml
deleted file mode 100644
index d7ba47ab75..0000000000
--- a/assets/textures/icon_item_gameover_static/icon_item_gameover_static.xml
+++ /dev/null
@@ -1,9 +0,0 @@
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/assets/textures/icon_item_nes_static/icon_item_nes_static.xml b/assets/textures/icon_item_nes_static/icon_item_nes_static.xml
deleted file mode 100644
index 6eb9717973..0000000000
--- a/assets/textures/icon_item_nes_static/icon_item_nes_static.xml
+++ /dev/null
@@ -1,35 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/assets/textures/icon_item_static/icon_item_static.xml b/assets/textures/icon_item_static/icon_item_static.xml
deleted file mode 100644
index ce07e46e89..0000000000
--- a/assets/textures/icon_item_static/icon_item_static.xml
+++ /dev/null
@@ -1,183 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/assets/xml/objects/gameplay_field_keep.xml.ignore b/assets/xml/objects/gameplay_field_keep.xml.ignore
deleted file mode 100644
index 86574f2e48..0000000000
--- a/assets/xml/objects/gameplay_field_keep.xml.ignore
+++ /dev/null
@@ -1,63 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/assets/xml/objects/gameplay_keep.xml b/assets/xml/objects/gameplay_keep.xml
index 955f244df4..0a6ee3b81b 100644
--- a/assets/xml/objects/gameplay_keep.xml
+++ b/assets/xml/objects/gameplay_keep.xml
@@ -1,369 +1,959 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/objects/object_pu_box.xml b/assets/xml/objects/object_pu_box.xml
index f056cfb3ed..49ca9b672d 100644
--- a/assets/xml/objects/object_pu_box.xml
+++ b/assets/xml/objects/object_pu_box.xml
@@ -1,7 +1,13 @@
-
-
-
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/objects/object_spot09_obj.xml b/assets/xml/objects/object_spot09_obj.xml
index 782cfe4f4e..01f94bbcc2 100644
--- a/assets/xml/objects/object_spot09_obj.xml
+++ b/assets/xml/objects/object_spot09_obj.xml
@@ -1,14 +1,14 @@
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/objects/object_spot11_obj.xml b/assets/xml/objects/object_spot11_obj.xml
index 7d90d15119..dc6a291e5f 100644
--- a/assets/xml/objects/object_spot11_obj.xml
+++ b/assets/xml/objects/object_spot11_obj.xml
@@ -1,7 +1,9 @@
-
-
-
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/objects/object_spot17_obj.xml b/assets/xml/objects/object_spot17_obj.xml
index 773c145fad..8bc6e9c488 100644
--- a/assets/xml/objects/object_spot17_obj.xml
+++ b/assets/xml/objects/object_spot17_obj.xml
@@ -1,6 +1,12 @@
-
-
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/objects/object_vase.xml b/assets/xml/objects/object_vase.xml
index f0a0da1199..1ec5148f9e 100644
--- a/assets/xml/objects/object_vase.xml
+++ b/assets/xml/objects/object_vase.xml
@@ -1,7 +1,7 @@
-
-
-
+
+
+
\ No newline at end of file
diff --git a/assets/xml/overlays/ovl_Magic_Dark.xml b/assets/xml/overlays/ovl_Magic_Dark.xml
index 7569fba64a..f1ab218433 100644
--- a/assets/xml/overlays/ovl_Magic_Dark.xml
+++ b/assets/xml/overlays/ovl_Magic_Dark.xml
@@ -1,8 +1,8 @@
-
-
-
+
+
+
\ No newline at end of file
diff --git a/assets/xml/textures/icon_item_24_static.xml b/assets/xml/textures/icon_item_24_static.xml
index 46e3bafa7a..3de679dc12 100644
--- a/assets/xml/textures/icon_item_24_static.xml
+++ b/assets/xml/textures/icon_item_24_static.xml
@@ -1,24 +1,24 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/textures/icon_item_dungeon_static.xml b/assets/xml/textures/icon_item_dungeon_static.xml
index a0f1dabaf8..5ad84ec6c2 100644
--- a/assets/xml/textures/icon_item_dungeon_static.xml
+++ b/assets/xml/textures/icon_item_dungeon_static.xml
@@ -1,23 +1,23 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/textures/icon_item_field_static.xml b/assets/xml/textures/icon_item_field_static.xml
index 91196736b7..28ed66f710 100644
--- a/assets/xml/textures/icon_item_field_static.xml
+++ b/assets/xml/textures/icon_item_field_static.xml
@@ -1,32 +1,32 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/textures/icon_item_gameover_static.xml b/assets/xml/textures/icon_item_gameover_static.xml
index d7ba47ab75..0b9f3536a6 100644
--- a/assets/xml/textures/icon_item_gameover_static.xml
+++ b/assets/xml/textures/icon_item_gameover_static.xml
@@ -1,9 +1,9 @@
-
-
-
-
-
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/textures/icon_item_nes_static.xml b/assets/xml/textures/icon_item_nes_static.xml
index 6eb9717973..8e0ec4cc0e 100644
--- a/assets/xml/textures/icon_item_nes_static.xml
+++ b/assets/xml/textures/icon_item_nes_static.xml
@@ -1,35 +1,35 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/assets/xml/textures/icon_item_static.xml b/assets/xml/textures/icon_item_static.xml
index ce07e46e89..c7eec2f232 100644
--- a/assets/xml/textures/icon_item_static.xml
+++ b/assets/xml/textures/icon_item_static.xml
@@ -1,183 +1,191 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
\ No newline at end of file
+
diff --git a/assets/xml/textures/parameter_static.xml b/assets/xml/textures/parameter_static.xml
new file mode 100644
index 0000000000..f35b52269f
--- /dev/null
+++ b/assets/xml/textures/parameter_static.xml
@@ -0,0 +1,60 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/data/overlays/actors/z_boss_fd.data.s b/data/overlays/actors/z_boss_fd.data.s
index e74177bc7b..324d2ed52b 100644
--- a/data/overlays/actors/z_boss_fd.data.s
+++ b/data/overlays/actors/z_boss_fd.data.s
@@ -63,7 +63,7 @@ glabel D_808D1A84
glabel D_808D1A90
.word 0xFF8000FF, 0x0000FFFF, 0x00FF0000
glabel D_808D1A9C
- .word 0x04051DB0, 0x04051DB0, 0x040521B0, 0x040525B0, 0x040529B0, 0x04052DB0, 0x040531B0, 0x040535B0, 0x040539B0
+ .word gDust1Tex, gDust1Tex, gDust2Tex, gDust3Tex, gDust4Tex, gDust5Tex, gDust6Tex, gDust7Tex, gDust8Tex
glabel D_808D1AC0
.byte 0x00, 0x00
glabel D_808D1AC2
diff --git a/data/overlays/actors/z_door_killer.data.s b/data/overlays/actors/z_door_killer.data.s
index 35e4ce8d5d..a4b748efa2 100644
--- a/data/overlays/actors/z_door_killer.data.s
+++ b/data/overlays/actors/z_door_killer.data.s
@@ -25,7 +25,7 @@ glabel D_80996000
glabel D_80996010
.word 0x002C0000
glabel D_80996014
- .word 0x0600E5A0, 0x00590000, 0x060035C0, 0x01870000, 0x06000000, 0x00010000, 0x0400EF38
+ .word 0x0600E5A0, 0x00590000, 0x060035C0, 0x01870000, 0x06000000, 0x00010000, gWoodenDoorTex
glabel D_80996030
.word 0x00000000, 0x00000000, 0x00000000
glabel D_8099603C
diff --git a/data/overlays/actors/z_en_anubice_fire.data.s b/data/overlays/actors/z_en_anubice_fire.data.s
index 7f462903bc..bd32605705 100644
--- a/data/overlays/actors/z_en_anubice_fire.data.s
+++ b/data/overlays/actors/z_en_anubice_fire.data.s
@@ -40,5 +40,5 @@ glabel D_809B3268
glabel D_809B326C
.word 0xFF0000FF
glabel D_809B3270
- .word 0x040529B0, 0x04052DB0, 0x040531B0, 0x040535B0, 0x040539B0, 0x040535B0, 0x040531B0, 0x04052DB0
+ .word gDust4Tex, gDust5Tex, gDust6Tex, gDust7Tex, gDust8Tex, gDust7Tex, gDust6Tex, gDust5Tex
diff --git a/data/overlays/actors/z_en_go.data.s b/data/overlays/actors/z_en_go.data.s
index c228d57452..b4c4d85576 100644
--- a/data/overlays/actors/z_en_go.data.s
+++ b/data/overlays/actors/z_en_go.data.s
@@ -38,5 +38,5 @@ glabel D_80A41BC0
glabel D_80A41BCC
.word 0x44160000, 0x00000000, 0x00000000
glabel D_80A41BD8
- .word 0x040539B0, 0x040535B0, 0x040531B0, 0x04052DB0, 0x040529B0, 0x040525B0, 0x040521B0, 0x04051DB0, 0x00000000, 0x00000000
+ .word gDust8Tex, gDust7Tex, gDust6Tex, gDust5Tex, gDust4Tex, gDust3Tex, gDust2Tex, gDust1Tex, 0x00000000, 0x00000000
diff --git a/data/overlays/actors/z_en_go2.data.s b/data/overlays/actors/z_en_go2.data.s
index d9c22e6e89..d4e8e31557 100644
--- a/data/overlays/actors/z_en_go2.data.s
+++ b/data/overlays/actors/z_en_go2.data.s
@@ -10,7 +10,7 @@
.balign 16
glabel D_80A480D0
- .word 0x040539B0, 0x040535B0, 0x040531B0, 0x04052DB0, 0x040529B0, 0x040525B0, 0x040521B0, 0x04051DB0
+ .word gDust8Tex, gDust7Tex, gDust6Tex, gDust5Tex, gDust4Tex, gDust3Tex, gDust2Tex, gDust1Tex
glabel D_80A480F0
.word 0x00000000, 0x00000000, 0x00000000
glabel D_80A480FC
diff --git a/data/overlays/actors/z_obj_bean.data.s b/data/overlays/actors/z_obj_bean.data.s
index 7b76afa386..ec87ba8057 100644
--- a/data/overlays/actors/z_obj_bean.data.s
+++ b/data/overlays/actors/z_obj_bean.data.s
@@ -22,7 +22,7 @@ glabel D_80B90E54
glabel D_80B90E80
.word 0x40400000, 0x3E99999A, 0x41200000, 0x3F000000, 0x41F00000, 0x3F000000, 0x40400000, 0x3E99999A
glabel D_80B90EA0
- .word 0x040355E0, 0x040356A0
+ .word gCuttableShrubStalkDL, gCuttableShrubTipDL
glabel D_80B90EA8
.word 0xC8500064, 0xB0F407D0, 0xB0F800C8, 0x30FC0640, 0x00000000, 0x00000000
diff --git a/data/overlays/actors/z_object_kankyo.data.s b/data/overlays/actors/z_object_kankyo.data.s
index 5c1f0e417c..734bb97b56 100644
--- a/data/overlays/actors/z_object_kankyo.data.s
+++ b/data/overlays/actors/z_object_kankyo.data.s
@@ -10,7 +10,7 @@
.balign 16
glabel D_80BA58E0
- .word 0x04029F30, 0x0402A530, 0x0402AB30, 0x0402B130, 0x0402B730, 0x0402BD30, 0x0402C330, 0x0402C930
+ .word gEffLightning1Tex, gEffLightning2Tex, gEffLightning3Tex, gEffLightning4Tex, gEffLightning5Tex, gEffLightning6Tex, gEffLightning7Tex, gEffLightning8Tex
glabel D_80BA5900
.word 0x060015E0, 0x060025E0, 0x060035E0, 0x060045E0, 0x060055E0, 0x060065E0, 0x060075E0, 0x060085E0
glabel Object_Kankyo_InitVars
diff --git a/include/variables.h b/include/variables.h
index a94250a1fe..122408062b 100644
--- a/include/variables.h
+++ b/include/variables.h
@@ -27,36 +27,6 @@ extern u8 D_02003AC0[];
extern u32 D_0201DA50;
extern u32 D_0300AA48;
extern u32 D_03012B20;
-extern Vec3s D_04002040[];
-extern Vec3s D_040020D0[];
-extern Vec3s D_04002160[];
-extern Vec3s D_040021F0[];
-extern Vec3s D_04002280[];
-extern LinkAnimationHeader D_04003238;
-extern u32 D_04004298;
-extern u8 D_04006020[];
-extern Gfx D_0400C820[];
-extern u32 D_0400CB70;
-extern Gfx D_04015720[];
-extern Gfx D_04015760[];
-//extern ? D_0401A0B0;
-extern u32 D_0401E370;
-extern Gfx D_04021770[];
-//extern ? D_0402CF30;
-extern Gfx D_04037730[];
-//extern ? D_04038F00;
-extern u8 D_04038FB0[];
-extern u32 D_0403B030;
-extern u32 D_0403BBA0;
-extern u32 D_0403BCD8;
-extern Gfx D_0403F070[];
-extern Gfx D_04042440[];
-//extern ? D_04048160;
-extern u32 D_04048180;
-extern Gfx D_04049210[];
-extern Gfx D_04049AD0[];
-//extern ? D_0404D1C0;
-extern Gfx D_0404D450[];
//extern ? D_0500CA70;
extern Gfx D_06006CC0[];
extern Gfx D_06016118[];
diff --git a/spec b/spec
index e3e8242be9..6889fd1cd5 100644
--- a/spec
+++ b/spec
@@ -140,6 +140,7 @@ beginseg
name "icon_item_static"
romalign 0x1000
include "build/assets/textures/icon_item_static/icon_item_static.o"
+ number 8
endseg
beginseg
@@ -169,7 +170,7 @@ endseg
beginseg
name "icon_item_nes_static"
romalign 0x1000
- include "build/baserom/icon_item_nes_static.o" //include "build/assets/textures/icon_item_nes_static/icon_item_nes_static.o"
+ include "build/baserom/icon_item_nes_static.o"
endseg
beginseg
@@ -6181,7 +6182,8 @@ endseg
beginseg
name "parameter_static"
romalign 0x1000
- include "build/baserom/parameter_static.o"
+ include "build/assets/textures/parameter_static/parameter_static.o"
+ number 2
endseg
beginseg
diff --git a/src/code/z_actor.c b/src/code/z_actor.c
index a009939877..c4661629a3 100644
--- a/src/code/z_actor.c
+++ b/src/code/z_actor.c
@@ -41,7 +41,7 @@ void ActorShadow_Draw(Actor* actor, Lights* lights, GlobalContext* globalCtx, Gf
func_80038A28(actor->floorPoly, actor->world.pos.x, actor->floorHeight, actor->world.pos.z, &sp60);
Matrix_Put(&sp60);
- if (dlist != D_04049210) {
+ if (dlist != gCircleShadowDL) {
Matrix_RotateY(actor->shape.rot.y * (M_PI / 32768), MTXMODE_APPLY);
}
@@ -58,17 +58,17 @@ void ActorShadow_Draw(Actor* actor, Lights* lights, GlobalContext* globalCtx, Gf
}
void ActorShadow_DrawCircle(Actor* actor, Lights* lights, GlobalContext* globalCtx) {
- ActorShadow_Draw(actor, lights, globalCtx, D_04049210, NULL);
+ ActorShadow_Draw(actor, lights, globalCtx, gCircleShadowDL, NULL);
}
void ActorShadow_DrawWhiteCircle(Actor* actor, Lights* lights, GlobalContext* globalCtx) {
static Color_RGBA8 white = { 255, 255, 255, 255 };
- ActorShadow_Draw(actor, lights, globalCtx, D_04049210, &white);
+ ActorShadow_Draw(actor, lights, globalCtx, gCircleShadowDL, &white);
}
void ActorShadow_DrawHorse(Actor* actor, Lights* lights, GlobalContext* globalCtx) {
- ActorShadow_Draw(actor, lights, globalCtx, D_04049AD0, NULL);
+ ActorShadow_Draw(actor, lights, globalCtx, gHorseShadowDL, NULL);
}
void ActorShadow_DrawFoot(GlobalContext* globalCtx, Light* light, MtxF* arg2, s32 arg3, f32 arg4, f32 arg5, f32 arg6) {
@@ -90,7 +90,7 @@ void ActorShadow_DrawFoot(GlobalContext* globalCtx, Light* light, MtxF* arg2, s3
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 1687),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_OPA_DISP++, &D_04048180);
+ gSPDisplayList(POLY_OPA_DISP++, gFootShadowDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 1693);
}
@@ -386,7 +386,7 @@ void func_8002C124(TargetContext* targetCtx, GlobalContext* globalCtx) {
Matrix_Translate(entry->unk_0C, entry->unk_0C, 0.0f, MTXMODE_APPLY);
gSPMatrix(OVERLAY_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 2116),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(OVERLAY_DISP++, D_0404D450);
+ gSPDisplayList(OVERLAY_DISP++, gZTargetLockOnTriangleDL);
Matrix_Pull();
}
}
@@ -413,7 +413,7 @@ void func_8002C124(TargetContext* targetCtx, GlobalContext* globalCtx) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, naviColor->inner.r, naviColor->inner.g, naviColor->inner.b, 255);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 2153),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &D_0400CB70);
+ gSPDisplayList(POLY_XLU_DISP++, &gZTargetArrowDL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 2158);
@@ -1919,7 +1919,7 @@ void func_8002FBAC(GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 5458),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &gGameKeepMoteDL0);
+ gSPDisplayList(POLY_XLU_DISP++, &gEffFlash1DL);
Matrix_Pull();
phi_f6 = ~((globalCtx->gameplayFrames * 1200) & 0xFFFF);
@@ -1927,7 +1927,7 @@ void func_8002FBAC(GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 5463),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &gGameKeepMoteDL0);
+ gSPDisplayList(POLY_XLU_DISP++, &gEffFlash1DL);
}
lightPos.x = gSaveContext.respawn[RESPAWN_MODE_TOP].pos.x;
@@ -2245,8 +2245,8 @@ void func_80030ED8(Actor* actor) {
void func_80030FA8(GraphicsContext* gfxCtx) {
OPEN_DISPS(gfxCtx, "../z_actor.c", 6161);
- gDPLoadTextureBlock(POLY_XLU_DISP++, &D_0401E370, G_IM_FMT_I, G_IM_SIZ_8b, 64, 64, 0, G_TX_MIRROR | G_TX_CLAMP,
- G_TX_MIRROR | G_TX_CLAMP, 6, 6, G_TX_NOLOD, G_TX_NOLOD);
+ gDPLoadTextureBlock(POLY_XLU_DISP++, gUnknownCircle5Tex, G_IM_FMT_I, G_IM_SIZ_8b, 64, 64, 0,
+ G_TX_MIRROR | G_TX_CLAMP, G_TX_MIRROR | G_TX_CLAMP, 6, 6, G_TX_NOLOD, G_TX_NOLOD);
gDPSetTileSize(POLY_XLU_DISP++, G_TX_RENDERTILE, 384, 224, 892, 732);
gSPTextureRectangle(POLY_XLU_DISP++, 0, 0, 1280, 960, G_TX_RENDERTILE, 2240, 1600, 576, 597);
@@ -3457,7 +3457,7 @@ void func_80033C30(Vec3f* arg0, Vec3f* arg1, u8 alpha, GlobalContext* globalCtx)
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_actor.c", 8149),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_OPA_DISP++, &D_04049210);
+ gSPDisplayList(POLY_OPA_DISP++, &gCircleShadowDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_actor.c", 8155);
}
diff --git a/src/code/z_debug_display.c b/src/code/z_debug_display.c
index e802e9b8e3..2f560f2b56 100644
--- a/src/code/z_debug_display.c
+++ b/src/code/z_debug_display.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
typedef struct {
/* 0x00 */ s16 drawType; // indicates which draw function to use when displaying the object
@@ -16,12 +17,8 @@ static DebugDispObject_DrawFunc sDebugObjectDrawFuncTable[] = {
};
static DebugDispObjectInfo sDebugObjectInfoTable[] = {
- { 0, 0x040035F0 }, // Circle
- { 0, 0x040038F0 }, // Cross
- { 0, 0x040036F0 }, // Ball
- { 0, 0x040037F0 }, // Cursor
- { 1, 0x040039F0 }, // Arrow
- { 1, 0x04003C90 }, // Camera
+ { 0, gDebugCircleTex }, { 0, gDebugCrossTex }, { 0, gDebugBallTex },
+ { 0, gDebugCursorTex }, { 1, gDebugArrowDL }, { 1, gDebugCameraDL },
};
static Lights1 sDebugObjectLights = gdSPDefLights1(0x80, 0x80, 0x80, 0xFF, 0xFF, 0xFF, 0x49, 0x49, 0x49);
@@ -86,7 +83,7 @@ void DebugDisplay_DrawSpriteI8(DebugDispObject* dispObj, u32 texture, GlobalCont
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_debug_display.c", 189),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &D_04004298);
+ gSPDisplayList(POLY_XLU_DISP++, &gDebugSpriteDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_debug_display.c", 192);
}
diff --git a/src/code/z_eff_blure.c b/src/code/z_eff_blure.c
index bc3d3465b3..4bd7603c29 100644
--- a/src/code/z_eff_blure.c
+++ b/src/code/z_eff_blure.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
void EffectBlure_AddVertex(EffectBlure* this, Vec3f* p1, Vec3f* p2) {
EffectBlureElement* elem;
@@ -755,8 +756,8 @@ void EffectBlure_SetupSimpleAlt(GraphicsContext* gfxCtx, EffectBlure* this, Vtx*
gDPSetTextureLUT(POLY_XLU_DISP++, G_TT_NONE);
gSPTexture(POLY_XLU_DISP++, 0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON);
- gDPLoadTextureBlock(POLY_XLU_DISP++, D_04006020, G_IM_FMT_I, G_IM_SIZ_8b, 64, 32, 0, G_TX_NOMIRROR | G_TX_CLAMP,
- G_TX_NOMIRROR | G_TX_WRAP, 6, 5, G_TX_NOLOD, G_TX_NOLOD);
+ gDPLoadTextureBlock(POLY_XLU_DISP++, gUnknownEffBlureTex, G_IM_FMT_I, G_IM_SIZ_8b, 64, 32, 0,
+ G_TX_NOMIRROR | G_TX_CLAMP, G_TX_NOMIRROR | G_TX_WRAP, 6, 5, G_TX_NOLOD, G_TX_NOLOD);
gDPSetCombineLERP(POLY_XLU_DISP++, TEXEL0, PRIMITIVE, PRIM_LOD_FRAC, TEXEL0, TEXEL0, 0, PRIMITIVE, 0, PRIMITIVE,
ENVIRONMENT, COMBINED, ENVIRONMENT, 0, 0, 0, COMBINED);
diff --git a/src/code/z_eff_shield_particle.c b/src/code/z_eff_shield_particle.c
index 852eaeefec..7122f5d03b 100644
--- a/src/code/z_eff_shield_particle.c
+++ b/src/code/z_eff_shield_particle.c
@@ -1,5 +1,6 @@
#include "global.h"
#include "vt.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
static Vtx sVertices[5] = {
VTX(-32, -32, 0, 0, 1024, 0xFF, 0xFF, 0xFF, 0xFF),
@@ -163,8 +164,8 @@ void EffectShieldParticle_Draw(void* thisx, GraphicsContext* gfxCtx) {
gDPPipeSync(POLY_XLU_DISP++);
gSPTexture(POLY_XLU_DISP++, 0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON);
- gDPLoadTextureBlock(POLY_XLU_DISP++, D_04038FB0, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_WRAP,
- G_TX_NOMIRROR | G_TX_WRAP, 5, 5, G_TX_NOLOD, G_TX_NOLOD);
+ gDPLoadTextureBlock(POLY_XLU_DISP++, gUnknownCircle6Tex, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0,
+ G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, 5, 5, G_TX_NOLOD, G_TX_NOLOD);
if (1) {} // Necessary to match
diff --git a/src/code/z_eff_spark.c b/src/code/z_eff_spark.c
index c310d4a3bd..78c74b9a2b 100644
--- a/src/code/z_eff_spark.c
+++ b/src/code/z_eff_spark.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
// original name: "spark"
void EffectSpark_Init(void* thisx, void* initParamsx) {
@@ -166,8 +167,8 @@ void EffectSpark_Draw(void* thisx, GraphicsContext* gfxCtx) {
gDPPipeSync(POLY_XLU_DISP++);
gSPTexture(POLY_XLU_DISP++, 0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON);
- gDPLoadTextureBlock(POLY_XLU_DISP++, D_04038FB0, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_WRAP,
- G_TX_NOMIRROR | G_TX_WRAP, 5, 5, G_TX_NOLOD, G_TX_NOLOD);
+ gDPLoadTextureBlock(POLY_XLU_DISP++, gUnknownCircle6Tex, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0,
+ G_TX_NOMIRROR | G_TX_WRAP, G_TX_NOMIRROR | G_TX_WRAP, 5, 5, G_TX_NOLOD, G_TX_NOLOD);
gDPSetCombineMode(POLY_XLU_DISP++, G_CC_SHADEDECALA, G_CC_PASS2);
gDPSetRenderMode(POLY_XLU_DISP++, G_RM_PASS, G_RM_ZB_CLD_SURF2);
diff --git a/src/code/z_en_a_keep.c b/src/code/z_en_a_keep.c
index 7f65ff5eb7..69d696ad3c 100644
--- a/src/code/z_en_a_keep.c
+++ b/src/code/z_en_a_keep.c
@@ -1,5 +1,6 @@
#include "global.h"
#include "vt.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -53,19 +54,25 @@ static ColliderCylinderInit sCylinderInit = {
{ 25, 60, 0, { 0, 0, 0 } },
};
-extern CollisionHeader D_040394B0;
-extern CollisionHeader D_0403A120;
-extern CollisionHeader D_0403A480;
-extern CollisionHeader D_0403A7F0;
extern CollisionHeader D_06000730;
static CollisionHeader* D_8011546C[] = {
- &D_040394B0, &D_040394B0, &D_0403A120, &D_0403A480, &D_0403A7F0, &D_06000730,
+ &gUnknown1Col, &gUnknown1Col, &gUnknown4Col, &gUnknown5Col, &gUnknown6Col, &D_06000730,
};
static Gfx* D_80115484[] = {
- 0x04039C00, 0x04039C00, 0x04039C00, 0x0403A2D0, 0x0403A2D0, 0x0403A630,
- 0x06000210, 0x0403AB80, 0x0403A9B0, 0x0403C050, 0x0403C5B0, 0x0400D340,
+ gUnusedRockRectangularPrism2DL,
+ gUnusedRockRectangularPrism2DL,
+ gUnusedRockRectangularPrism2DL,
+ gUnusedRockRectangularPrism4DL,
+ gUnusedRockRectangularPrism4DL,
+ gUnusedRockRectangularPrism5DL,
+ 0x06000210,
+ gUnusedGrassBladesDL,
+ gUnusedTreeStumpDL,
+ gSignRectangularDL,
+ gSignDirectionalDL,
+ gBoulderFragmentsDL,
};
void EnAObj_SetupAction(EnAObj* this, EnAObjActionFunc actionFunc) {
diff --git a/src/code/z_en_item00.c b/src/code/z_en_item00.c
index 4058748f83..5a436b0636 100644
--- a/src/code/z_en_item00.c
+++ b/src/code/z_en_item00.c
@@ -1,6 +1,7 @@
#include "global.h"
#include "overlays/actors/ovl_En_Elf/z_en_elf.h"
#include "overlays/effects/ovl_Effect_Ss_Dead_Sound/z_eff_ss_dead_sound.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -753,7 +754,7 @@ void func_8001EF30(EnItem00* this, GlobalContext* globalCtx) {
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80115530[iconNb]));
- gSPDisplayList(POLY_OPA_DISP++, &D_04042440);
+ gSPDisplayList(POLY_OPA_DISP++, &gRupeeDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_item00.c", 1568);
}
@@ -782,7 +783,7 @@ void func_8001F080(EnItem00* this, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_item00.c", 1607),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_OPA_DISP++, D_0403F070);
+ gSPDisplayList(POLY_OPA_DISP++, gItemDropDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_item00.c", 1611);
}
@@ -799,13 +800,13 @@ void func_8001F1F4(EnItem00* this, GlobalContext* globalCtx) {
func_8002EBCC(&this->actor, globalCtx, 0);
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_item00.c", 1634),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_OPA_DISP++, &D_0403BBA0);
+ gSPDisplayList(POLY_OPA_DISP++, &gHeartPieceExteriorDL);
func_80093D84(globalCtx->state.gfxCtx);
func_8002ED80(&this->actor, globalCtx, 0);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_item00.c", 1644),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &D_0403BCD8);
+ gSPDisplayList(POLY_XLU_DISP++, &gHeartContainerInteriorDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_item00.c", 1647);
}
@@ -822,7 +823,7 @@ void func_8001F334(EnItem00* this, GlobalContext* globalCtx) {
func_8002ED80(&this->actor, globalCtx, 0);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_item00.c", 1670),
G_MTX_MODELVIEW | G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &D_0403B030);
+ gSPDisplayList(POLY_XLU_DISP++, &gHeartPieceInteriorDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_item00.c", 1673);
}
diff --git a/src/code/z_lifemeter.c b/src/code/z_lifemeter.c
index b85cf87b5c..08f161c51e 100644
--- a/src/code/z_lifemeter.c
+++ b/src/code/z_lifemeter.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "textures/parameter_static/parameter_static.h"
/*
* These are the colors for the hearts in the interface. The prim color is the red color of the heart
@@ -256,15 +257,23 @@ s32 func_80078E84(GlobalContext* globalCtx) {
return 0;
}
+u64* sHeartTextures[] = {
+ gHUDHeartFullTex, gHUDHeartQuarterTex, gHUDHeartQuarterTex, gHUDHeartQuarterTex,
+ gHUDHeartQuarterTex, gHUDHeartQuarterTex, gHUDHeartHalfTex, gHUDHeartHalfTex,
+ gHUDHeartHalfTex, gHUDHeartHalfTex, gHUDHeartHalfTex, gHUDHeartThreeQuarterTex,
+ gHUDHeartThreeQuarterTex, gHUDHeartThreeQuarterTex, gHUDHeartThreeQuarterTex, gHUDHeartThreeQuarterTex,
+};
+
+u64* sDDHeartTextures[] = {
+ gHUDDefenseHeartFullTex, gHUDDefenseHeartQuarterTex, gHUDDefenseHeartQuarterTex,
+ gHUDDefenseHeartQuarterTex, gHUDDefenseHeartQuarterTex, gHUDDefenseHeartQuarterTex,
+ gHUDDefenseHeartHalfTex, gHUDDefenseHeartHalfTex, gHUDDefenseHeartHalfTex,
+ gHUDDefenseHeartHalfTex, gHUDDefenseHeartHalfTex, gHUDDefenseHeartThreeQuarterTex,
+ gHUDDefenseHeartThreeQuarterTex, gHUDDefenseHeartThreeQuarterTex, gHUDDefenseHeartThreeQuarterTex,
+ gHUDDefenseHeartThreeQuarterTex,
+};
+
void HealthMeter_Draw(GlobalContext* globalCtx) {
- static UNK_PTR sHeartTextures[] = {
- 0x02000400, 0x02000100, 0x02000100, 0x02000100, 0x02000100, 0x02000100, 0x02000200, 0x02000200,
- 0x02000200, 0x02000200, 0x02000200, 0x02000300, 0x02000300, 0x02000300, 0x02000300, 0x02000300,
- };
- static UNK_PTR sDDHeartTextures[] = {
- 0x02000900, 0x02000600, 0x02000600, 0x02000600, 0x02000600, 0x02000600, 0x02000700, 0x02000700,
- 0x02000700, 0x02000700, 0x02000700, 0x02000800, 0x02000800, 0x02000800, 0x02000800, 0x02000800,
- };
s32 pad[5];
UNK_PTR heartBgImg;
u32 curColorSet;
diff --git a/src/code/z_lights.c b/src/code/z_lights.c
index b140d8d579..8ea2955240 100644
--- a/src/code/z_lights.c
+++ b/src/code/z_lights.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define LIGHTS_BUFFER_SIZE 32
@@ -366,7 +367,7 @@ void Lights_DrawGlow(GlobalContext* globalCtx) {
POLY_XLU_DISP = func_800947AC(POLY_XLU_DISP++);
gDPSetAlphaDither(POLY_XLU_DISP++, G_AD_NOISE);
gDPSetColorDither(POLY_XLU_DISP++, G_CD_MAGICSQ);
- gSPDisplayList(POLY_XLU_DISP++, D_04015720);
+ gSPDisplayList(POLY_XLU_DISP++, gGlowCircleTextureLoadDL);
while (node != NULL) {
LightInfo* info;
@@ -385,7 +386,7 @@ void Lights_DrawGlow(GlobalContext* globalCtx) {
Matrix_Scale(scale, scale, scale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_lights.c", 918),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_04015760);
+ gSPDisplayList(POLY_XLU_DISP++, gGlowCircleDL);
}
node = node->next;
diff --git a/src/code/z_map_exp.c b/src/code/z_map_exp.c
index fab39d42b7..509c95145c 100644
--- a/src/code/z_map_exp.c
+++ b/src/code/z_map_exp.c
@@ -1,5 +1,6 @@
#include "global.h"
#include "vt.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
MapData* gMapData;
@@ -339,7 +340,7 @@ void Minimap_DrawCompassIcons(GlobalContext* globalCtx) {
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(OVERLAY_DISP++, 0, 0, 200, 255, 0, 255);
- gSPDisplayList(OVERLAY_DISP++, D_0400C820);
+ gSPDisplayList(OVERLAY_DISP++, gCompassArrowDL);
tempX = sPlayerInitialPosX;
tempZ = sPlayerInitialPosZ;
@@ -353,7 +354,7 @@ void Minimap_DrawCompassIcons(GlobalContext* globalCtx) {
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(OVERLAY_DISP++, 0, 0xFF, 200, 0, 0, 255);
- gSPDisplayList(OVERLAY_DISP++, D_0400C820);
+ gSPDisplayList(OVERLAY_DISP++, gCompassArrowDL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_map_exp.c", 607);
diff --git a/src/code/z_player_lib.c b/src/code/z_player_lib.c
index e4d9141ed1..b80f50251c 100644
--- a/src/code/z_player_lib.c
+++ b/src/code/z_player_lib.c
@@ -1,4 +1,5 @@
#include "global.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
typedef struct {
/* 0x00 */ u8 flag;
@@ -1365,7 +1366,7 @@ u32 func_80091738(GlobalContext* globalCtx, u8* segment, SkelAnime* skelAnime) {
gSegments[4] = VIRTUAL_TO_PHYSICAL(segment + 0x3800);
gSegments[6] = VIRTUAL_TO_PHYSICAL(segment + 0x8800);
- SkelAnime_InitLink(globalCtx, skelAnime, gPlayerSkelHeaders[(void)0, gSaveContext.linkAge], &D_04003238, 9, ptr,
+ SkelAnime_InitLink(globalCtx, skelAnime, gPlayerSkelHeaders[(void)0, gSaveContext.linkAge], &gPlayer488Anim, 9, ptr,
ptr, PLAYER_LIMB_MAX);
return size + 0x8890;
diff --git a/src/code/z_skin_matrix.c b/src/code/z_skin_matrix.c
index 1392b1fb06..28ddca1a40 100644
--- a/src/code/z_skin_matrix.c
+++ b/src/code/z_skin_matrix.c
@@ -96,7 +96,7 @@ void SkinMatrix_MtxFMtxFMult(MtxF* mfB, MtxF* mfA, MtxF* dest) {
rw = mfA->ww;
dest->wx = (cx * rx) + (cy * ry) + (cz * rz) + (cw * rw);
- //---COL2---
+ //---2Col---
cx = mfB->xy;
cy = mfB->yy;
cz = mfB->zy;
@@ -126,7 +126,7 @@ void SkinMatrix_MtxFMtxFMult(MtxF* mfB, MtxF* mfA, MtxF* dest) {
rw = mfA->ww;
dest->wy = (cx * rx) + (cy * ry) + (cz * rz) + (cw * rw);
- //---COL3---
+ //---3Col---
cx = mfB->xz;
cy = mfB->yz;
cz = mfB->zz;
@@ -156,7 +156,7 @@ void SkinMatrix_MtxFMtxFMult(MtxF* mfB, MtxF* mfA, MtxF* dest) {
rw = mfA->ww;
dest->wz = (cx * rx) + (cy * ry) + (cz * rz) + (cw * rw);
- //---COL4---
+ //---4Col---
cx = mfB->xw;
cy = mfB->yw;
cz = mfB->zw;
diff --git a/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c b/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c
index 08e6faf3fa..dc2208ceed 100644
--- a/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c
+++ b/src/overlays/actors/ovl_Bg_Haka_Gate/z_bg_haka_gate.c
@@ -5,6 +5,7 @@
*/
#include "z_bg_haka_gate.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -46,7 +47,6 @@ void BgHakaGate_GateOpen(BgHakaGate* this, GlobalContext* globalCtx);
void BgHakaGate_SkullOfTruth(BgHakaGate* this, GlobalContext* globalCtx);
void BgHakaGate_FalseSkull(BgHakaGate* this, GlobalContext* globalCtx);
-extern Gfx D_0404D4E0[];
extern CollisionHeader D_0600A938;
extern Gfx D_0600F1B0[];
extern Gfx D_06010A10[];
@@ -338,7 +338,7 @@ void BgHakaGate_DrawFlame(BgHakaGate* this, GlobalContext* globalCtx) {
Matrix_Scale(scale, scale, scale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_haka_gate.c", 744),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_haka_gate.c", 749);
}
}
diff --git a/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c b/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c
index 7dcd20b125..bb4b607e0f 100644
--- a/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c
+++ b/src/overlays/actors/ovl_Bg_Haka_Tubo/z_bg_haka_tubo.c
@@ -5,6 +5,7 @@
*/
#include "z_bg_haka_tubo.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -78,8 +79,6 @@ static InitChainEntry sInitChain[] = {
extern CollisionHeader D_060108B8;
extern Gfx D_0600FE40[];
-extern Gfx D_0400CD80[];
-extern Gfx D_040184B0[];
void BgHakaTubo_Init(Actor* thisx, GlobalContext* globalCtx) {
BgHakaTubo* this = THIS;
@@ -133,7 +132,8 @@ void BgHakaTubo_Idle(BgHakaTubo* this, GlobalContext* globalCtx) {
pos.y = this->dyna.actor.world.pos.y + 80.0f;
EffectSsBomb2_SpawnLayered(globalCtx, &pos, &sZeroVector, &sZeroVector, 100, 45);
Audio_PlaySoundAtPosition(globalCtx, &this->dyna.actor.world.pos, 50, NA_SE_EV_BOX_BREAK);
- EffectSsHahen_SpawnBurst(globalCtx, &pos, 20.0f, 0, 350, 100, 50, OBJECT_HAKA_OBJECTS, 40, D_0400CD80);
+ EffectSsHahen_SpawnBurst(globalCtx, &pos, 20.0f, 0, 350, 100, 50, OBJECT_HAKA_OBJECTS, 40,
+ gEffFragments2DL);
this->dropTimer = 5;
this->dyna.actor.draw = NULL;
Actor_SetScale(&this->dyna.actor, 0.0f);
@@ -240,7 +240,7 @@ void BgHakaTubo_DrawFlameCircle(BgHakaTubo* this, GlobalContext* globalCtx) {
(this->fireScroll * -15) & 0xFF, 32, 64));
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_haka_tubo.c", 497),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_040184B0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFireCircleDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_haka_tubo.c", 501);
}
diff --git a/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c b/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c
index 5713f37bfc..cf9550fd06 100644
--- a/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c
+++ b/src/overlays/actors/ovl_Bg_Hidan_Curtain/z_bg_hidan_curtain.c
@@ -5,6 +5,7 @@
*/
#include "z_bg_hidan_curtain.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -22,8 +23,6 @@ void BgHidanCurtain_TurnOn(BgHidanCurtain* this, GlobalContext* globalCtx);
void BgHidanCurtain_TurnOff(BgHidanCurtain* this, GlobalContext* globalCtx);
void BgHidanCurtain_WaitForTimer(BgHidanCurtain* this, GlobalContext* globalCtx);
-extern Gfx D_040184B0[];
-
typedef struct {
/* 0x00 */ s16 radius;
/* 0x02 */ s16 height;
@@ -257,7 +256,7 @@ void BgHidanCurtain_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_hidan_curtain.c", 698),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_040184B0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFireCircleDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_hidan_curtain.c", 702);
}
diff --git a/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c b/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c
index 1bac23a64e..65e53b04f9 100644
--- a/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c
+++ b/src/overlays/actors/ovl_Bg_Hidan_Fwbig/z_bg_hidan_fwbig.c
@@ -1,4 +1,5 @@
#include "z_bg_hidan_fwbig.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -25,8 +26,6 @@ void BgHidanFwbig_WaitForPlayer(BgHidanFwbig* this, GlobalContext* globalCtx);
void BgHidanFwbig_Move(BgHidanFwbig* this, GlobalContext* globalCtx);
extern Gfx D_0600DB20[];
-extern Gfx D_040173D0[];
-extern Gfx D_04017BD0[];
const ActorInit Bg_Hidan_Fwbig_InitVars = {
ACTOR_BG_HIDAN_FWBIG,
@@ -250,9 +249,9 @@ void BgHidanFwbig_Draw(Actor* thisx, GlobalContext* globalCtx) {
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_bg_hidan_fwbig.c", 630);
func_80093D84(globalCtx->state.gfxCtx);
- gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(D_040173D0));
+ gSPSegment(POLY_XLU_DISP++, 0x09, SEGMENTED_TO_VIRTUAL(gEffUnknown4Tex));
- gSPSegment(POLY_XLU_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(D_04017BD0));
+ gSPSegment(POLY_XLU_DISP++, 0x0A, SEGMENTED_TO_VIRTUAL(gEffUnknown5Tex));
height = thisx->scale.y * 2400.0f;
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 220, 0,
diff --git a/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c b/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c
index 78ff4335a7..95affff466 100644
--- a/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c
+++ b/src/overlays/actors/ovl_Bg_Mori_Hineri/z_bg_mori_hineri.c
@@ -5,6 +5,7 @@
*/
#include "z_bg_mori_hineri.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -51,7 +52,6 @@ extern CollisionHeader D_060054B8;
extern CollisionHeader D_06003490;
extern CollisionHeader D_060043D0;
extern CollisionHeader D_06006078;
-extern Gfx D_04049FE0[]; // display list for studded dungeon door
extern Gfx D_06000AE8[];
extern Gfx D_06001678[];
@@ -252,7 +252,7 @@ void BgMoriHineri_DrawHallAndRoom(Actor* thisx, GlobalContext* globalCtx) {
Matrix_Translate(0.0f, -50.0f, 0.0f, MTXMODE_APPLY);
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_mori_hineri.c", 652),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_OPA_DISP++, D_04049FE0);
+ gSPDisplayList(POLY_OPA_DISP++, gDoorMetalBarsDL);
}
if ((this->boxObjIdx > 0) && ((this->boxObjIdx = Object_GetIndex(&globalCtx->objectCtx, OBJECT_BOX)) > 0) &&
(Object_IsLoaded(&globalCtx->objectCtx, this->boxObjIdx))) {
diff --git a/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c b/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c
index 52c4b8f279..d68723068c 100644
--- a/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c
+++ b/src/overlays/actors/ovl_Bg_Po_Syokudai/z_bg_po_syokudai.c
@@ -5,6 +5,7 @@
*/
#include "z_bg_po_syokudai.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -75,7 +76,6 @@ static InitChainEntry sInitChain[] = {
};
extern Gfx D_060003A0[];
-extern Gfx D_0404D4E0[];
void BgPoSyokudai_Init(Actor* thisx, GlobalContext* globalCtx) {
BgPoSyokudai* this = THIS;
@@ -186,7 +186,7 @@ void BgPoSyokudai_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_po_syokudai.c", 368),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_po_syokudai.c", 373);
}
diff --git a/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c b/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c
index 3337507fd1..b9888508d7 100644
--- a/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c
+++ b/src/overlays/actors/ovl_Bg_Spot00_Hanebasi/z_bg_spot00_hanebasi.c
@@ -1,4 +1,5 @@
#include "z_bg_spot00_hanebasi.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -9,7 +10,6 @@ void BgSpot00Hanebasi_Destroy(Actor* thisx, GlobalContext* globalCtx);
void BgSpot00Hanebasi_Update(Actor* thisx, GlobalContext* globalCtx);
void BgSpot00Hanebasi_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_0404D4E0;
extern UNK_TYPE D_060000C0;
extern UNK_TYPE D_06000280;
extern UNK_TYPE D_06000430;
diff --git a/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c b/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c
index b63443cc53..fe426516b3 100644
--- a/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c
+++ b/src/overlays/actors/ovl_Bg_Spot09_Obj/z_bg_spot09_obj.c
@@ -32,7 +32,9 @@ const ActorInit Bg_Spot09_Obj_InitVars = {
(ActorFunc)BgSpot09Obj_Draw,
};
-static CollisionHeader* D_808B1F90[] = { NULL, gBgSpot09Col1, gBgSpot09Col2, gBgSpot09Col3, gBgSpot09Col4 };
+static CollisionHeader* D_808B1F90[] = {
+ NULL, &gValleyObjects1Col, &gValleyObjects2Col, &gValleyObjects3Col, &gValleyObjects4Col,
+};
static s32 (*D_808B1FA4[])(BgSpot09Obj* this, GlobalContext* globalCtx) = {
func_808B1BEC,
@@ -52,7 +54,9 @@ static InitChainEntry sInitChain2[] = {
ICHAIN_F32(uncullZoneDownward, 1500, ICHAIN_STOP),
};
-static Gfx* sDLists[] = { gBgSpot09DL1, gBgSpot09DL2, gBgSpot09DL3, gBgSpot09DL4, gBgSpot09DL5 };
+static Gfx* sDLists[] = {
+ gValleyBridgeSidesDL, gValleyBrokenBridgeDL, gValleyBridgeChildDL, gCarpentersTentDL, gValleyRepairedBridgeDL,
+};
s32 func_808B1AE0(BgSpot09Obj* this, GlobalContext* globalCtx) {
s32 carpentersRescued;
@@ -175,7 +179,7 @@ void BgSpot09Obj_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_spot09_obj.c", 391),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, gBgSpot09DL6);
+ gSPDisplayList(POLY_XLU_DISP++, gCarpentersTentEntranceDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_spot09_obj.c", 396);
}
diff --git a/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c b/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c
index 696a3bf0b3..35bb82a539 100644
--- a/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c
+++ b/src/overlays/actors/ovl_Bg_Spot11_Bakudankabe/z_bg_spot11_bakudankabe.c
@@ -121,7 +121,7 @@ void BgSpot11Bakudankabe_Init(Actor* thisx, GlobalContext* globalCtx) {
return;
}
func_808B2180(this, globalCtx);
- CollisionHeader_GetVirtual(&gBgSpot11Col, &colHeader);
+ CollisionHeader_GetVirtual(&gDesertColossusBombableWallCol, &colHeader);
this->dyna.bgId = DynaPoly_SetBgActor(globalCtx, &globalCtx->colCtx.dyna, &this->dyna.actor, colHeader);
Actor_SetScale(&this->dyna.actor, 1.0f);
osSyncPrintf("(spot11 爆弾壁)(arg_data 0x%04x)\n", this->dyna.actor.params);
@@ -151,5 +151,5 @@ void BgSpot11Bakudankabe_Update(Actor* thisx, GlobalContext* globalCtx) {
void BgSpot11Bakudankabe_Draw(Actor* thisx, GlobalContext* globalCtx) {
BgSpot11Bakudankabe* this = THIS;
- Gfx_DrawDListOpa(globalCtx, gBgSpot11DL1);
+ Gfx_DrawDListOpa(globalCtx, gDesertColossusBombableWallDL);
}
diff --git a/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c b/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c
index 2024014aed..cabec315d7 100644
--- a/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c
+++ b/src/overlays/actors/ovl_Bg_Spot11_Oasis/z_bg_spot11_oasis.c
@@ -1,5 +1,12 @@
+/*
+ * File: z_bg_spot11_oasis.c
+ * Overlay: ovl_Bg_Spot11_Oasis
+ * Description: Refilling Oasis (Desert Colossus)
+ */
+
#include "z_bg_spot11_oasis.h"
#include "overlays/actors/ovl_En_Elf/z_en_elf.h"
+#include "objects/object_spot11_obj/object_spot11_obj.h"
#define FLAGS 0x00000010
@@ -43,8 +50,6 @@ static Vec3f D_808B2E34[] = {
{ -75.0f, -90.0f, 90.0f }, { 30.0f, -100.0f, 40.0f },
};
-extern Gfx D_06000870[];
-
void func_808B27F0(GlobalContext* globalCtx, s16 waterSurface) {
WaterBox* waterBox = &globalCtx->colCtx.colHeader->waterBoxes[0];
@@ -154,6 +159,6 @@ void BgSpot11Oasis_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, 127 - (gameplayFrames % 128), (gameplayFrames * 1) % 128,
32, 32, 1, gameplayFrames % 128, (gameplayFrames * 1) % 128, 32, 32));
- gSPDisplayList(POLY_XLU_DISP++, D_06000870);
+ gSPDisplayList(POLY_XLU_DISP++, gDesertColossusOasisDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_spot11_oasis.c", 346);
}
diff --git a/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c b/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c
index e67a642ee6..c21fd4166e 100644
--- a/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c
+++ b/src/overlays/actors/ovl_Bg_Spot17_Bakudankabe/z_bg_spot17_bakudankabe.c
@@ -6,6 +6,7 @@
#include "z_bg_spot17_bakudankabe.h"
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
+#include "objects/object_spot17_obj/object_spot17_obj.h"
#define FLAGS 0x00000000
@@ -35,9 +36,6 @@ static InitChainEntry sInitChain[] = {
ICHAIN_F32(uncullZoneDownward, 1000, ICHAIN_STOP),
};
-extern CollisionHeader D_06000A38;
-extern Gfx D_060008A0[];
-extern Gfx D_06000960[];
extern Gfx D_0500A880[];
void func_808B6BC0(BgSpot17Bakudankabe* this, GlobalContext* globalCtx) {
@@ -105,7 +103,8 @@ void BgSpot17Bakudankabe_Init(Actor* thisx, GlobalContext* globalCtx) {
Actor_Kill(&this->dyna.actor);
return;
}
- CollisionHeader_GetVirtual(&D_06000A38, &colHeader);
+
+ CollisionHeader_GetVirtual(&gCraterBombableWallCol, &colHeader);
this->dyna.bgId = DynaPoly_SetBgActor(globalCtx, &globalCtx->colCtx.dyna, &this->dyna.actor, colHeader);
Actor_ProcessInitChain(&this->dyna.actor, sInitChain);
}
@@ -143,7 +142,7 @@ void BgSpot17Bakudankabe_Draw(Actor* thisx, GlobalContext* globalCtx) {
gDPSetEnvColor(POLY_OPA_DISP++, r, g, 255, 128);
- gSPDisplayList(POLY_OPA_DISP++, D_060008A0);
+ gSPDisplayList(POLY_OPA_DISP++, gCraterBombableWallDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_spot17_bakudankabe.c", 283);
@@ -153,7 +152,7 @@ void BgSpot17Bakudankabe_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_spot17_bakudankabe.c", 290),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_06000960);
+ gSPDisplayList(POLY_XLU_DISP++, gCraterBombableWallCracksDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_spot17_bakudankabe.c", 295);
}
diff --git a/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c b/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c
index 87e7de0e07..045cd7cd33 100644
--- a/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c
+++ b/src/overlays/actors/ovl_Bg_Spot17_Funen/z_bg_spot17_funen.c
@@ -67,7 +67,7 @@ void func_808B7478(Actor* thisx, GlobalContext* globalCtx) {
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, 0, (0 - globalCtx->gameplayFrames) & 0x7F, 0x20, 0x20, 1, 0,
(0 - globalCtx->gameplayFrames) & 0x7F, 0x20, 0x20));
- gSPDisplayList(POLY_XLU_DISP++, gBgSpot17DL1);
+ gSPDisplayList(POLY_XLU_DISP++, gCraterSmokeConeDL);
if (1) {}
diff --git a/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c b/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c
index 3c3e115a71..d57ea1bb59 100644
--- a/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c
+++ b/src/overlays/actors/ovl_Boss_Fd/z_boss_fd.c
@@ -1,4 +1,5 @@
#include "z_boss_fd.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000035
diff --git a/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c b/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c
index 0f29c3f27e..c41c92fe02 100644
--- a/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c
+++ b/src/overlays/actors/ovl_Boss_Tw/z_boss_tw.c
@@ -1,4 +1,5 @@
#include "z_boss_tw.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000035
diff --git a/src/overlays/actors/ovl_Boss_Va/z_boss_va.c b/src/overlays/actors/ovl_Boss_Va/z_boss_va.c
index 47acd0531d..67cc04c6e3 100644
--- a/src/overlays/actors/ovl_Boss_Va/z_boss_va.c
+++ b/src/overlays/actors/ovl_Boss_Va/z_boss_va.c
@@ -1,4 +1,5 @@
#include "z_boss_va.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000035
@@ -9,7 +10,6 @@ void BossVa_Destroy(Actor* thisx, GlobalContext* globalCtx);
void BossVa_Update(Actor* thisx, GlobalContext* globalCtx);
void BossVa_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_04055DB0;
extern UNK_TYPE D_06000024;
extern UNK_TYPE D_06000FA0;
extern UNK_TYPE D_06001230;
diff --git a/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c b/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c
index cb9a55e3ed..f32fdba94d 100644
--- a/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c
+++ b/src/overlays/actors/ovl_Demo_6K/z_demo_6k.c
@@ -1,4 +1,5 @@
#include "z_demo_6k.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -8,8 +9,6 @@ void Demo6K_Init(Actor* thisx, GlobalContext* globalCtx);
void Demo6K_Destroy(Actor* thisx, GlobalContext* globalCtx);
void Demo6K_Update(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_040101A8;
-extern UNK_TYPE D_04015780;
extern UNK_TYPE D_06001040;
extern UNK_TYPE D_06001190;
extern UNK_TYPE D_060022B0;
diff --git a/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c b/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c
index 70962d802f..8b00466e99 100644
--- a/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c
+++ b/src/overlays/actors/ovl_Demo_Effect/z_demo_effect.c
@@ -1880,7 +1880,7 @@ void DemoEffect_DrawLightEffect(Actor* thisx, GlobalContext* globalCtx) {
if (this->light.flicker == 0) {
this->light.flicker = 1;
} else {
- disp = (u32)gGameKeepMoteDL0; // necessary to match, should be able to remove after fake matches are fixed
+ disp = (u32)gEffFlash1DL; // necessary to match, should be able to remove after fake matches are fixed
alpha = &this->light.alpha;
func_80093D84(globalCtx->state.gfxCtx);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 128, this->primXluColor[0], this->primXluColor[1],
@@ -1923,7 +1923,7 @@ void DemoEffect_DrawBlueOrb(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_demo_effect.c", 2901),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
this->blueOrb.rotation += 0x01F4;
- gSPDisplayList(POLY_XLU_DISP++, gGameKeepMoteDL0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFlash1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_demo_effect.c", 2907);
}
diff --git a/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c b/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c
index 8225aa46d5..1125309d50 100644
--- a/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c
+++ b/src/overlays/actors/ovl_Demo_Kankyo/z_demo_kankyo.c
@@ -1,4 +1,5 @@
#include "z_demo_kankyo.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -10,8 +11,6 @@ void DemoKankyo_Update(Actor* thisx, GlobalContext* globalCtx);
void DemoKankyo_Draw(Actor* thisx, GlobalContext* globalCtx);
extern UNK_TYPE D_01000000;
-extern UNK_TYPE D_04010050;
-extern UNK_TYPE D_04052DB0;
extern UNK_TYPE D_06000080;
extern UNK_TYPE D_06000DE0;
extern UNK_TYPE D_06007440;
diff --git a/src/overlays/actors/ovl_Door_Killer/z_door_killer.c b/src/overlays/actors/ovl_Door_Killer/z_door_killer.c
index e44f5375f7..a178242cb0 100644
--- a/src/overlays/actors/ovl_Door_Killer/z_door_killer.c
+++ b/src/overlays/actors/ovl_Door_Killer/z_door_killer.c
@@ -1,4 +1,5 @@
#include "z_door_killer.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
diff --git a/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c b/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c
index 36da6c7776..6ab00688ee 100644
--- a/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c
+++ b/src/overlays/actors/ovl_Door_Shutter/z_door_shutter.c
@@ -6,6 +6,7 @@
#include "z_door_shutter.h"
#include "overlays/actors/ovl_Boss_Goma/z_boss_goma.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -80,16 +81,26 @@ typedef struct {
} ShutterInfo;
static ShutterInfo D_80998134[] = {
- { 0x060067A0, 0x0404B0D0, 130, 12, 20, 15 }, { 0x06006910, 0x0404B0D0, 130, 12, 20, 15 },
- { 0x060000C0, 0x060001F0, 240, 14, 70, 15 }, { 0x06000590, 0x06006460, 0, 110, 50, 15 },
- { 0x06012AB0, NULL, 130, 12, 50, 15 }, { 0x0601EC20, NULL, 130, 12, 50, 15 },
- { 0x06000100, 0x060001F0, 240, 14, 50, 15 }, { 0x060010C0, NULL, 130, 12, 50, 15 },
- { 0x04049FE0, 0x0404B0D0, 130, 12, 20, 15 }, { 0x06010CB0, 0x0404B0D0, 130, 12, 20, 15 },
- { 0x06011F20, 0x0404B0D0, 130, 12, 20, 15 }, { 0x060000C0, 0x0404B0D0, 130, 12, 20, 15 },
- { 0x06005D90, 0x0404B0D0, 130, 12, 20, 15 }, { 0x06007000, 0x0404B0D0, 130, 12, 20, 15 },
- { 0x06002620, 0x0404B0D0, 130, 12, 20, 15 }, { 0x06003890, 0x0404B0D0, 130, 12, 20, 15 },
- { 0x06001D10, 0x0404B0D0, 130, 12, 20, 15 }, { 0x060010D0, 0x0404B0D0, 130, 12, 20, 15 },
- { 0x060020D0, 0x0404B0D0, 130, 12, 20, 15 }, { 0x060000C0, 0x0404B0D0, 130, 12, 20, 15 },
+ { 0x060067A0, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06006910, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x060000C0, 0x060001F0, 240, 14, 70, 15 },
+ { 0x06000590, 0x06006460, 0, 110, 50, 15 },
+ { 0x06012AB0, NULL, 130, 12, 50, 15 },
+ { 0x0601EC20, NULL, 130, 12, 50, 15 },
+ { 0x06000100, 0x060001F0, 240, 14, 50, 15 },
+ { 0x060010C0, NULL, 130, 12, 50, 15 },
+ { gDoorMetalBarsDL, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06010CB0, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06011F20, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x060000C0, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06005D90, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06007000, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06002620, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06003890, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x06001D10, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x060010D0, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x060020D0, gDungeonDoorDL, 130, 12, 20, 15 },
+ { 0x060000C0, gDungeonDoorDL, 130, 12, 20, 15 },
};
static s8 D_80998224[] = {
diff --git a/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c b/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c
index caef504118..7dd8574e93 100644
--- a/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c
+++ b/src/overlays/actors/ovl_Eff_Dust/z_eff_dust.c
@@ -1,4 +1,5 @@
#include "z_eff_dust.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -9,8 +10,6 @@ void EffDust_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EffDust_Update(Actor* thisx, GlobalContext* globalCtx);
void EffDust_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_04037880;
-
/*
const ActorInit Eff_Dust_InitVars = {
ACTOR_EFF_DUST,
diff --git a/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c b/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c
index cd699e9042..7b39b54594 100644
--- a/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c
+++ b/src/overlays/actors/ovl_En_Anubice_Fire/z_en_anubice_fire.c
@@ -5,6 +5,7 @@
*/
#include "z_en_anubice_fire.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
diff --git a/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c b/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c
index c99c478af5..13f5adb68e 100644
--- a/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c
+++ b/src/overlays/actors/ovl_En_Arrow/z_en_arrow.c
@@ -5,6 +5,7 @@
*/
#include "z_en_arrow.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -15,11 +16,6 @@ void EnArrow_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EnArrow_Update(Actor* thisx, GlobalContext* globalCtx);
void EnArrow_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_04004310;
-extern UNK_TYPE D_0400436C;
-extern UNK_TYPE D_04006010;
-extern UNK_TYPE D_04037880;
-
/*
const ActorInit En_Arrow_InitVars = {
ACTOR_EN_ARROW,
diff --git a/src/overlays/actors/ovl_En_Bb/z_en_bb.c b/src/overlays/actors/ovl_En_Bb/z_en_bb.c
index 1055b920e3..a13dc72b1a 100644
--- a/src/overlays/actors/ovl_En_Bb/z_en_bb.c
+++ b/src/overlays/actors/ovl_En_Bb/z_en_bb.c
@@ -5,6 +5,7 @@
*/
#include "z_en_bb.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x01000015
@@ -90,7 +91,6 @@ void EnBb_Green(EnBb* this, GlobalContext* globalCtx);
void EnBb_Stunned(EnBb* this, GlobalContext* globalCtx);
-extern Gfx D_0404D4E0[];
extern AnimationHeader D_06000184;
extern AnimationHeader D_06000444;
extern SkeletonHeader D_06001A30;
@@ -1336,7 +1336,7 @@ void EnBb_Draw(Actor* thisx, GlobalContext* globalCtx) {
Matrix_Scale(this->flameScaleX * 0.01f, this->flameScaleY * 0.01f, 1.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_bb.c", 2106),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
} else {
Matrix_MultVec3f(&blureBase1, &blureVtx1);
Matrix_MultVec3f(&blureBase2, &blureVtx2);
diff --git a/src/overlays/actors/ovl_En_Bom/z_en_bom.c b/src/overlays/actors/ovl_En_Bom/z_en_bom.c
index 84be5871fd..bae8cbeb72 100644
--- a/src/overlays/actors/ovl_En_Bom/z_en_bom.c
+++ b/src/overlays/actors/ovl_En_Bom/z_en_bom.c
@@ -6,6 +6,7 @@
#include "z_en_bom.h"
#include "overlays/effects/ovl_Effect_Ss_Dead_Sound/z_eff_ss_dead_sound.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -84,9 +85,6 @@ static InitChainEntry sInitChain[] = {
ICHAIN_F32_DIV1000(gravity, -4000, ICHAIN_STOP),
};
-extern Gfx D_04007A50[]; // gold fuse cap
-extern Gfx D_04007860[]; // bomb
-
void EnBom_SetupAction(EnBom* this, EnBomActionFunc actionFunc) {
this->actionFunc = actionFunc;
}
@@ -369,14 +367,14 @@ void EnBom_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_bom.c", 928),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_OPA_DISP++, D_04007A50);
+ gSPDisplayList(POLY_OPA_DISP++, gBombCapDL);
Matrix_RotateRPY(0x4000, 0, 0, MTXMODE_APPLY);
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_bom.c", 934),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPPipeSync(POLY_OPA_DISP++);
gDPSetEnvColor(POLY_OPA_DISP++, (s16)this->flashIntensity, 0, 40, 255);
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, (s16)this->flashIntensity, 0, 40, 255);
- gSPDisplayList(POLY_OPA_DISP++, D_04007860);
+ gSPDisplayList(POLY_OPA_DISP++, gBombBodyDL);
Collider_UpdateSpheres(0, &this->explosionCollider);
}
diff --git a/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c b/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c
index 621ac46118..d709c35fd0 100644
--- a/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c
+++ b/src/overlays/actors/ovl_En_Bom_Chu/z_en_bom_chu.c
@@ -1,4 +1,5 @@
#include "z_en_bom_chu.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -9,8 +10,6 @@ void EnBomChu_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EnBomChu_Update(Actor* thisx, GlobalContext* globalCtx);
void EnBomChu_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_04007E10;
-
/*
const ActorInit En_Bom_Chu_InitVars = {
ACTOR_EN_BOM_CHU,
diff --git a/src/overlays/actors/ovl_En_Boom/z_en_boom.c b/src/overlays/actors/ovl_En_Boom/z_en_boom.c
index 5a28ab7e6d..537a9374e4 100644
--- a/src/overlays/actors/ovl_En_Boom/z_en_boom.c
+++ b/src/overlays/actors/ovl_En_Boom/z_en_boom.c
@@ -5,6 +5,7 @@
*/
#include "z_en_boom.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -54,8 +55,6 @@ static InitChainEntry sInitChain[] = {
ICHAIN_VEC3S(shape.rot, 0, ICHAIN_STOP),
};
-extern Gfx D_0400C808[];
-
void EnBoom_SetupAction(EnBoom* this, EnBoomActionFunc actionFunc) {
this->actionFunc = actionFunc;
}
@@ -274,7 +273,7 @@ void EnBoom_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_boom.c", 601),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_OPA_DISP++, D_0400C808);
+ gSPDisplayList(POLY_OPA_DISP++, gBoomerangRefDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_boom.c", 604);
}
diff --git a/src/overlays/actors/ovl_En_Butte/z_en_butte.c b/src/overlays/actors/ovl_En_Butte/z_en_butte.c
index cd24764a7c..5e2403356d 100644
--- a/src/overlays/actors/ovl_En_Butte/z_en_butte.c
+++ b/src/overlays/actors/ovl_En_Butte/z_en_butte.c
@@ -135,7 +135,7 @@ void EnButte_DrawTransformationEffect(EnButte* this, GlobalContext* globalCtx) {
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 200, 200, 180, alpha);
gDPSetEnvColor(POLY_XLU_DISP++, 200, 200, 210, 255);
- gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(&gGameKeepMoteDL0));
+ gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(&gEffFlash1DL));
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_choo.c", 326);
}
diff --git a/src/overlays/actors/ovl_En_Bw/z_en_bw.c b/src/overlays/actors/ovl_En_Bw/z_en_bw.c
index 9fa372255f..98261f3b04 100644
--- a/src/overlays/actors/ovl_En_Bw/z_en_bw.c
+++ b/src/overlays/actors/ovl_En_Bw/z_en_bw.c
@@ -5,6 +5,7 @@
*/
#include "z_en_bw.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000015
@@ -33,7 +34,6 @@ void func_809D0268(EnBw* this, GlobalContext* globalCtx);
void func_809D03CC(EnBw* this);
void func_809D0424(EnBw* this, GlobalContext* globalCtx);
-extern Gfx D_0404D4E0[];
extern AnimationHeader D_06000228;
extern SkeletonHeader D_060020F0;
extern AnimationHeader D_060021A0;
@@ -889,7 +889,7 @@ void EnBw_Draw(Actor* thisx, GlobalContext* globalCtx2) {
func_800D1FD4(&globalCtx->mf_11DA0);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_bw.c", 1500),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
if (this->iceTimer != 0) {
thisx->colorFilterTimer++;
diff --git a/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c b/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c
index a251fddf06..2a60632dd3 100644
--- a/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c
+++ b/src/overlays/actors/ovl_En_Dekubaba/z_en_dekubaba.c
@@ -1,4 +1,5 @@
#include "z_en_dekubaba.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000005
diff --git a/src/overlays/actors/ovl_En_Door/z_en_door.c b/src/overlays/actors/ovl_En_Door/z_en_door.c
index 64b78e8669..896a34b1cc 100644
--- a/src/overlays/actors/ovl_En_Door/z_en_door.c
+++ b/src/overlays/actors/ovl_En_Door/z_en_door.c
@@ -5,6 +5,7 @@
*/
#include "z_en_door.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -59,23 +60,17 @@ static InitChainEntry sInitChain[] = {
ICHAIN_F32(uncullZoneForward, 4000, ICHAIN_STOP),
};
-AnimationHeader* D_809FCECC[] = { 0x0400E758, 0x0400E5B4, 0x04010038, 0x0400E6A0 };
+AnimationHeader* D_809FCECC[] = { &gDoor3Anim, &gDoor1Anim, &gDoor4Anim, &gDoor2Anim };
static u8 sDoorAnimOpenFrames[] = { 25, 25, 25, 25 };
static u8 sDoorAnimCloseFrames[] = { 60, 70, 60, 70 };
static Gfx* D_809FCEE4[5][2] = {
- { 0x0400ECB8, 0x0400EE00 }, { 0x0600F998, 0x0600F938 }, { 0x06004958, 0x06004A10 },
- { 0x060013B8, 0x06001420 }, { 0x050047A0, 0x05004978 },
+ { gDoorLeftDL, gDoorRightDL }, { 0x0600F998, 0x0600F938 }, { 0x06004958, 0x06004A10 },
+ { 0x060013B8, 0x06001420 }, { 0x050047A0, 0x05004978 },
};
-extern Gfx D_0400ECB8[];
-extern Gfx D_0400EE00[];
-
-extern AnimationHeader D_0400E758;
-extern SkeletonHeader D_0400FF78;
-
void EnDoor_Init(Actor* thisx, GlobalContext* globalCtx2) {
GlobalContext* globalCtx = globalCtx2;
EnDoor* this = THIS;
@@ -87,7 +82,7 @@ void EnDoor_Init(Actor* thisx, GlobalContext* globalCtx2) {
objectInfo = &sDoorInfo[0];
Actor_ProcessInitChain(&this->actor, sInitChain);
- SkelAnime_Init(globalCtx, &this->skelAnime, &D_0400FF78, &D_0400E758, this->jointTable, this->morphTable, 5);
+ SkelAnime_Init(globalCtx, &this->skelAnime, &gDoorSkel, &gDoor3Anim, this->jointTable, this->morphTable, 5);
for (i = 0; i < ARRAY_COUNT(sDoorInfo) - 2; i++, objectInfo++) {
if (globalCtx->sceneNum == objectInfo->sceneNum) {
break;
@@ -335,9 +330,9 @@ void EnDoor_Draw(Actor* thisx, GlobalContext* globalCtx) {
if (this->actor.world.rot.y != 0) {
if (1) {}
if (this->actor.world.rot.y > 0) {
- gSPDisplayList(POLY_OPA_DISP++, D_0400EE00);
+ gSPDisplayList(POLY_OPA_DISP++, gDoorRightDL);
} else {
- gSPDisplayList(POLY_OPA_DISP++, D_0400ECB8);
+ gSPDisplayList(POLY_OPA_DISP++, gDoorLeftDL);
}
}
if (this->lockTimer != 0) {
diff --git a/src/overlays/actors/ovl_En_Elf/z_en_elf.c b/src/overlays/actors/ovl_En_Elf/z_en_elf.c
index 1e1fd74138..65fe060e66 100644
--- a/src/overlays/actors/ovl_En_Elf/z_en_elf.c
+++ b/src/overlays/actors/ovl_En_Elf/z_en_elf.c
@@ -5,6 +5,7 @@
*/
#include "z_en_elf.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x02000030
@@ -90,9 +91,6 @@ static FairyColorFlags sColorFlags[] = {
{ 0, 0, 1 }, { 2, 0, 1 }, { 0, 2, 1 }, { 1, 1, 0 }, { 1, 0, 1 }, { 0, 1, 1 },
};
-extern SkeletonHeader D_04016A48;
-extern AnimationHeader D_04014BA4;
-
void EnElf_SetupAction(EnElf* this, EnElfActionFunc actionFunc) {
this->actionFunc = actionFunc;
}
@@ -323,7 +321,7 @@ void EnElf_Init(Actor* thisx, GlobalContext* globalCtx) {
s32 i;
Actor_ProcessInitChain(thisx, sInitChain);
- SkelAnime_Init(globalCtx, &this->skelAnime, &D_04016A48, &D_04014BA4, this->jointTable, this->morphTable, 15);
+ SkelAnime_Init(globalCtx, &this->skelAnime, &gFairySkel, &gFairyAnim, this->jointTable, this->morphTable, 15);
ActorShape_Init(&thisx->shape, 0.0f, NULL, 15.0f);
thisx->shape.shadowAlpha = 0xFF;
diff --git a/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c b/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c
index 5ecb507643..296b97dd11 100644
--- a/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c
+++ b/src/overlays/actors/ovl_En_Ex_Item/z_en_ex_item.c
@@ -5,8 +5,9 @@
*/
#include "z_en_ex_item.h"
-#include "vt.h"
#include "overlays/actors/ovl_En_Bom_Bowl_Pit/z_en_bom_bowl_pit.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
+#include "vt.h"
#define FLAGS 0x00000030
@@ -504,7 +505,7 @@ void EnExItem_DrawKey(EnExItem* this, GlobalContext* globalCtx, s32 index) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_ex_item.c", 887),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(keySegments[index]));
- gSPDisplayList(POLY_OPA_DISP++, D_0403F070);
+ gSPDisplayList(POLY_OPA_DISP++, gItemDropDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ex_item.c", 893);
}
diff --git a/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c b/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c
index e875052898..f336c36654 100644
--- a/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c
+++ b/src/overlays/actors/ovl_En_Ex_Ruppy/z_en_ex_ruppy.c
@@ -1,6 +1,7 @@
#include "z_en_ex_ruppy.h"
#include "vt.h"
#include "../ovl_En_Diving_Game/z_en_diving_game.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -376,7 +377,9 @@ void EnExRuppy_Update(Actor* thisx, GlobalContext* globalCtx) {
Actor_UpdateBgCheckInfo(globalCtx, &this->actor, 20.0f, 20.0f, 50.0f, 0x1C);
}
-UNK_PTR D_80A0B3B8[] = { 0x04042140, 0x04042160, 0x04042180, 0x040421C0, 0x040421A0 };
+UNK_PTR D_80A0B3B8[] = {
+ gRupeeGreenTex, gRupeeBlueTex, gRupeeRedTex, gRupeePinkTex, gRupeeOrangeTex,
+};
void EnExRuppy_Draw(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
@@ -390,7 +393,7 @@ void EnExRuppy_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_ex_ruppy.c", 780),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80A0B3B8[this->colorIdx]));
- gSPDisplayList(POLY_OPA_DISP++, D_04042440);
+ gSPDisplayList(POLY_OPA_DISP++, gRupeeDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ex_ruppy.c", 784);
}
diff --git a/src/overlays/actors/ovl_En_Fd/z_en_fd.c b/src/overlays/actors/ovl_En_Fd/z_en_fd.c
index 3ef5f0529a..03dea3370f 100644
--- a/src/overlays/actors/ovl_En_Fd/z_en_fd.c
+++ b/src/overlays/actors/ovl_En_Fd/z_en_fd.c
@@ -1,4 +1,5 @@
#include "z_en_fd.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000215
@@ -863,8 +864,8 @@ void EnFd_UpdateDots(EnFd* this) {
}
void EnFd_DrawFlames(EnFd* this, GlobalContext* globalCtx) {
- static Gfx* D_80A0E0F8[] = {
- 0x040539B0, 0x040535B0, 0x040531B0, 0x04052DB0, 0x040529B0, 0x040525B0, 0x040521B0, 0x04051DB0,
+ static UNK_PTR D_80A0E0F8[] = {
+ gDust8Tex, gDust7Tex, gDust6Tex, gDust5Tex, gDust4Tex, gDust3Tex, gDust2Tex, gDust1Tex,
};
s32 firstDone;
s16 i;
diff --git a/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c b/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c
index 402342c886..0469fda545 100644
--- a/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c
+++ b/src/overlays/actors/ovl_En_Fd_Fire/z_en_fd_fire.c
@@ -1,4 +1,5 @@
#include "z_en_fd_fire.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000015
@@ -13,8 +14,6 @@ void func_80A0E70C(EnFdFire* this, GlobalContext* globalCtx);
void EnFdFire_DanceTowardsPlayer(EnFdFire* this, GlobalContext* globalCtx);
void EnFdFire_WaitToDie(EnFdFire* this, GlobalContext* globalCtx);
-extern Gfx D_0404D4E0[];
-
const ActorInit En_Fd_Fire_InitVars = {
ACTOR_EN_FD_FIRE,
ACTORCAT_ENEMY,
@@ -283,7 +282,7 @@ void EnFdFire_Draw(Actor* thisx, GlobalContext* globalCtx) {
envColors[((this->actor.params & 0x8000) >> 0xF)].b,
envColors[((this->actor.params & 0x8000) >> 0xF)].a);
gDPPipeSync(POLY_XLU_DISP++);
- gSPDisplayList(POLY_XLU_DISP++, &D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, &gEffFire1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_fd_fire.c", 672);
}
diff --git a/src/overlays/actors/ovl_En_Fish/z_en_fish.c b/src/overlays/actors/ovl_En_Fish/z_en_fish.c
index 8cfe3990c7..7c5f87b2c2 100644
--- a/src/overlays/actors/ovl_En_Fish/z_en_fish.c
+++ b/src/overlays/actors/ovl_En_Fish/z_en_fish.c
@@ -1,4 +1,5 @@
#include "z_en_fish.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -9,10 +10,6 @@ void EnFish_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EnFish_Update(Actor* thisx, GlobalContext* globalCtx);
void EnFish_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_040185FC;
-extern UNK_TYPE D_04018FE0;
-extern UNK_TYPE D_0401909C;
-
/*
const ActorInit En_Fish_InitVars = {
ACTOR_EN_FISH,
diff --git a/src/overlays/actors/ovl_En_Fw/z_en_fw.c b/src/overlays/actors/ovl_En_Fw/z_en_fw.c
index af8b421362..69031c56a8 100644
--- a/src/overlays/actors/ovl_En_Fw/z_en_fw.c
+++ b/src/overlays/actors/ovl_En_Fw/z_en_fw.c
@@ -1,5 +1,6 @@
#include "z_en_fw.h"
#include "overlays/actors/ovl_En_Bom/z_en_bom.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000215
@@ -440,8 +441,8 @@ void EnFw_UpdateDust(EnFw* this) {
}
void EnFw_DrawDust(EnFw* this, GlobalContext* globalCtx) {
- static Gfx* D_80A1FC18[] = {
- 0x040539B0, 0x040535B0, 0x040531B0, 0x04052DB0, 0x040529B0, 0x040525B0, 0x040521B0, 0x04051DB0,
+ static UNK_PTR D_80A1FC18[] = {
+ gDust8Tex, gDust7Tex, gDust6Tex, gDust5Tex, gDust4Tex, gDust3Tex, gDust2Tex, gDust1Tex,
};
EnFwEffect* eff = this->effects;
s16 firstDone;
diff --git a/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c b/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c
index 35e5a4d002..3eb8d773e7 100644
--- a/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c
+++ b/src/overlays/actors/ovl_En_G_Switch/z_en_g_switch.c
@@ -9,6 +9,7 @@
#include "overlays/actors/ovl_En_Syateki_Itm/z_en_syateki_itm.h"
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
#include "overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000030
@@ -466,7 +467,8 @@ void EnGSwitch_DrawPot(Actor* thisx, GlobalContext* globalCtx) {
}
}
-static u8* sRupeeTex[] = { 0x04042140, 0x04042160, 0x04042180, 0x040421C0, 0x040421A0, 0x040421E0 };
+static UNK_PTR sRupeeTex[] = { gRupeeGreenTex, gRupeeBlueTex, gRupeeRedTex,
+ gRupeePinkTex, gRupeeOrangeTex, gRupeeSilverTex };
void EnGSwitch_DrawRupee(Actor* thisx, GlobalContext* globalCtx) {
s32 pad;
@@ -480,7 +482,7 @@ void EnGSwitch_DrawRupee(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_g_switch.c", 957),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sRupeeTex[this->colorIdx]));
- gSPDisplayList(POLY_OPA_DISP++, D_04042440);
+ gSPDisplayList(POLY_OPA_DISP++, gRupeeDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_g_switch.c", 961);
}
if (this->type == ENGSWITCH_TARGET_RUPEE) {
@@ -564,7 +566,7 @@ void EnGSwitch_DrawEffects(EnGSwitch* this, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_g_switch.c", 1088),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_OPA_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sRupeeTex[effect->colorIdx]));
- gSPDisplayList(POLY_OPA_DISP++, D_04042440);
+ gSPDisplayList(POLY_OPA_DISP++, gRupeeDL);
}
}
CLOSE_DISPS(gfxCtx, "../z_en_g_switch.c", 1095);
diff --git a/src/overlays/actors/ovl_En_Go/z_en_go.c b/src/overlays/actors/ovl_En_Go/z_en_go.c
index 5e36f29a97..078e2a7995 100644
--- a/src/overlays/actors/ovl_En_Go/z_en_go.c
+++ b/src/overlays/actors/ovl_En_Go/z_en_go.c
@@ -1,4 +1,5 @@
#include "z_en_go.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000039
diff --git a/src/overlays/actors/ovl_En_Go2/z_en_go2.c b/src/overlays/actors/ovl_En_Go2/z_en_go2.c
index 2e3abc7699..bdac0d42db 100644
--- a/src/overlays/actors/ovl_En_Go2/z_en_go2.c
+++ b/src/overlays/actors/ovl_En_Go2/z_en_go2.c
@@ -1,4 +1,5 @@
#include "z_en_go2.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000039
diff --git a/src/overlays/actors/ovl_En_Goroiwa/z_en_goroiwa.c b/src/overlays/actors/ovl_En_Goroiwa/z_en_goroiwa.c
index f408b1cbb5..285c287c7d 100644
--- a/src/overlays/actors/ovl_En_Goroiwa/z_en_goroiwa.c
+++ b/src/overlays/actors/ovl_En_Goroiwa/z_en_goroiwa.c
@@ -6,7 +6,7 @@
#include "z_en_goroiwa.h"
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
-
+#include "objects/gameplay_keep/gameplay_keep.h"
#include "vt.h"
#define FLAGS 0x00000010
@@ -76,7 +76,6 @@ static CollisionCheckInfoInit sColChkInfoInit = { 0, 12, 60, MASS_HEAVY };
// Unused
static f32 D_80A4DEBC[] = { 10.0f, 9.2f };
-extern Gfx D_0400D340[];
extern Gfx D_060006B0[];
void func_80A4BCA0(EnGoroiwa* this) {
@@ -501,7 +500,7 @@ void func_80A4D0FC(EnGoroiwa* this, GlobalContext* globalCtx) {
fragmentVelocity.z = effectPos.z * 0.2f;
Math_Vec3f_Sum(&effectPos, thisPos, &effectPos);
EffectSsKakera_Spawn(globalCtx, &effectPos, &fragmentVelocity, &effectPos, -340, 33, 28, 2, 0,
- (Rand_ZeroOne() * 7.0f) + 1.0f, 1, 0, 70, KAKERA_COLOR_NONE, 1, D_0400D340);
+ (Rand_ZeroOne() * 7.0f) + 1.0f, 1, 0, 70, KAKERA_COLOR_NONE, 1, gBoulderFragmentsDL);
}
effectPos.x = thisPos->x;
diff --git a/src/overlays/actors/ovl_En_Gs/z_en_gs.c b/src/overlays/actors/ovl_En_Gs/z_en_gs.c
index 06c1485c73..8ac449cd14 100644
--- a/src/overlays/actors/ovl_En_Gs/z_en_gs.c
+++ b/src/overlays/actors/ovl_En_Gs/z_en_gs.c
@@ -6,6 +6,7 @@
#include "z_en_gs.h"
#include "overlays/actors/ovl_En_Elf/z_en_elf.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x02000009
@@ -21,7 +22,6 @@ void func_80A4F700(EnGs* this, GlobalContext* globalCtx);
void func_80A4F77C(EnGs* this);
-extern Gfx D_0404D4E0[];
extern Gfx D_06000950[];
extern Gfx D_060009D0[];
extern Gfx D_06000A60[];
@@ -614,7 +614,7 @@ void EnGs_Draw(Actor* thisx, GlobalContext* globalCtx) {
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, 0, 0, 0x20, 0x40, 1, 0, -frames * 0x14, 0x20, 0x80));
gDPSetPrimColor(POLY_XLU_DISP++, 128, 128, 255, 255, 0, 255);
gDPSetEnvColor(POLY_XLU_DISP++, 255, 0, 0, 0);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_gs.c", 1101);
diff --git a/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c b/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c
index 6cb7c16d32..c0b0505689 100644
--- a/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c
+++ b/src/overlays/actors/ovl_En_Honotrap/z_en_honotrap.c
@@ -5,6 +5,7 @@
*/
#include "z_en_honotrap.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -47,7 +48,6 @@ void EnHonotrap_FlameChase(EnHonotrap* this, GlobalContext* globalCtx);
void EnHonotrap_SetupFlameVanish(EnHonotrap* this);
void EnHonotrap_FlameVanish(EnHonotrap* this, GlobalContext* globalCtx);
-extern Gfx D_0404D4E0[];
extern Gfx D_05006810[];
const ActorInit En_Honotrap_InitVars = {
@@ -519,7 +519,7 @@ void EnHonotrap_DrawFlame(Actor* thisx, GlobalContext* globalCtx) {
MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_honotrap.c", 1024),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_honotrap.c", 1028);
}
diff --git a/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c b/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c
index 25e6c502a1..e46706193c 100644
--- a/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c
+++ b/src/overlays/actors/ovl_En_Horse_Normal/z_en_horse_normal.c
@@ -5,6 +5,7 @@
*/
#include "z_en_horse_normal.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -715,7 +716,7 @@ void EnHorseNormal_Draw(Actor* thisx, GlobalContext* globalCtx) {
mtx2 = Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_horse_normal.c", 2329);
if (mtx2 != NULL) {
gSPMatrix(POLY_XLU_DISP++, mtx2, G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_04049AD0);
+ gSPDisplayList(POLY_XLU_DISP++, gHorseShadowDL);
}
}
diff --git a/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c b/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c
index 00aae40d96..292b66bd12 100644
--- a/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c
+++ b/src/overlays/actors/ovl_En_Ice_Hono/z_en_ice_hono.c
@@ -1,4 +1,5 @@
#include "z_en_ice_hono.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -19,8 +20,6 @@ void EnIceHono_SetupActionDroppedFlame(EnIceHono* this);
void EnIceHono_SetupActionSpreadFlames(EnIceHono* this);
void EnIceHono_SetupActionSmallFlame(EnIceHono* this);
-extern Gfx D_0404D4E0[];
-
const ActorInit En_Ice_Hono_InitVars = {
ACTOR_EN_ICE_HONO,
ACTORCAT_ITEMACTION,
@@ -387,7 +386,7 @@ void EnIceHono_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_ice_hono.c", 718),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_ice_hono.c", 722);
}
diff --git a/src/overlays/actors/ovl_En_Insect/z_en_insect.c b/src/overlays/actors/ovl_En_Insect/z_en_insect.c
index 0115319071..4843d1f827 100644
--- a/src/overlays/actors/ovl_En_Insect/z_en_insect.c
+++ b/src/overlays/actors/ovl_En_Insect/z_en_insect.c
@@ -1,5 +1,6 @@
#include "z_en_insect.h"
#include "vt.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -26,9 +27,6 @@ void func_80A7D26C(EnInsect* this, GlobalContext* globalCtx);
void func_80A7D39C(EnInsect* this);
void func_80A7D460(EnInsect* this, GlobalContext* globalCtx);
-extern SkeletonHeader D_04035590;
-extern AnimationHeader D_040341FC;
-
static f32 D_80A7DEB0 = 0.0f;
static s16 D_80A7DEB4 = 0;
static s16 D_80A7DEB8 = 0;
@@ -108,7 +106,7 @@ s32 func_80A7BE6C(EnInsect* this, GlobalContext* globalCtx) {
}
void func_80A7BF58(EnInsect* this) {
- Animation_Change(&this->skelAnime, &D_040341FC, 1.0f, 0.0f, 0.0f, ANIMMODE_LOOP_INTERP, 0.0f);
+ Animation_Change(&this->skelAnime, &gBugCrawlAnim, 1.0f, 0.0f, 0.0f, ANIMMODE_LOOP_INTERP, 0.0f);
}
/**
@@ -168,7 +166,7 @@ void EnInsect_Init(Actor* thisx, GlobalContext* globalCtx) {
temp_s2 = this->actor.params & 3;
- SkelAnime_Init(globalCtx, &this->skelAnime, &D_04035590, &D_040341FC, this->jointTable, this->morphTable, 24);
+ SkelAnime_Init(globalCtx, &this->skelAnime, &gBugSkel, &gBugCrawlAnim, this->jointTable, this->morphTable, 24);
Collider_InitJntSph(globalCtx, &this->collider);
Collider_SetJntSph(globalCtx, &this->collider, &this->actor, &sColliderInit, &this->colliderItem);
diff --git a/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c b/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c
index 6b8a895cb2..b75559a811 100644
--- a/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c
+++ b/src/overlays/actors/ovl_En_Kanban/z_en_kanban.c
@@ -5,6 +5,7 @@
*/
#include "z_en_kanban.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#include "vt.h"
#define FLAGS 0x00000019
@@ -75,7 +76,6 @@ void EnKanban_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EnKanban_Update(Actor* thisx, GlobalContext* globalCtx);
void EnKanban_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern Gfx D_0403C050[];
extern Gfx D_06000C30[];
extern Gfx D_06001630[];
@@ -842,7 +842,7 @@ void EnKanban_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_OPA_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_kanban.c", 1725),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
if (this->partFlags == 0xFFFF) {
- gSPDisplayList(POLY_OPA_DISP++, D_0403C050);
+ gSPDisplayList(POLY_OPA_DISP++, gSignRectangularDL);
} else {
for (i = 0; i < ARRAY_COUNT(sPartFlags); i++) {
if (sPartFlags[i] & this->partFlags) {
diff --git a/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c b/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c
index 7bc1f9e501..b57116f370 100644
--- a/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c
+++ b/src/overlays/actors/ovl_En_Karebaba/z_en_karebaba.c
@@ -6,6 +6,7 @@
#include "z_en_karebaba.h"
#include "overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000005
@@ -459,7 +460,7 @@ void EnKarebaba_DrawCenterShadow(EnKarebaba* this, GlobalContext* globalCtx) {
Matrix_Scale(0.15f, 1.0f, 0.15f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_karebaba.c", 1029),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_04049210);
+ gSPDisplayList(POLY_XLU_DISP++, gCircleShadowDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_karebaba.c", 1034);
}
diff --git a/src/overlays/actors/ovl_En_Kusa/z_en_kusa.c b/src/overlays/actors/ovl_En_Kusa/z_en_kusa.c
index 74fb152098..de7292ee99 100644
--- a/src/overlays/actors/ovl_En_Kusa/z_en_kusa.c
+++ b/src/overlays/actors/ovl_En_Kusa/z_en_kusa.c
@@ -6,6 +6,7 @@
#include "z_en_kusa.h"
#include "overlays/effects/ovl_Effect_Ss_Kakera/z_eff_ss_kakera.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#include "vt.h"
#define FLAGS 0x00800010
@@ -91,8 +92,6 @@ static InitChainEntry sInitChain[] = {
};
extern Gfx D_060002E0[];
-extern Gfx D_040355E0[]; // bush fragments 1
-extern Gfx D_040356A0[]; // bush fragments 2
void EnKusa_SetupAction(EnKusa* this, EnKusaActionFunc actionFunc) {
this->timer = 0;
@@ -191,7 +190,7 @@ void EnKusa_SpawnFragments(EnKusa* this, GlobalContext* globalCtx) {
index = (s32)(Rand_ZeroOne() * 111.1f) & 7;
EffectSsKakera_Spawn(globalCtx, &pos, &velocity, &pos, -100, 64, 40, 3, 0, D_80A9C26C[index], 0, 0, 80,
- KAKERA_COLOR_NONE, OBJECT_GAMEPLAY_KEEP, D_040355E0);
+ KAKERA_COLOR_NONE, OBJECT_GAMEPLAY_KEEP, gCuttableShrubStalkDL);
pos.x = this->actor.world.pos.x + (scale->x * this->actor.scale.x * 40.0f);
pos.y = this->actor.world.pos.y + (scale->y * this->actor.scale.y * 40.0f) + 10.0f;
@@ -204,7 +203,7 @@ void EnKusa_SpawnFragments(EnKusa* this, GlobalContext* globalCtx) {
index = (s32)(Rand_ZeroOne() * 111.1f) % 7;
EffectSsKakera_Spawn(globalCtx, &pos, &velocity, &pos, -100, 64, 40, 3, 0, D_80A9C26C[index], 0, 0, 80,
- KAKERA_COLOR_NONE, OBJECT_GAMEPLAY_KEEP, D_040356A0);
+ KAKERA_COLOR_NONE, OBJECT_GAMEPLAY_KEEP, gCuttableShrubTipDL);
}
}
diff --git a/src/overlays/actors/ovl_En_Light/z_en_light.c b/src/overlays/actors/ovl_En_Light/z_en_light.c
index 8ff45bc796..35808a5074 100644
--- a/src/overlays/actors/ovl_En_Light/z_en_light.c
+++ b/src/overlays/actors/ovl_En_Light/z_en_light.c
@@ -5,6 +5,7 @@
*/
#include "z_en_light.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -45,7 +46,6 @@ static FlameParams D_80A9E840[] = {
{ { 170, 255, 255, 255 }, { 0, 0, 255 }, 75 }, { { 170, 255, 255, 255 }, { 0, 150, 255 }, 75 },
};
-extern Gfx D_0404D4E0[];
extern Gfx D_05000440[];
void EnLight_Init(Actor* thisx, GlobalContext* globalCtx) {
@@ -171,7 +171,7 @@ void EnLight_Draw(Actor* thisx, GlobalContext* globalCtx) {
POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, 0, 0, 32, 64, 1, 0, (this->timer * -20) & 511, 32, 128));
- dList = D_0404D4E0;
+ dList = gEffFire1DL;
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, flameParams->primColor.r, flameParams->primColor.g,
flameParams->primColor.b, flameParams->primColor.a);
gDPSetEnvColor(POLY_XLU_DISP++, flameParams->envColor.r, flameParams->envColor.g, flameParams->envColor.b, 0);
diff --git a/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c b/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c
index f1d446aca4..78f481a4a2 100644
--- a/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c
+++ b/src/overlays/actors/ovl_En_M_Thunder/z_en_m_thunder.c
@@ -1,4 +1,5 @@
#include "z_en_m_thunder.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000000
@@ -51,12 +52,6 @@ static u32 D_80AA0458[] = { 0x08000000, 0x02000000, 0x04000000 };
static u16 sSfxIds[] = { NA_SE_IT_ROLLING_CUT_LV2, NA_SE_IT_ROLLING_CUT_LV1, NA_SE_IT_ROLLING_CUT_LV2,
NA_SE_IT_ROLLING_CUT_LV1 };
-extern Gfx D_04012570[];
-extern Gfx D_04012690[];
-extern Gfx D_04012AF0[];
-extern Gfx D_04012C10[];
-extern Gfx D_04013610[];
-
// Setup action
void func_80A9EFE0(EnMThunder* this, EnMThunderActionFunc actionFunc) {
this->actionFunc = actionFunc;
@@ -345,13 +340,13 @@ void EnMThunder_Draw(Actor* thisx, GlobalContext* globalCtx2) {
switch (this->unk_1C6) {
case 0:
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 255, 255, 170, (u8)((u32)(this->unk_1B0 * 255) & 0xFF));
- gSPDisplayList(POLY_XLU_DISP++, D_04012AF0);
- gSPDisplayList(POLY_XLU_DISP++, D_04012C10);
+ gSPDisplayList(POLY_XLU_DISP++, gSpinAttack3DL);
+ gSPDisplayList(POLY_XLU_DISP++, gSpinAttack4DL);
break;
case 1:
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, 170, 255, 255, (u8)((u32)(this->unk_1B0 * 255) & 0xFF));
- gSPDisplayList(POLY_XLU_DISP++, D_04012570);
- gSPDisplayList(POLY_XLU_DISP++, D_04012690);
+ gSPDisplayList(POLY_XLU_DISP++, gSpinAttack1DL);
+ gSPDisplayList(POLY_XLU_DISP++, gSpinAttack2DL);
break;
}
@@ -404,7 +399,7 @@ void EnMThunder_Draw(Actor* thisx, GlobalContext* globalCtx2) {
(globalCtx->gameplayFrames * 0x14) & 0xFF,
(u8)(globalCtx->gameplayFrames * phi_t1) & 0xFF, 8, 8));
- gSPDisplayList(POLY_XLU_DISP++, D_04013610);
+ gSPDisplayList(POLY_XLU_DISP++, gSpinAttackChargingDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_m_thunder.c", 1031);
}
diff --git a/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c b/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c
index ebcf348718..5cc7250a4d 100644
--- a/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c
+++ b/src/overlays/actors/ovl_En_Ossan/z_en_ossan.c
@@ -1,4 +1,5 @@
#include "z_en_ossan.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000019
@@ -8,9 +9,6 @@ void EnOssan_Init(Actor* thisx, GlobalContext* globalCtx);
void EnOssan_Destroy(Actor* thisx, GlobalContext* globalCtx);
void EnOssan_Update(Actor* thisx, GlobalContext* globalCtx);
-extern UNK_TYPE D_0400CDC0;
-extern UNK_TYPE D_0400CE40;
-extern UNK_TYPE D_0400CF40;
extern UNK_TYPE D_060000F0;
extern UNK_TYPE D_060000FC;
extern UNK_TYPE D_060002E4;
diff --git a/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c b/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c
index adc0fafc1f..765e12b618 100644
--- a/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c
+++ b/src/overlays/actors/ovl_En_Po_Field/z_en_po_field.c
@@ -5,6 +5,7 @@
*/
#include "z_en_po_field.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00001035
@@ -151,7 +152,6 @@ extern AnimationHeader D_06000F9C;
extern AnimationHeader D_06000608;
extern AnimationHeader D_06000454;
extern AnimationHeader D_06001360;
-extern Gfx D_0404D4E0[];
extern Gfx D_060059F0[];
extern Gfx D_06005900[];
extern Gfx D_06005620[];
@@ -810,7 +810,7 @@ void EnPoField_DrawFlame(EnPoField* this, GlobalContext* globalCtx) {
}
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_po_field.c", 1709),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_po_field.c", 1712);
}
}
diff --git a/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c b/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c
index d1089914ec..b58ca4d6bf 100644
--- a/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c
+++ b/src/overlays/actors/ovl_En_Po_Sisters/z_en_po_sisters.c
@@ -5,6 +5,7 @@
*/
#include "z_en_po_sisters.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00005215
@@ -175,8 +176,6 @@ extern AnimationHeader D_06000680;
extern Gfx D_060027B0[];
extern Gfx D_060046E0[];
-extern Gfx D_0404D4E0[];
-
void EnPoSisters_Init(Actor* thisx, GlobalContext* globalCtx) {
EnPoSisters* this = THIS;
s32 pad;
@@ -1414,7 +1413,7 @@ void EnPoSisters_Draw(Actor* thisx, GlobalContext* globalCtx) {
Matrix_Scale(phi_f20, phi_f20, phi_f20, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_po_sisters.c", 3132),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_po_sisters.c", 3139);
}
diff --git a/src/overlays/actors/ovl_En_Pu_box/z_en_pu_box.c b/src/overlays/actors/ovl_En_Pu_box/z_en_pu_box.c
index a21b419978..22745408f7 100644
--- a/src/overlays/actors/ovl_En_Pu_box/z_en_pu_box.c
+++ b/src/overlays/actors/ovl_En_Pu_box/z_en_pu_box.c
@@ -57,7 +57,7 @@ void EnPubox_Init(Actor* thisx, GlobalContext* globalCtx) {
this->dyna.unk_15C = DPM_UNK;
thisx->targetMode = 1;
thisx->gravity = -2.0f;
- CollisionHeader_GetVirtual(&gPuBoxCol, &colHeader);
+ CollisionHeader_GetVirtual(&gUnknownUnusedBox2Col, &colHeader);
this->dyna.bgId = DynaPoly_SetBgActor(globalCtx, &globalCtx->colCtx.dyna, thisx, colHeader);
}
@@ -87,5 +87,5 @@ void EnPubox_Update(Actor* thisx, GlobalContext* globalCtx) {
}
void EnPubox_Draw(Actor* thisx, GlobalContext* globalCtx) {
- Gfx_DrawDListOpa(globalCtx, gPuBoxDL2);
+ Gfx_DrawDListOpa(globalCtx, gUnknownUnusedBox2DL);
}
diff --git a/src/overlays/actors/ovl_En_Tk/z_en_tk.c b/src/overlays/actors/ovl_En_Tk/z_en_tk.c
index 459ed39515..d638ca09e3 100644
--- a/src/overlays/actors/ovl_En_Tk/z_en_tk.c
+++ b/src/overlays/actors/ovl_En_Tk/z_en_tk.c
@@ -5,6 +5,7 @@
*/
#include "z_en_tk.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000009
@@ -20,14 +21,6 @@ void EnTk_Rest(EnTk* this, GlobalContext* globalCtx);
void EnTk_Walk(EnTk* this, GlobalContext* globalCtx);
void EnTk_Dig(EnTk* this, GlobalContext* globalCtx);
-extern UNK_TYPE D_04051DB0;
-extern UNK_TYPE D_040521B0;
-extern UNK_TYPE D_040525B0;
-extern UNK_TYPE D_040529B0;
-extern UNK_TYPE D_04052DB0;
-extern UNK_TYPE D_040531B0;
-extern UNK_TYPE D_040535B0;
-extern UNK_TYPE D_040539B0;
extern AnimationHeader D_06001144;
extern AnimationHeader D_06001FA8;
extern AnimationHeader D_06002F84;
@@ -96,8 +89,8 @@ void EnTkEff_Update(EnTk* this) {
}
void EnTkEff_Draw(EnTk* this, GlobalContext* globalCtx) {
- static UNK_PTR images[] = {
- &D_040539B0, &D_040535B0, &D_040531B0, &D_04052DB0, &D_040529B0, &D_040525B0, &D_040521B0, &D_04051DB0,
+ static UNK_PTR dustImages[] = {
+ &gDust8Tex, &gDust7Tex, &gDust6Tex, &gDust5Tex, &gDust4Tex, &gDust3Tex, &gDust2Tex, &gDust1Tex,
};
EnTkEff* eff = this->eff;
@@ -133,8 +126,8 @@ void EnTkEff_Draw(EnTk* this, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_tk_eff.c", 140),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- imageIdx = eff->timeLeft * ((f32)ARRAY_COUNT(images) / eff->timeTotal);
- gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(images[imageIdx]));
+ imageIdx = eff->timeLeft * ((f32)ARRAY_COUNT(dustImages) / eff->timeTotal);
+ gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(dustImages[imageIdx]));
gSPDisplayList(POLY_XLU_DISP++, D_0600BCA0);
}
diff --git a/src/overlays/actors/ovl_En_Vase/z_en_vase.c b/src/overlays/actors/ovl_En_Vase/z_en_vase.c
index fe49bf9b70..3b03d27735 100644
--- a/src/overlays/actors/ovl_En_Vase/z_en_vase.c
+++ b/src/overlays/actors/ovl_En_Vase/z_en_vase.c
@@ -39,5 +39,5 @@ void EnVase_Destroy(Actor* thisx, GlobalContext* globalCtx) {
}
void EnVase_Draw(Actor* thisx, GlobalContext* globalCtx) {
- Gfx_DrawDListOpa(globalCtx, &gVaseDL);
+ Gfx_DrawDListOpa(globalCtx, &gUnusedVaseDL);
}
diff --git a/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c b/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c
index 02b11d5c91..99fd39037b 100644
--- a/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c
+++ b/src/overlays/actors/ovl_En_Viewer/z_en_viewer.c
@@ -6,6 +6,7 @@
#include "z_en_viewer.h"
#include "overlays/actors/ovl_En_Ganon_Mant/z_en_ganon_mant.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -37,7 +38,6 @@ void func_80B2BA38(EnViewer* this, GlobalContext* globalCtx);
void func_80B2C130(EnViewer* this, GlobalContext* globalCtx);
extern Mtx D_01000000;
-extern Gfx D_0404D4E0[];
extern AnimationHeader D_06000450;
extern AnimationHeader D_060005B4;
extern AnimationHeader D_060008A0;
@@ -874,7 +874,7 @@ void func_80B2C8AC(EnViewer* this2, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_viewer.c", 2027),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPMatrix(POLY_XLU_DISP++, &D_01000000, G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_viewer.c", 2034);
}
diff --git a/src/overlays/actors/ovl_En_Vm/z_en_vm.c b/src/overlays/actors/ovl_En_Vm/z_en_vm.c
index 257de1df2e..a693e0553f 100644
--- a/src/overlays/actors/ovl_En_Vm/z_en_vm.c
+++ b/src/overlays/actors/ovl_En_Vm/z_en_vm.c
@@ -6,6 +6,7 @@
#include "z_en_vm.h"
#include "overlays/actors/ovl_En_Bom/z_en_bom.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000011
@@ -121,12 +122,14 @@ static Vec3f D_80B2EB70 = { -500.0f, 0.0f, 0.0f };
static Vec3f D_80B2EB7C = { 0.4f, 0.4f, 0.4f };
-static UNK_PTR D_80B2EB88[] = { 0x0402CFE0, 0x0402D7E0, 0x0402DFE0, 0x0402E7E0, 0x0402EFE0,
- 0x0402F7E0, 0x0402FFE0, 0x040307E0, 0x04030FE0, 0x040317E0 };
+static UNK_PTR D_80B2EB88[] = {
+ gEffEnemyDeathFlame1Tex, gEffEnemyDeathFlame2Tex, gEffEnemyDeathFlame3Tex, gEffEnemyDeathFlame4Tex,
+ gEffEnemyDeathFlame5Tex, gEffEnemyDeathFlame6Tex, gEffEnemyDeathFlame7Tex, gEffEnemyDeathFlame8Tex,
+ gEffEnemyDeathFlame9Tex, gEffEnemyDeathFlame10Tex,
+};
extern SkeletonHeader D_06003F60;
extern AnimationHeader D_06000068;
-extern Gfx D_04031FE0[];
extern Gfx D_06002728[];
void EnVm_SetupAction(EnVm* this, EnVmActionFunc actionFunc) {
@@ -539,12 +542,12 @@ void EnVm_Draw(Actor* thisx, GlobalContext* globalCtx) {
func_80094BC4(globalCtx->state.gfxCtx);
gDPSetEnvColor(POLY_XLU_DISP++, 0, 0, 255, 0);
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80B2EB88[globalCtx2->gameplayFrames % 8]));
- gSPDisplayList(POLY_XLU_DISP++, D_04031FE0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffEnemyDeathFlameDL);
Matrix_RotateY(32767.0f, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_vm.c", 1044),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(D_80B2EB88[(globalCtx2->gameplayFrames + 4) % 8]));
- gSPDisplayList(POLY_XLU_DISP++, D_04031FE0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffEnemyDeathFlameDL);
}
gSPSegment(POLY_OPA_DISP++, 0x08, func_80094E78(globalCtx->state.gfxCtx, 0, this->beamTexScroll));
Matrix_Translate(this->beamPos1.x, this->beamPos1.y, this->beamPos1.z, MTXMODE_NEW);
diff --git a/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c b/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c
index b117168f4d..9ea7bb8c9e 100644
--- a/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c
+++ b/src/overlays/actors/ovl_En_Wallmas/z_en_wallmas.c
@@ -5,6 +5,7 @@
*/
#include "z_en_wallmas.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000015
@@ -613,7 +614,7 @@ void EnWallmas_DrawXlu(EnWallmas* this, GlobalContext* globalCtx) {
Matrix_Scale(xzScale, 1.0f, xzScale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_en_wallmas.c", 1421), G_MTX_LOAD);
- gSPDisplayList(POLY_XLU_DISP++, &D_04049210);
+ gSPDisplayList(POLY_XLU_DISP++, &gCircleShadowDL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_en_wallmas.c", 1426);
}
diff --git a/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c b/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c
index ad6a2c6010..b03f41236d 100644
--- a/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c
+++ b/src/overlays/actors/ovl_Magic_Dark/z_magic_dark.c
@@ -221,7 +221,7 @@ void MagicDark_DiamondDraw(Actor* thisx, GlobalContext* globalCtx) {
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, 170, 255, 255, (s32)(this->primAlpha * 0.6f) & 0xFF);
gDPSetEnvColor(POLY_XLU_DISP++, 0, 100, 255, 128);
- gSPDisplayList(POLY_XLU_DISP++, sDiamondTextureDList);
+ gSPDisplayList(POLY_XLU_DISP++, sDiamondTexDList);
gSPDisplayList(POLY_XLU_DISP++,
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, gameplayFrames * 2, gameplayFrames * -4, 32, 32, 1,
0, gameplayFrames * -16, 64, 32));
@@ -270,12 +270,12 @@ void MagicDark_OrbDraw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_magic_dark.c", 632),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
Matrix_RotateZ(sp6C * (M_PI / 32), MTXMODE_APPLY);
- gSPDisplayList(POLY_XLU_DISP++, gGameKeepMoteDL0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFlash1DL);
Matrix_Pull();
Matrix_RotateZ(-sp6C * (M_PI / 32), MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_magic_dark.c", 639),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, gGameKeepMoteDL0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFlash1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_magic_dark.c", 643);
}
diff --git a/src/overlays/actors/ovl_Magic_Dark/z_magic_dark_gfx.c b/src/overlays/actors/ovl_Magic_Dark/z_magic_dark_gfx.c
index dfe6b56614..6326e3766a 100644
--- a/src/overlays/actors/ovl_Magic_Dark/z_magic_dark_gfx.c
+++ b/src/overlays/actors/ovl_Magic_Dark/z_magic_dark_gfx.c
@@ -1,11 +1,10 @@
#include "z_magic_dark.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
-static u64 sDiamondTexture[] = {
+static u64 sDiamondTex[] = {
#include "assets/overlays/ovl_Magic_Dark/diamond_texture.i8.inc.c"
};
-extern UNK_TYPE D_04032490[];
-
static Vtx sDiamondVerts[] = {
VTX(0, 0, 64, 1024, 512, 0x00, 0x00, 0x78, 0xFF), VTX(55, 0, 32, 1707, 512, 0x67, 0x00, 0x3C, 0xFF),
VTX(0, 108, 0, 1365, 0, 0x00, 0x78, 0x00, 0xFF), VTX(55, 0, -32, 2389, 512, 0x67, 0x00, 0xC4, 0xFF),
@@ -19,13 +18,13 @@ static Vtx sDiamondVerts[] = {
VTX(-55, 0, 32, 2389, 512, 0x98, 0x00, 0x3C, 0xFF), VTX(-55, 0, -32, 1707, 512, 0x99, 0x00, 0xC4, 0xFF),
};
-static Gfx sDiamondTextureDList[] = {
+static Gfx sDiamondTexDList[] = {
gsDPPipeSync(),
gsDPSetTextureLUT(G_TT_NONE),
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
- gsDPLoadTextureBlock(D_04032490, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_WRAP,
+ gsDPLoadTextureBlock(gEffUnknown10Tex, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_WRAP,
G_TX_NOMIRROR | G_TX_WRAP, 5, 5, G_TX_NOLOD, 1),
- gsDPLoadMultiBlock(sDiamondTexture, 0x0100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 64, 0, G_TX_NOMIRROR | G_TX_WRAP,
+ gsDPLoadMultiBlock(sDiamondTex, 0x0100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 64, 0, G_TX_NOMIRROR | G_TX_WRAP,
G_TX_MIRROR | G_TX_WRAP, 5, 6, 13, 13),
gsDPSetCombineLERP(TEXEL1, PRIMITIVE, ENV_ALPHA, TEXEL0, TEXEL1, TEXEL0, ENVIRONMENT, TEXEL0, PRIMITIVE,
ENVIRONMENT, COMBINED, ENVIRONMENT, COMBINED, 0, PRIMITIVE, 0),
diff --git a/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c b/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c
index c644aaad9a..05f935fa03 100644
--- a/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c
+++ b/src/overlays/actors/ovl_Obj_Bean/z_obj_bean.c
@@ -5,6 +5,7 @@
*/
#include "z_obj_bean.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00400000
diff --git a/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c b/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c
index cbc41deec9..e966e0b7c7 100644
--- a/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c
+++ b/src/overlays/actors/ovl_Obj_Ice_Poly/z_obj_ice_poly.c
@@ -5,6 +5,7 @@
*/
#include "z_obj_ice_poly.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000010
@@ -18,8 +19,6 @@ void ObjIcePoly_Draw(Actor* thisx, GlobalContext* globalCtx);
void ObjIcePoly_Idle(ObjIcePoly* this, GlobalContext* globalCtx);
void ObjIcePoly_Melt(ObjIcePoly* this, GlobalContext* globalCtx);
-extern Gfx* D_04033EE0[];
-
const ActorInit Obj_Ice_Poly_InitVars = {
ACTOR_OBJ_ICE_POLY,
ACTORCAT_PROP,
@@ -206,7 +205,7 @@ void ObjIcePoly_Draw(Actor* thisx, GlobalContext* globalCtx) {
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, 0, globalCtx->gameplayFrames % 0x100, 0x20, 0x10, 1, 0,
(globalCtx->gameplayFrames * 2) % 0x100, 0x40, 0x20));
gDPSetEnvColor(POLY_XLU_DISP++, 0, 50, 100, this->alpha);
- gSPDisplayList(POLY_XLU_DISP++, D_04033EE0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffIceFragment3DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_obj_ice_poly.c", 444);
}
diff --git a/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c b/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c
index 914a0f3548..a180b0f386 100644
--- a/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c
+++ b/src/overlays/actors/ovl_Obj_Syokudai/z_obj_syokudai.c
@@ -6,6 +6,7 @@
#include "z_obj_syokudai.h"
#include "overlays/actors/ovl_En_Arrow/z_en_arrow.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x00000410
@@ -16,8 +17,6 @@ void ObjSyokudai_Destroy(Actor* thisx, GlobalContext* globalCtx);
void ObjSyokudai_Update(Actor* thisx, GlobalContext* globalCtx);
void ObjSyokudai_Draw(Actor* thisx, GlobalContext* globalCtx);
-extern Gfx D_0404D4E0[];
-
const ActorInit Obj_Syokudai_InitVars = {
ACTOR_OBJ_SYOKUDAI,
ACTORCAT_PROP,
@@ -302,7 +301,7 @@ void ObjSyokudai_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_obj_syokudai.c", 745),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_obj_syokudai.c", 749);
}
diff --git a/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c b/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c
index ed8dc8753a..31fedde2c1 100644
--- a/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c
+++ b/src/overlays/actors/ovl_Object_Kankyo/z_object_kankyo.c
@@ -5,6 +5,7 @@
*/
#include "z_object_kankyo.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define FLAGS 0x02000030
@@ -16,12 +17,6 @@ void ObjectKankyo_Update(Actor* thisx, GlobalContext* globalCtx);
void ObjectKankyo_Draw(Actor* thisx, GlobalContext* globalCtx);
extern UNK_TYPE D_01000000;
-extern UNK_TYPE D_04010050;
-extern UNK_TYPE D_0402CF30;
-extern UNK_TYPE D_0404C160;
-extern UNK_TYPE D_0404D160;
-extern UNK_TYPE D_0404D1A8;
-extern UNK_TYPE D_04052DB0;
extern UNK_TYPE D_06005FF0;
extern UNK_TYPE D_06009620;
diff --git a/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm_gfx.c b/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm_gfx.c
index e2a9ebef23..5e94690c61 100644
--- a/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm_gfx.c
+++ b/src/overlays/actors/ovl_Oceff_Storm/z_oceff_storm_gfx.c
@@ -1,7 +1,5 @@
#include "z_oceff_storm.h"
-
-extern u32 D_04032490[];
-extern u32 D_04032890[];
+#include "objects/gameplay_keep/gameplay_keep.h"
static u32 tex0[] = {
0x2F6E6F59, 0x6197B3CC, 0xC8AD8E6C, 0x5333170A, 0x17366173, 0x86ABC7C6, 0xA9928C7E, 0x55496341, 0x40705B59,
@@ -157,9 +155,9 @@ static Gfx sCylinderTexDl[] = {
gsDPPipeSync(),
gsDPSetTextureLUT(G_TT_NONE),
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
- gsDPLoadTextureBlock(D_04032490, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
+ gsDPLoadTextureBlock(gEffUnknown10Tex, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
G_TX_NOMIRROR | G_TX_NOMIRROR, 5, 5, 2, 13),
- gsDPLoadMultiBlock(D_04032890, 0x100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
+ gsDPLoadMultiBlock(gEffUnknown11Tex, 0x100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
G_TX_NOMIRROR | G_TX_NOMIRROR, 5, 5, 1, 12),
gsDPSetCombineLERP(TEXEL1, TEXEL0, ENV_ALPHA, TEXEL0, TEXEL1, TEXEL0, ENVIRONMENT, TEXEL0, PRIMITIVE, ENVIRONMENT,
COMBINED, ENVIRONMENT, COMBINED, 0, SHADE, 0),
diff --git a/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c b/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c
index 94c337f432..933aa470c4 100644
--- a/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c
+++ b/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4.c
@@ -98,12 +98,12 @@ void OceffWipe4_Draw(Actor* thisx, GlobalContext* globalCtx) {
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
if (this->actor.params == OCEFF_WIPE4_UNUSED) {
- gSPDisplayList(POLY_XLU_DISP++, sTextureDL1);
+ gSPDisplayList(POLY_XLU_DISP++, sTexture1DL);
} else {
- gSPDisplayList(POLY_XLU_DISP++, sTextureDL0);
+ gSPDisplayList(POLY_XLU_DISP++, sTexture0DL);
}
- gSPDisplayList(POLY_XLU_DISP++, sTextureDL2);
+ gSPDisplayList(POLY_XLU_DISP++, sTexture2DL);
gSPDisplayList(POLY_XLU_DISP++, Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, scroll * 2, scroll * (-2), 32, 64, 1,
scroll * (-1), scroll, 32, 32));
gSPDisplayList(POLY_XLU_DISP++, sFrustrumDl);
diff --git a/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4_gfx.c b/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4_gfx.c
index dd7a1ef05c..f843987eee 100644
--- a/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4_gfx.c
+++ b/src/overlays/actors/ovl_Oceff_Wipe4/z_oceff_wipe4_gfx.c
@@ -1,6 +1,5 @@
#include "z_oceff_wipe4.h"
-
-extern u8 D_04032C90[];
+#include "objects/gameplay_keep/gameplay_keep.h"
static u32 tex0[] = {
0x00061507, 0x00000000, 0x295a2b08, 0x10030f03, 0x0d070006, 0x00031625, 0x3f230012, 0x79590000, 0x00102c2a,
@@ -76,29 +75,29 @@ static Vtx vertices[] = {
VTX(143, -46, 0, 410, 1024, 0xFF, 0xFF, 0xFF, 0x00), VTX(243, -176, 1000, 307, 0, 0xFF, 0xFF, 0xFF, 0xFF),
};
-static Gfx sTextureDL0[] = {
+static Gfx sTexture0DL[] = {
gsDPPipeSync(),
gsDPSetTextureLUT(G_TT_NONE),
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
- gsDPLoadMultiBlock(D_04032C90, 0x100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
+ gsDPLoadMultiBlock(gEffUnknown12Tex, 0x100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
G_TX_NOMIRROR | G_TX_NOMIRROR, 5, 5, 1, 15),
gsDPSetPrimColor(0x00, 0x00, 170, 255, 255, 255),
gsDPSetEnvColor(0, 150, 0, 128),
gsSPEndDisplayList(),
};
-static Gfx sTextureDL1[] = {
+static Gfx sTexture1DL[] = {
gsDPPipeSync(),
gsDPSetTextureLUT(G_TT_NONE),
gsSPTexture(0xFFFF, 0xFFFF, 0, G_TX_RENDERTILE, G_ON),
- gsDPLoadMultiBlock(D_04032C90, 0x100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
+ gsDPLoadMultiBlock(gEffUnknown12Tex, 0x100, 1, G_IM_FMT_I, G_IM_SIZ_8b, 32, 32, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
G_TX_NOMIRROR | G_TX_NOMIRROR, 5, 5, 1, 0),
gsDPSetPrimColor(0x00, 0x00, 255, 170, 255, 255),
gsDPSetEnvColor(120, 0, 100, 128),
gsSPEndDisplayList(),
};
-static Gfx sTextureDL2[] = {
+static Gfx sTexture2DL[] = {
gsDPPipeSync(),
gsDPLoadTextureBlock(tex0, G_IM_FMT_I, G_IM_SIZ_8b, 32, 64, 0, G_TX_NOMIRROR | G_TX_NOMIRROR,
G_TX_NOMIRROR | G_TX_NOMIRROR, 5, 6, 14, 1),
diff --git a/src/overlays/actors/ovl_player_actor/z_player.c b/src/overlays/actors/ovl_player_actor/z_player.c
index b2cfc50a48..1e0091d561 100644
--- a/src/overlays/actors/ovl_player_actor/z_player.c
+++ b/src/overlays/actors/ovl_player_actor/z_player.c
@@ -15,6 +15,7 @@
#include "overlays/actors/ovl_En_Elf/z_en_elf.h"
#include "overlays/actors/ovl_En_Horse/z_en_horse.h"
#include "overlays/effects/ovl_Effect_Ss_Fhg_Flash/z_eff_ss_fhg_flash.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define THIS ((Player*)thisx)
@@ -392,15 +393,15 @@ PlayerAgeProperties sAgeProperties[] = {
},
0,
0x80,
- 0x04002718,
- 0x04002720,
- 0x04002838,
- 0x04002E70,
- 0x04002E78,
- { 0x04002E80, 0x04002E88, 0x04002D90, 0x04002D98 },
- { 0x04002D70, 0x04002D78 },
- { 0x04002E50, 0x04002E58 },
- { 0x04002E68, 0x04002E60 },
+ &gPlayer132Anim,
+ &gPlayer133Anim,
+ &gPlayer168Anim,
+ &gPlayer367Anim,
+ &gPlayer368Anim,
+ { &gPlayer369Anim, &gPlayer370Anim, &gPlayer339Anim, &gPlayer340Anim },
+ { &gPlayer335Anim, &gPlayer336Anim },
+ { &gPlayer363Anim, &gPlayer364Anim },
+ { &gPlayer366Anim, &gPlayer365Anim },
},
{
40.0f,
@@ -443,15 +444,15 @@ PlayerAgeProperties sAgeProperties[] = {
},
0x20,
0,
- 0x04002318,
- 0x04002360,
- 0x040023A8,
- 0x040023E0,
- 0x040023E8,
- { 0x040023F0, 0x040023F8, 0x04002D90, 0x04002D98 },
- { 0x04002D70, 0x04002D78 },
- { 0x040023C0, 0x040023C8 },
- { 0x040023D8, 0x040023D0 },
+ &gPlayer4Anim,
+ &gPlayer13Anim,
+ &gPlayer22Anim,
+ &gPlayer29Anim,
+ &gPlayer30Anim,
+ { &gPlayer31Anim, &gPlayer32Anim, &gPlayer339Anim, &gPlayer340Anim },
+ { &gPlayer335Anim, &gPlayer336Anim },
+ { &gPlayer25Anim, &gPlayer26Anim },
+ { &gPlayer28Anim, &gPlayer27Anim },
},
};
@@ -611,197 +612,198 @@ GetItemEntry sGetItemTable[] = {
};
LinkAnimationHeader* D_80853914[] = {
- 0x04003240, 0x04003238, 0x04003238, 0x04002BE0, 0x04003240, 0x04003240,
+ &gPlayer489Anim, &gPlayer488Anim, &gPlayer488Anim, &gPlayer285Anim, &gPlayer489Anim, &gPlayer489Anim,
};
LinkAnimationHeader* D_8085392C[] = {
- 0x04003290, 0x04003268, 0x04003268, 0x04002BF8, 0x04003290, 0x04003290,
+ &gPlayer499Anim, &gPlayer494Anim, &gPlayer494Anim, &gPlayer288Anim, &gPlayer499Anim, &gPlayer499Anim,
};
LinkAnimationHeader* D_80853944[] = {
- 0x04003140, 0x04002B38, 0x04003138, 0x04002B40, 0x04003140, 0x04003140,
+ &gPlayer457Anim, &gPlayer264Anim, &gPlayer456Anim, &gPlayer265Anim, &gPlayer457Anim, &gPlayer457Anim,
};
LinkAnimationHeader* D_8085395C[] = {
- 0x04002E98, 0x040029E8, 0x04002E98, 0x040029F0, 0x04002E98, 0x04002E98,
+ &gPlayer372Anim, &gPlayer222Anim, &gPlayer372Anim, &gPlayer223Anim, &gPlayer372Anim, &gPlayer372Anim,
};
LinkAnimationHeader* D_80853974[] = {
- 0x04002FB0, 0x04002FA8, 0x04002FB0, 0x04002A40, 0x04002FB0, 0x04002FB0,
+ &gPlayer407Anim, &gPlayer406Anim, &gPlayer407Anim, &gPlayer233Anim, &gPlayer407Anim, &gPlayer407Anim,
};
LinkAnimationHeader* D_8085398C[] = {
- 0x04003220, 0x04002590, 0x04002590, 0x04002BC0, 0x04003220, 0x04003220,
+ &gPlayer485Anim, &gPlayer83Anim, &gPlayer83Anim, &gPlayer281Anim, &gPlayer485Anim, &gPlayer485Anim,
};
LinkAnimationHeader* D_808539A4[] = {
- 0x04003230, 0x040025D0, 0x040025D0, 0x04002BD0, 0x04003230, 0x04003230,
+ &gPlayer487Anim, &gPlayer91Anim, &gPlayer91Anim, &gPlayer283Anim, &gPlayer487Anim, &gPlayer487Anim,
};
LinkAnimationHeader* D_808539BC[] = {
- 0x04002BB0, 0x040031F8, 0x040031F8, 0x04002BB0, 0x04002BB0, 0x04002BB0,
+ &gPlayer279Anim, &gPlayer480Anim, &gPlayer480Anim, &gPlayer279Anim, &gPlayer279Anim, &gPlayer279Anim,
};
LinkAnimationHeader* D_808539D4[] = {
- 0x04003088, 0x04002A70, 0x04002A70, 0x04003088, 0x04003088, 0x04003088,
+ &gPlayer434Anim, &gPlayer239Anim, &gPlayer239Anim, &gPlayer434Anim, &gPlayer434Anim, &gPlayer434Anim,
};
LinkAnimationHeader* D_808539EC[] = {
- 0x04002750, 0x04002748, 0x04002748, 0x04002750, 0x04002750, 0x04002750,
+ &gPlayer139Anim, &gPlayer138Anim, &gPlayer138Anim, &gPlayer139Anim, &gPlayer139Anim, &gPlayer139Anim,
};
LinkAnimationHeader* D_80853A04[] = {
- 0x04002330, 0x04002330, 0x04002330, 0x04002330, 0x04002330, 0x04002330,
+ &gPlayer7Anim, &gPlayer7Anim, &gPlayer7Anim, &gPlayer7Anim, &gPlayer7Anim, &gPlayer7Anim,
};
LinkAnimationHeader* D_80853A1C[] = {
- 0x04002760, 0x04002758, 0x04002758, 0x04002760, 0x04002760, 0x04002760,
+ &gPlayer141Anim, &gPlayer140Anim, &gPlayer140Anim, &gPlayer141Anim, &gPlayer141Anim, &gPlayer141Anim,
};
LinkAnimationHeader* D_80853A34[] = {
- 0x04002338, 0x04002338, 0x04002338, 0x04002338, 0x04002338, 0x04002338,
+ &gPlayer8Anim, &gPlayer8Anim, &gPlayer8Anim, &gPlayer8Anim, &gPlayer8Anim, &gPlayer8Anim,
};
LinkAnimationHeader* D_80853A4C[] = {
- 0x04002E08, 0x04002E00, 0x04002E00, 0x04002E08, 0x04002E08, 0x04002E08,
+ &gPlayer354Anim, &gPlayer353Anim, &gPlayer353Anim, &gPlayer354Anim, &gPlayer354Anim, &gPlayer354Anim,
};
LinkAnimationHeader* D_80853A64[] = {
- 0x04003028, 0x04003020, 0x04003020, 0x04003028, 0x04003028, 0x04003028,
+ &gPlayer422Anim, &gPlayer421Anim, &gPlayer421Anim, &gPlayer422Anim, &gPlayer422Anim, &gPlayer422Anim,
};
LinkAnimationHeader* D_80853A7C[] = {
- 0x04003170, 0x04003168, 0x04003168, 0x04003170, 0x04003170, 0x04003170,
+ &gPlayer463Anim, &gPlayer462Anim, &gPlayer462Anim, &gPlayer463Anim, &gPlayer463Anim, &gPlayer463Anim,
};
LinkAnimationHeader* D_80853A94[] = {
- 0x04003038, 0x04003030, 0x04003030, 0x04002A68, 0x04003038, 0x04003038,
+ &gPlayer424Anim, &gPlayer423Anim, &gPlayer423Anim, &gPlayer238Anim, &gPlayer424Anim, &gPlayer424Anim,
};
LinkAnimationHeader* D_80853AAC[] = {
- 0x04002FC0, 0x04002FB8, 0x04002FB8, 0x04002FC8, 0x04002FC0, 0x04002FC0,
+ &gPlayer409Anim, &gPlayer408Anim, &gPlayer408Anim, &gPlayer410Anim, &gPlayer409Anim, &gPlayer409Anim,
};
LinkAnimationHeader* D_80853AC4[] = {
- 0x04003278, 0x04003270, 0x04003270, 0x04002BE8, 0x04003278, 0x04003278,
+ &gPlayer496Anim, &gPlayer495Anim, &gPlayer495Anim, &gPlayer286Anim, &gPlayer496Anim, &gPlayer496Anim,
};
LinkAnimationHeader* D_80853ADC[] = {
- 0x04003288, 0x04003280, 0x04003280, 0x04002BF0, 0x04003288, 0x04003288,
+ &gPlayer498Anim, &gPlayer497Anim, &gPlayer497Anim, &gPlayer287Anim, &gPlayer498Anim, &gPlayer498Anim,
};
LinkAnimationHeader* D_80853AF4[] = {
- 0x04002EB8, 0x04002EA0, 0x04002EA0, 0x04002EB8, 0x040026C8, 0x04002EB8,
+ &gPlayer376Anim, &gPlayer373Anim, &gPlayer373Anim, &gPlayer376Anim, &gPlayer122Anim, &gPlayer376Anim,
};
LinkAnimationHeader* D_80853B0C[] = {
- 0x04002ED8, 0x04002ED0, 0x04002ED0, 0x04002ED8, 0x040026D0, 0x04002ED8,
+ &gPlayer380Anim, &gPlayer379Anim, &gPlayer379Anim, &gPlayer380Anim, &gPlayer123Anim, &gPlayer380Anim,
};
LinkAnimationHeader* D_80853B24[] = {
- 0x04002EB0, 0x04002EA8, 0x04002EA8, 0x04002EB0, 0x04002EB0, 0x04002EB0,
+ &gPlayer375Anim, &gPlayer374Anim, &gPlayer374Anim, &gPlayer375Anim, &gPlayer375Anim, &gPlayer375Anim,
};
LinkAnimationHeader* D_80853B3C[] = {
- 0x04003190, 0x04003188, 0x04003188, 0x04002B68, 0x04003190, 0x04003190,
+ &gPlayer467Anim, &gPlayer466Anim, &gPlayer466Anim, &gPlayer270Anim, &gPlayer467Anim, &gPlayer467Anim,
};
LinkAnimationHeader* D_80853B54[] = {
- 0x04003178, 0x04002568, 0x04002568, 0x04002B58, 0x04003178, 0x04003178,
+ &gPlayer464Anim, &gPlayer78Anim, &gPlayer78Anim, &gPlayer268Anim, &gPlayer464Anim, &gPlayer464Anim,
};
LinkAnimationHeader* D_80853B6C[] = {
- 0x04003180, 0x04002570, 0x04002570, 0x04002B60, 0x04003180, 0x04003180,
+ &gPlayer465Anim, &gPlayer79Anim, &gPlayer79Anim, &gPlayer269Anim, &gPlayer465Anim, &gPlayer465Anim,
};
LinkAnimationHeader* D_80853B84[] = {
- 0x04002D60, 0x04002D58, 0x04002D58, 0x04002D60, 0x04002D60, 0x04002D60,
+ &gPlayer333Anim, &gPlayer332Anim, &gPlayer332Anim, &gPlayer333Anim, &gPlayer333Anim, &gPlayer333Anim,
};
LinkAnimationHeader* D_80853B9C[] = {
- 0x04002BB8, 0x04003218, 0x04003218, 0x04002BB8, 0x04002BB8, 0x04002BB8,
+ &gPlayer280Anim, &gPlayer484Anim, &gPlayer484Anim, &gPlayer280Anim, &gPlayer280Anim, &gPlayer280Anim,
};
LinkAnimationHeader* D_80853BB4[] = {
- 0x04002BC8, 0x04003228, 0x04003228, 0x04002BC8, 0x04002BC8, 0x04002BC8,
+ &gPlayer282Anim, &gPlayer486Anim, &gPlayer486Anim, &gPlayer282Anim, &gPlayer282Anim, &gPlayer282Anim,
};
LinkAnimationHeader* D_80853BCC[] = {
- 0x040031C8, 0x040031C0, 0x040031C0, 0x040031C8, 0x040031C8, 0x040031C8,
+ &gPlayer474Anim, &gPlayer473Anim, &gPlayer473Anim, &gPlayer474Anim, &gPlayer474Anim, &gPlayer474Anim,
};
LinkAnimationHeader* D_80853BE4[] = {
- 0x04003118, 0x04003110, 0x04003110, 0x04003118, 0x04003118, 0x04003118,
+ &gPlayer452Anim, &gPlayer451Anim, &gPlayer451Anim, &gPlayer452Anim, &gPlayer452Anim, &gPlayer452Anim,
};
LinkAnimationHeader* D_80853BFC[] = {
- 0x04002DE8, 0x04002DE8, 0x04002DE8, 0x04002DE8, 0x04002DE8, 0x04002DE8,
+ &gPlayer350Anim, &gPlayer350Anim, &gPlayer350Anim, &gPlayer350Anim, &gPlayer350Anim, &gPlayer350Anim,
};
LinkAnimationHeader* D_80853C14[] = {
- 0x04002E30, 0x04002E18, 0x04002E18, 0x04002E30, 0x04002E30, 0x04002E30,
+ &gPlayer359Anim, &gPlayer356Anim, &gPlayer356Anim, &gPlayer359Anim, &gPlayer359Anim, &gPlayer359Anim,
};
LinkAnimationHeader* D_80853C2C[] = {
- 0x04002E40, 0x04002E38, 0x04002E38, 0x04002E40, 0x04002E40, 0x04002E40,
+ &gPlayer361Anim, &gPlayer360Anim, &gPlayer360Anim, &gPlayer361Anim, &gPlayer361Anim, &gPlayer361Anim,
};
LinkAnimationHeader* D_80853C44[] = {
- 0x04002E28, 0x04002E20, 0x04002E20, 0x04002E28, 0x04002E28, 0x04002E28,
+ &gPlayer358Anim, &gPlayer357Anim, &gPlayer357Anim, &gPlayer358Anim, &gPlayer358Anim, &gPlayer358Anim,
};
LinkAnimationHeader* D_80853C5C[] = {
- 0x040030C8, 0x040030C0, 0x040030C0, 0x040030C8, 0x040030C8, 0x040030C8,
+ &gPlayer442Anim, &gPlayer441Anim, &gPlayer441Anim, &gPlayer442Anim, &gPlayer442Anim, &gPlayer442Anim,
};
LinkAnimationHeader* D_80853C74[] = {
- 0x040030D8, 0x040030D0, 0x040030D0, 0x040030D8, 0x040030D8, 0x040030D8,
+ &gPlayer444Anim, &gPlayer443Anim, &gPlayer443Anim, &gPlayer444Anim, &gPlayer444Anim, &gPlayer444Anim,
};
LinkAnimationHeader* D_80853C8C[] = {
- 0x040030B8, 0x040030B0, 0x040030B0, 0x040030B8, 0x040030B8, 0x040030B8,
+ &gPlayer440Anim, &gPlayer439Anim, &gPlayer439Anim, &gPlayer440Anim, &gPlayer440Anim, &gPlayer440Anim,
};
LinkAnimationHeader* D_80853CA4[] = {
- 0x04002F20, 0x04002F18, 0x04002F18, 0x04002F20, 0x04002F20, 0x04002F20,
+ &gPlayer389Anim, &gPlayer388Anim, &gPlayer388Anim, &gPlayer389Anim, &gPlayer389Anim, &gPlayer389Anim,
};
LinkAnimationHeader* D_80853CBC[] = {
- 0x04002FF0, 0x04002FE8, 0x04002FE8, 0x04002FF0, 0x04002FF0, 0x04002FF0,
+ &gPlayer415Anim, &gPlayer414Anim, &gPlayer414Anim, &gPlayer415Anim, &gPlayer415Anim, &gPlayer415Anim,
};
LinkAnimationHeader* D_80853CD4[] = {
- 0x04003010, 0x04003008, 0x04003008, 0x04003010, 0x04003010, 0x04003010,
+ &gPlayer419Anim, &gPlayer418Anim, &gPlayer418Anim, &gPlayer419Anim, &gPlayer419Anim, &gPlayer419Anim,
};
LinkAnimationHeader* D_80853CEC[] = {
- 0x04003000, 0x04002FF8, 0x04002FF8, 0x04003000, 0x04003000, 0x04003000,
+ &gPlayer417Anim, &gPlayer416Anim, &gPlayer416Anim, &gPlayer417Anim, &gPlayer417Anim, &gPlayer417Anim,
};
LinkAnimationHeader* D_80853D04[] = {
- 0x04002EF0, 0x04002EE8, 0x04002EE8, 0x04002EF8, 0x04002EF0, 0x04002EF0,
+ &gPlayer383Anim, &gPlayer382Anim, &gPlayer382Anim, &gPlayer384Anim, &gPlayer383Anim, &gPlayer383Anim,
};
LinkAnimationHeader* D_80853D1C[] = {
- 0x040031E0, 0x040031D8, 0x040031D8, 0x040031E8, 0x040031E0, 0x040031E0,
+ &gPlayer477Anim, &gPlayer476Anim, &gPlayer476Anim, &gPlayer478Anim, &gPlayer477Anim, &gPlayer477Anim,
};
LinkAnimationHeader* D_80853D34[] = {
- 0x04003468, 0x04003438, 0x04003438, 0x04003468, 0x04003468, 0x04003468,
+ &gPlayer558Anim, &gPlayer552Anim, &gPlayer552Anim, &gPlayer558Anim, &gPlayer558Anim, &gPlayer558Anim,
};
LinkAnimationHeader* D_80853D4C[][3] = {
- { 0x04002A28, 0x04002A38, 0x04002A30 },
- { 0x04002950, 0x04002960, 0x04002958 },
- { 0x040029D0, 0x040029E0, 0x040029D8 },
- { 0x04002988, 0x04002998, 0x04002990 },
+ { &gPlayer230Anim, &gPlayer232Anim, &gPlayer231Anim },
+ { &gPlayer203Anim, &gPlayer205Anim, &gPlayer204Anim },
+ { &gPlayer219Anim, &gPlayer221Anim, &gPlayer220Anim },
+ { &gPlayer210Anim, &gPlayer212Anim, &gPlayer211Anim },
};
LinkAnimationHeader* D_80853D7C[][2] = {
- { 0x04003248, 0x04003200 }, { 0x04003258, 0x04003210 }, { 0x04003250, 0x04003208 }, { 0x04003250, 0x04003208 },
- { 0x04003430, 0x040033F0 }, { 0x04003430, 0x040033F0 }, { 0x04003430, 0x040033F0 }, { 0x040033F8, 0x040033D0 },
- { 0x04003400, 0x040033D8 }, { 0x04003420, 0x04003420 }, { 0x04003408, 0x040033E0 }, { 0x04003410, 0x040033E8 },
- { 0x04003418, 0x04003418 }, { 0x04003428, 0x04003428 },
+ { &gPlayer490Anim, &gPlayer481Anim }, { &gPlayer492Anim, &gPlayer483Anim }, { &gPlayer491Anim, &gPlayer482Anim },
+ { &gPlayer491Anim, &gPlayer482Anim }, { &gPlayer551Anim, &gPlayer543Anim }, { &gPlayer551Anim, &gPlayer543Anim },
+ { &gPlayer551Anim, &gPlayer543Anim }, { &gPlayer544Anim, &gPlayer539Anim }, { &gPlayer545Anim, &gPlayer540Anim },
+ { &gPlayer549Anim, &gPlayer549Anim }, { &gPlayer546Anim, &gPlayer541Anim }, { &gPlayer547Anim, &gPlayer542Anim },
+ { &gPlayer548Anim, &gPlayer548Anim }, { &gPlayer550Anim, &gPlayer550Anim },
};
struct_80832924 D_80853DEC[] = {
@@ -953,9 +955,10 @@ void (*D_80853FE8[])(GlobalContext* globalCtx, Player* this) = {
};
struct_808540F4 D_808540F4[] = {
- { 0x04002F50, 12 }, { 0x04003080, 6 }, { 0x04002C68, 8 }, { 0x04003090, 8 }, { 0x04002A20, 8 },
- { 0x04002F30, 10 }, { 0x04002C58, 7 }, { 0x04002C60, 11 }, { 0x04002F50, 12 }, { 0x04003078, 4 },
- { 0x04003058, 4 }, { 0x04002F38, 4 }, { 0x040024E0, 5 }, { 0x04002F48, 13 },
+ { &gPlayer395Anim, 12 }, { &gPlayer433Anim, 6 }, { &gPlayer302Anim, 8 }, { &gPlayer435Anim, 8 },
+ { &gPlayer229Anim, 8 }, { &gPlayer391Anim, 10 }, { &gPlayer300Anim, 7 }, { &gPlayer301Anim, 11 },
+ { &gPlayer395Anim, 12 }, { &gPlayer432Anim, 4 }, { &gPlayer428Anim, 4 }, { &gPlayer392Anim, 4 },
+ { &gPlayer61Anim, 5 }, { &gPlayer394Anim, 13 },
};
s8 D_80854164[][6] = {
@@ -969,50 +972,64 @@ ExplosiveInfo sExplosiveInfos[] = {
};
struct_80854190 D_80854190[] = {
- { 0x04002A80, 0x04002A90, 0x04002A88, 1, 4 }, { 0x040028C0, 0x040028C8, 0x04002498, 1, 4 },
- { 0x04002A98, 0x04002AA0, 0x04002540, 0, 5 }, { 0x040028D0, 0x040028D8, 0x040024A0, 1, 7 },
- { 0x04002968, 0x04002970, 0x040024C0, 1, 4 }, { 0x04002880, 0x04002888, 0x04002478, 0, 5 },
- { 0x04002978, 0x04002980, 0x040024C8, 2, 8 }, { 0x04002890, 0x04002898, 0x04002480, 3, 8 },
- { 0x040029A0, 0x040029A8, 0x040024D0, 0, 4 }, { 0x040028A0, 0x040028A8, 0x04002488, 0, 5 },
- { 0x040029B0, 0x040029B8, 0x040024D8, 0, 6 }, { 0x040028B0, 0x040028B8, 0x04002490, 1, 5 },
- { 0x04002AA8, 0x04002AB0, 0x04002548, 0, 3 }, { 0x040028E0, 0x040028E8, 0x040024A8, 0, 3 },
- { 0x04002AB8, 0x04002AC0, 0x04002550, 1, 9 }, { 0x040028F0, 0x040028F8, 0x040024B0, 1, 8 },
- { 0x04002A60, 0x04002A50, 0x04002A50, 1, 10 }, { 0x04002900, 0x04002910, 0x04002910, 1, 11 },
- { 0x04002A50, 0x04002A58, 0x04002A58, 1, 2 }, { 0x04002910, 0x04002908, 0x04002908, 1, 2 },
- { 0x04002B80, 0x04002B88, 0x04002B88, 1, 5 }, { 0x04002B70, 0x04002B78, 0x04002B78, 1, 4 },
- { 0x04002C40, 0x04002C50, 0x04002C48, 3, 10 }, { 0x04002C70, 0x04002C80, 0x04002C78, 2, 11 },
- { 0x04002B28, 0x04002B30, 0x04002560, 0, 12 }, { 0x04002940, 0x04002948, 0x040024B8, 0, 15 },
- { 0x040029C0, 0x040029C8, 0x04002560, 0, 16 }, { 0x040029C0, 0x040029C8, 0x040024B8, 0, 16 },
+ { &gPlayer241Anim, &gPlayer243Anim, &gPlayer242Anim, 1, 4 },
+ { &gPlayer185Anim, &gPlayer186Anim, &gPlayer52Anim, 1, 4 },
+ { &gPlayer244Anim, &gPlayer245Anim, &gPlayer73Anim, 0, 5 },
+ { &gPlayer187Anim, &gPlayer188Anim, &gPlayer53Anim, 1, 7 },
+ { &gPlayer206Anim, &gPlayer207Anim, &gPlayer57Anim, 1, 4 },
+ { &gPlayer177Anim, &gPlayer178Anim, &gPlayer48Anim, 0, 5 },
+ { &gPlayer208Anim, &gPlayer209Anim, &gPlayer58Anim, 2, 8 },
+ { &gPlayer179Anim, &gPlayer180Anim, &gPlayer49Anim, 3, 8 },
+ { &gPlayer213Anim, &gPlayer214Anim, &gPlayer59Anim, 0, 4 },
+ { &gPlayer181Anim, &gPlayer182Anim, &gPlayer50Anim, 0, 5 },
+ { &gPlayer215Anim, &gPlayer216Anim, &gPlayer60Anim, 0, 6 },
+ { &gPlayer183Anim, &gPlayer184Anim, &gPlayer51Anim, 1, 5 },
+ { &gPlayer246Anim, &gPlayer247Anim, &gPlayer74Anim, 0, 3 },
+ { &gPlayer189Anim, &gPlayer190Anim, &gPlayer54Anim, 0, 3 },
+ { &gPlayer248Anim, &gPlayer249Anim, &gPlayer75Anim, 1, 9 },
+ { &gPlayer191Anim, &gPlayer192Anim, &gPlayer55Anim, 1, 8 },
+ { &gPlayer237Anim, &gPlayer235Anim, &gPlayer235Anim, 1, 10 },
+ { &gPlayer193Anim, &gPlayer195Anim, &gPlayer195Anim, 1, 11 },
+ { &gPlayer235Anim, &gPlayer236Anim, &gPlayer236Anim, 1, 2 },
+ { &gPlayer195Anim, &gPlayer194Anim, &gPlayer194Anim, 1, 2 },
+ { &gPlayer273Anim, &gPlayer274Anim, &gPlayer274Anim, 1, 5 },
+ { &gPlayer271Anim, &gPlayer272Anim, &gPlayer272Anim, 1, 4 },
+ { &gPlayer297Anim, &gPlayer299Anim, &gPlayer298Anim, 3, 10 },
+ { &gPlayer303Anim, &gPlayer305Anim, &gPlayer304Anim, 2, 11 },
+ { &gPlayer262Anim, &gPlayer263Anim, &gPlayer77Anim, 0, 12 },
+ { &gPlayer201Anim, &gPlayer202Anim, &gPlayer56Anim, 0, 15 },
+ { &gPlayer217Anim, &gPlayer218Anim, &gPlayer77Anim, 0, 16 },
+ { &gPlayer217Anim, &gPlayer218Anim, &gPlayer56Anim, 0, 16 },
};
LinkAnimationHeader* D_80854350[] = {
- 0x04002AE8,
- 0x04002920,
+ &gPlayer254Anim,
+ &gPlayer197Anim,
};
LinkAnimationHeader* D_80854358[] = {
- 0x04002AE0,
- 0x04002920,
+ &gPlayer253Anim,
+ &gPlayer197Anim,
};
LinkAnimationHeader* D_80854360[] = {
- 0x04002AF0,
- 0x04002928,
+ &gPlayer255Anim,
+ &gPlayer198Anim,
};
LinkAnimationHeader* D_80854368[] = {
- 0x04002AF8,
- 0x04002930,
+ &gPlayer256Anim,
+ &gPlayer199Anim,
};
LinkAnimationHeader* D_80854370[] = {
- 0x04002B00,
- 0x04002938,
+ &gPlayer257Anim,
+ &gPlayer200Anim,
};
LinkAnimationHeader* D_80854378[] = {
- 0x04002AD8,
- 0x04002918,
+ &gPlayer252Anim,
+ &gPlayer196Anim,
};
u8 D_80854380[2] = { 0x18, 0x19 };
@@ -1027,175 +1044,40 @@ u16 D_80854398[] = { NA_SE_IT_BOW_DRAW, NA_SE_IT_SLING_DRAW, NA_SE_IT_HOOKSHOT_R
u8 sMagicArrowCosts[] = { 4, 4, 8 };
LinkAnimationHeader* D_808543A4[] = {
- 0x040025C0,
- 0x040025C8,
+ &gPlayer89Anim,
+ &gPlayer90Anim,
};
LinkAnimationHeader* D_808543AC[] = {
- 0x04002580,
- 0x04002588,
+ &gPlayer81Anim,
+ &gPlayer82Anim,
};
LinkAnimationHeader* D_808543B4[] = {
- 0x04002510,
- 0x04002518,
+ &gPlayer67Anim,
+ &gPlayer68Anim,
};
LinkAnimationHeader* D_808543BC[] = {
- 0x04002510,
- 0x04002520,
+ &gPlayer67Anim,
+ &gPlayer69Anim,
};
LinkAnimationHeader* D_808543C4[] = {
- 0x04002EC0,
- 0x04002A08,
+ &gPlayer377Anim,
+ &gPlayer226Anim,
};
LinkAnimationHeader* D_808543CC[] = {
- 0x040026F0,
- 0x04002CC8,
+ &gPlayer127Anim,
+ &gPlayer314Anim,
};
LinkAnimationHeader* D_808543D4[] = {
- 0x040026C0,
- 0x04002CC0,
+ &gPlayer121Anim,
+ &gPlayer313Anim,
};
-// external segments
-extern LinkAnimationHeader D_04002340;
-extern LinkAnimationHeader D_04002378;
-extern LinkAnimationHeader D_04002400;
-extern LinkAnimationHeader D_04002408;
-extern LinkAnimationHeader D_04002420;
-extern LinkAnimationHeader D_04002428;
-extern LinkAnimationHeader D_04002430;
-extern LinkAnimationHeader D_04002468;
-extern LinkAnimationHeader D_040024E8;
-extern LinkAnimationHeader D_040024F8;
-extern LinkAnimationHeader D_04002538;
-extern LinkAnimationHeader D_040025F8;
-extern LinkAnimationHeader D_04002600;
-extern LinkAnimationHeader D_04002608;
-extern LinkAnimationHeader D_04002618;
-extern LinkAnimationHeader D_04002620;
-extern LinkAnimationHeader D_04002628;
-extern LinkAnimationHeader D_04002630;
-extern LinkAnimationHeader D_04002638;
-extern LinkAnimationHeader D_04002650;
-extern LinkAnimationHeader D_04002660;
-extern LinkAnimationHeader D_04002668;
-extern LinkAnimationHeader D_04002670;
-extern LinkAnimationHeader D_04002688;
-extern LinkAnimationHeader D_04002698;
-extern LinkAnimationHeader D_040026A0;
-extern LinkAnimationHeader D_040026B0;
-extern LinkAnimationHeader D_040026B8;
-extern LinkAnimationHeader D_040026E8;
-extern LinkAnimationHeader D_04002700;
-extern LinkAnimationHeader D_04002708;
-extern LinkAnimationHeader D_04002770;
-extern LinkAnimationHeader D_04002780;
-extern LinkAnimationHeader D_04002788;
-extern LinkAnimationHeader D_040027D0;
-extern LinkAnimationHeader D_04002830;
-extern LinkAnimationHeader D_04002838;
-extern LinkAnimationHeader D_04002860;
-extern LinkAnimationHeader D_04002878;
-extern LinkAnimationHeader D_04002908;
-extern LinkAnimationHeader D_04002AC8;
-extern LinkAnimationHeader D_04002C00;
-extern LinkAnimationHeader D_04002C08;
-extern LinkAnimationHeader D_04002C10;
-extern LinkAnimationHeader D_04002C18;
-extern LinkAnimationHeader D_04002C20;
-extern LinkAnimationHeader D_04002C28;
-extern LinkAnimationHeader D_04002C30;
-extern LinkAnimationHeader D_04002C38;
-extern LinkAnimationHeader D_04002C90;
-extern LinkAnimationHeader D_04002C98;
-extern LinkAnimationHeader D_04002CA0;
-extern LinkAnimationHeader D_04002D28;
-extern LinkAnimationHeader D_04002D38;
-extern LinkAnimationHeader D_04002D40;
-extern LinkAnimationHeader D_04002D48;
-extern LinkAnimationHeader D_04002D68;
-extern LinkAnimationHeader D_04002D80;
-extern LinkAnimationHeader D_04002D88;
-extern LinkAnimationHeader D_04002DA0;
-extern LinkAnimationHeader D_04002DA8;
-extern LinkAnimationHeader D_04002DB0;
-extern LinkAnimationHeader D_04002DB8;
-extern LinkAnimationHeader D_04002DC0;
-extern LinkAnimationHeader D_04002DD0;
-extern LinkAnimationHeader D_04002DF0;
-extern LinkAnimationHeader D_04002DF8;
-extern LinkAnimationHeader D_04002E10;
-extern LinkAnimationHeader D_04002E48;
-extern LinkAnimationHeader D_04002E90;
-extern LinkAnimationHeader D_04002EC8;
-extern LinkAnimationHeader D_04002F00;
-extern LinkAnimationHeader D_04002F08;
-extern LinkAnimationHeader D_04002F10;
-extern LinkAnimationHeader D_04002F28;
-extern LinkAnimationHeader D_04002F30;
-extern LinkAnimationHeader D_04002F40;
-extern LinkAnimationHeader D_04002F58;
-extern LinkAnimationHeader D_04002F60;
-extern LinkAnimationHeader D_04002F68;
-extern LinkAnimationHeader D_04002F98;
-extern LinkAnimationHeader D_04002FA0;
-extern LinkAnimationHeader D_04002FD0;
-extern LinkAnimationHeader D_04002FE0;
-extern LinkAnimationHeader D_04003000;
-extern LinkAnimationHeader D_04003020;
-extern LinkAnimationHeader D_04003040;
-extern LinkAnimationHeader D_04003048;
-extern LinkAnimationHeader D_04003050;
-extern LinkAnimationHeader D_04003060;
-extern LinkAnimationHeader D_04003068;
-extern LinkAnimationHeader D_04003070;
-extern LinkAnimationHeader D_04003098;
-extern LinkAnimationHeader D_040030A0;
-extern LinkAnimationHeader D_040030A8;
-extern LinkAnimationHeader D_040030E0;
-extern LinkAnimationHeader D_040030F0;
-extern LinkAnimationHeader D_040030F8;
-extern LinkAnimationHeader D_04003100;
-extern LinkAnimationHeader D_04003108;
-extern LinkAnimationHeader D_04003120;
-extern LinkAnimationHeader D_04003128;
-extern LinkAnimationHeader D_04003148;
-extern LinkAnimationHeader D_04003150;
-extern LinkAnimationHeader D_04003158;
-extern LinkAnimationHeader D_04003160;
-extern LinkAnimationHeader D_040031A0;
-extern LinkAnimationHeader D_040031A8;
-extern LinkAnimationHeader D_04003298;
-extern LinkAnimationHeader D_040032B0;
-extern LinkAnimationHeader D_040032B8;
-extern LinkAnimationHeader D_040032C0;
-extern LinkAnimationHeader D_040032C8;
-extern LinkAnimationHeader D_040032D0;
-extern LinkAnimationHeader D_040032D8;
-extern LinkAnimationHeader D_040032E0;
-extern LinkAnimationHeader D_040032E8;
-extern LinkAnimationHeader D_040032F0;
-extern LinkAnimationHeader D_04003300;
-extern LinkAnimationHeader D_04003308;
-extern LinkAnimationHeader D_04003310;
-extern LinkAnimationHeader D_04003318;
-extern LinkAnimationHeader D_04003320;
-extern LinkAnimationHeader D_04003328;
-extern LinkAnimationHeader D_04003330;
-extern LinkAnimationHeader D_04003380;
-extern LinkAnimationHeader D_04003390;
-extern LinkAnimationHeader D_040033A0;
-extern LinkAnimationHeader D_040033B0;
-extern LinkAnimationHeader D_040033B8;
-extern LinkAnimationHeader D_040033C8;
-extern Gfx D_04037E30[];
-extern Gfx D_04033EE0[];
-
// return type can't be void due to regalloc in func_8084FCAC
s32 func_80832210(Player* this) {
this->actor.speedXZ = 0.0f;
@@ -1671,7 +1553,7 @@ s32 func_808334B4(Player* this) {
LinkAnimationHeader* func_808334E4(Player* this) {
if (func_808334B4(this)) {
- return &D_04002638;
+ return &gPlayer104Anim;
} else {
return D_808539A4[this->modelAnimType];
}
@@ -1679,7 +1561,7 @@ LinkAnimationHeader* func_808334E4(Player* this) {
LinkAnimationHeader* func_80833528(Player* this) {
if (func_808334B4(this)) {
- return &D_04002630;
+ return &gPlayer103Anim;
} else {
return D_8085398C[this->modelAnimType];
}
@@ -1687,7 +1569,7 @@ LinkAnimationHeader* func_80833528(Player* this) {
LinkAnimationHeader* func_8083356C(Player* this) {
if (func_8002DD78(this)) {
- return &D_040026E8;
+ return &gPlayer126Anim;
} else {
return D_80853B3C[this->modelAnimType];
}
@@ -1695,7 +1577,7 @@ LinkAnimationHeader* func_8083356C(Player* this) {
LinkAnimationHeader* func_808335B0(Player* this) {
if (func_808334B4(this)) {
- return &D_04002620;
+ return &gPlayer101Anim;
} else {
return D_80853B6C[this->modelAnimType];
}
@@ -1703,7 +1585,7 @@ LinkAnimationHeader* func_808335B0(Player* this) {
LinkAnimationHeader* func_808335F4(Player* this) {
if (func_808334B4(this)) {
- return &D_04002618;
+ return &gPlayer100Anim;
} else {
return D_80853B54[this->modelAnimType];
}
@@ -2004,8 +1886,8 @@ void func_808340DC(Player* this, GlobalContext* globalCtx) {
this->unk_15A = ABS(sp38);
anim = D_808540F4[this->unk_15A].anim;
- if ((anim == &D_04002F30) && (this->currentShield == PLAYER_SHIELD_NONE)) {
- anim = &D_04002F40;
+ if ((anim == &gPlayer391Anim) && (this->currentShield == PLAYER_SHIELD_NONE)) {
+ anim = &gPlayer393Anim;
}
phi_f2 = Animation_GetLastFrame(anim);
@@ -2290,19 +2172,19 @@ s32 func_80834D2C(Player* this, GlobalContext* globalCtx) {
}
if (!Player_HoldsHookshot(this)) {
- anim = &D_040026A0;
+ anim = &gPlayer117Anim;
} else {
- anim = &D_04002CA0;
+ anim = &gPlayer309Anim;
}
LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, anim);
} else {
func_80833638(this, func_80835884);
this->unk_834 = 10;
- LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &D_04002628);
+ LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &gPlayer102Anim);
}
if (this->stateFlags1 & 0x800000) {
- func_80832284(globalCtx, this, &D_04003380);
+ func_80832284(globalCtx, this, &gPlayer529Anim);
} else if ((this->actor.bgCheckFlags & 1) && !func_80833B54(this)) {
func_80832284(globalCtx, this, D_80853914[this->modelAnimType]);
}
@@ -2420,7 +2302,7 @@ s32 func_808351D4(Player* this, GlobalContext* globalCtx) {
Math_ScaledStepToS(&this->unk_6C0, 1200, 400);
this->unk_6AE |= 0x100;
- if ((this->unk_836 == 0) && (func_80833350(this) == 0) && (this->skelAnime.animation == &D_040026E8)) {
+ if ((this->unk_836 == 0) && (func_80833350(this) == 0) && (this->skelAnime.animation == &gPlayer126Anim)) {
LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, D_808543CC[sp2C]);
this->unk_836 = -1;
} else if (LinkAnimation_Update(globalCtx, &this->skelAnime2)) {
@@ -2471,7 +2353,7 @@ s32 func_808353D8(Player* this, GlobalContext* globalCtx) {
if (Player_HoldsHookshot(this)) {
this->unk_836 = 1;
} else {
- LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &D_040026B8);
+ LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &gPlayer120Anim);
}
}
} else {
@@ -2490,7 +2372,7 @@ s32 func_808353D8(Player* this, GlobalContext* globalCtx) {
func_80833638(this, func_8083501C);
} else {
func_80833638(this, func_80835588);
- LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &D_040026B0);
+ LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &gPlayer119Anim);
}
this->unk_834 = 0;
@@ -2530,7 +2412,7 @@ s32 func_80835644(GlobalContext* globalCtx, Player* this, Actor* arg2) {
void func_80835688(Player* this, GlobalContext* globalCtx) {
if (!func_80835644(globalCtx, this, this->heldActor)) {
func_80833638(this, func_808356E8);
- LinkAnimation_PlayLoop(globalCtx, &this->skelAnime2, &D_04002E10);
+ LinkAnimation_PlayLoop(globalCtx, &this->skelAnime2, &gPlayer355Anim);
}
}
@@ -2547,7 +2429,7 @@ s32 func_808356E8(Player* this, GlobalContext* globalCtx) {
if (this->stateFlags1 & 0x800) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime2)) {
- LinkAnimation_PlayLoop(globalCtx, &this->skelAnime2, &D_04002E10);
+ LinkAnimation_PlayLoop(globalCtx, &this->skelAnime2, &gPlayer355Anim);
}
if ((heldActor->id == ACTOR_EN_NIW) && (this->actor.velocity.y <= 0.0f)) {
@@ -2583,7 +2465,7 @@ s32 func_80835800(Player* this, GlobalContext* globalCtx) {
s32 func_80835884(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime2)) {
func_80833638(this, func_808358F0);
- LinkAnimation_PlayLoop(globalCtx, &this->skelAnime2, &D_04002638);
+ LinkAnimation_PlayLoop(globalCtx, &this->skelAnime2, &gPlayer104Anim);
}
func_80834EB8(this, globalCtx);
@@ -2606,7 +2488,7 @@ s32 func_808358F0(Player* this, GlobalContext* globalCtx) {
if (!D_80853618) {
func_80833638(this, func_808359FC);
- LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, (this->unk_870 < 0.5f) ? &D_04002608 : &D_04002600);
+ LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, (this->unk_870 < 0.5f) ? &gPlayer98Anim : &gPlayer97Anim);
}
return 1;
@@ -2648,7 +2530,7 @@ s32 func_80835B60(Player* this, GlobalContext* globalCtx) {
if (!(this->stateFlags1 & 0x2000000)) {
func_80833638(this, func_80835C08);
- LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &D_040025F8);
+ LinkAnimation_PlayOnce(globalCtx, &this->skelAnime2, &gPlayer96Anim);
func_808357E8(this, D_80125EF8);
func_8002F7DC(&this->actor, NA_SE_PL_CATCH_BOOMERANG);
func_80832698(this, NA_SE_VO_LI_SWORD_N);
@@ -2864,7 +2746,7 @@ void func_80836448(GlobalContext* globalCtx, Player* this, LinkAnimationHeader*
this->stateFlags1 |= 0x80;
func_80832264(globalCtx, this, anim);
- if (anim == &D_04002878) {
+ if (anim == &gPlayer176Anim) {
this->skelAnime.endFrame = 84.0f;
}
@@ -2902,7 +2784,7 @@ s32 func_80836670(Player* this, GlobalContext* globalCtx) {
if (!(this->stateFlags1 & 0x800000) && (this->actor.parent != NULL) && Player_HoldsHookshot(this)) {
func_80835C58(globalCtx, this, func_80850AEC, 1);
this->stateFlags3 |= 0x80;
- func_80832264(globalCtx, this, &D_04002C90);
+ func_80832264(globalCtx, this, &gPlayer307Anim);
func_80832F54(globalCtx, this, 0x9B);
func_80832224(this);
this->currentYaw = this->actor.shape.rot.y;
@@ -3458,7 +3340,7 @@ void func_80837B60(Player* this) {
void func_80837B9C(Player* this, GlobalContext* globalCtx) {
func_80835C58(globalCtx, this, func_8084411C, 0);
- func_80832284(globalCtx, this, &D_04003040);
+ func_80832284(globalCtx, this, &gPlayer425Anim);
this->unk_850 = 1;
if (this->unk_6AD != 3) {
this->unk_6AD = 0;
@@ -3466,7 +3348,8 @@ void func_80837B9C(Player* this, GlobalContext* globalCtx) {
}
LinkAnimationHeader* D_808544B0[] = {
- 0x04002F80, 0x04002F78, 0x04002DE0, 0x04002DD8, 0x04002F70, 0x04002528, 0x04002DC8, 0x040024F0,
+ &gPlayer401Anim, &gPlayer400Anim, &gPlayer349Anim, &gPlayer348Anim,
+ &gPlayer399Anim, &gPlayer70Anim, &gPlayer346Anim, &gPlayer63Anim,
};
void func_80837C0C(GlobalContext* globalCtx, Player* this, s32 arg2, f32 arg3, f32 arg4, s16 arg5, s32 arg6) {
@@ -3494,7 +3377,7 @@ void func_80837C0C(GlobalContext* globalCtx, Player* this, s32 arg2, f32 arg3, f
if (arg2 == 3) {
func_80835C58(globalCtx, this, func_8084FB10, 0);
- sp2C = &D_04002FD0;
+ sp2C = &gPlayer411Anim;
func_80832224(this);
func_8083264C(this, 255, 10, 40, 0);
@@ -3506,7 +3389,7 @@ void func_80837C0C(GlobalContext* globalCtx, Player* this, s32 arg2, f32 arg3, f
func_8083264C(this, 255, 80, 150, 0);
- func_808322A4(globalCtx, this, &D_04002F00);
+ func_808322A4(globalCtx, this, &gPlayer385Anim);
func_80832224(this);
this->unk_850 = 20;
@@ -3519,7 +3402,7 @@ void func_80837C0C(GlobalContext* globalCtx, Player* this, s32 arg2, f32 arg3, f
this->linearVelocity = 4.0f;
this->actor.velocity.y = 0.0f;
- sp2C = &D_04003320;
+ sp2C = &gPlayer517Anim;
func_80832698(this, NA_SE_VO_LI_DAMAGE_S);
} else if ((arg2 == 1) || (arg2 == 2) || !(this->actor.bgCheckFlags & 1) || (this->stateFlags1 & 0x206000)) {
@@ -3545,9 +3428,9 @@ void func_80837C0C(GlobalContext* globalCtx, Player* this, s32 arg2, f32 arg3, f
this->actor.velocity.y = arg4;
if (ABS(arg5) > 0x4000) {
- sp2C = &D_04002F58;
+ sp2C = &gPlayer396Anim;
} else {
- sp2C = &D_04002DB0;
+ sp2C = &gPlayer343Anim;
}
if ((this->actor.category != ACTORCAT_PLAYER) && (this->actor.colChkInfo.health == 0)) {
@@ -3880,7 +3763,7 @@ s32 func_80838A14(Player* this, GlobalContext* globalCtx) {
sp34 = this->wallHeight;
if (this->ageProperties->unk_14 <= sp34) {
- sp38 = &D_04002D48;
+ sp38 = &gPlayer330Anim;
this->linearVelocity = 1.0f;
} else {
sp2C = COLPOLY_GET_NORMAL(this->actor.wallPoly->normal.x);
@@ -3890,14 +3773,14 @@ s32 func_80838A14(Player* this, GlobalContext* globalCtx) {
this->stateFlags1 |= 0x4000;
if (func_808332B8(this)) {
- sp38 = &D_040032E8;
+ sp38 = &gPlayer510Anim;
sp34 -= (60.0f * this->ageProperties->unk_08);
this->stateFlags1 &= ~0x8000000;
} else if (this->ageProperties->unk_18 <= sp34) {
- sp38 = &D_04002D40;
+ sp38 = &gPlayer329Anim;
sp34 -= (59.0f * this->ageProperties->unk_08);
} else {
- sp38 = &D_04002D38;
+ sp38 = &gPlayer328Anim;
sp34 -= (41.0f * this->ageProperties->unk_08);
}
@@ -3921,7 +3804,7 @@ s32 func_80838A14(Player* this, GlobalContext* globalCtx) {
}
} else if ((this->actor.bgCheckFlags & 1) && (this->unk_88C == 1) && (this->unk_88D >= 3)) {
temp = (this->wallHeight * 0.08f) + 5.5f;
- func_808389E8(this, &D_04002FE0, temp, globalCtx);
+ func_808389E8(this, &gPlayer413Anim, temp, globalCtx);
this->linearVelocity = 2.5f;
return 1;
@@ -3945,7 +3828,7 @@ void func_80838E70(GlobalContext* globalCtx, Player* this, f32 arg2, s16 arg3) {
void func_80838F18(GlobalContext* globalCtx, Player* this) {
func_80835C58(globalCtx, this, func_8084D610, 0);
- func_80832C6C(globalCtx, this, &D_04003328);
+ func_80832C6C(globalCtx, this, &gPlayer518Anim);
}
void func_80838F5C(GlobalContext* globalCtx, Player* this) {
@@ -3959,7 +3842,7 @@ void func_80838F5C(GlobalContext* globalCtx, Player* this) {
s32 func_80838FB8(GlobalContext* globalCtx, Player* this) {
if ((globalCtx->sceneLoadFlag == 0) && (this->stateFlags1 & 0x80000000)) {
func_80838F5C(globalCtx, this);
- func_80832284(globalCtx, this, &D_04003040);
+ func_80832284(globalCtx, this, &gPlayer425Anim);
func_80832698(this, NA_SE_VO_LI_FALL_S);
func_800788CC(NA_SE_OC_SECRET_WARP_IN);
return 1;
@@ -4386,10 +4269,10 @@ void func_8083A0F4(GlobalContext* globalCtx, Player* this) {
if (interactActorId == ACTOR_BG_HEAVY_BLOCK) {
func_80835C58(globalCtx, this, func_80846120, 0);
this->stateFlags1 |= 0x20000000;
- anim = &D_04002F98;
+ anim = &gPlayer404Anim;
} else if ((interactActorId == ACTOR_EN_ISHI) && ((interactRangeActor->params & 0xF) == 1)) {
func_80835C58(globalCtx, this, func_80846260, 0);
- anim = &D_040032B0;
+ anim = &gPlayer503Anim;
} else if (((interactActorId == ACTOR_EN_BOMBF) || (interactActorId == ACTOR_EN_KUSA)) &&
(Player_GetStrength() <= PLAYER_STR_NONE)) {
func_80835C58(globalCtx, this, func_80846408, 0);
@@ -4398,7 +4281,7 @@ void func_8083A0F4(GlobalContext* globalCtx, Player* this) {
this->actor.world.pos.z =
(Math_CosS(interactRangeActor->yawTowardsPlayer) * 20.0f) + interactRangeActor->world.pos.z;
this->currentYaw = this->actor.shape.rot.y = interactRangeActor->yawTowardsPlayer + 0x8000;
- anim = &D_04003060;
+ anim = &gPlayer429Anim;
} else {
func_80835C58(globalCtx, this, func_80846050, 0);
anim = D_80853A4C[this->modelAnimType];
@@ -4468,9 +4351,9 @@ s32 func_8083A4A8(Player* this, GlobalContext* globalCtx) {
yawDiff = this->currentYaw - this->actor.shape.rot.y;
if ((ABS(yawDiff) < 0x1000) && (this->linearVelocity > 4.0f)) {
- anim = &D_04003148;
+ anim = &gPlayer458Anim;
} else {
- anim = &D_04002FE0;
+ anim = &gPlayer413Anim;
}
if (this->linearVelocity > (IREG(66) / 100.0f)) {
@@ -4539,7 +4422,7 @@ s32 func_8083A6AC(Player* this, GlobalContext* globalCtx) {
sp50 = 1;
}
- func_8083A5C4(globalCtx, this, sp84, sp54, sp50 ? &D_04002D88 : &D_04002F10);
+ func_8083A5C4(globalCtx, this, sp84, sp54, sp50 ? &gPlayer338Anim : &gPlayer387Anim);
if (sp50) {
func_80836898(globalCtx, this, func_8083A3B0);
@@ -4625,7 +4508,7 @@ void func_8083AA10(Player* this, GlobalContext* globalCtx) {
if (WaterBox_GetSurface1(globalCtx, &globalCtx->colCtx, sp44.x, sp44.z, &sp3C, &sp50) &&
((sp3C - sp40) > 50.0f)) {
- func_808389E8(this, &D_04003158, 6.0f, globalCtx);
+ func_808389E8(this, &gPlayer460Anim, 6.0f, globalCtx);
func_80835C58(globalCtx, this, func_80844A44, 0);
return;
}
@@ -4637,7 +4520,7 @@ void func_8083AA10(Player* this, GlobalContext* globalCtx) {
if ((D_80853604 == 9) || (D_80853600 <= this->ageProperties->unk_34) ||
!func_8083A6AC(this, globalCtx)) {
- func_80832284(globalCtx, this, &D_04003040);
+ func_80832284(globalCtx, this, &gPlayer425Anim);
return;
}
}
@@ -4709,7 +4592,7 @@ void func_8083AF44(GlobalContext* globalCtx, Player* this, s32 magicSpell) {
this->unk_84F = magicSpell - 3;
func_80087708(globalCtx, sMagicSpellCosts[magicSpell], 4);
- LinkAnimation_PlayOnceSetSpeed(globalCtx, &this->skelAnime, &D_04002D28, 0.83f);
+ LinkAnimation_PlayOnceSetSpeed(globalCtx, &this->skelAnime, &gPlayer326Anim, 0.83f);
if (magicSpell == 5) {
this->unk_46C = func_800800F8(globalCtx, 1100, -101, NULL, 0);
@@ -4734,9 +4617,9 @@ u8 D_80854528[] = {
};
LinkAnimationHeader* D_80854548[] = {
- 0x04002F88,
- 0x04002690,
- 0x04003198,
+ &gPlayer402Anim,
+ &gPlayer115Anim,
+ &gPlayer468Anim,
};
s32 func_8083B040(Player* this, GlobalContext* globalCtx) {
@@ -4836,20 +4719,20 @@ s32 func_8083B040(Player* this, GlobalContext* globalCtx) {
if (sp2C >= 0) {
if (sp2C == 0xC) {
func_80835DE4(globalCtx, this, func_8084EED8, 0);
- func_808322D0(globalCtx, this, &D_04002650);
+ func_808322D0(globalCtx, this, &gPlayer107Anim);
func_80835EA4(globalCtx, 3);
} else if ((sp2C > 0) && (sp2C < 4)) {
func_80835DE4(globalCtx, this, func_8084EFC0, 0);
- func_808322D0(globalCtx, this, &D_04002688);
+ func_808322D0(globalCtx, this, &gPlayer114Anim);
func_80835EA4(globalCtx, (sp2C == 1) ? 1 : 5);
} else {
func_80835DE4(globalCtx, this, func_8084EAC0, 0);
- func_80832B78(globalCtx, this, &D_04002668);
+ func_80832B78(globalCtx, this, &gPlayer110Anim);
func_80835EA4(globalCtx, 2);
}
} else {
func_80835DE4(globalCtx, this, func_8084E3C4, 0);
- func_808322D0(globalCtx, this, &D_040030A0);
+ func_808322D0(globalCtx, this, &gPlayer437Anim);
this->stateFlags2 |= 0x8000000;
func_80835EA4(globalCtx, (this->unk_6A8 != NULL) ? 0x5B : 0x5A);
if (this->unk_6A8 != NULL) {
@@ -5066,7 +4949,7 @@ s32 func_8083BDBC(Player* this, GlobalContext* globalCtx) {
if (func_80833BCC(this)) {
if (this->actor.category != ACTORCAT_PLAYER) {
if (sp2C < 0) {
- func_808389E8(this, &D_04002FE0, REG(69) / 100.0f, globalCtx);
+ func_808389E8(this, &gPlayer413Anim, REG(69) / 100.0f, globalCtx);
} else {
func_8083BC04(this, globalCtx);
}
@@ -5179,7 +5062,7 @@ s32 func_8083C2B0(Player* this, GlobalContext* globalCtx) {
Player_SetModelsForHoldingShield(this);
anim = D_80853AF4[this->modelAnimType];
} else {
- anim = &D_04002400;
+ anim = &gPlayer33Anim;
}
if (anim != this->skelAnime.animation) {
@@ -5248,7 +5131,7 @@ s32 func_8083C544(Player* this, GlobalContext* globalCtx) {
s32 func_8083C61C(GlobalContext* globalCtx, Player* this) {
if ((globalCtx->roomCtx.curRoom.unk_03 != 2) && (this->actor.bgCheckFlags & 1) && (AMMO(ITEM_NUT) != 0)) {
func_80835C58(globalCtx, this, func_8084E604, 0);
- func_80832264(globalCtx, this, &D_04003048);
+ func_80832264(globalCtx, this, &gPlayer426Anim);
this->unk_6AD = 0;
return 1;
}
@@ -5257,8 +5140,8 @@ s32 func_8083C61C(GlobalContext* globalCtx, Player* this) {
}
struct_80854554 D_80854554[] = {
- { 0x04002648, 0x04002640, 2, 3 },
- { 0x04002680, 0x04002678, 5, 3 },
+ { &gPlayer106Anim, &gPlayer105Anim, 2, 3 },
+ { &gPlayer113Anim, &gPlayer112Anim, 5, 3 },
};
s32 func_8083C6B8(GlobalContext* globalCtx, Player* this) {
@@ -5292,7 +5175,7 @@ s32 func_8083C6B8(GlobalContext* globalCtx, Player* this) {
func_80835C58(globalCtx, this, func_80850C68, 0);
this->unk_860 = 1;
func_80832210(this);
- func_80832264(globalCtx, this, &D_04002C30);
+ func_80832264(globalCtx, this, &gPlayer295Anim);
return 1;
} else {
return 0;
@@ -5333,7 +5216,7 @@ s32 func_8083C910(GlobalContext* globalCtx, Player* this, f32 arg2) {
sp28 -= this->actor.world.pos.y;
if (this->ageProperties->unk_24 <= sp28) {
func_80835C58(globalCtx, this, func_8084D7C4, 0);
- func_80832C6C(globalCtx, this, &D_040032F0);
+ func_80832C6C(globalCtx, this, &gPlayer511Anim);
this->stateFlags1 |= 0x28000000;
this->unk_850 = 20;
this->linearVelocity = 2.0f;
@@ -5390,8 +5273,8 @@ void func_8083CB94(Player* this, GlobalContext* globalCtx) {
void func_8083CBF0(Player* this, s16 yaw, GlobalContext* globalCtx) {
func_80835C58(globalCtx, this, func_808423EC, 1);
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_040024F8, 2.2f, 0.0f, Animation_GetLastFrame(&D_040024F8),
- ANIMMODE_ONCE, -6.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer64Anim, 2.2f, 0.0f,
+ Animation_GetLastFrame(&gPlayer64Anim), ANIMMODE_ONCE, -6.0f);
this->linearVelocity = 8.0f;
this->currentYaw = yaw;
}
@@ -5404,7 +5287,7 @@ void func_8083CC9C(Player* this, GlobalContext* globalCtx) {
void func_8083CD00(Player* this, GlobalContext* globalCtx) {
func_80835C58(globalCtx, this, func_8084251C, 1);
- LinkAnimation_PlayOnceSetSpeed(globalCtx, &this->skelAnime, &D_040024E8, 2.0f);
+ LinkAnimation_PlayOnceSetSpeed(globalCtx, &this->skelAnime, &gPlayer62Anim, 2.0f);
}
void func_8083CD54(GlobalContext* globalCtx, Player* this, s16 yaw) {
@@ -5495,7 +5378,7 @@ s32 func_8083D12C(GlobalContext* globalCtx, Player* this, Input* arg2) {
(this->currentBoots != PLAYER_BOOTS_IRON))) {
func_80835C58(globalCtx, this, func_8084DC48, 0);
- func_80832264(globalCtx, this, &D_04003308);
+ func_80832264(globalCtx, this, &gPlayer514Anim);
this->unk_6C2 = 0;
this->stateFlags2 |= 0x400;
@@ -5527,7 +5410,7 @@ s32 func_8083D12C(GlobalContext* globalCtx, Player* this, Input* arg2) {
}
func_80832340(globalCtx, this);
- func_80832B0C(globalCtx, this, (this->stateFlags1 & 0x800) ? &D_04003318 : &D_04003300);
+ func_80832B0C(globalCtx, this, (this->stateFlags1 & 0x800) ? &gPlayer516Anim : &gPlayer513Anim);
if (func_8083CFA8(globalCtx, this, this->actor.velocity.y, 500)) {
func_8002F7DC(&this->actor, NA_SE_PL_FACE_UP);
@@ -5542,7 +5425,7 @@ s32 func_8083D12C(GlobalContext* globalCtx, Player* this, Input* arg2) {
}
void func_8083D330(GlobalContext* globalCtx, Player* this) {
- func_80832284(globalCtx, this, &D_040032F0);
+ func_80832284(globalCtx, this, &gPlayer511Anim);
this->unk_6C2 = 16000;
this->unk_850 = 1;
}
@@ -5560,7 +5443,7 @@ void func_8083D36C(GlobalContext* globalCtx, Player* this) {
func_8083D330(globalCtx, this);
} else {
func_80835C58(globalCtx, this, func_8084D610, 1);
- func_80832B0C(globalCtx, this, (this->actor.bgCheckFlags & 1) ? &D_04003330 : &D_040032E0);
+ func_80832B0C(globalCtx, this, (this->actor.bgCheckFlags & 1) ? &gPlayer519Anim : &gPlayer509Anim);
}
}
@@ -5800,8 +5683,8 @@ void func_8083DFE0(Player* this, f32* arg1, s16* arg2) {
}
struct_80854578 D_80854578[] = {
- { 0x04003398, 35.16999817f, 6.609999657f },
- { 0x040033A8, -34.15999985f, 7.909999847f },
+ { &gPlayer532Anim, 35.16999817f, 6.609999657f },
+ { &gPlayer534Anim, -34.15999985f, 7.909999847f },
};
s32 func_8083E0FC(Player* this, GlobalContext* globalCtx) {
@@ -5858,8 +5741,8 @@ void func_8083E298(CollisionPoly* arg0, Vec3f* arg1, s16* arg2) {
}
LinkAnimationHeader* D_80854590[] = {
- 0x04002EE0,
- 0x040031D0,
+ &gPlayer381Anim,
+ &gPlayer475Anim,
};
s32 func_8083E318(GlobalContext* globalCtx, Player* this, CollisionPoly* arg2) {
@@ -5947,7 +5830,7 @@ s32 func_8083E5A8(Player* this, GlobalContext* globalCtx) {
if (!(this->stateFlags2 & 0x400) || (this->currentBoots == PLAYER_BOOTS_IRON)) {
func_80836898(globalCtx, this, func_8083A434);
- func_808322D0(globalCtx, this, &D_04002788);
+ func_808322D0(globalCtx, this, &gPlayer146Anim);
func_80835EA4(globalCtx, 9);
}
@@ -5990,7 +5873,7 @@ s32 func_8083E5A8(Player* this, GlobalContext* globalCtx) {
chest->unk_1F4 = 1;
Camera_ChangeSetting(Gameplay_GetCamera(globalCtx, 0), CAM_SET_ITEM0);
} else {
- func_80832264(globalCtx, this, &D_04002DF8);
+ func_80832264(globalCtx, this, &gPlayer352Anim);
chest->unk_1F4 = -1;
}
@@ -6138,9 +6021,9 @@ s32 func_8083EC18(Player* this, GlobalContext* globalCtx, u32 arg2) {
if ((sp8C != 0) || (arg2 & 2)) {
if ((this->unk_84F = sp8C) != 0) {
if (this->actor.bgCheckFlags & 1) {
- sp30 = &D_04002D80;
+ sp30 = &gPlayer337Anim;
} else {
- sp30 = &D_04002D68;
+ sp30 = &gPlayer334Anim;
}
sp34 = (this->ageProperties->unk_38 - 1.0f) - sp34;
} else {
@@ -6227,7 +6110,7 @@ s32 func_8083F0C8(Player* this, GlobalContext* globalCtx, u32 arg2) {
this->actor.world.pos.z = sp44 + (sp30 * sp34);
func_80832224(this);
this->actor.prevPos = this->actor.world.pos;
- func_80832264(globalCtx, this, &D_04002708);
+ func_80832264(globalCtx, this, &gPlayer130Anim);
func_80832F54(globalCtx, this, 0x9D);
return 1;
@@ -6303,13 +6186,13 @@ s32 func_8083F570(Player* this, GlobalContext* globalCtx) {
if (this->linearVelocity > 0.0f) {
this->actor.shape.rot.y = this->actor.wallYaw + 0x8000;
- func_80832264(globalCtx, this, &D_04002700);
+ func_80832264(globalCtx, this, &gPlayer129Anim);
func_80832F54(globalCtx, this, 0x9D);
func_800800F8(globalCtx, 0x2581, 999, NULL, 0);
} else {
this->actor.shape.rot.y = this->actor.wallYaw;
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04002708, -1.0f,
- Animation_GetLastFrame(&D_04002708), 0.0f, ANIMMODE_ONCE, 0.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer130Anim, -1.0f,
+ Animation_GetLastFrame(&gPlayer130Anim), 0.0f, ANIMMODE_ONCE, 0.0f);
func_80832F54(globalCtx, this, 0x9D);
func_800800F8(globalCtx, 0x2582, 999, NULL, 0);
}
@@ -6375,7 +6258,7 @@ s32 func_8083F7BC(Player* this, GlobalContext* globalCtx) {
this->unk_3C4 = NULL;
}
- func_8083F72C(this, &D_040030F8, globalCtx);
+ func_8083F72C(this, &gPlayer448Anim, globalCtx);
return 1;
}
@@ -6404,7 +6287,7 @@ s32 func_8083F9D0(GlobalContext* globalCtx, Player* this) {
}
func_80839FFC(this, globalCtx);
- func_80832264(globalCtx, this, &D_04003100);
+ func_80832264(globalCtx, this, &gPlayer449Anim);
this->stateFlags2 &= ~0x10;
return 1;
}
@@ -6412,7 +6295,7 @@ s32 func_8083F9D0(GlobalContext* globalCtx, Player* this) {
void func_8083FAB8(Player* this, GlobalContext* globalCtx) {
func_80835C58(globalCtx, this, func_8084B898, 0);
this->stateFlags2 |= 0x10;
- func_80832264(globalCtx, this, &D_040030F0);
+ func_80832264(globalCtx, this, &gPlayer447Anim);
}
void func_8083FB14(Player* this, GlobalContext* globalCtx) {
@@ -6864,7 +6747,7 @@ void func_80840DE4(Player* this, GlobalContext* globalCtx) {
this->skelAnime.animation = func_8083356C(this);
- if (this->skelAnime.animation == &D_040026E8) {
+ if (this->skelAnime.animation == &gPlayer126Anim) {
frames = 24.0f;
coeff = -(MREG(95) / 100.0f);
} else {
@@ -6967,7 +6850,7 @@ void func_80841138(Player* this, GlobalContext* globalCtx) {
func_8084029C(this, 1.2f + ((REG(38) / 1000.0f) * temp2));
}
LinkAnimation_LoadToMorph(globalCtx, &this->skelAnime, D_80853BFC[this->modelAnimType], this->unk_868);
- LinkAnimation_LoadToJoint(globalCtx, &this->skelAnime, &D_04002DD0, this->unk_868 * 0.551724135876f);
+ LinkAnimation_LoadToJoint(globalCtx, &this->skelAnime, &gPlayer347Anim, this->unk_868 * 0.551724135876f);
}
}
@@ -6978,7 +6861,7 @@ void func_80841138(Player* this, GlobalContext* globalCtx) {
void func_8084140C(Player* this, GlobalContext* globalCtx) {
func_80835C58(globalCtx, this, func_8084170C, 1);
- func_80832B0C(globalCtx, this, &D_04002DA0);
+ func_80832B0C(globalCtx, this, &gPlayer341Anim);
}
s32 func_80841458(Player* this, f32* arg1, s16* arg2, GlobalContext* globalCtx) {
@@ -7041,7 +6924,7 @@ void func_808414F8(Player* this, GlobalContext* globalCtx) {
void func_808416C0(Player* this, GlobalContext* globalCtx) {
func_80835C58(globalCtx, this, func_808417FC, 1);
- func_80832264(globalCtx, this, &D_04002DA8);
+ func_80832264(globalCtx, this, &gPlayer342Anim);
}
void func_8084170C(Player* this, GlobalContext* globalCtx) {
@@ -7221,10 +7104,10 @@ void func_80841CC4(Player* this, s32 arg1, GlobalContext* globalCtx) {
}
if (rate < 0.0f) {
- anim = &D_04002E48;
+ anim = &gPlayer362Anim;
rate = -rate;
} else {
- anim = &D_04002E90;
+ anim = &gPlayer371Anim;
}
if (arg1 == 0) {
@@ -7445,7 +7328,7 @@ s32 func_8084285C(Player* this, f32 arg1, f32 arg2, f32 arg3) {
s32 func_808428D8(Player* this, GlobalContext* globalCtx) {
if (!Player_IsChildWithHylianShield(this) && Player_GetSwordHeld(this) && D_80853614) {
- func_80832264(globalCtx, this, &D_04002EC8);
+ func_80832264(globalCtx, this, &gPlayer378Anim);
this->unk_84F = 1;
this->swordAnimation = 0xC;
this->currentYaw = this->actor.shape.rot.y + this->unk_6BE;
@@ -7515,10 +7398,10 @@ void func_80842CF0(GlobalContext* globalCtx, Player* this) {
}
LinkAnimationHeader* D_808545CC[] = {
- 0x04002B10,
- 0x04002B20,
- 0x04002B08,
- 0x04002B18,
+ &gPlayer259Anim,
+ &gPlayer261Anim,
+ &gPlayer258Anim,
+ &gPlayer260Anim,
};
void func_80842D20(GlobalContext* globalCtx, Player* this) {
@@ -7705,8 +7588,8 @@ void func_80843188(Player* this, GlobalContext* globalCtx) {
if (Player_IsChildWithHylianShield(this)) {
func_8083A060(this, globalCtx);
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04002400, 1.0f,
- Animation_GetLastFrame(&D_04002400), 0.0f, ANIMMODE_ONCE, 0.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer33Anim, 1.0f,
+ Animation_GetLastFrame(&gPlayer33Anim), 0.0f, ANIMMODE_ONCE, 0.0f);
func_80832F54(globalCtx, this, 4);
} else {
if (this->itemActionParam < 0) {
@@ -7801,7 +7684,8 @@ void func_8084377C(Player* this, GlobalContext* globalCtx) {
this->stateFlags1 |= 0x4000000;
}
- func_80832264(globalCtx, this, (this->currentYaw != this->actor.shape.rot.y) ? &D_04002F60 : &D_04002DB8);
+ func_80832264(globalCtx, this,
+ (this->currentYaw != this->actor.shape.rot.y) ? &gPlayer397Anim : &gPlayer344Anim);
func_80832698(this, NA_SE_VO_LI_FREEZE);
}
}
@@ -7825,7 +7709,8 @@ void func_80843954(Player* this, GlobalContext* globalCtx) {
this->stateFlags1 |= 0x4000000;
}
- func_808322D0(globalCtx, this, (this->currentYaw != this->actor.shape.rot.y) ? &D_04002F68 : &D_04002DC0);
+ func_808322D0(globalCtx, this,
+ (this->currentYaw != this->actor.shape.rot.y) ? &gPlayer398Anim : &gPlayer345Anim);
this->currentYaw = this->actor.shape.rot.y;
}
}
@@ -7861,11 +7746,11 @@ void func_80843AE8(GlobalContext* globalCtx, Player* this) {
this->unk_850--;
if (this->unk_850 == 0) {
if (this->stateFlags1 & 0x8000000) {
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04003328, 1.0f, 0.0f,
- Animation_GetLastFrame(&D_04003328), ANIMMODE_ONCE, -16.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer518Anim, 1.0f, 0.0f,
+ Animation_GetLastFrame(&gPlayer518Anim), ANIMMODE_ONCE, -16.0f);
} else {
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04002878, 1.0f, 99.0f,
- Animation_GetLastFrame(&D_04002878), ANIMMODE_ONCE, 0.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer176Anim, 1.0f, 99.0f,
+ Animation_GetLastFrame(&gPlayer176Anim), ANIMMODE_ONCE, 0.0f);
}
gSaveContext.healthAccumulator = 0x140;
this->unk_850 = -1;
@@ -7916,9 +7801,9 @@ void func_80843CEC(Player* this, GlobalContext* globalCtx) {
return;
}
- if (this->skelAnime.animation == &D_04002878) {
+ if (this->skelAnime.animation == &gPlayer176Anim) {
func_80832924(this, D_808545F0);
- } else if (this->skelAnime.animation == &D_04002F08) {
+ } else if (this->skelAnime.animation == &gPlayer386Anim) {
if (LinkAnimation_OnFrame(&this->skelAnime, 88.0f)) {
func_80832770(this, NA_SE_PL_BOUND);
}
@@ -8047,8 +7932,8 @@ void func_8084411C(Player* this, GlobalContext* globalCtx) {
this->stateFlags1 &= ~4;
}
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04003020, 1.0f, 0.0f, 0.0f, ANIMMODE_ONCE,
- 8.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer421Anim, 1.0f, 0.0f, 0.0f,
+ ANIMMODE_ONCE, 8.0f);
this->unk_850 = -1;
}
} else {
@@ -8090,10 +7975,10 @@ void func_8084411C(Player* this, GlobalContext* globalCtx) {
} else {
anim = D_80853D4C[this->unk_84F][1];
}
- } else if (this->skelAnime.animation == &D_04003148) {
- anim = &D_04003150;
+ } else if (this->skelAnime.animation == &gPlayer458Anim) {
+ anim = &gPlayer459Anim;
} else if (func_8008E9C4(this)) {
- anim = &D_04002538;
+ anim = &gPlayer72Anim;
func_80833C3C(this);
} else if (this->fallDistance <= 80) {
anim = D_80853A7C[this->modelAnimType];
@@ -8208,7 +8093,7 @@ void func_80844A44(Player* this, GlobalContext* globalCtx) {
this->stateFlags2 |= 0x20;
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_80832284(globalCtx, this, &D_04003160);
+ func_80832284(globalCtx, this, &gPlayer461Anim);
}
Math_StepToF(&this->linearVelocity, 0.0f, 0.05f);
@@ -8485,7 +8370,7 @@ void func_80845668(Player* this, GlobalContext* globalCtx) {
this->stateFlags2 |= 0x20;
sp3C = LinkAnimation_Update(globalCtx, &this->skelAnime);
- if (this->skelAnime.animation == &D_04002D48) {
+ if (this->skelAnime.animation == &gPlayer330Anim) {
this->linearVelocity = 1.0f;
if (LinkAnimation_OnFrame(&this->skelAnime, 8.0f)) {
@@ -8525,14 +8410,14 @@ void func_80845668(Player* this, GlobalContext* globalCtx) {
temp3 = 0.0f;
- if (this->skelAnime.animation == &D_040032E8) {
+ if (this->skelAnime.animation == &gPlayer510Anim) {
if (LinkAnimation_OnFrame(&this->skelAnime, 30.0f)) {
func_8083D0A8(globalCtx, this, 10.0f);
}
temp3 = 50.0f;
- } else if (this->skelAnime.animation == &D_04002D40) {
+ } else if (this->skelAnime.animation == &gPlayer329Anim) {
temp3 = 30.0f;
- } else if (this->skelAnime.animation == &D_04002D38) {
+ } else if (this->skelAnime.animation == &gPlayer328Anim) {
temp3 = 16.0f;
}
@@ -8541,7 +8426,7 @@ void func_80845668(Player* this, GlobalContext* globalCtx) {
func_80832698(this, NA_SE_VO_LI_CLIMB_END);
}
- if ((this->skelAnime.animation == &D_04002D38) || (this->skelAnime.curFrame > 5.0f)) {
+ if ((this->skelAnime.animation == &gPlayer328Anim) || (this->skelAnime.curFrame > 5.0f)) {
if (this->unk_850 == 0) {
func_80832854(this);
this->unk_850 = 1;
@@ -8754,7 +8639,7 @@ struct_80832924 D_8085461C[] = {
void func_80846120(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime) && (this->unk_850++ > 20)) {
if (!func_8083B040(this, globalCtx)) {
- func_8083A098(this, &D_04002FA0, globalCtx);
+ func_8083A098(this, &gPlayer405Anim, globalCtx);
}
return;
}
@@ -8787,7 +8672,7 @@ void func_80846260(Player* this, GlobalContext* globalCtx) {
func_8083721C(this);
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_80832284(globalCtx, this, &D_040032C0);
+ func_80832284(globalCtx, this, &gPlayer505Anim);
this->unk_850 = 1;
return;
}
@@ -8809,7 +8694,7 @@ void func_80846260(Player* this, GlobalContext* globalCtx) {
} else if (CHECK_BTN_ANY(sControlInput->press.button, BTN_A | BTN_B | BTN_CLEFT | BTN_CRIGHT | BTN_CDOWN)) {
func_80835C58(globalCtx, this, func_80846358, 1);
- func_80832264(globalCtx, this, &D_040032B8);
+ func_80832264(globalCtx, this, &gPlayer504Anim);
}
}
@@ -8833,7 +8718,7 @@ void func_80846358(Player* this, GlobalContext* globalCtx) {
void func_80846408(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_80832284(globalCtx, this, &D_04003070);
+ func_80832284(globalCtx, this, &gPlayer431Anim);
this->unk_850 = 15;
return;
}
@@ -8841,7 +8726,7 @@ void func_80846408(Player* this, GlobalContext* globalCtx) {
if (this->unk_850 != 0) {
this->unk_850--;
if (this->unk_850 == 0) {
- func_8083A098(this, &D_04003068, globalCtx);
+ func_8083A098(this, &gPlayer430Anim, globalCtx);
this->stateFlags1 &= ~0x800;
func_80832698(this, NA_SE_VO_LI_DAMAGE_S);
}
@@ -8961,7 +8846,7 @@ void func_80846660(GlobalContext* globalCtx, Player* this) {
this->unk_84F = 1;
}
this->stateFlags1 |= 0x20000000;
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04003298, 2.0f / 3.0f, 0.0f, 24.0f, ANIMMODE_ONCE, 0.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer500Anim, 2.0f / 3.0f, 0.0f, 24.0f, ANIMMODE_ONCE, 0.0f);
this->actor.world.pos.y += 800.0f;
}
@@ -9007,7 +8892,7 @@ void func_808468A8(GlobalContext* globalCtx, Player* this) {
}
void func_808468E8(GlobalContext* globalCtx, Player* this) {
- func_808389E8(this, &D_04002FE0, 12.0f, globalCtx);
+ func_808389E8(this, &gPlayer413Anim, 12.0f, globalCtx);
func_80835C58(globalCtx, this, func_8084F9C0, 0);
this->stateFlags1 |= 0x20000000;
this->fallStartHeight = this->actor.world.pos.y;
@@ -9998,7 +9883,7 @@ void Player_UpdateCommon(Player* this, GlobalContext* globalCtx, Input* input) {
this->actor.parent = this->rideActor;
func_8083A360(globalCtx, this);
this->stateFlags1 |= 0x800000;
- func_80832264(globalCtx, this, &D_040033B8);
+ func_80832264(globalCtx, this, &gPlayer536Anim);
func_80832F54(globalCtx, this, 0x9B);
this->unk_850 = 99;
}
@@ -10130,8 +10015,8 @@ void Player_UpdateCommon(Player* this, GlobalContext* globalCtx, Input* input) {
func_80837B9C(this, globalCtx);
} else if ((this->actor.bgCheckFlags & 1) || (this->stateFlags1 & 0x8000000)) {
func_80836448(globalCtx, this,
- func_808332B8(this) ? &D_04003310
- : (this->shockTimer != 0) ? &D_04002F08 : &D_04002878);
+ func_808332B8(this) ? &gPlayer515Anim
+ : (this->shockTimer != 0) ? &gPlayer386Anim : &gPlayer176Anim);
}
} else {
if ((this->actor.parent == NULL) &&
@@ -10422,7 +10307,7 @@ void func_8084A0E8(GlobalContext* globalCtx, Player* this, s32 lod, Gfx* cullDLi
(globalCtx->gameplayFrames * -15) % 128, 16, 32));
gDPSetPrimColor(POLY_XLU_DISP++, 0x80, 0x80, 255, 255, 255, D_8085486C);
gDPSetEnvColor(POLY_XLU_DISP++, 120, 90, 30, 128);
- gSPDisplayList(POLY_XLU_DISP++, D_04037E30);
+ gSPDisplayList(POLY_XLU_DISP++, gHoverBootsCircleDL);
}
}
@@ -10514,7 +10399,7 @@ void Player_Draw(Actor* thisx, GlobalContext* globalCtx) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_player.c", 19459),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetEnvColor(POLY_XLU_DISP++, 0, 50, 100, 255);
- gSPDisplayList(POLY_XLU_DISP++, D_04033EE0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffIceFragment3DL);
}
if (this->unk_862 > 0) {
@@ -10770,12 +10655,12 @@ void func_8084B530(Player* this, GlobalContext* globalCtx) {
func_80832DBC(this);
if ((this->targetActor->category == ACTORCAT_NPC) &&
(this->heldItemActionParam != PLAYER_AP_FISHING_POLE)) {
- func_808322D0(globalCtx, this, &D_040031A0);
+ func_808322D0(globalCtx, this, &gPlayer469Anim);
} else {
func_80832284(globalCtx, this, func_80833338(this));
}
} else {
- func_808322A4(globalCtx, this, &D_040031A8);
+ func_808322A4(globalCtx, this, &gPlayer470Anim);
}
}
@@ -10827,7 +10712,7 @@ void func_8084B898(Player* this, GlobalContext* globalCtx) {
this->stateFlags2 |= 0x141;
- if (func_80832CB0(globalCtx, this, &D_04003108)) {
+ if (func_80832CB0(globalCtx, this, &gPlayer450Anim)) {
this->unk_850 = 1;
} else if (this->unk_850 == 0) {
if (LinkAnimation_OnFrame(&this->skelAnime, 11.0f)) {
@@ -10844,7 +10729,7 @@ void func_8084B898(Player* this, GlobalContext* globalCtx) {
if (temp < 0) {
func_8083FB14(this, globalCtx);
} else if (temp == 0) {
- func_8083F72C(this, &D_040030E0, globalCtx);
+ func_8083F72C(this, &gPlayer445Anim, globalCtx);
} else {
this->stateFlags2 |= 0x10;
}
@@ -10929,10 +10814,10 @@ void func_8084BBE4(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
// clang-format off
- anim = (this->unk_84F > 0) ? &D_04002F28 : D_80853CD4[this->modelAnimType]; func_80832284(globalCtx, this, anim);
+ anim = (this->unk_84F > 0) ? &gPlayer390Anim : D_80853CD4[this->modelAnimType]; func_80832284(globalCtx, this, anim);
// clang-format on
} else if (this->unk_84F == 0) {
- if (this->skelAnime.animation == &D_04002F10) {
+ if (this->skelAnime.animation == &gPlayer387Anim) {
temp = 11.0f;
} else {
temp = 1.0f;
@@ -10940,7 +10825,7 @@ void func_8084BBE4(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_OnFrame(&this->skelAnime, temp)) {
func_80832770(this, NA_SE_PL_WALK_GROUND);
- if (this->skelAnime.animation == &D_04002F10) {
+ if (this->skelAnime.animation == &gPlayer387Anim) {
this->unk_84F = 1;
} else {
this->unk_84F = -1;
@@ -11070,10 +10955,10 @@ void func_8084BF1C(Player* this, GlobalContext* globalCtx) {
this->actor.world.pos.y = temp_f0;
this->stateFlags1 &= ~0x200000;
func_8083A5C4(globalCtx, this, this->actor.wallPoly, this->ageProperties->unk_3C,
- &D_04003000);
+ &gPlayer417Anim);
this->currentYaw += 0x8000;
this->actor.shape.rot.y = this->currentYaw;
- func_8083A9B8(this, &D_04003000, globalCtx);
+ func_8083A9B8(this, &gPlayer417Anim, globalCtx);
this->stateFlags1 |= 0x4000;
} else {
func_8083F070(this, this->ageProperties->unk_CC[this->unk_850], globalCtx);
@@ -11291,7 +11176,7 @@ s32 func_8084C9BC(Player* this, GlobalContext* globalCtx) {
rideActor->actor.child = NULL;
func_80835DAC(globalCtx, this, func_8084D3E4, 0);
this->unk_878 = sp34 - rideActor->actor.world.pos.y;
- func_80832264(globalCtx, this, (this->unk_43C < 0) ? &D_04003390 : &D_040033A0);
+ func_80832264(globalCtx, this, (this->unk_43C < 0) ? &gPlayer531Anim : &gPlayer533Anim);
return 1;
}
}
@@ -11321,17 +11206,33 @@ void func_8084CBF4(Player* this, f32 arg1, f32 arg2) {
}
LinkAnimationHeader* D_80854944[] = {
- 0x04003370, 0x04003368, 0x04003380, 0x04003358, 0x04003338, 0x04003348, 0x04003350, NULL, NULL,
+ &gPlayer527Anim,
+ &gPlayer526Anim,
+ &gPlayer529Anim,
+ &gPlayer524Anim,
+ &gPlayer520Anim,
+ &gPlayer522Anim,
+ &gPlayer523Anim,
+ NULL,
+ NULL,
};
LinkAnimationHeader* D_80854968[] = {
- 0x04003388, 0x04003388, 0x04003388, 0x04003360, 0x04003340, 0x04003340, 0x04003340, NULL, NULL,
+ &gPlayer530Anim,
+ &gPlayer530Anim,
+ &gPlayer530Anim,
+ &gPlayer525Anim,
+ &gPlayer521Anim,
+ &gPlayer521Anim,
+ &gPlayer521Anim,
+ NULL,
+ NULL,
};
LinkAnimationHeader* D_8085498C[] = {
- 0x040033C8,
- 0x040033B8,
- 0x040033C0,
+ &gPlayer538Anim,
+ &gPlayer536Anim,
+ &gPlayer537Anim,
};
u8 D_80854998[2][2] = {
@@ -11357,7 +11258,7 @@ void func_8084CC98(Player* this, GlobalContext* globalCtx) {
if (this->unk_850 == 0) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- this->skelAnime.animation = &D_040033B8;
+ this->skelAnime.animation = &gPlayer536Anim;
this->unk_850 = 99;
return;
}
@@ -11406,10 +11307,10 @@ void func_8084CC98(Player* this, GlobalContext* globalCtx) {
if (this->unk_850 == 1) {
if ((D_808535E0 != 0) || func_8083224C(globalCtx)) {
- func_80832264(globalCtx, this, &D_040033C8);
+ func_80832264(globalCtx, this, &gPlayer538Anim);
} else if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
this->unk_850 = 99;
- } else if (this->skelAnime.animation == &D_040033B8) {
+ } else if (this->skelAnime.animation == &gPlayer536Anim) {
func_80832924(this, D_808549A4);
}
} else {
@@ -11449,7 +11350,7 @@ void func_8084CC98(Player* this, GlobalContext* globalCtx) {
this->unk_84F = 0;
}
- if (this->skelAnime2.animation == &D_040033B0) {
+ if (this->skelAnime2.animation == &gPlayer535Anim) {
if (LinkAnimation_OnFrame(&this->skelAnime2, 23.0f)) {
func_8002F7DC(&this->actor, NA_SE_IT_LASH);
func_80832698(this, NA_SE_VO_LI_LASH);
@@ -11470,7 +11371,7 @@ void func_8084CC98(Player* this, GlobalContext* globalCtx) {
LinkAnimationHeader* anim = NULL;
if (EN_HORSE_CHECK_3(rideActor)) {
- anim = &D_040033B0;
+ anim = &gPlayer535Anim;
} else if (EN_HORSE_CHECK_2(rideActor)) {
if ((this->unk_850 >= 2) && (this->unk_850 != 99)) {
anim = D_80854968[this->unk_850 - 2];
@@ -11567,19 +11468,19 @@ void func_8084D530(Player* this, f32* arg1, f32 arg2, s16 arg3) {
void func_8084D574(GlobalContext* globalCtx, Player* this, s16 arg2) {
func_80835C58(globalCtx, this, func_8084D84C, 0);
this->actor.shape.rot.y = this->currentYaw = arg2;
- func_80832C6C(globalCtx, this, &D_040032F0);
+ func_80832C6C(globalCtx, this, &gPlayer511Anim);
}
void func_8084D5CC(GlobalContext* globalCtx, Player* this) {
func_80835C58(globalCtx, this, func_8084DAB4, 0);
- func_80832C6C(globalCtx, this, &D_040032F0);
+ func_80832C6C(globalCtx, this, &gPlayer511Anim);
}
void func_8084D610(Player* this, GlobalContext* globalCtx) {
f32 sp34;
s16 sp32;
- func_80832CB0(globalCtx, this, &D_04003328);
+ func_80832CB0(globalCtx, this, &gPlayer518Anim);
func_8084B000(this);
if (!func_8083224C(globalCtx) && !func_80837348(globalCtx, this, D_80854444, 1) &&
@@ -11662,7 +11563,7 @@ s32 func_8084D980(GlobalContext* globalCtx, Player* this, f32* arg2, s16* arg3)
temp1 = this->currentYaw - *arg3;
if (ABS(temp1) > 0x6000) {
- anim = &D_04003328;
+ anim = &gPlayer518Anim;
if (Math_StepToF(&this->linearVelocity, 0.0f, 1.0f)) {
this->currentYaw = *arg3;
@@ -11674,13 +11575,13 @@ s32 func_8084D980(GlobalContext* globalCtx, Player* this, f32* arg2, s16* arg3)
temp2 = func_8083FD78(this, arg2, arg3, globalCtx);
if (temp2 > 0) {
- anim = &D_040032F0;
+ anim = &gPlayer511Anim;
} else if (temp2 < 0) {
- anim = &D_040032D8;
+ anim = &gPlayer508Anim;
} else if ((temp1 = this->actor.shape.rot.y - *arg3) > 0) {
- anim = &D_040032D0;
+ anim = &gPlayer507Anim;
} else {
- anim = &D_040032C8;
+ anim = &gPlayer506Anim;
}
}
@@ -11757,7 +11658,7 @@ void func_8084DC48(Player* this, GlobalContext* globalCtx) {
func_8084DBC4(globalCtx, this, -2.0f);
} else {
this->unk_84F++;
- func_80832C6C(globalCtx, this, &D_04003328);
+ func_80832C6C(globalCtx, this, &gPlayer518Anim);
}
} else if (this->unk_84F == 1) {
LinkAnimation_Update(globalCtx, &this->skelAnime);
@@ -11766,7 +11667,7 @@ void func_8084DC48(Player* this, GlobalContext* globalCtx) {
if (this->unk_6C2 < 10000) {
this->unk_84F++;
this->unk_850 = this->actor.yDistToWater;
- func_80832C6C(globalCtx, this, &D_040032F0);
+ func_80832C6C(globalCtx, this, &gPlayer511Anim);
}
} else if (!func_8083D12C(globalCtx, this, sControlInput)) {
sp2C = (this->unk_850 * 0.018f) + 4.0f;
@@ -11896,7 +11797,7 @@ s16 D_808549D4[] = { 0x0600, 0x04F6, 0x0604, 0x01F1, 0x0568, 0x05F4 };
void func_8084E3C4(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_808322A4(globalCtx, this, &D_040030A8);
+ func_808322A4(globalCtx, this, &gPlayer438Anim);
this->unk_850 = 1;
if (this->stateFlags2 & 0x2800000) {
this->stateFlags2 |= 0x1000000;
@@ -11920,7 +11821,7 @@ void func_8084E3C4(Player* this, GlobalContext* globalCtx) {
this->naviActor->textId = -this->naviTextId;
func_80853148(globalCtx, this->targetActor);
} else if (!func_8083B040(this, globalCtx)) {
- func_8083A098(this, &D_04003098, globalCtx);
+ func_8083A098(this, &gPlayer436Anim, globalCtx);
}
this->stateFlags2 &= ~0x3800000;
@@ -11950,7 +11851,7 @@ void func_8084E3C4(Player* this, GlobalContext* globalCtx) {
void func_8084E604(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_8083A098(this, &D_04003050, globalCtx);
+ func_8083A098(this, &gPlayer427Anim, globalCtx);
} else if (LinkAnimation_OnFrame(&this->skelAnime, 3.0f)) {
Inventory_ChangeAmmo(ITEM_NUT, -1);
Actor_Spawn(&globalCtx->actorCtx, globalCtx, ACTOR_EN_ARROW, this->bodyPartsPos[15].x, this->bodyPartsPos[15].y,
@@ -12010,10 +11911,10 @@ void func_8084E6D4(Player* this, GlobalContext* globalCtx) {
return;
}
- if (this->skelAnime.animation == &D_04002DF8) {
- func_808322D0(globalCtx, this, &D_04002788);
+ if (this->skelAnime.animation == &gPlayer352Anim) {
+ func_808322D0(globalCtx, this, &gPlayer146Anim);
} else {
- func_808322D0(globalCtx, this, &D_04002780);
+ func_808322D0(globalCtx, this, &gPlayer145Anim);
}
this->unk_850 = 2;
@@ -12027,7 +11928,7 @@ void func_8084E6D4(Player* this, GlobalContext* globalCtx) {
return;
}
- if (this->skelAnime.animation == &D_04002788) {
+ if (this->skelAnime.animation == &gPlayer146Anim) {
Math_ScaledStepToS(&this->actor.shape.rot.y, Camera_GetCamDirYaw(ACTIVE_CAM) + 0x8000, 4000);
}
@@ -12113,7 +12014,7 @@ void func_8084EAC0(Player* this, GlobalContext* globalCtx) {
}
}
- func_808322A4(globalCtx, this, &D_04002670);
+ func_808322A4(globalCtx, this, &gPlayer111Anim);
this->unk_850 = 1;
return;
}
@@ -12122,7 +12023,7 @@ void func_8084EAC0(Player* this, GlobalContext* globalCtx) {
func_8005B1A4(Gameplay_GetCamera(globalCtx, 0));
} else if (this->unk_850 == 1) {
if ((gSaveContext.healthAccumulator == 0) && (gSaveContext.unk_13F0 != 9)) {
- func_80832B78(globalCtx, this, &D_04002660);
+ func_80832B78(globalCtx, this, &gPlayer109Anim);
this->unk_850 = 2;
Player_UpdateBottleHeld(globalCtx, this, ITEM_BOTTLE, PLAYER_AP_BOTTLE);
}
@@ -12298,7 +12199,7 @@ void func_8084F104(Player* this, GlobalContext* globalCtx) {
this->unk_862 = 0;
if (this->unk_84F == 1) {
- func_80832264(globalCtx, this, &D_04002698);
+ func_80832264(globalCtx, this, &gPlayer116Anim);
this->unk_850 = -1;
} else {
func_8083C0E8(this, globalCtx);
@@ -12320,7 +12221,7 @@ void func_8084F308(Player* this, GlobalContext* globalCtx) {
this->stateFlags2 |= 0x60;
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_80832284(globalCtx, this, &D_04003128);
+ func_80832284(globalCtx, this, &gPlayer454Anim);
}
if (func_80832594(this, 0, 100)) {
@@ -12722,8 +12623,8 @@ void func_808502D0(Player* this, GlobalContext* globalCtx) {
func_80832318(this);
this->skelAnime.moveFlags = 0;
- if ((sp3C == &D_04002908) && (this->modelAnimType != 3)) {
- sp3C = &D_04002AC8;
+ if ((sp3C == &gPlayer194Anim) && (this->modelAnimType != 3)) {
+ sp3C = &gPlayer250Anim;
}
func_8083A098(this, sp3C, globalCtx);
@@ -12815,21 +12716,21 @@ void func_8085076C(Player* this, GlobalContext* globalCtx) {
}
LinkAnimationHeader* D_80854A58[] = {
- 0x04002CF8,
- 0x04002CE0,
- 0x04002D10,
+ &gPlayer320Anim,
+ &gPlayer317Anim,
+ &gPlayer323Anim,
};
LinkAnimationHeader* D_80854A64[] = {
- 0x04002D00,
- 0x04002CE8,
- 0x04002D18,
+ &gPlayer321Anim,
+ &gPlayer318Anim,
+ &gPlayer324Anim,
};
LinkAnimationHeader* D_80854A70[] = {
- 0x04002D08,
- 0x04002CF0,
- 0x04002D20,
+ &gPlayer322Anim,
+ &gPlayer319Anim,
+ &gPlayer325Anim,
};
u8 D_80854A7C[] = { 70, 10, 10 };
@@ -12928,7 +12829,7 @@ void func_80850AEC(Player* this, GlobalContext* globalCtx) {
this->stateFlags2 |= 0x20;
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_80832284(globalCtx, this, &D_04002C98);
+ func_80832284(globalCtx, this, &gPlayer308Anim);
}
Math_Vec3f_Sum(&this->actor.world.pos, &this->actor.velocity, &this->actor.world.pos);
@@ -12953,7 +12854,7 @@ void func_80850AEC(Player* this, GlobalContext* globalCtx) {
return;
}
- if ((this->skelAnime.animation != &D_04002C90) || (4.0f <= this->skelAnime.curFrame)) {
+ if ((this->skelAnime.animation != &gPlayer307Anim) || (4.0f <= this->skelAnime.curFrame)) {
this->actor.gravity = 0.0f;
Math_ScaledStepToS(&this->actor.shape.rot.x, this->actor.world.rot.x, 0x800);
func_8083264C(this, 100, 2, 100, 0);
@@ -12969,16 +12870,16 @@ void func_80850C68(Player* this, GlobalContext* globalCtx) {
this->skelAnime.curFrame -= this->skelAnime.animLength;
}
- LinkAnimation_BlendToJoint(globalCtx, &this->skelAnime, &D_04002C38, this->skelAnime.curFrame,
- (this->unk_858 < 0.0f) ? &D_04002C18 : &D_04002C20, 5.0f, fabsf(this->unk_858),
- this->blendTable);
- LinkAnimation_BlendToMorph(globalCtx, &this->skelAnime, &D_04002C38, this->skelAnime.curFrame,
- (this->unk_85C < 0.0f) ? &D_04002C28 : &D_04002C10, 5.0f, fabsf(this->unk_85C),
- D_80858AD8);
+ LinkAnimation_BlendToJoint(globalCtx, &this->skelAnime, &gPlayer296Anim, this->skelAnime.curFrame,
+ (this->unk_858 < 0.0f) ? &gPlayer292Anim : &gPlayer293Anim, 5.0f,
+ fabsf(this->unk_858), this->blendTable);
+ LinkAnimation_BlendToMorph(globalCtx, &this->skelAnime, &gPlayer296Anim, this->skelAnime.curFrame,
+ (this->unk_85C < 0.0f) ? &gPlayer294Anim : &gPlayer291Anim, 5.0f,
+ fabsf(this->unk_85C), D_80858AD8);
LinkAnimation_InterpJointMorph(globalCtx, &this->skelAnime, 0.5f);
} else if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
this->unk_860 = 2;
- func_80832284(globalCtx, this, &D_04002C38);
+ func_80832284(globalCtx, this, &gPlayer296Anim);
this->unk_850 = 1;
}
@@ -12988,13 +12889,13 @@ void func_80850C68(Player* this, GlobalContext* globalCtx) {
func_80853080(this, globalCtx);
} else if (this->unk_860 == 3) {
func_80835C58(globalCtx, this, func_80850E84, 0);
- func_80832B0C(globalCtx, this, &D_04002C00);
+ func_80832B0C(globalCtx, this, &gPlayer289Anim);
}
}
void func_80850E84(Player* this, GlobalContext* globalCtx) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime) && (this->unk_860 == 0)) {
- func_8083A098(this, &D_04002C08, globalCtx);
+ func_8083A098(this, &gPlayer290Anim, globalCtx);
}
}
@@ -13020,51 +12921,215 @@ struct_80832924 D_80854B14[] = {
};
struct_80854B18 D_80854B18[] = {
- { 0, NULL }, { -1, func_808515A4 }, { 2, 0x04002790 }, { 0, NULL }, { 0, NULL },
- { 3, 0x04002740 }, { 0, NULL }, { 0, NULL }, { -1, func_808515A4 }, { 2, 0x04002778 },
- { -1, func_80851788 }, { 3, 0x04002860 }, { -1, func_808518DC }, { 7, 0x04002348 }, { 5, 0x04002350 },
- { 5, 0x04002358 }, { 5, 0x040023B0 }, { 7, 0x040023B8 }, { -1, func_808519EC }, { 2, 0x04002728 },
- { 2, 0x04002738 }, { 0, NULL }, { -1, func_80851B90 }, { 3, 0x040027A8 }, { 9, 0x04002DB0 },
- { 2, 0x04002DC0 }, { -1, func_80851D2C }, { 2, 0x04003098 }, { 3, 0x04002780 }, { -1, func_808515A4 },
- { 2, 0x04003088 }, { 0, NULL }, { 0, NULL }, { 5, 0x04002320 }, { -1, func_80851368 },
- { -1, func_80851E64 }, { 5, 0x04002328 }, { 16, 0x04002F90 }, { -1, func_80851F84 }, { -1, func_80851E90 },
- { 6, 0x04002410 }, { 6, 0x04002418 }, { -1, func_80852080 }, { 5, 0x04002390 }, { -1, func_808521F4 },
- { -1, func_8085225C }, { -1, func_80852280 }, { 5, 0x040023A0 }, { 5, 0x04002368 }, { -1, func_808515A4 },
- { 5, 0x04002370 }, { 5, 0x040027B0 }, { 5, 0x040027B8 }, { 5, 0x040027C0 }, { 3, 0x04002768 },
- { 3, 0x040027D8 }, { 4, 0x040027E0 }, { 3, 0x04002380 }, { 3, 0x04002828 }, { 6, 0x04002470 },
- { 6, 0x040032A8 }, { 14, 0x040032A0 }, { 3, 0x040032A0 }, { 5, 0x04002AE8 }, { 16, 0x04002450 },
- { 15, 0x04002460 }, { 15, 0x04002458 }, { 3, 0x04002440 }, { 3, 0x04002438 }, { 3, 0x04002C88 },
- { 6, 0x04003450 }, { 6, 0x04003448 }, { 6, 0x04003460 }, { 6, 0x04003440 }, { 3, 0x04002798 },
- { 3, 0x04002818 }, { 4, 0x04002848 }, { 3, 0x04002850 }, { 3, 0x040034E0 }, { 3, 0x040034D8 },
- { 6, 0x040034C8 }, { 3, 0x04003470 }, { 3, 0x04003478 }, { 3, 0x040034C0 }, { 3, 0x04003480 },
- { 3, 0x04003490 }, { 3, 0x04003488 }, { 3, 0x04003498 }, { 3, 0x040034B0 }, { -1, func_808524B0 },
- { 3, 0x04003420 }, { -1, func_80852544 }, { -1, func_80852564 }, { 3, 0x04003250 }, { -1, func_80852608 },
- { 3, 0x04002810 }, { 3, 0x04002838 }, { 3, 0x04002CD0 }, { 3, 0x04002CD8 }, { 3, 0x04002868 },
- { 3, 0x040027E8 }, { 3, 0x040027F8 }, { 3, 0x04002800 },
+ { 0, NULL },
+ { -1, func_808515A4 },
+ { 2, &gPlayer147Anim },
+ { 0, NULL },
+ { 0, NULL },
+ { 3, &gPlayer137Anim },
+ { 0, NULL },
+ { 0, NULL },
+ { -1, func_808515A4 },
+ { 2, &gPlayer144Anim },
+ { -1, func_80851788 },
+ { 3, &gPlayer173Anim },
+ { -1, func_808518DC },
+ { 7, &gPlayer10Anim },
+ { 5, &gPlayer11Anim },
+ { 5, &gPlayer12Anim },
+ { 5, &gPlayer23Anim },
+ { 7, &gPlayer24Anim },
+ { -1, func_808519EC },
+ { 2, &gPlayer134Anim },
+ { 2, &gPlayer136Anim },
+ { 0, NULL },
+ { -1, func_80851B90 },
+ { 3, &gPlayer150Anim },
+ { 9, &gPlayer343Anim },
+ { 2, &gPlayer345Anim },
+ { -1, func_80851D2C },
+ { 2, &gPlayer436Anim },
+ { 3, &gPlayer145Anim },
+ { -1, func_808515A4 },
+ { 2, &gPlayer434Anim },
+ { 0, NULL },
+ { 0, NULL },
+ { 5, &gPlayer5Anim },
+ { -1, func_80851368 },
+ { -1, func_80851E64 },
+ { 5, &gPlayer6Anim },
+ { 16, &gPlayer403Anim },
+ { -1, func_80851F84 },
+ { -1, func_80851E90 },
+ { 6, &gPlayer35Anim },
+ { 6, &gPlayer36Anim },
+ { -1, func_80852080 },
+ { 5, &gPlayer19Anim },
+ { -1, func_808521F4 },
+ { -1, func_8085225C },
+ { -1, func_80852280 },
+ { 5, &gPlayer21Anim },
+ { 5, &gPlayer14Anim },
+ { -1, func_808515A4 },
+ { 5, &gPlayer15Anim },
+ { 5, &gPlayer151Anim },
+ { 5, &gPlayer152Anim },
+ { 5, &gPlayer153Anim },
+ { 3, &gPlayer142Anim },
+ { 3, &gPlayer156Anim },
+ { 4, &gPlayer157Anim },
+ { 3, &gPlayer17Anim },
+ { 3, &gPlayer166Anim },
+ { 6, &gPlayer47Anim },
+ { 6, &gPlayer502Anim },
+ { 14, &gPlayer501Anim },
+ { 3, &gPlayer501Anim },
+ { 5, &gPlayer254Anim },
+ { 16, &gPlayer43Anim },
+ { 15, &gPlayer45Anim },
+ { 15, &gPlayer44Anim },
+ { 3, &gPlayer41Anim },
+ { 3, &gPlayer40Anim },
+ { 3, &gPlayer306Anim },
+ { 6, &gPlayer555Anim },
+ { 6, &gPlayer554Anim },
+ { 6, &gPlayer557Anim },
+ { 6, &gPlayer553Anim },
+ { 3, &gPlayer148Anim },
+ { 3, &gPlayer164Anim },
+ { 4, &gPlayer170Anim },
+ { 3, &gPlayer171Anim },
+ { 3, &gPlayer573Anim },
+ { 3, &gPlayer572Anim },
+ { 6, &gPlayer570Anim },
+ { 3, &gPlayer559Anim },
+ { 3, &gPlayer560Anim },
+ { 3, &gPlayer569Anim },
+ { 3, &gPlayer561Anim },
+ { 3, &gPlayer563Anim },
+ { 3, &gPlayer562Anim },
+ { 3, &gPlayer564Anim },
+ { 3, &gPlayer567Anim },
+ { -1, func_808524B0 },
+ { 3, &gPlayer549Anim },
+ { -1, func_80852544 },
+ { -1, func_80852564 },
+ { 3, &gPlayer491Anim },
+ { -1, func_80852608 },
+ { 3, &gPlayer163Anim },
+ { 3, &gPlayer168Anim },
+ { 3, &gPlayer315Anim },
+ { 3, &gPlayer316Anim },
+ { 3, &gPlayer174Anim },
+ { 3, &gPlayer158Anim },
+ { 3, &gPlayer160Anim },
+ { 3, &gPlayer161Anim },
};
struct_80854B18 D_80854E50[] = {
- { 0, NULL }, { -1, func_808514C0 }, { -1, func_8085157C }, { -1, func_80851998 }, { -1, func_808519C0 },
- { 11, NULL }, { -1, func_80852C50 }, { -1, func_80852944 }, { -1, func_80851688 }, { -1, func_80851750 },
- { -1, func_80851828 }, { -1, func_808521B8 }, { -1, func_8085190C }, { 11, NULL }, { 11, NULL },
- { 11, NULL }, { 18, D_80854AF0 }, { 11, NULL }, { -1, func_80851A50 }, { 12, 0x04002730 },
- { 11, NULL }, { 0, NULL }, { -1, func_80851BE8 }, { 11, NULL }, { -1, func_80851CA4 },
- { 11, NULL }, { 17, 0x040030A8 }, { 11, NULL }, { 11, NULL }, { 11, NULL },
- { -1, func_80851D80 }, { -1, func_80851DEC }, { -1, func_80851E28 }, { 18, D_80854B00 }, { -1, func_808513BC },
- { 11, NULL }, { 11, NULL }, { 11, NULL }, { 11, NULL }, { -1, func_80851ECC },
- { -1, func_80851FB0 }, { -1, func_80852048 }, { -1, func_80852174 }, { 13, 0x04002398 }, { -1, func_80852234 },
- { 0, NULL }, { 0, NULL }, { 11, NULL }, { -1, func_80852450 }, { -1, func_80851688 },
- { -1, func_80852298 }, { 13, 0x040027D0 }, { -1, func_80852480 }, { 13, 0x040027C8 }, { -1, func_80852328 },
- { 11, NULL }, { 11, NULL }, { 12, 0x04002388 }, { -1, func_80852358 }, { 11, NULL },
- { 18, D_80854B14 }, { 11, NULL }, { 11, NULL }, { 11, NULL }, { 11, NULL },
- { -1, func_80852388 }, { 17, 0x04002450 }, { 12, 0x04002448 }, { 12, 0x04002450 }, { 11, NULL },
- { -1, func_808526EC }, { 17, 0x04003468 }, { -1, func_808526EC }, { 17, 0x04003468 }, { 12, 0x040027A0 },
- { 12, 0x04002820 }, { 11, NULL }, { 12, 0x04002858 }, { 12, 0x040034D0 }, { 13, 0x040034F0 },
- { 12, 0x040034E8 }, { 12, 0x040034A8 }, { 11, NULL }, { 11, NULL }, { 11, NULL },
- { 11, NULL }, { -1, func_80852648 }, { 11, NULL }, { 12, 0x040034A0 }, { -1, func_808524D0 },
- { -1, func_80852514 }, { -1, func_80852554 }, { -1, func_808525C0 }, { 11, NULL }, { 11, NULL },
- { 11, NULL }, { -1, func_8085283C }, { -1, func_808528C8 }, { -1, func_808528C8 }, { 12, 0x04002870 },
- { 12, 0x040027F0 }, { 12, 0x04002808 }, { 12, 0x04002450 },
+ { 0, NULL },
+ { -1, func_808514C0 },
+ { -1, func_8085157C },
+ { -1, func_80851998 },
+ { -1, func_808519C0 },
+ { 11, NULL },
+ { -1, func_80852C50 },
+ { -1, func_80852944 },
+ { -1, func_80851688 },
+ { -1, func_80851750 },
+ { -1, func_80851828 },
+ { -1, func_808521B8 },
+ { -1, func_8085190C },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { 18, D_80854AF0 },
+ { 11, NULL },
+ { -1, func_80851A50 },
+ { 12, &gPlayer135Anim },
+ { 11, NULL },
+ { 0, NULL },
+ { -1, func_80851BE8 },
+ { 11, NULL },
+ { -1, func_80851CA4 },
+ { 11, NULL },
+ { 17, &gPlayer438Anim },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { -1, func_80851D80 },
+ { -1, func_80851DEC },
+ { -1, func_80851E28 },
+ { 18, D_80854B00 },
+ { -1, func_808513BC },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { -1, func_80851ECC },
+ { -1, func_80851FB0 },
+ { -1, func_80852048 },
+ { -1, func_80852174 },
+ { 13, &gPlayer20Anim },
+ { -1, func_80852234 },
+ { 0, NULL },
+ { 0, NULL },
+ { 11, NULL },
+ { -1, func_80852450 },
+ { -1, func_80851688 },
+ { -1, func_80852298 },
+ { 13, &gPlayer155Anim },
+ { -1, func_80852480 },
+ { 13, &gPlayer154Anim },
+ { -1, func_80852328 },
+ { 11, NULL },
+ { 11, NULL },
+ { 12, &gPlayer18Anim },
+ { -1, func_80852358 },
+ { 11, NULL },
+ { 18, D_80854B14 },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { -1, func_80852388 },
+ { 17, &gPlayer43Anim },
+ { 12, &gPlayer42Anim },
+ { 12, &gPlayer43Anim },
+ { 11, NULL },
+ { -1, func_808526EC },
+ { 17, &gPlayer558Anim },
+ { -1, func_808526EC },
+ { 17, &gPlayer558Anim },
+ { 12, &gPlayer149Anim },
+ { 12, &gPlayer165Anim },
+ { 11, NULL },
+ { 12, &gPlayer172Anim },
+ { 12, &gPlayer571Anim },
+ { 13, &gPlayer575Anim },
+ { 12, &gPlayer574Anim },
+ { 12, &gPlayer566Anim },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { -1, func_80852648 },
+ { 11, NULL },
+ { 12, &gPlayer565Anim },
+ { -1, func_808524D0 },
+ { -1, func_80852514 },
+ { -1, func_80852554 },
+ { -1, func_808525C0 },
+ { 11, NULL },
+ { 11, NULL },
+ { 11, NULL },
+ { -1, func_8085283C },
+ { -1, func_808528C8 },
+ { -1, func_808528C8 },
+ { 12, &gPlayer175Anim },
+ { 12, &gPlayer159Anim },
+ { 12, &gPlayer162Anim },
+ { 12, &gPlayer43Anim },
};
void func_80850ED8(GlobalContext* globalCtx, Player* this, LinkAnimationHeader* anim) {
@@ -13187,7 +13252,7 @@ void func_80851368(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
this->stateFlags2 |= 0x400;
this->stateFlags1 &= ~0xC0000;
- func_80832284(globalCtx, this, &D_040032F0);
+ func_80832284(globalCtx, this, &gPlayer511Anim);
}
void func_808513BC(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
@@ -13206,9 +13271,9 @@ void func_808513BC(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
if (this->unk_84F == 1) {
- func_80832C6C(globalCtx, this, &D_04003328);
+ func_80832C6C(globalCtx, this, &gPlayer518Anim);
} else {
- func_80832284(globalCtx, this, &D_04003328);
+ func_80832284(globalCtx, this, &gPlayer518Anim);
}
}
@@ -13356,8 +13421,8 @@ void func_808519C0(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
// unused
LinkAnimationHeader* D_80855190[] = {
- 0x04002720,
- 0x04002360,
+ &gPlayer133Anim,
+ &gPlayer13Anim,
};
Vec3f D_80855198 = { -1.0f, 70.0f, 20.0f };
@@ -13411,7 +13476,8 @@ void func_80851A50(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
}
void func_80851B90(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04002860, -(2.0f / 3.0f), 12.0f, 12.0f, ANIMMODE_ONCE, 0.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer173Anim, -(2.0f / 3.0f), 12.0f, 12.0f, ANIMMODE_ONCE,
+ 0.0f);
}
struct_80832924 D_808551B4[] = {
@@ -13425,8 +13491,8 @@ void func_80851BE8(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
if (this->unk_850 >= 180) {
if (this->unk_850 == 180) {
- LinkAnimation_Change(globalCtx, &this->skelAnime, &D_04003298, (2.0f / 3.0f), 10.0f,
- Animation_GetLastFrame(&D_04003298), ANIMMODE_ONCE, -8.0f);
+ LinkAnimation_Change(globalCtx, &this->skelAnime, &gPlayer500Anim, (2.0f / 3.0f), 10.0f,
+ Animation_GetLastFrame(&gPlayer500Anim), ANIMMODE_ONCE, -8.0f);
}
func_80832924(this, D_808551B4);
}
@@ -13434,7 +13500,7 @@ void func_80851BE8(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
void func_80851CA4(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime) && (this->unk_850 == 0) && (this->actor.bgCheckFlags & 1)) {
- func_80832264(globalCtx, this, &D_04002DB8);
+ func_80832264(globalCtx, this, &gPlayer344Anim);
this->unk_850 = 1;
}
@@ -13444,7 +13510,7 @@ void func_80851CA4(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
}
void func_80851D2C(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80850F1C(globalCtx, this, &D_040030A0);
+ func_80850F1C(globalCtx, this, &gPlayer437Anim);
func_8084B498(this);
Player_SetModels(this, Player_ActionToModelGroup(this, this->itemActionParam));
}
@@ -13474,17 +13540,17 @@ void func_80851E28(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
}
void func_80851E64(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80833064(globalCtx, this, &D_04003318, 0x98);
+ func_80833064(globalCtx, this, &gPlayer516Anim, 0x98);
}
void func_80851E90(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_8083303C(globalCtx, this, &D_04002408, 0x9C);
+ func_8083303C(globalCtx, this, &gPlayer34Anim, 0x9C);
func_80832698(this, NA_SE_VO_LI_GROAN);
}
void func_80851ECC(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_808330EC(globalCtx, this, &D_04002428, 0x9C);
+ func_808330EC(globalCtx, this, &gPlayer38Anim, 0x9C);
}
}
@@ -13499,7 +13565,7 @@ void func_80851F14(GlobalContext* globalCtx, Player* this, LinkAnimationHeader*
void func_80851F84(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
this->actor.shape.shadowDraw = NULL;
- func_80851134(globalCtx, this, &D_04002420);
+ func_80851134(globalCtx, this, &gPlayer37Anim);
}
struct_80832924 D_808551BC[] = {
@@ -13510,7 +13576,7 @@ struct_80832924 D_808551BC[] = {
void func_80851FB0(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_808330EC(globalCtx, this, &D_04002430, 0x9C);
+ func_808330EC(globalCtx, this, &gPlayer39Anim, 0x9C);
this->unk_850 = 1;
} else if (this->unk_850 == 0) {
func_80832924(this, D_808551BC);
@@ -13533,7 +13599,7 @@ void func_80852048(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
}
void func_80852080(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80833064(globalCtx, this, &D_04002340, 0x9D);
+ func_80833064(globalCtx, this, &gPlayer9Anim, 0x9D);
func_80832698(this, NA_SE_VO_LI_FALL_L);
}
@@ -13588,7 +13654,7 @@ void func_80852280(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
void func_80852298(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_8083313C(globalCtx, this, &D_04002378);
+ func_8083313C(globalCtx, this, &gPlayer16Anim);
this->unk_850 = 1;
} else if (this->unk_850 == 0) {
if (LinkAnimation_OnFrame(&this->skelAnime, 10.0f)) {
@@ -13603,7 +13669,7 @@ struct_80832924 D_808551E0[] = {
};
void func_80852328(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80851F14(globalCtx, this, &D_04002770, D_808551E0);
+ func_80851F14(globalCtx, this, &gPlayer143Anim, D_808551E0);
}
struct_80832924 D_808551E8[] = {
@@ -13612,12 +13678,12 @@ struct_80832924 D_808551E8[] = {
};
void func_80852358(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80851F14(globalCtx, this, &D_04002830, D_808551E8);
+ func_80851F14(globalCtx, this, &gPlayer167Anim, D_808551E8);
}
void func_80852388(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
if (LinkAnimation_Update(globalCtx, &this->skelAnime)) {
- func_808322A4(globalCtx, this, &D_04002468);
+ func_808322A4(globalCtx, this, &gPlayer46Anim);
this->unk_850 = 1;
}
@@ -13641,7 +13707,7 @@ struct_80832924 D_808551F0[] = {
};
void func_80852450(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80852414(globalCtx, this, &D_04002378, D_808551F0);
+ func_80852414(globalCtx, this, &gPlayer16Anim, D_808551F0);
}
struct_80832924 D_808551F8[] = {
@@ -13649,7 +13715,7 @@ struct_80832924 D_808551F8[] = {
};
void func_80852480(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
- func_80852414(globalCtx, this, &D_040027D0, D_808551F8);
+ func_80852414(globalCtx, this, &gPlayer155Anim, D_808551F8);
}
void func_808524B0(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
@@ -13677,7 +13743,7 @@ void func_80852564(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
this->linearVelocity = 2.0f;
this->actor.velocity.y = -1.0f;
- func_80832264(globalCtx, this, &D_04002DB0);
+ func_80832264(globalCtx, this, &gPlayer343Anim);
func_80832698(this, NA_SE_VO_LI_FALL_L);
}
@@ -13693,7 +13759,7 @@ void func_808525C0(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
void func_80852608(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
func_80846720(globalCtx, this, 0);
- func_808322D0(globalCtx, this, &D_04002838);
+ func_808322D0(globalCtx, this, &gPlayer168Anim);
}
void func_80852648(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg2) {
@@ -13711,8 +13777,8 @@ void func_80852648(GlobalContext* globalCtx, Player* this, CsCmdActorAction* arg
}
LinkAnimationHeader* D_80855208[] = {
- 0x040034B8,
- 0x04003458,
+ &gPlayer568Anim,
+ &gPlayer556Anim,
};
Vec3s D_80855210[2][2] = {
@@ -13903,7 +13969,7 @@ s32 func_80852F38(GlobalContext* globalCtx, Player* this) {
!(this->stateFlags3 & 0x80)) {
func_80832564(globalCtx, this);
func_80835C58(globalCtx, this, func_8084F308, 0);
- func_80832264(globalCtx, this, &D_04003120);
+ func_80832264(globalCtx, this, &gPlayer453Anim);
this->stateFlags2 |= 0x80;
func_80832224(this);
func_80832698(this, NA_SE_VO_LI_HELD);
@@ -13980,23 +14046,23 @@ void func_80853148(GlobalContext* globalCtx, Actor* actor) {
} else {
if (func_808332B8(this)) {
func_80836898(globalCtx, this, func_8083A2F8);
- func_80832C6C(globalCtx, this, &D_04003328);
+ func_80832C6C(globalCtx, this, &gPlayer518Anim);
} else if ((actor->category != ACTORCAT_NPC) || (this->heldItemActionParam == PLAYER_AP_FISHING_POLE)) {
func_8083A2F8(globalCtx, this);
if (!func_8008E9C4(this)) {
if ((actor != this->naviActor) && (actor->xzDistToPlayer < 40.0f)) {
- func_808322D0(globalCtx, this, &D_04002DF0);
+ func_808322D0(globalCtx, this, &gPlayer351Anim);
} else {
func_80832284(globalCtx, this, func_80833338(this));
}
}
} else {
func_80836898(globalCtx, this, func_8083A2F8);
- func_808322D0(globalCtx, this, (actor->xzDistToPlayer < 40.0f) ? &D_04002DF0 : &D_040031A0);
+ func_808322D0(globalCtx, this, (actor->xzDistToPlayer < 40.0f) ? &gPlayer351Anim : &gPlayer469Anim);
}
- if (this->skelAnime.animation == &D_04002DF0) {
+ if (this->skelAnime.animation == &gPlayer351Anim) {
func_80832F54(globalCtx, this, 0x19);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c b/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c
index 4bf0ee5d08..b3671e9e75 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Blast/z_eff_ss_blast.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_blast.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -28,8 +29,6 @@ EffectSsInit Effect_Ss_Blast_InitVars = {
EffectSsBlast_Init,
};
-extern Gfx D_0401A0B0[];
-
u32 EffectSsBlast_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsBlastParams* initParams = (EffectSsBlastParams*)initParamsx;
@@ -37,7 +36,7 @@ u32 EffectSsBlast_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void
this->pos.y += 5.0f;
this->velocity = initParams->velocity;
this->accel = initParams->accel;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_0401A0B0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffShockwaveDL);
this->life = initParams->life;
this->draw = EffectSsBlast_Draw;
this->update = EffectSsBlast_Update;
diff --git a/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c b/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c
index 4f4f0626de..bc4cf93d35 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Bomb/z_eff_ss_bomb.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_bomb.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
#define rTexIdx regs[1]
@@ -18,15 +19,13 @@ EffectSsInit Effect_Ss_Bomb_InitVars = {
EffectSsBomb_Init,
};
-extern Gfx D_0400BF80[];
-
u32 EffectSsBomb_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsBombInitParams* initParams = (EffectSsBombInitParams*)initParamsx;
Math_Vec3f_Copy(&this->pos, &initParams->pos);
Math_Vec3f_Copy(&this->velocity, &initParams->velocity);
Math_Vec3f_Copy(&this->accel, &initParams->accel);
- this->gfx = SEGMENTED_TO_VIRTUAL(D_0400BF80);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffBombExplosion1DL);
this->life = 20;
this->draw = EffectSsBomb_Draw;
this->update = EffectSsBomb_Update;
@@ -36,11 +35,11 @@ u32 EffectSsBomb_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void*
return 1;
}
-static void* sTextures[] = {
- 0x04007F80,
- 0x04008780,
- 0x04008F80,
- 0x04009780,
+static UNK_PTR sTextures[] = {
+ gEffBombExplosion1Tex,
+ gEffBombExplosion2Tex,
+ gEffBombExplosion3Tex,
+ gEffBombExplosion4Tex,
};
void EffectSsBomb_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
diff --git a/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c b/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c
index 06b3e18829..e97a8e36d6 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Bomb2/z_eff_ss_bomb2.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_bomb2.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
#define rTexIdx regs[1]
@@ -33,10 +34,6 @@ static EffectSsDrawFunc sDrawFuncs[] = {
EffectSsBomb2_DrawLayered,
};
-extern Gfx D_0400BF80[];
-extern Gfx D_0400BFE8[];
-extern Gfx D_0400C040[];
-
u32 EffectSsBomb2_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsBomb2InitParams* initParams = (EffectSsBomb2InitParams*)initParamsx;
@@ -44,7 +41,7 @@ u32 EffectSsBomb2_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void
Math_Vec3f_Copy(&this->pos, &initParams->pos);
Math_Vec3f_Copy(&this->velocity, &initParams->velocity);
Math_Vec3f_Copy(&this->accel, &initParams->accel);
- this->gfx = SEGMENTED_TO_VIRTUAL(D_0400BF80);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffBombExplosion1DL);
this->life = 24;
this->update = EffectSsBomb2_Update;
this->draw = sDrawFuncs[initParams->drawMode];
@@ -63,8 +60,9 @@ u32 EffectSsBomb2_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void
// unused in the original game. looks like EffectSsBomb but with color
void EffectSsBomb2_DrawFade(GlobalContext* globalCtx, u32 index, EffectSs* this) {
- static void* textures[] = {
- 0x04007F80, 0x04008780, 0x04008F80, 0x04009780, 0x04009F80, 0x0400A780, 0x0400AF80, 0x0400B780,
+ static UNK_PTR textures[] = {
+ gEffBombExplosion1Tex, gEffBombExplosion2Tex, gEffBombExplosion3Tex, gEffBombExplosion4Tex,
+ gEffBombExplosion5Tex, gEffBombExplosion6Tex, gEffBombExplosion7Tex, gEffBombExplosion8Tex,
};
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
MtxF mfTrans;
@@ -102,8 +100,9 @@ void EffectSsBomb2_DrawFade(GlobalContext* globalCtx, u32 index, EffectSs* this)
}
void EffectSsBomb2_DrawLayered(GlobalContext* globalCtx, u32 index, EffectSs* this) {
- static void* textures[] = {
- 0x04007F80, 0x04008780, 0x04008F80, 0x04009780, 0x04009F80, 0x0400A780, 0x0400AF80, 0x0400B780,
+ static UNK_PTR textures[] = {
+ gEffBombExplosion1Tex, gEffBombExplosion2Tex, gEffBombExplosion3Tex, gEffBombExplosion4Tex,
+ gEffBombExplosion5Tex, gEffBombExplosion6Tex, gEffBombExplosion7Tex, gEffBombExplosion8Tex,
};
GraphicsContext* gfxCtx = globalCtx->state.gfxCtx;
MtxF mfTrans;
@@ -141,8 +140,8 @@ void EffectSsBomb2_DrawLayered(GlobalContext* globalCtx, u32 index, EffectSs* th
this->rPrimColorA);
gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, 0);
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(textures[this->rTexIdx]));
- gSPDisplayList(POLY_XLU_DISP++, D_0400BFE8);
- gSPDisplayList(POLY_XLU_DISP++, D_0400C040);
+ gSPDisplayList(POLY_XLU_DISP++, gEffBombExplosion2DL);
+ gSPDisplayList(POLY_XLU_DISP++, gEffBombExplosion3DL);
Matrix_MtxToMtxF(mtx2, &mtx2F);
Matrix_Put(&mtx2F);
@@ -153,7 +152,7 @@ void EffectSsBomb2_DrawLayered(GlobalContext* globalCtx, u32 index, EffectSs* th
Matrix_Scale(layer2Scale, layer2Scale, layer2Scale, MTXMODE_APPLY);
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_eff_ss_bomb2.c", 448),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0400C040);
+ gSPDisplayList(POLY_XLU_DISP++, gEffBombExplosion3DL);
layer2Scale -= 0.15f;
}
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c b/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c
index c38732cbe5..906276d8dd 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Bubble/z_eff_ss_bubble.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_bubble.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
@@ -17,17 +18,13 @@ EffectSsInit Effect_Ss_Bubble_InitVars = {
EffectSsBubble_Init,
};
-extern void* D_04055DB0;
-extern void* D_04055EB0;
-extern Gfx D_0401A160[];
-
u32 EffectSsBubble_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsBubbleInitParams* initParams = (EffectSsBubbleInitParams*)initParamsx;
// @bug Rand_ZeroOne in the macro means a random number is generated for both parts of the macro.
// In the base game this works out because both addresses are segment 4, but it may break if
// the addresses were changed to refer to different segments
- this->gfx = SEGMENTED_TO_VIRTUAL(Rand_ZeroOne() < 0.5f ? &D_04055DB0 : &D_04055EB0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(Rand_ZeroOne() < 0.5f ? &gEffBubble1Tex : &gEffBubble2Tex);
this->pos.x = ((Rand_ZeroOne() - 0.5f) * initParams->xzPosRandScale) + initParams->pos.x;
this->pos.y = (((Rand_ZeroOne() - 0.5f) * initParams->yPosRandScale) + initParams->yPosOffset) + initParams->pos.y;
this->pos.z = ((Rand_ZeroOne() - 0.5f) * initParams->xzPosRandScale) + initParams->pos.z;
@@ -54,7 +51,7 @@ void EffectSsBubble_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, 255, 255, 255, 255);
gDPSetEnvColor(POLY_OPA_DISP++, 150, 150, 150, 0);
gSPSegment(POLY_OPA_DISP++, 0x08, this->gfx);
- gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(D_0401A160));
+ gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(gEffBubbleDL));
CLOSE_DISPS(gfxCtx, "../z_eff_ss_bubble.c", 179);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c b/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c
index 06fd3fc9fe..c41e490903 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Dead_Db/z_eff_ss_dead_db.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_dead_db.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
#define rTextIdx regs[1]
@@ -28,15 +29,13 @@ EffectSsInit Effect_Ss_Dead_Db_InitVars = {
EffectSsDeadDb_Init,
};
-extern Gfx D_04031FE0[];
-
u32 EffectSsDeadDb_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsDeadDbInitParams* initParams = (EffectSsDeadDbInitParams*)initParamsx;
this->pos = initParams->pos;
this->velocity = initParams->velocity;
this->accel = initParams->accel;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04031FE0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffEnemyDeathFlameDL);
this->life = initParams->unk_34;
this->flags = 4;
this->rScaleStep = initParams->scaleStep;
@@ -57,9 +56,10 @@ u32 EffectSsDeadDb_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, voi
return 1;
}
-static void* sTextures[] = {
- 0x0402CFE0, 0x0402D7E0, 0x0402DFE0, 0x0402E7E0, 0x0402EFE0,
- 0x0402F7E0, 0x0402FFE0, 0x040307E0, 0x04030FE0, 0x040317E0,
+static UNK_PTR sTextures[] = {
+ gEffEnemyDeathFlame1Tex, gEffEnemyDeathFlame2Tex, gEffEnemyDeathFlame3Tex, gEffEnemyDeathFlame4Tex,
+ gEffEnemyDeathFlame5Tex, gEffEnemyDeathFlame6Tex, gEffEnemyDeathFlame7Tex, gEffEnemyDeathFlame8Tex,
+ gEffEnemyDeathFlame9Tex, gEffEnemyDeathFlame10Tex,
};
void EffectSsDeadDb_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
diff --git a/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c b/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c
index a2c365308c..6e3cb0aff5 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Dead_Dd/z_eff_ss_dead_dd.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_dead_dd.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
#define rPrimColorR regs[2]
@@ -115,7 +116,7 @@ void EffectSsDeadDd_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gSPMatrix(POLY_XLU_DISP++, &D_01000000, G_MTX_NOPUSH | G_MTX_MUL | G_MTX_MODELVIEW);
gDPSetCombineLERP(POLY_XLU_DISP++, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, 0, 0, 0, PRIMITIVE, TEXEL0, 0,
PRIMITIVE, 0);
- gSPDisplayList(POLY_XLU_DISP++, D_04037730);
+ gSPDisplayList(POLY_XLU_DISP++, gEffBurnMark1DL);
}
CLOSE_DISPS(gfxCtx, "../z_eff_ss_dead_dd.c", 259);
diff --git a/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c b/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c
index e42ff4d6d6..85ecb77ecb 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Dead_Ds/z_eff_ss_dead_ds.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_dead_ds.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
#define rTimer regs[1]
@@ -25,8 +26,6 @@ EffectSsInit Effect_Ss_Dead_Ds_InitVars = {
EffectSsDeadDs_Init,
};
-extern Gfx D_04037730[];
-
u32 EffectSsDeadDs_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsDeadDsInitParams* initParams = (EffectSsDeadDsInitParams*)initParamsx;
@@ -104,7 +103,7 @@ void EffectSsDeadDs_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
gDPSetCombineLERP(POLY_XLU_DISP++, 0, 0, 0, PRIMITIVE, TEXEL0, 0, PRIMITIVE, 0, 0, 0, 0, PRIMITIVE, TEXEL0, 0,
PRIMITIVE, 0);
- gSPDisplayList(POLY_XLU_DISP++, D_04037730);
+ gSPDisplayList(POLY_XLU_DISP++, gEffBurnMark1DL);
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_eff_ss_dead_ds.c", 255);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c b/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c
index 8163886a42..e7c6eb0f76 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Dt_Bubble/z_eff_ss_dt_bubble.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_dt_bubble.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -30,17 +31,13 @@ EffectSsInit Effect_Ss_Dt_Bubble_InitVars = {
EffectSsDtBubble_Init,
};
-extern void* D_04055DB0;
-extern void* D_04055EB0;
-extern Gfx D_0401A160[];
-
u32 EffectSsDtBubble_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsDtBubbleInitParams* initParams = (EffectSsDtBubbleInitParams*)initParamsx;
// @bug Rand_ZeroOne in the macro means a random number is generated for both parts of the macro.
// In the base game this works out because both addresses are segment 4, but it may break if
// the addresses were changed to refer to different segments
- this->gfx = SEGMENTED_TO_VIRTUAL(Rand_ZeroOne() < 0.5f ? &D_04055DB0 : &D_04055EB0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(Rand_ZeroOne() < 0.5f ? &gEffBubble1Tex : &gEffBubble2Tex);
this->pos = initParams->pos;
this->velocity = initParams->velocity;
this->accel = initParams->accel;
@@ -92,7 +89,7 @@ void EffectSsDtBubble_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this)
gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB,
(this->rEnvColorA * this->life) / this->rLifespan);
gSPSegment(POLY_XLU_DISP++, 0x08, this->gfx);
- gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(D_0401A160));
+ gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gEffBubbleDL));
CLOSE_DISPS(gfxCtx, "../z_eff_ss_dt_bubble.c", 236);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c b/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c
index ee7fc4a229..544f5c0421 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Dust/z_eff_ss_dust.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_dust.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -35,8 +36,6 @@ static EffectSsUpdateFunc sUpdateFuncs[] = {
EffectSsBlast_UpdateFire,
};
-extern Gfx D_04010050[];
-
u32 EffectSsDust_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
s32 randColorOffset;
EffectSsDustInitParams* initParams = (EffectSsDustInitParams*)initParamsx;
@@ -44,7 +43,7 @@ u32 EffectSsDust_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void*
Math_Vec3f_Copy(&this->pos, &initParams->pos);
Math_Vec3f_Copy(&this->velocity, &initParams->velocity);
Math_Vec3f_Copy(&this->accel, &initParams->accel);
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04010050);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffDustDL);
this->life = initParams->life;
this->update = sUpdateFuncs[initParams->updateMode];
this->draw = EffectSsDust_Draw;
@@ -78,7 +77,7 @@ u32 EffectSsDust_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void*
}
static UNK_PTR sTextures[] = {
- 0x04051DB0, 0x040521B0, 0x040525B0, 0x040529B0, 0x04052DB0, 0x040531B0, 0x040535B0, 0x040539B0,
+ gDust1Tex, gDust2Tex, gDust3Tex, gDust4Tex, gDust5Tex, gDust6Tex, gDust7Tex, gDust8Tex,
};
void EffectSsDust_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
diff --git a/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c b/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c
index 79b8003789..8ce179f3f1 100644
--- a/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c
+++ b/src/overlays/effects/ovl_Effect_Ss_En_Fire/z_eff_ss_en_fire.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_en_fire.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScaleMax regs[0]
#define rScale regs[1]
@@ -26,9 +27,6 @@ EffectSsInit Effect_Ss_En_Fire_InitVars = {
EffectSsEnFire_Init,
};
-extern Gfx D_0404D5A0[];
-extern Gfx D_0404D4E0[];
-
u32 EffectSsEnFire_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsEnFireInitParams* initParams = (EffectSsEnFireInitParams*)initParamsx;
Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
@@ -97,9 +95,9 @@ void EffectSsEnFire_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
0x20, 0x80));
if (((this->rFlags & 0x7FFF) != 0) || (this->life < 18)) {
- gSPDisplayList(POLY_XLU_DISP++, D_0404D5A0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire2DL);
} else {
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(gfxCtx, "../z_eff_en_fire.c", 213);
diff --git a/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c b/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c
index 07178c36ce..a28f8c66de 100644
--- a/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c
+++ b/src/overlays/effects/ovl_Effect_Ss_En_Ice/z_eff_ss_en_ice.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_en_ice.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rLifespan regs[0]
#define rYaw regs[1]
@@ -30,8 +31,6 @@ EffectSsInit Effect_Ss_En_Ice_InitVars = {
EffectSsEnIce_Init,
};
-extern Gfx D_04033818[];
-
u32 EffectSsEnIce_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsEnIceInitParams* initParams = (EffectSsEnIceInitParams*)initParamsx;
@@ -129,7 +128,7 @@ void EffectSsEnIce_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0x80, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB,
this->rPrimColorA);
gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, (u32)alpha);
- gSPDisplayList(POLY_XLU_DISP++, D_04033818);
+ gSPDisplayList(POLY_XLU_DISP++, gEffIceFragment2DL);
CLOSE_DISPS(gfxCtx, "../z_eff_en_ice.c", 294);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c b/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c
index b8fa5dd544..50fef57632 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Fcircle/z_eff_ss_fcircle.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_fcircle.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rUnused regs[3] // probably supposed to be an alpha
#define rRadius regs[8]
@@ -21,8 +22,6 @@ EffectSsInit Effect_Ss_Fcircle_InitVars = {
EffectSsFcircle_Init,
};
-extern Gfx D_040184B0[];
-
u32 EffectSsFcircle_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsFcircleInitParams* initParams = (EffectSsFcircleInitParams*)initParamsx;
@@ -31,7 +30,7 @@ u32 EffectSsFcircle_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, vo
this->vec.x = initParams->pos.x - initParams->actor->world.pos.x;
this->vec.y = initParams->pos.y - initParams->actor->world.pos.y;
this->vec.z = initParams->pos.z - initParams->actor->world.pos.z;
- this->gfx = D_040184B0;
+ this->gfx = gEffFireCircleDL;
this->life = 20;
this->draw = EffectSsFcircle_Draw;
this->update = EffectSsFcircle_Update;
diff --git a/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c b/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c
index 0db7f20ffa..d94366e384 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Fire_Tail/z_eff_ss_fire_tail.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_fire_tail.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rScale regs[0]
#define rLifespan regs[1]
@@ -29,9 +30,6 @@ EffectSsInit Effect_Ss_Fire_Tail_InitVars = {
EffectSsFireTail_Init,
};
-extern Gfx D_0404D5A0[];
-extern Gfx D_0404D4E0[];
-
u32 EffectSsFireTail_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsFireTailInitParams* initParams = (EffectSsFireTailInitParams*)initParamsx;
@@ -129,9 +127,9 @@ void EffectSsFireTail_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this)
(globalCtx->state.frames * -0x14) & 0x1FF, 32, 128));
if (this->rType != 0) {
- gSPDisplayList(POLY_XLU_DISP++, D_0404D5A0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire2DL);
} else {
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
}
CLOSE_DISPS(gfxCtx, "../z_eff_fire_tail.c", 273);
diff --git a/src/overlays/effects/ovl_Effect_Ss_G_Fire/z_eff_ss_g_fire.c b/src/overlays/effects/ovl_Effect_Ss_G_Fire/z_eff_ss_g_fire.c
index 407744e121..fc8644c3d5 100644
--- a/src/overlays/effects/ovl_Effect_Ss_G_Fire/z_eff_ss_g_fire.c
+++ b/src/overlays/effects/ovl_Effect_Ss_G_Fire/z_eff_ss_g_fire.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_g_fire.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
u32 EffectSsGFire_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx);
void EffectSsGFire_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this);
@@ -15,8 +16,6 @@ EffectSsInit Effect_Ss_G_Fire_InitVars = {
EffectSsGFire_Init,
};
-extern Gfx D_0401C220[];
-
u32 EffectSsGFire_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsGFireInitParams* initParams = (EffectSsGFireInitParams*)initParamsx;
Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
@@ -25,7 +24,7 @@ u32 EffectSsGFire_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void
this->pos = initParams->pos;
this->draw = EffectSsGFire_Draw;
this->update = EffectSsGFire_Update;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_0401C220);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffFireFootprintDL);
this->life = 8;
this->flags = 0;
this->rgScale = 200;
@@ -44,8 +43,9 @@ u32 EffectSsGFire_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void
}
void EffectSsGFire_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
- void* textures[] = {
- 0x0401A220, 0x0401A620, 0x0401AA20, 0x0401AE20, 0x0401B220, 0x0401B620, 0x0401BA20, 0x0401BE20,
+ UNK_PTR textures[] = {
+ gEffFireFootprint1Tex, gEffFireFootprint2Tex, gEffFireFootprint3Tex, gEffFireFootprint4Tex,
+ gEffFireFootprint5Tex, gEffFireFootprint6Tex, gEffFireFootprint7Tex, gEffFireFootprint8Tex,
};
s16 texIdx = (this->rgTexIdx / 100) % 7;
diff --git a/src/overlays/effects/ovl_Effect_Ss_G_Magma/z_eff_ss_g_magma.c b/src/overlays/effects/ovl_Effect_Ss_G_Magma/z_eff_ss_g_magma.c
index 381f8c77cf..6392fd3fc9 100644
--- a/src/overlays/effects/ovl_Effect_Ss_G_Magma/z_eff_ss_g_magma.c
+++ b/src/overlays/effects/ovl_Effect_Ss_G_Magma/z_eff_ss_g_magma.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_g_magma.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
u32 EffectSsGMagma_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx);
void EffectSsGMagma_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this);
@@ -15,8 +16,6 @@ EffectSsInit Effect_Ss_G_Magma_InitVars = {
EffectSsGMagma_Init,
};
-extern Gfx D_04024410[];
-
u32 EffectSsGMagma_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsGMagmaInitParams* initParams = (EffectSsGMagmaInitParams*)initParamsx;
Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
@@ -25,7 +24,7 @@ u32 EffectSsGMagma_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, voi
this->pos = initParams->pos;
this->draw = EffectSsGMagma_Draw;
this->update = EffectSsGMagma_Update;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04024410);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffMagmaBubbleDL);
this->life = 16;
this->rgScale = (s16)(Rand_ZeroOne() * 100.0f) + 200;
this->rgTexIdx = 0;
@@ -42,8 +41,10 @@ u32 EffectSsGMagma_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, voi
return 1;
}
-static void* sTextures[] = { 0x04023810, 0x04023990, 0x04023B10, 0x04023C90,
- 0x04023E10, 0x04023F90, 0x04024110, 0x04024290 };
+static void* sTextures[] = {
+ gEffMagmaBubble1Tex, gEffMagmaBubble2Tex, gEffMagmaBubble3Tex, gEffMagmaBubble4Tex,
+ gEffMagmaBubble5Tex, gEffMagmaBubble6Tex, gEffMagmaBubble7Tex, gEffMagmaBubble8Tex,
+};
void EffectSsGMagma_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
s16 texIdx = this->rgTexIdx / 100;
diff --git a/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c b/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c
index 04186f3ce3..483ef01578 100644
--- a/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c
+++ b/src/overlays/effects/ovl_Effect_Ss_G_Ripple/z_eff_ss_g_ripple.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_g_ripple.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rWaterBoxNum regs[0]
#define rRadius regs[1]
@@ -28,9 +29,6 @@ EffectSsInit Effect_Ss_G_Ripple_InitVars = {
EffectSsGRipple_Init,
};
-extern Gfx D_040254B0[];
-extern Gfx D_040244B0[];
-
u32 EffectSsGRipple_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
s32 pad;
Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
@@ -40,7 +38,7 @@ u32 EffectSsGRipple_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, vo
waterBox = NULL;
this->velocity = this->accel = zeroVec;
this->pos = initParams->pos;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_040254B0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffWaterRippleDL);
this->life = initParams->life + 20;
this->flags = 0;
this->draw = EffectSsGRipple_Draw;
@@ -105,7 +103,7 @@ void EffectSsGRipple_DrawRipple(GlobalContext* globalCtx, EffectSs* this, UNK_PT
void EffectSsGRipple_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
if (this->rLifespan == 0) {
- EffectSsGRipple_DrawRipple(globalCtx, this, D_040244B0);
+ EffectSsGRipple_DrawRipple(globalCtx, this, gEffWaterRippleTex);
}
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c b/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c
index 122b190643..7247d3bba2 100644
--- a/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c
+++ b/src/overlays/effects/ovl_Effect_Ss_G_Spk/z_eff_ss_g_spk.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_g_spk.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -28,15 +29,13 @@ EffectSsInit Effect_Ss_G_Spk_InitVars = {
EffectSsGSpk_Init,
};
-extern Gfx D_04025550[];
-
u32 EffectSsGSpk_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsGSpkInitParams* initParams = (EffectSsGSpkInitParams*)initParamsx;
Math_Vec3f_Copy(&this->pos, &initParams->pos);
Math_Vec3f_Copy(&this->velocity, &initParams->velocity);
Math_Vec3f_Copy(&this->accel, &initParams->accel);
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04025550);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffSparkDL);
if (initParams->updateMode == 0) {
this->life = 10;
@@ -66,11 +65,11 @@ u32 EffectSsGSpk_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void*
return 1;
}
-static void* sTextures[] = {
- 0x04055FB0,
- 0x040561B0,
- 0x040563B0,
- 0x040565B0,
+static UNK_PTR sTextures[] = {
+ gEffSpark1Tex,
+ gEffSpark2Tex,
+ gEffSpark3Tex,
+ gEffSpark4Tex,
};
void EffectSsGSpk_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
diff --git a/src/overlays/effects/ovl_Effect_Ss_G_Splash/z_eff_ss_g_splash.c b/src/overlays/effects/ovl_Effect_Ss_G_Splash/z_eff_ss_g_splash.c
index e871a57651..2754f702ec 100644
--- a/src/overlays/effects/ovl_Effect_Ss_G_Splash/z_eff_ss_g_splash.c
+++ b/src/overlays/effects/ovl_Effect_Ss_G_Splash/z_eff_ss_g_splash.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_g_splash.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
//! @bug the reuse of regs[11] means that EffectSs_DrawGEffect will treat the type as an object bank index
// this ends up having no effect because the texture provided does not use segment 6
@@ -19,8 +20,6 @@ EffectSsInit Effect_Ss_G_Splash_InitVars = {
EffectSsGSplash_Init,
};
-extern Gfx D_04027DF0[];
-
u32 EffectSsGSplash_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsGSplashInitParams* initParams = (EffectSsGSplashInitParams*)initParamsx;
Vec3f zeroVec = { 0.0f, 0.0f, 0.0f };
@@ -34,7 +33,7 @@ u32 EffectSsGSplash_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, vo
initParams->scale = 600;
}
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04027DF0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffWaterSplashDL);
this->life = 8;
this->rgScale = initParams->scale;
this->rgTexIdx = 0;
@@ -90,8 +89,9 @@ u32 EffectSsGSplash_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, vo
return 1;
}
-static void* sTextures[] = {
- 0x040255F0, 0x04025AF0, 0x04025FF0, 0x040264F0, 0x040269F0, 0x04026EF0, 0x040273F0, 0x040278F0,
+static UNK_PTR sTextures[] = {
+ gEffWaterSplash1Tex, gEffWaterSplash2Tex, gEffWaterSplash3Tex, gEffWaterSplash4Tex,
+ gEffWaterSplash5Tex, gEffWaterSplash6Tex, gEffWaterSplash7Tex, gEffWaterSplash8Tex,
};
void EffectSsGSplash_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
diff --git a/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c b/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c
index 6c3f1b378d..a76fcc2094 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Hahen/z_eff_ss_hahen.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_hahen.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPitch regs[0]
#define rYaw regs[1]
@@ -24,9 +25,6 @@ EffectSsInit Effect_Ss_Hahen_InitVars = {
EffectSsHahen_Init,
};
-extern Gfx D_0400C0D0[];
-extern Gfx D_0400CD80[];
-
void EffectSsHahen_CheckForObject(EffectSs* this, GlobalContext* globalCtx) {
if (((this->rObjBankIdx = Object_GetIndex(&globalCtx->objectCtx, this->rObjId)) < 0) ||
!Object_IsLoaded(&globalCtx->objectCtx, this->rObjBankIdx)) {
@@ -48,11 +46,11 @@ u32 EffectSsHahen_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void
this->rObjId = initParams->objId;
EffectSsHahen_CheckForObject(this, globalCtx);
} else {
- this->gfx = SEGMENTED_TO_VIRTUAL(D_0400C0D0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffFragments1DL);
this->rObjId = -1;
}
- if ((this->rObjId == OBJECT_HAKA_OBJECTS) && (this->gfx == D_0400CD80)) {
+ if ((this->rObjId == OBJECT_HAKA_OBJECTS) && (this->gfx == gEffFragments2DL)) {
this->draw = EffectSsHahen_DrawGray;
} else {
this->draw = EffectSsHahen_Draw;
diff --git a/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c b/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c
index 8f5cd55ea4..863bd09f96 100644
--- a/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c
+++ b/src/overlays/effects/ovl_Effect_Ss_HitMark/z_eff_ss_hitmark.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_hitmark.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rTexIdx regs[0]
#define rType regs[1]
@@ -26,11 +27,13 @@ static Color_RGB8 sColors[] = {
{ 255, 255, 255 }, { 0, 255, 200 }, { 255, 255, 255 }, { 150, 0, 255 },
};
-static void* sTextures[] = {
- 0x0401F370, 0x0401F4F0, 0x0401F670, 0x0401F7F0, 0x0401F970, 0x0401FAF0, 0x0401FC70, 0x0401FDF0,
- 0x0401FF70, 0x040200F0, 0x04020270, 0x040203F0, 0x04020570, 0x040206F0, 0x04020870, 0x040209F0,
- 0x04020B70, 0x04020CF0, 0x04020E70, 0x04020FF0, 0x04021170, 0x040212F0, 0x04021470, 0x040215F0,
- 0x0401F370, 0x0401F4F0, 0x0401F670, 0x0401F7F0, 0x0401F970, 0x0401FAF0, 0x0401FC70, 0x0401FDF0,
+static UNK_PTR sTextures[] = {
+ gEffHitMark1Tex, gEffHitMark2Tex, gEffHitMark3Tex, gEffHitMark4Tex, gEffHitMark5Tex, gEffHitMark6Tex,
+ gEffHitMark7Tex, gEffHitMark8Tex, gEffHitMark9Tex, gEffHitMark10Tex, gEffHitMark11Tex, gEffHitMark12Tex,
+ gEffHitMark13Tex, gEffHitMark14Tex, gEffHitMark15Tex, gEffHitMark16Tex, gEffHitMark17Tex, gEffHitMark18Tex,
+ gEffHitMark19Tex, gEffHitMark20Tex, gEffHitMark21Tex, gEffHitMark22Tex, gEffHitMark23Tex, gEffHitMark24Tex,
+ gEffHitMark1Tex, gEffHitMark2Tex, gEffHitMark3Tex, gEffHitMark4Tex, gEffHitMark5Tex, gEffHitMark6Tex,
+ gEffHitMark7Tex, gEffHitMark8Tex,
};
EffectSsInit Effect_Ss_HitMark_InitVars = {
@@ -42,7 +45,7 @@ u32 EffectSsHitMark_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, vo
s32 colorIdx;
EffectSsHitMarkInitParams* initParams = (EffectSsHitMarkInitParams*)initParamsx;
this->pos = initParams->pos;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04021770);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffHitMarkDL);
if (initParams->type == EFFECT_HITMARK_DUST) {
this->life = 16;
diff --git a/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c b/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c
index 61de667e8b..2d1cb502c6 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Ice_Piece/z_eff_ss_ice_piece.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_ice_piece.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rLifespan regs[0]
#define rYaw regs[1]
@@ -21,7 +22,7 @@ EffectSsInit Effect_Ss_Ice_Piece_InitVars = {
EffectSsIcePiece_Init,
};
-extern Gfx D_04033720[];
+extern Gfx gEffIceFragment1DL[];
u32 EffectSsIcePiece_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsIcePieceInitParams* initParams = (EffectSsIcePieceInitParams*)initParamsx;
@@ -74,7 +75,7 @@ void EffectSsIcePiece_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this)
gSPSegment(POLY_XLU_DISP++, 0x08,
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, 0, (1 * frames) % 256, 0x20, 0x10, 1, 0, (2 * frames) % 256,
0x40, 0x20));
- gSPDisplayList(POLY_XLU_DISP++, D_04033720);
+ gSPDisplayList(POLY_XLU_DISP++, gEffIceFragment1DL);
CLOSE_DISPS(gfxCtx, "../z_eff_ice_piece.c", 209);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c b/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c
index f87064e47e..aac599314d 100644
--- a/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c
+++ b/src/overlays/effects/ovl_Effect_Ss_K_Fire/z_eff_ss_k_fire.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_k_fire.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rAlpha regs[0]
#define rScroll regs[2]
@@ -22,8 +23,6 @@ EffectSsInit Effect_Ss_K_Fire_InitVars = {
EffectSsKFire_Init,
};
-extern Gfx D_0404D4E0[];
-
u32 EffectSsKFire_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsKFireInitParams* initParams = (EffectSsKFireInitParams*)initParamsx;
@@ -78,7 +77,7 @@ void EffectSsKFire_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_eff_k_fire.c", 215),
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
- gSPDisplayList(POLY_XLU_DISP++, D_0404D4E0);
+ gSPDisplayList(POLY_XLU_DISP++, gEffFire1DL);
CLOSE_DISPS(gfxCtx, "../z_eff_k_fire.c", 220);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c b/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c
index dbf844065c..41dceb770b 100644
--- a/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c
+++ b/src/overlays/effects/ovl_Effect_Ss_KiraKira/z_eff_ss_kirakira.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_kirakira.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rRotSpeed regs[0]
#define rYaw regs[1]
@@ -31,8 +32,6 @@ EffectSsInit Effect_Ss_KiraKira_InitVars = {
EffectSsKiraKira_Init,
};
-extern Gfx D_04037880[];
-
u32 EffectSsKiraKira_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsKiraKiraInitParams* initParams = (EffectSsKiraKiraInitParams*)initParamsx;
@@ -42,12 +41,12 @@ u32 EffectSsKiraKira_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, v
if ((this->life = initParams->life) < 0) {
this->life = -this->life;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04037880);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffFairySparklesDL);
this->update = func_809AAD6C;
this->rEnvColorA = initParams->scale;
this->rScale = 0;
} else {
- this->gfx = SEGMENTED_TO_VIRTUAL(D_04037880);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffFairySparklesDL);
if (initParams->updateMode == 0) {
this->update = func_809AABF0;
diff --git a/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c b/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c
index 9e1a2b3258..3e229e326d 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Lightning/z_eff_ss_lightning.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_lightning.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -28,13 +29,11 @@ EffectSsInit Effect_Ss_Lightning_InitVars = {
EffectSsLightning_Init,
};
-extern Gfx D_0402CF30[];
-
u32 EffectSsLightning_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsLightningInitParams* initParams = (EffectSsLightningInitParams*)initParamsx;
this->pos = initParams->pos;
- this->gfx = SEGMENTED_TO_VIRTUAL(D_0402CF30);
+ this->gfx = SEGMENTED_TO_VIRTUAL(gEffLightningDL);
this->life = initParams->life;
this->draw = EffectSsLightning_Draw;
this->update = EffectSsLightning_Update;
@@ -67,8 +66,9 @@ void EffectSsLightning_NewLightning(GlobalContext* globalCtx, Vec3f* pos, s16 ya
EffectSs_Insert(globalCtx, &newLightning);
}
-static void* sTextures[] = {
- 0x04029F30, 0x0402A530, 0x0402AB30, 0x0402B130, 0x0402B730, 0x0402BD30, 0x0402C330, 0x0402C930,
+static UNK_PTR sTextures[] = {
+ gEffLightning1Tex, gEffLightning2Tex, gEffLightning3Tex, gEffLightning4Tex,
+ gEffLightning5Tex, gEffLightning6Tex, gEffLightning7Tex, gEffLightning8Tex,
};
void EffectSsLightning_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
diff --git a/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c b/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c
index 2b0467a8ae..251856139e 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Sibuki/z_eff_ss_sibuki.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_sibuki.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -27,10 +28,6 @@ EffectSsInit Effect_Ss_Sibuki_InitVars = {
EffectSsSibuki_Init,
};
-extern void* D_04055EB0;
-extern void* D_04055DB0;
-extern Gfx D_0401A160[];
-
u32 EffectSsSibuki_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsSibukiInitParams* initParams = (EffectSsSibukiInitParams*)initParamsx;
@@ -39,9 +36,9 @@ u32 EffectSsSibuki_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, voi
this->accel = initParams->accel;
if (KREG(2) != 0) {
- this->gfx = SEGMENTED_TO_VIRTUAL(&D_04055EB0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(&gEffBubble2Tex);
} else {
- this->gfx = SEGMENTED_TO_VIRTUAL(&D_04055DB0);
+ this->gfx = SEGMENTED_TO_VIRTUAL(&gEffBubble1Tex);
}
this->life = ((s16)((Rand_ZeroOne() * (500.0f + KREG(64))) * 0.01f)) + KREG(65) + 10;
@@ -76,7 +73,7 @@ void EffectSsSibuki_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gDPSetPrimColor(POLY_OPA_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA);
gDPSetEnvColor(POLY_OPA_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA);
gSPSegment(POLY_OPA_DISP++, 0x08, this->gfx);
- gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(D_0401A160));
+ gSPDisplayList(POLY_OPA_DISP++, SEGMENTED_TO_VIRTUAL(gEffBubbleDL));
CLOSE_DISPS(gfxCtx, "../z_eff_ss_sibuki.c", 198);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c b/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c
index 5b41efccc8..bd8277a1c3 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Sibuki2/z_eff_ss_sibuki2.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_sibuki2.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rPrimColorR regs[0]
#define rPrimColorG regs[1]
@@ -26,8 +27,6 @@ EffectSsInit Effect_Ss_Sibuki2_InitVars = {
EffectSsSibuki2_Init,
};
-extern Gfx D_0401E2C0[];
-
u32 EffectSsSibuki2_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsSibuki2InitParams* initParams = (EffectSsSibuki2InitParams*)initParamsx;
@@ -51,8 +50,9 @@ u32 EffectSsSibuki2_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, vo
return 1;
}
-static void* sTextures[] = {
- 0x0401C2C0, 0x0401C2C0, 0x0401C6C0, 0x0401CAC0, 0x0401CEC0, 0x0401D2C0, 0x0401D6C0, 0x0401DAC0, 0x0401DEC0,
+static UNK_PTR sTextures[] = {
+ gEffUnusedBubbles1Tex, gEffUnusedBubbles1Tex, gEffUnusedBubbles2Tex, gEffUnusedBubbles3Tex, gEffUnusedBubbles4Tex,
+ gEffUnusedBubbles5Tex, gEffUnusedBubbles6Tex, gEffUnusedBubbles7Tex, gEffUnusedBubbles8Tex,
};
void EffectSsSibuki2_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
@@ -69,7 +69,7 @@ void EffectSsSibuki2_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, this->rPrimColorR, this->rPrimColorG, this->rPrimColorB, this->rPrimColorA);
gDPSetEnvColor(POLY_XLU_DISP++, this->rEnvColorR, this->rEnvColorG, this->rEnvColorB, this->rEnvColorA);
gSPSegment(POLY_XLU_DISP++, 0x08, SEGMENTED_TO_VIRTUAL(sTextures[this->rTexIdx]));
- gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(D_0401E2C0));
+ gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(gEffUnusedBubblesDL));
CLOSE_DISPS(gfxCtx, "../z_eff_ss_sibuki2.c", 198);
}
diff --git a/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c b/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c
index 0861f45b9b..6980f59811 100644
--- a/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c
+++ b/src/overlays/effects/ovl_Effect_Ss_Stone1/z_eff_ss_stone1.c
@@ -5,6 +5,7 @@
*/
#include "z_eff_ss_stone1.h"
+#include "objects/gameplay_keep/gameplay_keep.h"
#define rReg0 regs[0]
@@ -24,18 +25,16 @@ typedef struct {
} EffStoneDrawInfo;
static EffStoneDrawInfo sDrawInfo[] = {
- { 0x04029A90, { 200, 0, 0, 255 }, { 0, 0, 0, 255 } },
- { 0x04029690, { 255, 100, 0, 255 }, { 100, 0, 0, 255 } },
- { 0x04029290, { 255, 200, 0, 255 }, { 200, 0, 0, 255 } },
- { 0x04028E90, { 255, 255, 0, 255 }, { 255, 0, 0, 255 } },
- { 0x04028A90, { 255, 255, 150, 255 }, { 255, 150, 0, 255 } },
- { 0x04028690, { 255, 255, 255, 255 }, { 255, 255, 0, 255 } },
- { 0x04028290, { 255, 255, 255, 255 }, { 0, 255, 0, 255 } },
- { 0x04027E90, { 255, 255, 255, 255 }, { 0, 255, 255, 255 } },
+ { gUnknownEffStone8Tex, { 200, 0, 0, 255 }, { 0, 0, 0, 255 } },
+ { gUnknownEffStone7Tex, { 255, 100, 0, 255 }, { 100, 0, 0, 255 } },
+ { gUnknownEffStone6Tex, { 255, 200, 0, 255 }, { 200, 0, 0, 255 } },
+ { gUnknownEffStone5Tex, { 255, 255, 0, 255 }, { 255, 0, 0, 255 } },
+ { gUnknownEffStone4Tex, { 255, 255, 150, 255 }, { 255, 150, 0, 255 } },
+ { gUnknownEffStone3Tex, { 255, 255, 255, 255 }, { 255, 255, 0, 255 } },
+ { gUnknownEffStone2Tex, { 255, 255, 255, 255 }, { 0, 255, 0, 255 } },
+ { gUnknownEffStone1Tex, { 255, 255, 255, 255 }, { 0, 255, 255, 255 } },
};
-extern Gfx D_04029E90[];
-
u32 EffectSsStone1_Init(GlobalContext* globalCtx, u32 index, EffectSs* this, void* initParamsx) {
EffectSsStone1InitParams* initParams = (EffectSsStone1InitParams*)initParamsx;
Vec3f pos = initParams->pos;
@@ -70,7 +69,7 @@ void EffectSsStone1_Draw(GlobalContext* globalCtx, u32 index, EffectSs* this) {
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, drawParams->primColor.r, drawParams->primColor.g, drawParams->primColor.b,
255);
gDPSetEnvColor(POLY_XLU_DISP++, drawParams->envColor.r, drawParams->envColor.g, drawParams->envColor.b, 255);
- gSPDisplayList(POLY_XLU_DISP++, D_04029E90);
+ gSPDisplayList(POLY_XLU_DISP++, gUnknownEffStoneDL);
CLOSE_DISPS(gfxCtx, "../z_eff_ss_stone1.c", 183);
}
diff --git a/tools/ZAPD/.gitrepo b/tools/ZAPD/.gitrepo
index 3fbd6a6ddf..e9c9dcfe8e 100644
--- a/tools/ZAPD/.gitrepo
+++ b/tools/ZAPD/.gitrepo
@@ -6,7 +6,7 @@
[subrepo]
remote = https://github.com/zeldaret/ZAPD.git
branch = master
- commit = 2e1174063f3ed6bcf929bc7093cd2d1b05f8518b
- parent = d73976503126d10a82016f8f72fac4092dff1932
+ commit = f84d8337bdc55f39dfa5a6dbb39a4fcae0b24e1c
+ parent = 1d4d75f09bc6939438dd4b0fe6e1c212c3f1e198
method = merge
cmdver = 0.4.3
diff --git a/tools/ZAPD/ZAPD/Directory.h b/tools/ZAPD/ZAPD/Directory.h
index ab682972c3..bddec9d466 100644
--- a/tools/ZAPD/ZAPD/Directory.h
+++ b/tools/ZAPD/ZAPD/Directory.h
@@ -26,6 +26,17 @@ public:
static void CreateDirectory(const std::string& path)
{
- fs::create_directory(path);
+ std::string curPath = "";
+ std::vector split = StringHelper::Split(path, "/");
+
+ for (std::string s : split)
+ {
+ curPath += s + "/";
+
+ if (!Exists(curPath))
+ fs::create_directory(curPath);
+ }
+
+ //fs::create_directory(path);
}
};
diff --git a/tools/ZAPD/ZAPD/Globals.cpp b/tools/ZAPD/ZAPD/Globals.cpp
index 16ecd4bc14..572ce2ef76 100644
--- a/tools/ZAPD/ZAPD/Globals.cpp
+++ b/tools/ZAPD/ZAPD/Globals.cpp
@@ -17,6 +17,7 @@ Globals::Globals()
symbolMap = std::map ();
segmentRefs = map();
segmentRefFiles = map();
+ game = ZGame::OOT_RETAIL;
genSourceFile = true;
testMode = false;
profile = false;
@@ -117,3 +118,12 @@ bool Globals::HasSegment(int segment)
{
return std::find(segments.begin(), segments.end(), segment) != segments.end();
}
+
+GameConfig::GameConfig()
+{
+ segmentRefs = map();
+ segmentRefFiles = map();
+ symbolMap = std::map();
+ actorList = std::vector();
+ objectList = std::vector();
+}
diff --git a/tools/ZAPD/ZAPD/Globals.h b/tools/ZAPD/ZAPD/Globals.h
index 8b68291cc6..7b034de135 100644
--- a/tools/ZAPD/ZAPD/Globals.h
+++ b/tools/ZAPD/ZAPD/Globals.h
@@ -13,6 +13,8 @@ typedef enum VerbosityLevel {
VERBOSITY_DEBUG
} VerbosityLevel;
+class GameConfig;
+
class Globals
{
public:
@@ -27,6 +29,7 @@ public:
ZFileMode fileMode;
std::string baseRomPath, inputPath, outputPath, cfgPath;
TextureType texType;
+ ZGame game;
std::vector files;
std::vector segments;
@@ -43,6 +46,21 @@ public:
bool HasSegment(int segment);
};
+class GameConfig
+{
+public:
+ std::map segmentRefs;
+ std::map segmentRefFiles;
+ std::map symbolMap;
+ std::vector actorList;
+ std::vector objectList;
+
+ GameConfig();
+
+private:
+
+};
+
/*
* Note: In being able to track references across files, there are a few major files that make use of segments...
* Segment 1: nintendo_rogo_static/title_static
diff --git a/tools/ZAPD/ZAPD/Main.cpp b/tools/ZAPD/ZAPD/Main.cpp
index 8d53c979e2..4ae1174510 100644
--- a/tools/ZAPD/ZAPD/Main.cpp
+++ b/tools/ZAPD/ZAPD/Main.cpp
@@ -7,6 +7,7 @@
#include "Overlays/ZOverlay.h"
#include "Path.h"
#include "File.h"
+#include "Directory.h"
#include "Globals.h"
#if !defined(_MSC_VER) && !defined(__CYGWIN__)
diff --git a/tools/ZAPD/ZAPD/ZAPD.vcxproj.filters b/tools/ZAPD/ZAPD/ZAPD.vcxproj.filters
index aee2be95fd..8f784fd12b 100644
--- a/tools/ZAPD/ZAPD/ZAPD.vcxproj.filters
+++ b/tools/ZAPD/ZAPD/ZAPD.vcxproj.filters
@@ -199,7 +199,7 @@
Source Files\Z64
- Source Files
+ Source Files\Z64
diff --git a/tools/ZAPD/ZAPD/ZAnimation.cpp b/tools/ZAPD/ZAPD/ZAnimation.cpp
index f1fccf622e..a130268772 100644
--- a/tools/ZAPD/ZAPD/ZAnimation.cpp
+++ b/tools/ZAPD/ZAPD/ZAnimation.cpp
@@ -37,8 +37,6 @@ void ZAnimation::Save(const std::string& outFolder)
void ZAnimation::ParseXML(tinyxml2::XMLElement* reader)
{
ZResource::ParseXML(reader);
-
- name = reader->Attribute("Name");
}
string ZAnimation::GetSourceOutputCode(const std::string& prefix)
diff --git a/tools/ZAPD/ZAPD/ZDisplayList.cpp b/tools/ZAPD/ZAPD/ZDisplayList.cpp
index f1f1eb3e61..3bf96e168a 100644
--- a/tools/ZAPD/ZAPD/ZDisplayList.cpp
+++ b/tools/ZAPD/ZAPD/ZDisplayList.cpp
@@ -26,6 +26,7 @@ ZDisplayList::ZDisplayList() : ZResource()
lastTexIsPalette = false;
name = "";
scene = nullptr;
+ dListType = Globals::Instance->game == ZGame::OOT_SW97 ? DListType::F3DEX : DListType::F3DZEX;
fileData = vector();
instructions = vector();
@@ -83,16 +84,364 @@ void ZDisplayList::ParseRawData()
instructions.push_back(BitConverter::ToUInt64BE(rawDataArr, (i * 8)));
}
-int ZDisplayList::GetDListLength(vector rawData, int rawDataIndex)
+void ZDisplayList::ParseF3DZEX(F3DZEXOpcode opcode, uint64_t data, int i, std::string prefix, char* line)
+{
+ switch (opcode)
+ {
+ case F3DZEXOpcode::G_NOOP:
+ sprintf(line, "gsDPNoOpTag(0x%08lX),", data & 0xFFFFFFFF);
+ break;
+ case F3DZEXOpcode::G_DL:
+ Opcode_G_DL(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_MODIFYVTX:
+ Opcode_G_MODIFYVTX(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_CULLDL:
+ Opcode_G_CULLDL(data, i, prefix, line);
+ break;
+ /*case F3DZEXOpcode::G_BRANCH_Z:
+ {
+ int aaa = (data & 0x00FFF00000000000) >> 44;
+ int bbb = (data & 0x00000FFF00000000) >> 32;
+ int zzzzzzzz = (data & 0x00000000FFFFFFFF);
+
+ sprintf(line, "gsSPBranchLessZraw(%i, %i, %i),", );
+ }
+ break;*/
+ case F3DZEXOpcode::G_TRI1:
+ Opcode_G_TRI1(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_TRI2:
+ Opcode_G_TRI2(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_QUAD:
+ {
+ int aa = ((data & 0x00FF000000000000ULL) >> 48) / 2;
+ int bb = ((data & 0x0000FF0000000000ULL) >> 40) / 2;
+ int cc = ((data & 0x000000FF00000000ULL) >> 32) / 2;
+ int dd = ((data & 0x000000000000FFULL)) / 2;
+ sprintf(line, "gsSP1Quadrangle(%i, %i, %i, %i, 0),", aa, bb, cc, dd);
+ }
+ break;
+ case F3DZEXOpcode::G_VTX:
+ {
+ Opcode_G_VTX(data, i, prefix, line);
+ }
+ break;
+ case F3DZEXOpcode::G_SETTIMG: // HOTSPOT
+ {
+ Opcode_G_SETTIMG(data, i, prefix, line);
+ }
+ break;
+ case F3DZEXOpcode::G_GEOMETRYMODE:
+ {
+ int cccccc = (data & 0x00FFFFFF00000000) >> 32;
+ int ssssssss = (data & 0xFFFFFFFF);
+ string geoModeStr = "G_TEXTURE_ENABLE";
+
+ int geoModeParam = ~cccccc;
+
+ if (ssssssss != 0)
+ geoModeParam = ssssssss;
+
+ if (geoModeParam & 0x00000001)
+ geoModeStr += " | G_ZBUFFER";
+
+ if (geoModeParam & 0x00000004)
+ geoModeStr += " | G_SHADE";
+
+ if (geoModeParam & 0x00000200)
+ geoModeStr += " | G_CULL_FRONT";
+
+ if (geoModeParam & 0x00000400)
+ geoModeStr += " | G_CULL_BACK";
+
+ if (geoModeParam & 0x00010000)
+ geoModeStr += " | G_FOG";
+
+ if (geoModeParam & 0x00020000)
+ geoModeStr += " | G_LIGHTING";
+
+ if (geoModeParam & 0x00040000)
+ geoModeStr += " | G_TEXTURE_GEN";
+
+ if (geoModeParam & 0x00080000)
+ geoModeStr += " | G_TEXTURE_GEN_LINEAR";
+
+ if (geoModeParam & 0x00200000)
+ geoModeStr += " | G_SHADING_SMOOTH";
+
+ if (geoModeParam & 0x00800000)
+ geoModeStr += " | G_CLIPPING";
+
+ if (ssssssss != 0)
+ {
+ if ((~cccccc & 0xFF000000) != 0)
+ sprintf(line, "gsSPSetGeometryMode(%s),", geoModeStr.c_str());
+ else
+ sprintf(line, "gsSPLoadGeometryMode(%s),", geoModeStr.c_str());
+ }
+ else
+ sprintf(line, "gsSPClearGeometryMode(%s),", geoModeStr.c_str());
+
+ //sprintf(line, "gsSPGeometryMode(0x%08X, 0x%08X),", ~cccccc, ssssssss);
+ }
+ break;
+ case F3DZEXOpcode::G_SETPRIMCOLOR:
+ Opcode_G_SETPRIMCOLOR(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_SETOTHERMODE_L:
+ Opcode_G_SETOTHERMODE_L(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_SETOTHERMODE_H:
+ Opcode_G_SETOTHERMODE_H(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_SETTILE:
+ Opcode_G_SETTILE(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_SETTILESIZE:
+ Opcode_G_SETTILESIZE(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_LOADBLOCK:
+ Opcode_G_LOADBLOCK(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_TEXTURE:
+ Opcode_G_TEXTURE(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_RDPSETOTHERMODE:
+ {
+ int hhhhhh = (data & 0x00FFFFFF00000000) >> 32;
+ int llllllll = (data & 0x00000000FFFFFFFF);
+
+ sprintf(line, "gsDPSetOtherMode(%i, %i),", hhhhhh, llllllll);
+ }
+ break;
+ case F3DZEXOpcode::G_POPMTX:
+ {
+ sprintf(line, "gsSPPopMatrix(%li),", data);
+ }
+ break;
+ case F3DZEXOpcode::G_LOADTLUT:
+ Opcode_G_LOADTLUT(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_SETENVCOLOR:
+ {
+ uint8_t r = (uint8_t)((data & 0xFF000000) >> 24);
+ uint8_t g = (uint8_t)((data & 0x00FF0000) >> 16);
+ uint8_t b = (uint8_t)((data & 0xFF00FF00) >> 8);
+ uint8_t a = (uint8_t)((data & 0x000000FF) >> 0);
+
+ sprintf(line, "gsDPSetEnvColor(%i, %i, %i, %i),", r, g, b, a);
+ }
+ break;
+ case F3DZEXOpcode::G_SETCOMBINE:
+ {
+ Opcode_G_SETCOMBINE(data, i, prefix, line);
+ }
+ break;
+ case F3DZEXOpcode::G_RDPLOADSYNC:
+ sprintf(line, "gsDPLoadSync(),");
+ break;
+ case F3DZEXOpcode::G_RDPPIPESYNC:
+ sprintf(line, "gsDPPipeSync(),");
+ break;
+ case F3DZEXOpcode::G_RDPTILESYNC:
+ sprintf(line, "gsDPTileSync(),");
+ break;
+ case F3DZEXOpcode::G_RDPFULLSYNC:
+ sprintf(line, "gsDPFullSync(),");
+ break;
+ case F3DZEXOpcode::G_ENDDL:
+ Opcode_G_ENDDL(data, i, prefix, line);
+ break;
+ case F3DZEXOpcode::G_RDPHALF_1:
+ {
+ uint64_t data2 = instructions[i + 1];
+ uint32_t h = (data & 0xFFFFFFFF);
+ F3DZEXOpcode opcode2 = (F3DZEXOpcode)(instructions[i + 1] >> 56);
+
+ if (opcode2 == F3DZEXOpcode::G_BRANCH_Z)
+ {
+ uint32_t a = (data2 & 0x00FFF00000000000) >> 44;
+ uint32_t b = (data2 & 0x00000FFF00000000) >> 32;
+ uint32_t z = (data2 & 0x00000000FFFFFFFF) >> 0;
+
+ //sprintf(line, "gsDPWord(%i, 0),", h);
+ sprintf(line, "gsSPBranchLessZraw(%sDlist0x%06X, 0x%02X, 0x%02X),", prefix.c_str(), h & 0x00FFFFFF, (a / 5) | (b / 2), z);
+
+ ZDisplayList* nList = new ZDisplayList(fileData, h & 0x00FFFFFF, GetDListLength(fileData, h & 0x00FFFFFF, dListType));
+ nList->scene = scene;
+ nList->parent = parent;
+ otherDLists.push_back(nList);
+
+ i++;
+ }
+ }
+ break;
+ /*case F3DZEXOpcode::G_BRANCH_Z:
+ {
+ uint8_t h = (data & 0xFFFFFFFF);
+
+ sprintf(line, "gsSPBranchLessZraw(%i, %i, %i),", h);
+ }
+ break;*/
+ case F3DZEXOpcode::G_MTX:
+ Opcode_G_MTX(data, i, prefix, line);
+ break;
+ default:
+ sprintf(line, "// Opcode 0x%02X unimplemented!", (uint32_t)opcode);
+ break;
+ }
+}
+
+void ZDisplayList::ParseF3DEX(F3DEXOpcode opcode, uint64_t data, int i, std::string prefix, char* line)
+{
+ switch (opcode)
+ {
+ case F3DEXOpcode::G_NOOP:
+ sprintf(line, "gsDPNoOpTag(0x%08lX),", data & 0xFFFFFFFF);
+ break;
+ case F3DEXOpcode::G_VTX:
+ Opcode_G_VTX(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_DL:
+ Opcode_G_DL(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_CULLDL:
+ Opcode_G_CULLDL(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_MODIFYVTX:
+ Opcode_G_MODIFYVTX(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_MTX:
+ Opcode_G_MTX(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_TRI1:
+ Opcode_G_TRI1(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_TRI2:
+ Opcode_G_TRI2(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_ENDDL:
+ Opcode_G_ENDDL(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_RDPLOADSYNC:
+ sprintf(line, "gsDPLoadSync(),");
+ break;
+ case F3DEXOpcode::G_RDPPIPESYNC:
+ sprintf(line, "gsDPPipeSync(),");
+ break;
+ case F3DEXOpcode::G_RDPTILESYNC:
+ sprintf(line, "gsDPTileSync(),");
+ break;
+ case F3DEXOpcode::G_RDPFULLSYNC:
+ sprintf(line, "gsDPFullSync(),");
+ break;
+ case F3DEXOpcode::G_TEXTURE:
+ Opcode_G_TEXTURE(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETTIMG:
+ Opcode_G_SETTIMG(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETTILE:
+ Opcode_G_SETTILE(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETTILESIZE:
+ Opcode_G_SETTILESIZE(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_LOADBLOCK:
+ Opcode_G_LOADBLOCK(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETCOMBINE:
+ Opcode_G_SETCOMBINE(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETPRIMCOLOR:
+ Opcode_G_SETPRIMCOLOR(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETOTHERMODE_L:
+ Opcode_G_SETOTHERMODE_L(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_SETOTHERMODE_H:
+ Opcode_G_SETOTHERMODE_H(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_LOADTLUT:
+ Opcode_G_LOADTLUT(data, i, prefix, line);
+ break;
+ case F3DEXOpcode::G_CLEARGEOMETRYMODE:
+ case F3DEXOpcode::G_SETGEOMETRYMODE:
+ {
+ int cccccc = (data & 0x00FFFFFF00000000) >> 32;
+ int ssssssss = (data & 0xFFFFFFFF);
+ string geoModeStr = "G_TEXTURE_ENABLE";
+
+ int geoModeParam = ~cccccc;
+
+ if (ssssssss != 0)
+ geoModeParam = ssssssss;
+
+ if (geoModeParam & 0x00000002)
+ geoModeStr += " | G_TEXTURE_ENABLE";
+
+ if (geoModeParam & 0x00000200)
+ geoModeStr += " | G_SHADING_SMOOTH";
+
+ if (geoModeParam & 0x00001000)
+ geoModeStr += " | G_CULL_FRONT";
+
+ if (geoModeParam & 0x00002000)
+ geoModeStr += " | G_CULL_BACK";
+
+ if (geoModeParam & 0x00000001)
+ geoModeStr += " | G_ZBUFFER";
+
+ if (geoModeParam & 0x00000004)
+ geoModeStr += " | G_SHADE";
+
+ if (geoModeParam & 0x00010000)
+ geoModeStr += " | G_FOG";
+
+ if (geoModeParam & 0x00020000)
+ geoModeStr += " | G_LIGHTING";
+
+ if (geoModeParam & 0x00040000)
+ geoModeStr += " | G_TEXTURE_GEN";
+
+ if (geoModeParam & 0x00080000)
+ geoModeStr += " | G_TEXTURE_GEN_LINEAR";
+
+ if (geoModeParam & 0x00800000)
+ geoModeStr += " | G_CLIPPING";
+
+ if (opcode == F3DEXOpcode::G_SETGEOMETRYMODE)
+ sprintf(line, "gsSPSetGeometryMode(%s),", geoModeStr.c_str());
+ else
+ sprintf(line, "gsSPClearGeometryMode(%s),", geoModeStr.c_str());
+ }
+ break;
+ default:
+ sprintf(line, "// Opcode 0x%02X unimplemented!", (uint32_t)opcode);
+ break;
+ }
+}
+
+int ZDisplayList::GetDListLength(vector rawData, int rawDataIndex, DListType dListType)
{
int i = 0;
+ uint8_t endDLOpcode;
+
+ if (dListType == DListType::F3DZEX)
+ endDLOpcode = (uint8_t)F3DZEXOpcode::G_ENDDL;
+ else
+ endDLOpcode = (uint8_t)F3DEXOpcode::G_ENDDL;
+
while (true)
{
- F3DZEXOpcode opcode = (F3DZEXOpcode)rawData[rawDataIndex + (i * 8)];
+ uint8_t opcode = (uint8_t)rawData[rawDataIndex + (i * 8)];
i++;
- if (opcode == F3DZEXOpcode::G_ENDDL)
+ if (opcode == endDLOpcode)
return i * 8;
}
}
@@ -132,6 +481,11 @@ int ZDisplayList::OptimizationChecks(int startIndex, string& output, string pref
int ZDisplayList::OptimizationCheck_LoadTextureBlock(int startIndex, string& output, string prefix)
{
+ if (scene == nullptr)
+ {
+ return -1;
+ }
+
std::vector sequence = { F3DZEXOpcode::G_SETTIMG, F3DZEXOpcode::G_SETTILE, F3DZEXOpcode::G_RDPLOADSYNC, F3DZEXOpcode::G_LOADBLOCK, F3DZEXOpcode::G_RDPPIPESYNC, F3DZEXOpcode::G_SETTILE, F3DZEXOpcode::G_SETTILESIZE };
bool seqRes = SequenceCheck(sequence, startIndex);
@@ -261,13 +615,17 @@ int ZDisplayList::OptimizationCheck_LoadTextureBlock(int startIndex, string& out
texStr.c_str(), tmem, rtile, fmtTbl[fmt].c_str(), width2, height2, pal, cms, cmt, masks, maskt, shifts, shiftt);
else
output += StringHelper::Sprintf("gsDPLoadTextureBlock_4b(%s, %s, %i, %i, %i, %i, %i, %i, %i, %i, %i),",
- texStr.c_str(), fmtTbl[fmt].c_str(), width2, height2, pal, cms, cmt, masks, maskt, shifts, shiftt);
+ texStr.c_str(), fmtTbl[fmt].c_str(), width2, height2, pal, cms, cmt, masks, maskt, shifts, shiftt);
}
- /*else if (siz == 2 && sizB == 1)
+ else if (siz == 2 && sizB != 0)
{
- output += StringHelper::Sprintf("gsDPLoadTextureBlock(%s, %s, %s, %i, %i, %i, %i, %i, %i, %i, %i, %i),",
- texStr.c_str(), fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), width2, height2, pal, cms, cmt, masks, maskt, shifts, shiftt);
- }*/
+ if (tmem != 0)
+ output += StringHelper::Sprintf("gsDPLoadMultiBlock(%s, %i, %i, %s, %s, %i, %i, %i, %i, %i, %i, %i, %i, %i),",
+ texStr.c_str(), tmem, rtile, fmtTbl[fmt].c_str(), sizTbl[sizB].c_str(), width2, height2, pal, cms, cmt, masks, maskt, shifts, shiftt);
+ else
+ output += StringHelper::Sprintf("gsDPLoadTextureBlock(%s, %s, %s, %i, %i, %i, %i, %i, %i, %i, %i, %i),",
+ texStr.c_str(), fmtTbl[fmt].c_str(), sizTbl[sizB].c_str(), width2, height2, pal, cms, cmt, masks, maskt, shifts, shiftt);
+ }
else
{
if (siz != sizB)
@@ -303,6 +661,760 @@ int ZDisplayList::OptimizationCheck_LoadTextureBlock(int startIndex, string& out
return -1;
}
+void ZDisplayList::Opcode_G_DL(uint64_t data, int i, std::string prefix, char* line)
+{
+ int pp = (data & 0x00FF000000000000) >> 56;
+ int segNum = (data & 0xFF000000) >> 24;
+
+ Declaration* dListDecl = nullptr;
+
+ if (parent != nullptr)
+ dListDecl = parent->GetDeclaration(SEG2FILESPACE(data));
+
+ if (pp != 0)
+ {
+ if (!Globals::Instance->HasSegment(segNum))
+ sprintf(line, "gsSPBranchList(0x%08lX),", data & 0xFFFFFFFF);
+ else if (dListDecl != nullptr)
+ sprintf(line, "gsSPBranchList(%s),", dListDecl->varName.c_str());
+ else
+ sprintf(line, "gsSPBranchList(%sDlist0x%06lX),", prefix.c_str(), SEG2FILESPACE(data));
+ }
+ else
+ {
+ if (!Globals::Instance->HasSegment(segNum))
+ sprintf(line, "gsSPDisplayList(0x%08lX),", data & 0xFFFFFFFF);
+ else if (dListDecl != nullptr)
+ sprintf(line, "gsSPDisplayList(%s),", dListDecl->varName.c_str());
+ else
+ sprintf(line, "gsSPDisplayList(%sDlist0x%06lX),", prefix.c_str(), SEG2FILESPACE(data));
+ }
+
+ int segmentNumber = (data & 0xFF000000) >> 24;
+
+ if (segmentNumber == 8 || segmentNumber == 9 || segmentNumber == 10 || segmentNumber == 11 || segmentNumber == 12 || segmentNumber == 13) // Used for runtime-generated display lists
+ {
+ if (pp != 0)
+ sprintf(line, "gsSPBranchList(0x%08lX),", data & 0xFFFFFFFF);
+ else
+ sprintf(line, "gsSPDisplayList(0x%08lX),", data & 0xFFFFFFFF);
+ }
+ else
+ {
+ ZDisplayList* nList = new ZDisplayList(fileData, data & 0x00FFFFFF, GetDListLength(fileData, data & 0x00FFFFFF, dListType));
+ nList->scene = scene;
+ nList->parent = parent;
+ otherDLists.push_back(nList);
+ }
+}
+
+void ZDisplayList::Opcode_G_MODIFYVTX(uint64_t data, int i, std::string prefix, char* line)
+{
+ int ww = (data & 0x00FF000000000000ULL) >> 48;
+ int nnnn = (data & 0x0000FFFF00000000ULL) >> 32;
+ int vvvvvvvv = (data & 0x00000000FFFFFFFFULL);
+
+ sprintf(line, "gsSPModifyVertex(%i, %i, %i),", nnnn / 2, ww, vvvvvvvv);
+}
+
+void ZDisplayList::Opcode_G_CULLDL(uint64_t data, int i, std::string prefix, char* line)
+{
+ int vvvv = (data & 0xFFFF00000000) >> 32;
+ int wwww = (data & 0x0000FFFF);
+
+ sprintf(line, "gsSPCullDisplayList(%i, %i),", vvvv / 2, wwww / 2);
+}
+
+void ZDisplayList::Opcode_G_TRI1(uint64_t data, int i, std::string prefix, char* line)
+{
+ if (dListType == DListType::F3DZEX)
+ {
+ int aa = ((data & 0x00FF000000000000ULL) >> 48) / 2;
+ int bb = ((data & 0x0000FF0000000000ULL) >> 40) / 2;
+ int cc = ((data & 0x000000FF00000000ULL) >> 32) / 2;
+ sprintf(line, "gsSP1Triangle(%i, %i, %i, 0),", aa, bb, cc);
+ }
+ else
+ {
+ int aa = ((data & 0x0000000000FF0000ULL) >> 16) / 2;
+ int bb = ((data & 0x000000000000FF00ULL) >> 8) / 2;
+ int cc = ((data & 0x00000000000000FFULL) >> 0) / 2;
+ sprintf(line, "gsSP1Triangle(%i, %i, %i, 0),", aa, bb, cc);
+ }
+}
+
+void ZDisplayList::Opcode_G_TRI2(uint64_t data, int i, std::string prefix, char* line)
+{
+ int aa = ((data & 0x00FF000000000000ULL) >> 48) / 2;
+ int bb = ((data & 0x0000FF0000000000ULL) >> 40) / 2;
+ int cc = ((data & 0x000000FF00000000ULL) >> 32) / 2;
+ int dd = ((data & 0x00000000FF0000ULL) >> 16) / 2;
+ int ee = ((data & 0x0000000000FF00ULL) >> 8) / 2;
+ int ff = ((data & 0x000000000000FFULL) >> 0) / 2;
+ sprintf(line, "gsSP2Triangles(%i, %i, %i, 0, %i, %i, %i, 0),", aa, bb, cc, dd, ee, ff);
+}
+
+void ZDisplayList::Opcode_G_MTX(uint64_t data, int i, std::string prefix, char* line)
+{
+ // TODO: FINISH THIS
+ uint32_t pp = 0;
+ uint32_t mm = (data & 0x00000000FFFFFFFF);
+
+ if (dListType == DListType::F3DEX)
+ pp = (data & 0x00FF000000000000) >> 48;
+ else
+ pp = (data & 0x000000FF00000000) >> 32;
+
+ std::string matrixRef = "";
+
+ if (Globals::Instance->symbolMap.find(mm) != Globals::Instance->symbolMap.end())
+ matrixRef = StringHelper::Sprintf("&%s", Globals::Instance->symbolMap[mm].c_str());
+ else
+ matrixRef = StringHelper::Sprintf("0x%08X", mm);
+
+ sprintf(line, "gsSPMatrix(%s, 0x%02X),", matrixRef.c_str(), pp ^ 0x01);
+}
+
+void ZDisplayList::Opcode_G_VTX(uint64_t data, int i, std::string prefix, char* line)
+{
+ int nn = (data & 0x000FF00000000000ULL) >> 44;
+ int aa = (data & 0x000000FF00000000ULL) >> 32;
+
+ uint32_t vtxAddr = SEG2FILESPACE(data);
+
+ if (GETSEGNUM(data) == 0x80) // Are these vertices defined in code?
+ vtxAddr -= SEG2FILESPACE(parent->baseAddress);
+
+ if (dListType == DListType::F3DZEX)
+ sprintf(line, "gsSPVertex(@r, %i, %i),", nn, ((aa >> 1) - nn));
+ else
+ {
+ uint32_t hi = data >> 32;
+
+#define _SHIFTR( v, s, w ) \
+ (((uint32_t)v >> s) & ((0x01 << w) - 1))
+
+ nn = _SHIFTR(hi, 10, 6);
+
+ sprintf(line, "gsSPVertex(@r, %i, %i),", nn, _SHIFTR(hi, 17, 7));
+ }
+
+ references.push_back(vtxAddr);
+
+ {
+ uint32_t currentPtr = SEG2FILESPACE(data);
+
+ if (GETSEGNUM(data) == 0x80) // Are these vertices defined in code?
+ currentPtr -= SEG2FILESPACE(parent->baseAddress);
+
+ // Check for vertex intersections from other display lists
+ // TODO: These two could probably be condenced to one...
+ if (parent->GetDeclarationRanged(vtxAddr + (nn * 16)) != nullptr)
+ {
+ Declaration* decl = parent->GetDeclarationRanged(vtxAddr + (nn * 16));
+ uint32_t addr = parent->GetDeclarationRangedAddress(vtxAddr + (nn * 16));
+ int diff = addr - vtxAddr;
+ if (diff > 0)
+ nn = diff / 16;
+ else
+ nn = 0;
+ }
+
+ if (parent->GetDeclarationRanged(vtxAddr) != nullptr)
+ {
+ Declaration* decl = parent->GetDeclarationRanged(vtxAddr);
+ uint32_t addr = parent->GetDeclarationRangedAddress(vtxAddr);
+ int diff = addr - vtxAddr;
+ if (diff > 0)
+ nn = diff / 16;
+ else
+ nn = 0;
+ }
+
+ if (nn > 0)
+ {
+ vector vtxList = vector();
+ vtxList.reserve(nn);
+
+ for (int i = 0; i < nn; i++)
+ {
+ Vertex vtx = Vertex(fileData, currentPtr);
+ vtxList.push_back(vtx);
+
+ currentPtr += 16;
+ }
+
+ vertices[vtxAddr] = vtxList;
+ }
+ }
+}
+
+void ZDisplayList::Opcode_G_TEXTURE(uint64_t data, int i, std::string prefix, char* line)
+{
+ int ____ = (data & 0x0000FFFF00000000) >> 32;
+ int ssss = (data & 0x00000000FFFF0000) >> 16;
+ int tttt = (data & 0x000000000000FFFF);
+ int lll = (____ & 0x3800) >> 11;
+ int ddd = (____ & 0x700) >> 8;
+ int nnnnnnn = 0;
+
+ if (dListType == DListType::F3DEX)
+ nnnnnnn = (____ & 0xFF);
+ else
+ nnnnnnn = (____ & 0xFE) >> 1;
+
+ sprintf(line, "gsSPTexture(%i, %i, %i, %i, %s),", ssss, tttt, lll, ddd, nnnnnnn == 1 ? "G_ON" : "G_OFF");
+}
+
+void ZDisplayList::Opcode_G_SETTIMG(uint64_t data, int i, std::string prefix, char* line)
+{
+ int __ = (data & 0x00FF000000000000) >> 48;
+ int www = (data & 0x00000FFF00000000) >> 32;
+ string fmtTbl[] = { "G_IM_FMT_RGBA", "G_IM_FMT_YUV", "G_IM_FMT_CI", "G_IM_FMT_IA", "G_IM_FMT_I" };
+ string sizTbl[] = { "G_IM_SIZ_4b", "G_IM_SIZ_8b", "G_IM_SIZ_16b", "G_IM_SIZ_32b" };
+
+ uint32_t fmt = (__ & 0xE0) >> 5;
+ uint32_t siz = (__ & 0x18) >> 3;
+
+ if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
+ printf("TextureGenCheck G_SETTIMG\n");
+
+ TextureGenCheck(prefix); // HOTSPOT
+
+ lastTexFmt = (F3DZEXTexFormats)fmt;
+ lastTexSiz = (F3DZEXTexSizes)siz;
+ lastTexSeg = data;
+ lastTexAddr = data & 0x00FFFFFF;
+
+ if (GETSEGNUM(lastTexSeg) == 0x80) // Is this texture defined in code?
+ lastTexAddr -= SEG2FILESPACE(parent->baseAddress);
+
+ int segmentNumber = (data >> 24) & 0xFF;
+
+ if (segmentNumber != 2)
+ {
+ char texStr[2048];
+ int32_t texAddress = SEG2FILESPACE(data);
+ Declaration* texDecl = nullptr;
+
+ if (segmentNumber == 0x80) // Is this texture defined in code?
+ texAddress -= SEG2FILESPACE(parent->baseAddress);
+
+ if (parent != nullptr)
+ {
+ if (Globals::Instance->HasSegment(segmentNumber))
+ texDecl = parent->GetDeclaration(texAddress);
+ else
+ texDecl = parent->GetDeclaration(data);
+ }
+
+ if (texDecl != nullptr)
+ sprintf(texStr, "%s", texDecl->varName.c_str());
+ else if (data != 0 && Globals::Instance->HasSegment(segmentNumber))
+ sprintf(texStr, "%sTex_%06X", prefix.c_str(), texAddress);
+ else
+ {
+ // TEST: CHECK OTHER FILES FOR REF
+ //if (segmentNumber == 4)
+ //{
+ //Globals::Instance->FindSymbolSegRef(segmentNumber, texAddress);
+ //}
+ //else
+ {
+ sprintf(texStr, "0x%08lX", data & 0xFFFFFFFF);
+ }
+ }
+
+ sprintf(line, "gsDPSetTextureImage(%s, %s, %i, %s),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1, texStr);
+ //sprintf(line, "gsDPSetTextureImage(%s, %s, %i, @r),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1);
+ //references.push_back(data & 0x00FFFFFF);
+ }
+ else
+ {
+ //sprintf(line, "gsDPSetTextureImage(%s, %s, %i, 0x%08X),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1, data & 0xFFFFFFFF);
+ sprintf(line, "gsDPSetTextureImage(%s, %s, %i, %sTex_%06lX),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1, scene->GetName().c_str(), SEG2FILESPACE(data));
+ }
+}
+
+void ZDisplayList::Opcode_G_SETTILE(uint64_t data, int i, std::string prefix, char* line)
+{
+ int fff = (data & 0b0000000011100000000000000000000000000000000000000000000000000000) >> 53;
+ int ii = (data & 0b0000000000011000000000000000000000000000000000000000000000000000) >> 51;
+ int nnnnnnnnn = (data & 0b0000000000000011111111100000000000000000000000000000000000000000) >> 41;
+ int mmmmmmmmm = (data & 0b0000000000000000000000011111111100000000000000000000000000000000) >> 32;
+ int ttt = (data & 0b0000000000000000000000000000000000000111000000000000000000000000) >> 24;
+ int pppp = (data & 0b0000000000000000000000000000000000000000111100000000000000000000) >> 20;
+ int cc = (data & 0b0000000000000000000000000000000000000000000011000000000000000000) >> 18;
+ int aaaa = (data & 0b0000000000000000000000000000000000000000000000111100000000000000) >> 14;
+ int ssss = (data & 0b0000000000000000000000000000000000000000000000000011110000000000) >> 10;
+ int dd = (data & 0b0000000000000000000000000000000000000000000000000000001100000000) >> 8;
+ int bbbb = (data & 0b0000000000000000000000000000000000000000000000000000000011110000) >> 4;
+ int uuuu = (data & 0b0000000000000000000000000000000000000000000000000000000000001111);
+
+ string fmtTbl[] = { "G_IM_FMT_RGBA", "G_IM_FMT_YUV", "G_IM_FMT_CI", "G_IM_FMT_IA", "G_IM_FMT_I" };
+ string sizTbl[] = { "G_IM_SIZ_4b", "G_IM_SIZ_8b", "G_IM_SIZ_16b", "G_IM_SIZ_32b" };
+
+ if (fff == (int)F3DZEXTexFormats::G_IM_FMT_CI)
+ lastCISiz = (F3DZEXTexSizes)ii;
+
+ lastTexSizTest = (F3DZEXTexSizes)ii;
+
+ sprintf(line, "gsDPSetTile(%s, %s, %i, %i, %i, %i, %i, %i, %i, %i, %i, %i),", fmtTbl[fff].c_str(), sizTbl[ii].c_str(), nnnnnnnnn, mmmmmmmmm, ttt, pppp, cc, aaaa, ssss, dd, bbbb, uuuu);
+}
+
+void ZDisplayList::Opcode_G_SETTILESIZE(uint64_t data, int index, std::string prefix, char* line)
+{
+ int sss = (data & 0x00FFF00000000000) >> 44;
+ int ttt = (data & 0x00000FFF00000000) >> 32;
+ int uuu = (data & 0x0000000000FFF000) >> 12;
+ int vvv = (data & 0x0000000000000FFF);
+ int i = (data & 0x000000000F000000) >> 24;
+
+ int shiftAmtW = 2;
+ int shiftAmtH = 2;
+
+ if (lastTexSizTest == F3DZEXTexSizes::G_IM_SIZ_8b && lastTexFmt == F3DZEXTexFormats::G_IM_FMT_IA)
+ shiftAmtW = 3;
+
+ //if (lastTexFmt == F3DZEXTexFormats::G_IM_FMT_I || lastTexFmt == F3DZEXTexFormats::G_IM_FMT_CI)
+ if (lastTexSizTest == F3DZEXTexSizes::G_IM_SIZ_4b)
+ shiftAmtW = 3;
+
+ if (lastTexSizTest == F3DZEXTexSizes::G_IM_SIZ_4b && lastTexFmt == F3DZEXTexFormats::G_IM_FMT_IA)
+ shiftAmtH = 3;
+
+
+ lastTexWidth = (uuu >> shiftAmtW) + 1;
+ lastTexHeight = (vvv >> shiftAmtH) + 1;
+
+ if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
+ printf("lastTexWidth: %i lastTexHeight: %i, lastTexSizTest: 0x%x, lastTexFmt: 0x%x\n", lastTexWidth, lastTexHeight, (uint32_t)lastTexSizTest, (uint32_t)lastTexFmt);
+
+ if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
+ printf("TextureGenCheck G_SETTILESIZE\n");
+
+ TextureGenCheck(prefix);
+
+ sprintf(line, "gsDPSetTileSize(%i, %i, %i, %i, %i),", i, sss, ttt, uuu, vvv);
+}
+
+void ZDisplayList::Opcode_G_LOADBLOCK(uint64_t data, int index, std::string prefix, char* line)
+{
+ int sss = (data & 0x00FFF00000000000) >> 48;
+ int ttt = (data & 0x00000FFF00000000) >> 36;
+ int i = (data & 0x000000000F000000) >> 24;
+ int xxx = (data & 0x0000000000FFF000) >> 12;
+ int ddd = (data & 0x0000000000000FFF);
+
+ //lastTexHeight = (ddd + 1) / 16;
+
+ lastTexLoaded = true;
+
+ //TextureGenCheck(prefix);
+
+ sprintf(line, "gsDPLoadBlock(%i, %i, %i, %i, %i),", i, sss, ttt, xxx, ddd);
+}
+
+void ZDisplayList::Opcode_G_SETCOMBINE(uint64_t data, int i, std::string prefix, char* line)
+{
+ int a0 = (data & 0b000000011110000000000000000000000000000000000000000000000000000) >> 52;
+ int c0 = (data & 0b000000000001111100000000000000000000000000000000000000000000000) >> 47;
+ int aa0 = (data & 0b00000000000000011100000000000000000000000000000000000000000000) >> 44;
+ int ac0 = (data & 0b00000000000000000011100000000000000000000000000000000000000000) >> 41;
+ int a1 = (data & 0b000000000000000000000011110000000000000000000000000000000000000) >> 37;
+ int c1 = (data & 0b000000000000000000000000001111100000000000000000000000000000000) >> 32;
+ int b0 = (data & 0b000000000000000000000000000000011110000000000000000000000000000) >> 28;
+ int b1 = (data & 0b000000000000000000000000000000000001111000000000000000000000000) >> 24;
+ int aa1 = (data & 0b00000000000000000000000000000000000000111000000000000000000000) >> 21;
+ int ac1 = (data & 0b00000000000000000000000000000000000000000111000000000000000000) >> 18;
+ int d0 = (data & 0b000000000000000000000000000000000000000000000111000000000000000) >> 15;
+ int ab0 = (data & 0b00000000000000000000000000000000000000000000000111000000000000) >> 12;
+ int ad0 = (data & 0b00000000000000000000000000000000000000000000000000111000000000) >> 9;
+ int d1 = (data & 0b000000000000000000000000000000000000000000000000000000111000000) >> 6;
+ int ab1 = (data & 0b00000000000000000000000000000000000000000000000000000000111000) >> 3;
+ int ad1 = (data & 0b00000000000000000000000000000000000000000000000000000000000111) >> 0;
+
+ string modes[] = { "COMBINED", "TEXEL0", "TEXEL1", "PRIMITIVE", "SHADE", "ENVIRONMENT", "1", "COMBINED_ALPHA",
+ "TEXEL0_ALPHA", "TEXEL1_ALPHA", "PRIMITIVE_ALPHA", "SHADE_ALPHA", "ENV_ALPHA", "LOD_FRACTION", "PRIM_LOD_FRAC", "K5",
+ "17", "18", "19", "20", "21", "22", "23", "24",
+ "25", "26", "27", "28", "29", "30", "31", "0" };
+
+ string modes2[] = { "COMBINED", "TEXEL0", "TEXEL1", "PRIMITIVE", "SHADE", "ENVIRONMENT", "1", "0" };
+
+ sprintf(line, "gsDPSetCombineLERP(%s, %s, %s, %s, %s, %s, %s, %s,\n %s, %s, %s, %s, %s, %s, %s, %s),",
+ modes[a0].c_str(), modes[b0].c_str(), modes[c0].c_str(), modes[d0].c_str(),
+ modes2[aa0].c_str(), modes2[ab0].c_str(), modes2[ac0].c_str(), modes2[ad0].c_str(),
+ modes[a1].c_str(), modes[b1].c_str(), modes[c1].c_str(), modes[d1].c_str(),
+ modes2[aa1].c_str(), modes2[ab1].c_str(), modes2[ac1].c_str(), modes2[ad1].c_str());
+}
+
+void ZDisplayList::Opcode_G_SETPRIMCOLOR(uint64_t data, int i, std::string prefix, char* line)
+{
+ int mm = (data & 0x0000FF0000000000) >> 40;
+ int ff = (data & 0x000000FF00000000) >> 32;
+ int rr = (data & 0x00000000FF000000) >> 24;
+ int gg = (data & 0x0000000000FF0000) >> 16;
+ int bb = (data & 0x000000000000FF00) >> 8;
+ int aa = (data & 0x00000000000000FF) >> 0;
+ sprintf(line, "gsDPSetPrimColor(%i, %i, %i, %i, %i, %i),", mm, ff, rr, gg, bb, aa);
+}
+
+void ZDisplayList::Opcode_F3DEX_G_SETOTHERMODE_L(uint64_t data, int i, std::string prefix, char* line)
+{
+ int sft = (data & 0x0000FF0000000000) >> 40;
+ int len = (data & 0x000000FF00000000) >> 32;
+ int dat = (data & 0xFFFFFFFF);
+
+ // TODO: Output the correct render modes in data
+
+ sprintf(line, "gsSPSetOtherMode(0xE2, %i, %i, 0x%08X),", sft, len, dat);
+}
+
+void ZDisplayList::Opcode_G_SETOTHERMODE_L(uint64_t data, int i, std::string prefix, char* line)
+{
+ int dd = (data & 0xFFFFFFFF);
+ int sft = 0;
+ int len = 0;
+
+ if (dListType == DListType::F3DEX)
+ {
+ sft = (data & 0x0000FF0000000000) >> 40;
+ len = (data & 0x000000FF00000000) >> 32;
+ }
+ else
+ {
+ int ss = (data & 0x0000FF0000000000) >> 40;
+ len = ((data & 0x000000FF00000000) >> 32) + 1;
+ sft = 32 - (len) - ss;
+ }
+
+ if (sft == G_MDSFT_RENDERMODE)
+ {
+ int mode1 = (dd & 0xCCCC0000) >> 0;
+ int mode2 = (dd & 0x3333FFFF);
+
+ // TODO: Jesus Christ This is Messy
+
+ uint32_t tblA[] =
+ {
+ G_RM_FOG_SHADE_A, G_RM_FOG_PRIM_A, G_RM_PASS, G_RM_AA_ZB_OPA_SURF,
+ G_RM_AA_ZB_XLU_SURF, G_RM_AA_ZB_OPA_DECAL, G_RM_AA_ZB_XLU_DECAL,
+ G_RM_AA_ZB_OPA_INTER, G_RM_AA_ZB_XLU_INTER, G_RM_AA_ZB_XLU_LINE,
+ G_RM_AA_ZB_DEC_LINE, G_RM_AA_ZB_TEX_EDGE, G_RM_AA_ZB_TEX_INTER,
+ G_RM_AA_ZB_SUB_SURF, G_RM_AA_ZB_PCL_SURF, G_RM_AA_ZB_OPA_TERR,
+ G_RM_AA_ZB_TEX_TERR, G_RM_AA_ZB_SUB_TERR, G_RM_RA_ZB_OPA_SURF,
+ G_RM_RA_ZB_OPA_DECAL, G_RM_RA_ZB_OPA_INTER, G_RM_AA_OPA_SURF,
+ G_RM_AA_XLU_SURF, G_RM_AA_XLU_LINE, G_RM_AA_DEC_LINE,
+ G_RM_AA_TEX_EDGE, G_RM_AA_SUB_SURF, G_RM_AA_PCL_SURF,
+ G_RM_AA_OPA_TERR, G_RM_AA_TEX_TERR, G_RM_AA_SUB_TERR,
+ G_RM_RA_OPA_SURF, G_RM_ZB_OPA_SURF, G_RM_ZB_XLU_SURF,
+ G_RM_ZB_OPA_DECAL, G_RM_ZB_XLU_DECAL, G_RM_ZB_CLD_SURF,
+ G_RM_ZB_OVL_SURF, G_RM_ZB_PCL_SURF, G_RM_OPA_SURF,
+ G_RM_XLU_SURF, G_RM_CLD_SURF, G_RM_TEX_EDGE, G_RM_PCL_SURF,
+ G_RM_ADD, G_RM_NOOP, G_RM_VISCVG, G_RM_OPA_CI
+ };
+
+ uint32_t tblB[] =
+ {
+ G_RM_AA_ZB_OPA_SURF2,
+ G_RM_AA_ZB_XLU_SURF2, G_RM_AA_ZB_OPA_DECAL2, G_RM_AA_ZB_XLU_DECAL2,
+ G_RM_AA_ZB_OPA_INTER2, G_RM_AA_ZB_XLU_INTER2, G_RM_AA_ZB_XLU_LINE2,
+ G_RM_AA_ZB_DEC_LINE2, G_RM_AA_ZB_TEX_EDGE2, G_RM_AA_ZB_TEX_INTER2,
+ G_RM_AA_ZB_SUB_SURF2, G_RM_AA_ZB_PCL_SURF2, G_RM_AA_ZB_OPA_TERR2,
+ G_RM_AA_ZB_TEX_TERR2, G_RM_AA_ZB_SUB_TERR2, G_RM_RA_ZB_OPA_SURF2,
+ G_RM_RA_ZB_OPA_DECAL2, G_RM_RA_ZB_OPA_INTER2, G_RM_AA_OPA_SURF2,
+ G_RM_AA_XLU_SURF2, G_RM_AA_XLU_LINE2, G_RM_AA_DEC_LINE2,
+ G_RM_AA_TEX_EDGE2, G_RM_AA_SUB_SURF2, G_RM_AA_PCL_SURF2,
+ G_RM_AA_OPA_TERR2, G_RM_AA_TEX_TERR2, G_RM_AA_SUB_TERR2,
+ G_RM_RA_OPA_SURF2, G_RM_ZB_OPA_SURF2, G_RM_ZB_XLU_SURF2,
+ G_RM_ZB_OPA_DECAL2, G_RM_ZB_XLU_DECAL2, G_RM_ZB_CLD_SURF2,
+ G_RM_ZB_OVL_SURF2, G_RM_ZB_PCL_SURF2, G_RM_OPA_SURF2,
+ G_RM_XLU_SURF2, G_RM_CLD_SURF2, G_RM_TEX_EDGE2, G_RM_PCL_SURF2,
+ G_RM_ADD2, G_RM_NOOP2,G_RM_VISCVG2, G_RM_OPA_CI2
+ };
+
+ map str =
+ {
+ { G_RM_FOG_SHADE_A, "G_RM_FOG_SHADE_A" },
+ { G_RM_FOG_PRIM_A, "G_RM_FOG_PRIM_A" },
+ { G_RM_PASS, "G_RM_PASS" },
+ { G_RM_AA_ZB_OPA_SURF, "G_RM_AA_ZB_OPA_SURF" },
+ { G_RM_AA_ZB_OPA_SURF2, "G_RM_AA_ZB_OPA_SURF2" },
+ { G_RM_AA_ZB_XLU_SURF, "G_RM_AA_ZB_XLU_SURF" },
+ { G_RM_AA_ZB_XLU_SURF2, "G_RM_AA_ZB_XLU_SURF2" },
+ { G_RM_AA_ZB_OPA_DECAL, "G_RM_AA_ZB_OPA_DECAL" },
+ { G_RM_AA_ZB_OPA_DECAL2, "G_RM_AA_ZB_OPA_DECAL2" },
+ { G_RM_AA_ZB_XLU_DECAL, "G_RM_AA_ZB_XLU_DECAL" },
+ { G_RM_AA_ZB_XLU_DECAL2, "G_RM_AA_ZB_XLU_DECAL2" },
+ { G_RM_AA_ZB_OPA_INTER, "G_RM_AA_ZB_OPA_INTER" },
+ { G_RM_AA_ZB_OPA_INTER2, "G_RM_AA_ZB_OPA_INTER2" },
+ { G_RM_AA_ZB_XLU_INTER, "G_RM_AA_ZB_XLU_INTER" },
+ { G_RM_AA_ZB_XLU_INTER2, "G_RM_AA_ZB_XLU_INTER2" },
+ { G_RM_AA_ZB_XLU_LINE, "G_RM_AA_ZB_XLU_LINE" },
+ { G_RM_AA_ZB_XLU_LINE2, "G_RM_AA_ZB_XLU_LINE2" },
+ { G_RM_AA_ZB_DEC_LINE, "G_RM_AA_ZB_DEC_LINE" },
+ { G_RM_AA_ZB_DEC_LINE2, "G_RM_AA_ZB_DEC_LINE2" },
+ { G_RM_AA_ZB_TEX_EDGE, "G_RM_AA_ZB_TEX_EDGE" },
+ { G_RM_AA_ZB_TEX_EDGE2, "G_RM_AA_ZB_TEX_EDGE2" },
+ { G_RM_AA_ZB_TEX_INTER, "G_RM_AA_ZB_TEX_INTER" },
+ { G_RM_AA_ZB_TEX_INTER2, "G_RM_AA_ZB_TEX_INTER2" },
+ { G_RM_AA_ZB_SUB_SURF, "G_RM_AA_ZB_SUB_SURF" },
+ { G_RM_AA_ZB_SUB_SURF2, "G_RM_AA_ZB_SUB_SURF2" },
+ { G_RM_AA_ZB_PCL_SURF, "G_RM_AA_ZB_PCL_SURF" },
+ { G_RM_AA_ZB_PCL_SURF2, "G_RM_AA_ZB_PCL_SURF2" },
+ { G_RM_AA_ZB_OPA_TERR, "G_RM_AA_ZB_OPA_TERR" },
+ { G_RM_AA_ZB_OPA_TERR2, "G_RM_AA_ZB_OPA_TERR2" },
+ { G_RM_AA_ZB_TEX_TERR, "G_RM_AA_ZB_TEX_TERR" },
+ { G_RM_AA_ZB_TEX_TERR2, "G_RM_AA_ZB_TEX_TERR2" },
+ { G_RM_AA_ZB_SUB_TERR, "G_RM_AA_ZB_SUB_TERR" },
+ { G_RM_AA_ZB_SUB_TERR2, "G_RM_AA_ZB_SUB_TERR2" },
+ { G_RM_RA_ZB_OPA_SURF, "G_RM_RA_ZB_OPA_SURF" },
+ { G_RM_RA_ZB_OPA_SURF2, "G_RM_RA_ZB_OPA_SURF2" },
+ { G_RM_RA_ZB_OPA_DECAL, "G_RM_RA_ZB_OPA_DECAL" },
+ { G_RM_RA_ZB_OPA_DECAL2, "G_RM_RA_ZB_OPA_DECAL2" },
+ { G_RM_RA_ZB_OPA_INTER, "G_RM_RA_ZB_OPA_INTER" },
+ { G_RM_RA_ZB_OPA_INTER2, "G_RM_RA_ZB_OPA_INTER2" },
+ { G_RM_AA_OPA_SURF, "G_RM_AA_OPA_SURF" },
+ { G_RM_AA_OPA_SURF2, "G_RM_AA_OPA_SURF2" },
+ { G_RM_AA_XLU_SURF, "G_RM_AA_XLU_SURF" },
+ { G_RM_AA_XLU_SURF2, "G_RM_AA_XLU_SURF2" },
+ { G_RM_AA_XLU_LINE, "G_RM_AA_XLU_LINE" },
+ { G_RM_AA_XLU_LINE2, "G_RM_AA_XLU_LINE2" },
+ { G_RM_AA_DEC_LINE, "G_RM_AA_DEC_LINE" },
+ { G_RM_AA_DEC_LINE2, "G_RM_AA_DEC_LINE2" },
+ { G_RM_AA_TEX_EDGE, "G_RM_AA_TEX_EDGE" },
+ { G_RM_AA_TEX_EDGE2, "G_RM_AA_TEX_EDGE2" },
+ { G_RM_AA_SUB_SURF, "G_RM_AA_SUB_SURF" },
+ { G_RM_AA_SUB_SURF2, "G_RM_AA_SUB_SURF2" },
+ { G_RM_AA_PCL_SURF, "G_RM_AA_PCL_SURF" },
+ { G_RM_AA_PCL_SURF2, "G_RM_AA_PCL_SURF2" },
+ { G_RM_AA_OPA_TERR, "G_RM_AA_OPA_TERR" },
+ { G_RM_AA_OPA_TERR2, "G_RM_AA_OPA_TERR2" },
+ { G_RM_AA_TEX_TERR, "G_RM_AA_TEX_TERR" },
+ { G_RM_AA_TEX_TERR2, "G_RM_AA_TEX_TERR2" },
+ { G_RM_AA_TEX_TERR, "G_RM_AA_TEX_TERR" },
+ { G_RM_AA_TEX_TERR2, "G_RM_AA_TEX_TERR2" },
+ { G_RM_AA_SUB_TERR, "G_RM_AA_SUB_TERR" },
+ { G_RM_AA_SUB_TERR2, "G_RM_AA_SUB_TERR2" },
+ { G_RM_RA_OPA_SURF, "G_RM_RA_OPA_SURF" },
+ { G_RM_RA_OPA_SURF2, "G_RM_RA_OPA_SURF2" },
+ { G_RM_ZB_OPA_SURF, "G_RM_ZB_OPA_SURF" },
+ { G_RM_ZB_OPA_SURF2, "G_RM_ZB_OPA_SURF2" },
+ { G_RM_ZB_XLU_SURF, "G_RM_ZB_XLU_SURF" },
+ { G_RM_ZB_XLU_SURF2, "G_RM_ZB_XLU_SURF2" },
+ { G_RM_ZB_OPA_DECAL, "G_RM_ZB_OPA_DECAL" },
+ { G_RM_ZB_OPA_DECAL2, "G_RM_ZB_OPA_DECAL2" },
+ { G_RM_ZB_XLU_DECAL, "G_RM_ZB_XLU_DECAL" },
+ { G_RM_ZB_XLU_DECAL2, "G_RM_ZB_XLU_DECAL2" },
+ { G_RM_ZB_CLD_SURF, "G_RM_ZB_CLD_SURF" },
+ { G_RM_ZB_CLD_SURF2, "G_RM_ZB_CLD_SURF2" },
+ { G_RM_ZB_OVL_SURF, "G_RM_ZB_OVL_SURF" },
+ { G_RM_ZB_OVL_SURF2, "G_RM_ZB_OVL_SURF2" },
+ { G_RM_ZB_PCL_SURF, "G_RM_ZB_PCL_SURF" },
+ { G_RM_ZB_PCL_SURF2, "G_RM_ZB_PCL_SURF2" },
+ { G_RM_OPA_SURF, "G_RM_OPA_SURF" },
+ { G_RM_OPA_SURF2, "G_RM_OPA_SURF2" },
+ { G_RM_XLU_SURF, "G_RM_XLU_SURF" },
+ { G_RM_XLU_SURF2, "G_RM_XLU_SURF2" },
+ { G_RM_CLD_SURF, "G_RM_CLD_SURF" },
+ { G_RM_CLD_SURF2, "G_RM_CLD_SURF2" },
+ { G_RM_TEX_EDGE, "G_RM_TEX_EDGE" },
+ { G_RM_TEX_EDGE2, "G_RM_TEX_EDGE2" },
+ { G_RM_PCL_SURF, "G_RM_PCL_SURF" },
+ { G_RM_PCL_SURF2, "G_RM_PCL_SURF2" },
+ { G_RM_ADD, "G_RM_ADD" },
+ { G_RM_ADD2, "G_RM_ADD2" },
+ { G_RM_NOOP, "G_RM_NOOP" },
+ { G_RM_NOOP2, "G_RM_NOOP2" },
+ { G_RM_VISCVG, "G_RM_VISCVG" },
+ { G_RM_VISCVG2, "G_RM_VISCVG2" },
+ { G_RM_OPA_CI, "G_RM_OPA_CI" },
+ { G_RM_OPA_CI2, "G_RM_OPA_CI2" },
+ };
+
+ for (int k = 0; k < sizeof(tblA) / 4; k++)
+ {
+ if ((dd & tblA[k]) == tblA[k])
+ {
+ if (tblA[k] > mode1)
+ mode1 = tblA[k];
+ }
+ }
+
+ for (int k = 0; k < sizeof(tblB) / 4; k++)
+ {
+ if ((dd & tblB[k]) == tblB[k])
+ {
+ if (tblB[k] > mode2)
+ mode2 = tblB[k];
+ }
+ }
+
+ std::string mode1Str = str[mode1];
+ std::string mode2Str = str[mode2];
+
+ if (mode1Str == "")
+ {
+ mode1Str = StringHelper::Sprintf("0x%08X", mode1);
+ }
+
+ if (mode2Str == "")
+ {
+ int remainingFlags = mode2;
+
+ if (mode2 & AA_EN)
+ {
+ mode2Str += "AA_EN | ";
+ remainingFlags ^= AA_EN;
+ }
+
+ if (mode2 & Z_CMP)
+ {
+ mode2Str += "Z_CMP | ";
+ remainingFlags ^= Z_CMP;
+ }
+
+ if (mode2 & Z_UPD)
+ {
+ mode2Str += "Z_UPD | ";
+ remainingFlags ^= Z_UPD;
+ }
+
+ if (mode2 & IM_RD)
+ {
+ mode2Str += "IM_RD | ";
+ remainingFlags ^= IM_RD;
+ }
+
+ if (mode2 & CLR_ON_CVG)
+ {
+ mode2Str += "CLR_ON_CVG | ";
+ remainingFlags ^= CLR_ON_CVG;
+ }
+
+ if (mode2 & CVG_DST_CLAMP)
+ {
+ mode2Str += "CVG_DST_CLAMP | ";
+ remainingFlags ^= CVG_DST_CLAMP;
+ }
+
+ if (mode2 & CVG_DST_WRAP)
+ {
+ mode2Str += "CVG_DST_WRAP | ";
+ remainingFlags ^= CVG_DST_WRAP;
+ }
+
+ if (mode2 & CVG_DST_FULL)
+ {
+ mode2Str += "CVG_DST_FULL | ";
+ remainingFlags ^= CVG_DST_FULL;
+ }
+
+ if (mode2 & CVG_DST_SAVE)
+ {
+ mode2Str += "CVG_DST_SAVE | ";
+ remainingFlags ^= CVG_DST_SAVE;
+ }
+
+ int zMode = mode2 & 0xC00;
+
+ if (zMode == ZMODE_INTER)
+ {
+ mode2Str += "ZMODE_INTER | ";
+ remainingFlags ^= ZMODE_INTER;
+ }
+ else if (zMode == ZMODE_XLU)
+ {
+ mode2Str += "ZMODE_XLU | ";
+ remainingFlags ^= ZMODE_XLU;
+ }
+ else if (zMode == ZMODE_DEC)
+ {
+ mode2Str += "ZMODE_DEC | ";
+ remainingFlags ^= ZMODE_DEC;
+ }
+
+ if (mode2 & CVG_X_ALPHA)
+ {
+ mode2Str += "CVG_X_ALPHA | ";
+ remainingFlags ^= CVG_X_ALPHA;
+ }
+
+ if (mode2 & ALPHA_CVG_SEL)
+ {
+ mode2Str += "ALPHA_CVG_SEL | ";
+ remainingFlags ^= ALPHA_CVG_SEL;
+ }
+
+ if (mode2 & FORCE_BL)
+ {
+ mode2Str += "FORCE_BL | ";
+ remainingFlags ^= FORCE_BL;
+ }
+
+ int bp = (mode2 >> 28) & 0b11;
+ int ba = (mode2 >> 24) & 0b11;
+ int bm = (mode2 >> 20) & 0b11;
+ int bb = (mode2 >> 16) & 0b11;
+
+ mode2Str += StringHelper::Sprintf("GBL_c2(%i, %i, %i, %i)", bp, ba, bm, bb);
+ //mode2Str = StringHelper::Sprintf("0x%08X", mode2);
+ }
+
+ sprintf(line, "gsDPSetRenderMode(%s, %s),", mode1Str.c_str(), mode2Str.c_str());
+ }
+ else
+ {
+ sprintf(line, "gsSPSetOtherMode(0xE2, %i, %i, 0x%08X),", sft, len, dd);
+ }
+}
+
+void ZDisplayList::Opcode_G_SETOTHERMODE_H(uint64_t data, int i, std::string prefix, char* line)
+{
+ int ss = (data & 0x0000FF0000000000) >> 40;
+ int nn = (data & 0x000000FF00000000) >> 32;
+ int dd = (data & 0xFFFFFFFF);
+
+ int sft = 32 - (nn + 1) - ss;
+
+ if (sft == 14) // G_MDSFT_TEXTLUT
+ {
+ string types[] = { "G_TT_NONE", "G_TT_NONE", "G_TT_RGBA16", "G_TT_IA16" };
+ sprintf(line, "gsDPSetTextureLUT(%s),", types[dd >> 14].c_str());
+ }
+ else
+ sprintf(line, "gsSPSetOtherMode(0xE3, %i, %i, 0x%08X),", sft, nn + 1, dd);
+}
+
+void ZDisplayList::Opcode_G_LOADTLUT(uint64_t data, int i, std::string prefix, char* line)
+{
+ int t = (data & 0x0000000007000000) >> 24;
+ int ccc = (data & 0x00000000003FF000) >> 14;
+
+ lastTexWidth = sqrt(ccc + 1);
+ lastTexHeight = sqrt(ccc + 1);
+
+ lastTexLoaded = true;
+ lastTexIsPalette = true;
+
+ if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
+ printf("TextureGenCheck G_LOADTLUT (lastCISiz: %i)\n", (uint32_t)lastCISiz);
+
+ TextureGenCheck(prefix);
+
+ sprintf(line, "gsDPLoadTLUTCmd(%i, %i),", t, ccc);
+}
+
+void ZDisplayList::Opcode_G_ENDDL(uint64_t data, int i, std::string prefix, char* line)
+{
+ sprintf(line, "gsSPEndDisplayList(),");
+
+ if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
+ printf("TextureGenCheck G_ENDDL\n");
+
+ TextureGenCheck(prefix);
+}
+
string ZDisplayList::GetSourceOutputHeader(const std::string& prefix)
{
return "";
@@ -315,7 +1427,7 @@ string ZDisplayList::GetSourceOutputCode(const std::string& prefix)
for (int i = 0; i < instructions.size(); i++)
{
- F3DZEXOpcode opcode = (F3DZEXOpcode)(instructions[i] >> 56);
+ uint8_t opcode = (uint8_t)(instructions[i] >> 56);
uint64_t data = instructions[i];
sourceOutput += " ";
@@ -330,743 +1442,10 @@ string ZDisplayList::GetSourceOutputCode(const std::string& prefix)
}
else
{
- switch (opcode)
- {
- case F3DZEXOpcode::G_NOOP:
- sprintf(line, "gsDPNoOpTag(0x%08lX),", data & 0xFFFFFFFF);
- break;
- case F3DZEXOpcode::G_DL:
- {
- int pp = (data & 0x00FF000000000000) >> 56;
- int segNum = (data & 0xFF000000) >> 24;
-
- Declaration* dListDecl = nullptr;
-
- if (parent != nullptr)
- dListDecl = parent->GetDeclaration(SEG2FILESPACE(data));
-
- if (pp != 0)
- {
- if (!Globals::Instance->HasSegment(segNum))
- sprintf(line, "gsSPBranchList(0x%08lX),", data & 0xFFFFFFFF);
- else if (dListDecl != nullptr)
- sprintf(line, "gsSPBranchList(%s),", dListDecl->varName.c_str());
- else
- sprintf(line, "gsSPBranchList(%sDlist0x%06lX),", prefix.c_str(), SEG2FILESPACE(data));
- }
- else
- {
- if (!Globals::Instance->HasSegment(segNum))
- sprintf(line, "gsSPDisplayList(0x%08lX),", data & 0xFFFFFFFF);
- else if (dListDecl != nullptr)
- sprintf(line, "gsSPDisplayList(%s),", dListDecl->varName.c_str());
- else
- sprintf(line, "gsSPDisplayList(%sDlist0x%06lX),", prefix.c_str(), SEG2FILESPACE(data));
- }
-
- int segmentNumber = (data & 0xFF000000) >> 24;
-
- if (segmentNumber == 8 || segmentNumber == 9 || segmentNumber == 10 || segmentNumber == 11 || segmentNumber == 12 || segmentNumber == 13) // Used for runtime-generated display lists
- {
- if (pp != 0)
- sprintf(line, "gsSPBranchList(0x%08lX),", data & 0xFFFFFFFF);
- else
- sprintf(line, "gsSPDisplayList(0x%08lX),", data & 0xFFFFFFFF);
- }
- else
- {
- ZDisplayList* nList = new ZDisplayList(fileData, data & 0x00FFFFFF, GetDListLength(fileData, data & 0x00FFFFFF));
- nList->scene = scene;
- nList->parent = parent;
- otherDLists.push_back(nList);
- }
- }
- break;
- case F3DZEXOpcode::G_MODIFYVTX:
- {
- int ww = (data & 0x00FF000000000000ULL) >> 48;
- int nnnn = (data & 0x0000FFFF00000000ULL) >> 32;
- int vvvvvvvv = (data & 0x00000000FFFFFFFFULL);
-
- sprintf(line, "gsSPModifyVertex(%i, %i, %i),", nnnn / 2, ww, vvvvvvvv);
- }
- break;
- case F3DZEXOpcode::G_CULLDL:
- {
- int vvvv = (data & 0xFFFF00000000) >> 32;
- int wwww = (data & 0x0000FFFF);
-
- sprintf(line, "gsSPCullDisplayList(%i, %i),", vvvv / 2, wwww / 2);
- }
- break;
- /*case F3DZEXOpcode::G_BRANCH_Z:
- {
- int aaa = (data & 0x00FFF00000000000) >> 44;
- int bbb = (data & 0x00000FFF00000000) >> 32;
- int zzzzzzzz = (data & 0x00000000FFFFFFFF);
-
- sprintf(line, "gsSPBranchLessZraw(%i, %i, %i),", );
- }
- break;*/
- case F3DZEXOpcode::G_TRI1:
- {
- int aa = ((data & 0x00FF000000000000ULL) >> 48) / 2;
- int bb = ((data & 0x0000FF0000000000ULL) >> 40) / 2;
- int cc = ((data & 0x000000FF00000000ULL) >> 32) / 2;
- sprintf(line, "gsSP1Triangle(%i, %i, %i, 0),", aa, bb, cc);
- }
- break;
- case F3DZEXOpcode::G_TRI2:
- {
- int aa = ((data & 0x00FF000000000000ULL) >> 48) / 2;
- int bb = ((data & 0x0000FF0000000000ULL) >> 40) / 2;
- int cc = ((data & 0x000000FF00000000ULL) >> 32) / 2;
- int dd = ((data & 0x00000000FF0000ULL) >> 16) / 2;
- int ee = ((data & 0x0000000000FF00ULL) >> 8) / 2;
- int ff = ((data & 0x000000000000FFULL) >> 0) / 2;
- sprintf(line, "gsSP2Triangles(%i, %i, %i, 0, %i, %i, %i, 0),", aa, bb, cc, dd, ee, ff);
- }
- break;
- case F3DZEXOpcode::G_QUAD:
- {
- int aa = ((data & 0x00FF000000000000ULL) >> 48) / 2;
- int bb = ((data & 0x0000FF0000000000ULL) >> 40) / 2;
- int cc = ((data & 0x000000FF00000000ULL) >> 32) / 2;
- int dd = ((data & 0x000000000000FFULL)) / 2;
- sprintf(line, "gsSP1Quadrangle(%i, %i, %i, %i, 0),", aa, bb, cc, dd);
- }
- break;
- case F3DZEXOpcode::G_VTX:
- {
- int nn = (data & 0x000FF00000000000ULL) >> 44;
- int aa = (data & 0x000000FF00000000ULL) >> 32;
- uint32_t vtxAddr = SEG2FILESPACE(data);
-
- if (GETSEGNUM(data) == 0x80) // Are these vertices defined in code?
- vtxAddr -= SEG2FILESPACE(parent->baseAddress);
-
- //sprintf(line, "gsSPVertex(%sVtx_%06X, %i, %i),", prefix.c_str(), vtxAddr, nn, ((aa >> 1) - nn));
- sprintf(line, "gsSPVertex(@r, %i, %i),", nn, ((aa >> 1) - nn));
- references.push_back(vtxAddr);
-
- {
- uint32_t currentPtr = SEG2FILESPACE(data);
-
- if (GETSEGNUM(data) == 0x80) // Are these vertices defined in code?
- currentPtr -= SEG2FILESPACE(parent->baseAddress);
-
- // Check for vertex intersections from other display lists
- // TODO: These two could probably be condenced to one...
- if (parent->GetDeclarationRanged(vtxAddr + (nn * 16)) != nullptr)
- {
- Declaration* decl = parent->GetDeclarationRanged(vtxAddr + (nn * 16));
- uint32_t addr = parent->GetDeclarationRangedAddress(vtxAddr + (nn * 16));
- int diff = addr - vtxAddr;
- if (diff > 0)
- nn = diff / 16;
- else
- nn = 0;
- }
-
- if (parent->GetDeclarationRanged(vtxAddr) != nullptr)
- {
- Declaration* decl = parent->GetDeclarationRanged(vtxAddr);
- uint32_t addr = parent->GetDeclarationRangedAddress(vtxAddr);
- int diff = addr - vtxAddr;
- if (diff > 0)
- nn = diff / 16;
- else
- nn = 0;
- }
-
- if (nn > 0)
- {
- vector vtxList = vector();
- vtxList.reserve(nn);
-
- for (int i = 0; i < nn; i++)
- {
- Vertex vtx = Vertex(fileData, currentPtr);
- vtxList.push_back(vtx);
-
- currentPtr += 16;
- }
-
- vertices[vtxAddr] = vtxList;
- }
- }
-
- }
- break;
- case F3DZEXOpcode::G_SETTIMG: // HOTSPOT
- {
- int __ = (data & 0x00FF000000000000) >> 48;
- int www = (data & 0x00000FFF00000000) >> 32;
- string fmtTbl[] = { "G_IM_FMT_RGBA", "G_IM_FMT_YUV", "G_IM_FMT_CI", "G_IM_FMT_IA", "G_IM_FMT_I" };
- string sizTbl[] = { "G_IM_SIZ_4b", "G_IM_SIZ_8b", "G_IM_SIZ_16b", "G_IM_SIZ_32b" };
-
- uint32_t fmt = (__ & 0xE0) >> 5;
- uint32_t siz = (__ & 0x18) >> 3;
-
- if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
- printf("TextureGenCheck G_SETTIMG\n");
-
- TextureGenCheck(prefix); // HOTSPOT
-
- lastTexFmt = (F3DZEXTexFormats)fmt;
- lastTexSiz = (F3DZEXTexSizes)siz;
- lastTexSeg = data;
- lastTexAddr = data & 0x00FFFFFF;
-
- if (GETSEGNUM(lastTexSeg) == 0x80) // Is this texture defined in code?
- lastTexAddr -= SEG2FILESPACE(parent->baseAddress);
-
- int segmentNumber = (data >> 24) & 0xFF;
-
- if (segmentNumber != 2)
- {
- char texStr[2048];
- int32_t texAddress = SEG2FILESPACE(data);
- Declaration* texDecl = nullptr;
-
- if (segmentNumber == 0x80) // Is this texture defined in code?
- texAddress -= SEG2FILESPACE(parent->baseAddress);
-
- if (parent != nullptr)
- {
- if (Globals::Instance->HasSegment(segmentNumber))
- texDecl = parent->GetDeclaration(texAddress);
- else
- texDecl = parent->GetDeclaration(data);
- }
-
- if (texDecl != nullptr)
- sprintf(texStr, "%s", texDecl->varName.c_str());
- else if (data != 0 && Globals::Instance->HasSegment(segmentNumber))
- sprintf(texStr, "%sTex_%06X", prefix.c_str(), texAddress);
- else
- {
- // TEST: CHECK OTHER FILES FOR REF
- //if (segmentNumber == 4)
- //{
- //Globals::Instance->FindSymbolSegRef(segmentNumber, texAddress);
- //}
- //else
- {
- sprintf(texStr, "0x%08lX", data & 0xFFFFFFFF);
- }
- }
-
- sprintf(line, "gsDPSetTextureImage(%s, %s, %i, %s),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1, texStr);
- //sprintf(line, "gsDPSetTextureImage(%s, %s, %i, @r),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1);
- //references.push_back(data & 0x00FFFFFF);
- }
- else
- {
- //sprintf(line, "gsDPSetTextureImage(%s, %s, %i, 0x%08X),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1, data & 0xFFFFFFFF);
- sprintf(line, "gsDPSetTextureImage(%s, %s, %i, %sTex_%06lX),", fmtTbl[fmt].c_str(), sizTbl[siz].c_str(), www + 1, scene->GetName().c_str(), SEG2FILESPACE(data));
- }
- }
- break;
- case F3DZEXOpcode::G_GEOMETRYMODE:
- {
- int cccccc = (data & 0x00FFFFFF00000000) >> 32;
- int ssssssss = (data & 0xFFFFFFFF);
- string geoModeStr = "G_TEXTURE_ENABLE";
-
- int geoModeParam = ~cccccc;
-
- if (ssssssss != 0)
- geoModeParam = ssssssss;
-
- if (geoModeParam & 0x00000001)
- geoModeStr += " | G_ZBUFFER";
-
- if (geoModeParam & 0x00000004)
- geoModeStr += " | G_SHADE";
-
- if (geoModeParam & 0x00000200)
- geoModeStr += " | G_CULL_FRONT";
-
- if (geoModeParam & 0x00000400)
- geoModeStr += " | G_CULL_BACK";
-
- if (geoModeParam & 0x00010000)
- geoModeStr += " | G_FOG";
-
- if (geoModeParam & 0x00020000)
- geoModeStr += " | G_LIGHTING";
-
- if (geoModeParam & 0x00040000)
- geoModeStr += " | G_TEXTURE_GEN";
-
- if (geoModeParam & 0x00080000)
- geoModeStr += " | G_TEXTURE_GEN_LINEAR";
-
- if (geoModeParam & 0x00200000)
- geoModeStr += " | G_SHADING_SMOOTH";
-
- if (geoModeParam & 0x00800000)
- geoModeStr += " | G_CLIPPING";
-
- if (ssssssss != 0)
- {
- if ((~cccccc & 0xFF000000) != 0)
- sprintf(line, "gsSPSetGeometryMode(%s),", geoModeStr.c_str());
- else
- sprintf(line, "gsSPLoadGeometryMode(%s),", geoModeStr.c_str());
- }
- else
- sprintf(line, "gsSPClearGeometryMode(%s),", geoModeStr.c_str());
-
- //sprintf(line, "gsSPGeometryMode(0x%08X, 0x%08X),", ~cccccc, ssssssss);
- }
- break;
- case F3DZEXOpcode::G_SETPRIMCOLOR:
- {
- int mm = (data & 0x0000FF0000000000) >> 40;
- int ff = (data & 0x000000FF00000000) >> 32;
- int rr = (data & 0x00000000FF000000) >> 24;
- int gg = (data & 0x0000000000FF0000) >> 16;
- int bb = (data & 0x000000000000FF00) >> 8;
- int aa = (data & 0x00000000000000FF) >> 0;
- sprintf(line, "gsDPSetPrimColor(%i, %i, %i, %i, %i, %i),", mm, ff, rr, gg, bb, aa);
- }
- break;
- case F3DZEXOpcode::G_SETOTHERMODE_L:
- {
- int ss = (data & 0x0000FF0000000000) >> 40;
- int nn = (data & 0x000000FF00000000) >> 32;
- int dd = (data & 0xFFFFFFFF);
-
- int sft = 32 - (nn + 1) - ss;
-
- //if (sft == 3)
- if (false)
- {
- int mode1 = (dd & 0xCCCC0000) >> 0;
- int mode2 = (dd & 0x33330000) >> 0;
-
- // TODO: Jesus Christ This is Messy
-
- uint32_t tblA[] =
- {
- G_RM_FOG_SHADE_A, G_RM_FOG_PRIM_A, G_RM_PASS, G_RM_AA_ZB_OPA_SURF,
- G_RM_AA_ZB_XLU_SURF, G_RM_AA_ZB_OPA_DECAL, G_RM_AA_ZB_XLU_DECAL,
- G_RM_AA_ZB_OPA_INTER, G_RM_AA_ZB_XLU_INTER, G_RM_AA_ZB_XLU_LINE,
- G_RM_AA_ZB_DEC_LINE, G_RM_AA_ZB_TEX_EDGE, G_RM_AA_ZB_TEX_INTER,
- G_RM_AA_ZB_SUB_SURF, G_RM_AA_ZB_PCL_SURF, G_RM_AA_ZB_OPA_TERR,
- G_RM_AA_ZB_TEX_TERR, G_RM_AA_ZB_SUB_TERR, G_RM_RA_ZB_OPA_SURF,
- G_RM_RA_ZB_OPA_DECAL, G_RM_RA_ZB_OPA_INTER, G_RM_AA_OPA_SURF,
- G_RM_AA_XLU_SURF, G_RM_AA_XLU_LINE, G_RM_AA_DEC_LINE,
- G_RM_AA_TEX_EDGE, G_RM_AA_SUB_SURF, G_RM_AA_PCL_SURF,
- G_RM_AA_OPA_TERR, G_RM_AA_TEX_TERR, G_RM_AA_SUB_TERR,
- G_RM_RA_OPA_SURF, G_RM_ZB_OPA_SURF, G_RM_ZB_XLU_SURF,
- G_RM_ZB_OPA_DECAL, G_RM_ZB_XLU_DECAL, G_RM_ZB_CLD_SURF,
- G_RM_ZB_OVL_SURF, G_RM_ZB_PCL_SURF, G_RM_OPA_SURF,
- G_RM_XLU_SURF, G_RM_CLD_SURF, G_RM_TEX_EDGE, G_RM_PCL_SURF,
- G_RM_ADD, G_RM_NOOP, G_RM_VISCVG, G_RM_OPA_CI
- };
-
- uint32_t tblB[] =
- {
- G_RM_AA_ZB_OPA_SURF2,
- G_RM_AA_ZB_XLU_SURF2, G_RM_AA_ZB_OPA_DECAL2, G_RM_AA_ZB_XLU_DECAL2,
- G_RM_AA_ZB_OPA_INTER2, G_RM_AA_ZB_XLU_INTER2, G_RM_AA_ZB_XLU_LINE2,
- G_RM_AA_ZB_DEC_LINE2, G_RM_AA_ZB_TEX_EDGE2, G_RM_AA_ZB_TEX_INTER2,
- G_RM_AA_ZB_SUB_SURF2, G_RM_AA_ZB_PCL_SURF2, G_RM_AA_ZB_OPA_TERR2,
- G_RM_AA_ZB_TEX_TERR2, G_RM_AA_ZB_SUB_TERR2, G_RM_RA_ZB_OPA_SURF2,
- G_RM_RA_ZB_OPA_DECAL2, G_RM_RA_ZB_OPA_INTER2, G_RM_AA_OPA_SURF2,
- G_RM_AA_XLU_SURF2, G_RM_AA_XLU_LINE2, G_RM_AA_DEC_LINE2,
- G_RM_AA_TEX_EDGE2, G_RM_AA_SUB_SURF2, G_RM_AA_PCL_SURF2,
- G_RM_AA_OPA_TERR2, G_RM_AA_TEX_TERR2, G_RM_AA_SUB_TERR2,
- G_RM_RA_OPA_SURF2, G_RM_ZB_OPA_SURF2, G_RM_ZB_XLU_SURF2,
- G_RM_ZB_OPA_DECAL2, G_RM_ZB_XLU_DECAL2, G_RM_ZB_CLD_SURF2,
- G_RM_ZB_OVL_SURF2, G_RM_ZB_PCL_SURF2, G_RM_OPA_SURF2,
- G_RM_XLU_SURF2, G_RM_CLD_SURF2, G_RM_TEX_EDGE2, G_RM_PCL_SURF2,
- G_RM_ADD2, G_RM_NOOP2,G_RM_VISCVG2, G_RM_OPA_CI2
- };
-
- map str =
- {
- { G_RM_FOG_SHADE_A, "G_RM_FOG_SHADE_A" },
- { G_RM_FOG_PRIM_A, "G_RM_FOG_PRIM_A" },
- { G_RM_PASS, "G_RM_PASS" },
- { G_RM_AA_ZB_OPA_SURF, "G_RM_AA_ZB_OPA_SURF" },
- { G_RM_AA_ZB_OPA_SURF2, "G_RM_AA_ZB_OPA_SURF2" },
- { G_RM_AA_ZB_XLU_SURF, "G_RM_AA_ZB_XLU_SURF" },
- { G_RM_AA_ZB_XLU_SURF2, "G_RM_AA_ZB_XLU_SURF2" },
- { G_RM_AA_ZB_OPA_DECAL, "G_RM_AA_ZB_OPA_DECAL" },
- { G_RM_AA_ZB_OPA_DECAL2, "G_RM_AA_ZB_OPA_DECAL2" },
- { G_RM_AA_ZB_XLU_DECAL, "G_RM_AA_ZB_XLU_DECAL" },
- { G_RM_AA_ZB_XLU_DECAL2, "G_RM_AA_ZB_XLU_DECAL2" },
- { G_RM_AA_ZB_OPA_INTER, "G_RM_AA_ZB_OPA_INTER" },
- { G_RM_AA_ZB_OPA_INTER2, "G_RM_AA_ZB_OPA_INTER2" },
- { G_RM_AA_ZB_XLU_INTER, "G_RM_AA_ZB_XLU_INTER" },
- { G_RM_AA_ZB_XLU_INTER2, "G_RM_AA_ZB_XLU_INTER2" },
- { G_RM_AA_ZB_XLU_LINE, "G_RM_AA_ZB_XLU_LINE" },
- { G_RM_AA_ZB_XLU_LINE2, "G_RM_AA_ZB_XLU_LINE2" },
- { G_RM_AA_ZB_DEC_LINE, "G_RM_AA_ZB_DEC_LINE" },
- { G_RM_AA_ZB_DEC_LINE2, "G_RM_AA_ZB_DEC_LINE2" },
- { G_RM_AA_ZB_TEX_EDGE, "G_RM_AA_ZB_TEX_EDGE" },
- { G_RM_AA_ZB_TEX_EDGE2, "G_RM_AA_ZB_TEX_EDGE2" },
- { G_RM_AA_ZB_TEX_INTER, "G_RM_AA_ZB_TEX_INTER" },
- { G_RM_AA_ZB_TEX_INTER2, "G_RM_AA_ZB_TEX_INTER2" },
- { G_RM_AA_ZB_SUB_SURF, "G_RM_AA_ZB_SUB_SURF" },
- { G_RM_AA_ZB_SUB_SURF2, "G_RM_AA_ZB_SUB_SURF2" },
- { G_RM_AA_ZB_PCL_SURF, "G_RM_AA_ZB_PCL_SURF" },
- { G_RM_AA_ZB_PCL_SURF2, "G_RM_AA_ZB_PCL_SURF2" },
- { G_RM_AA_ZB_OPA_TERR, "G_RM_AA_ZB_OPA_TERR" },
- { G_RM_AA_ZB_OPA_TERR2, "G_RM_AA_ZB_OPA_TERR2" },
- { G_RM_AA_ZB_TEX_TERR, "G_RM_AA_ZB_TEX_TERR" },
- { G_RM_AA_ZB_TEX_TERR2, "G_RM_AA_ZB_TEX_TERR2" },
- { G_RM_AA_ZB_SUB_TERR, "G_RM_AA_ZB_SUB_TERR" },
- { G_RM_AA_ZB_SUB_TERR2, "G_RM_AA_ZB_SUB_TERR2" },
- { G_RM_RA_ZB_OPA_SURF, "G_RM_RA_ZB_OPA_SURF" },
- { G_RM_RA_ZB_OPA_SURF2, "G_RM_RA_ZB_OPA_SURF2" },
- { G_RM_RA_ZB_OPA_DECAL, "G_RM_RA_ZB_OPA_DECAL" },
- { G_RM_RA_ZB_OPA_DECAL2, "G_RM_RA_ZB_OPA_DECAL2" },
- { G_RM_RA_ZB_OPA_INTER, "G_RM_RA_ZB_OPA_INTER" },
- { G_RM_RA_ZB_OPA_INTER2, "G_RM_RA_ZB_OPA_INTER2" },
- { G_RM_AA_OPA_SURF, "G_RM_AA_OPA_SURF" },
- { G_RM_AA_OPA_SURF2, "G_RM_AA_OPA_SURF2" },
- { G_RM_AA_XLU_SURF, "G_RM_AA_XLU_SURF" },
- { G_RM_AA_XLU_SURF2, "G_RM_AA_XLU_SURF2" },
- { G_RM_AA_XLU_LINE, "G_RM_AA_XLU_LINE" },
- { G_RM_AA_XLU_LINE2, "G_RM_AA_XLU_LINE2" },
- { G_RM_AA_DEC_LINE, "G_RM_AA_DEC_LINE" },
- { G_RM_AA_DEC_LINE2, "G_RM_AA_DEC_LINE2" },
- { G_RM_AA_TEX_EDGE, "G_RM_AA_TEX_EDGE" },
- { G_RM_AA_TEX_EDGE2, "G_RM_AA_TEX_EDGE2" },
- { G_RM_AA_SUB_SURF, "G_RM_AA_SUB_SURF" },
- { G_RM_AA_SUB_SURF2, "G_RM_AA_SUB_SURF2" },
- { G_RM_AA_PCL_SURF, "G_RM_AA_PCL_SURF" },
- { G_RM_AA_PCL_SURF2, "G_RM_AA_PCL_SURF2" },
- { G_RM_AA_OPA_TERR, "G_RM_AA_OPA_TERR" },
- { G_RM_AA_OPA_TERR2, "G_RM_AA_OPA_TERR2" },
- { G_RM_AA_TEX_TERR, "G_RM_AA_TEX_TERR" },
- { G_RM_AA_TEX_TERR2, "G_RM_AA_TEX_TERR2" },
- { G_RM_AA_TEX_TERR, "G_RM_AA_TEX_TERR" },
- { G_RM_AA_TEX_TERR2, "G_RM_AA_TEX_TERR2" },
- { G_RM_AA_SUB_TERR, "G_RM_AA_SUB_TERR" },
- { G_RM_AA_SUB_TERR2, "G_RM_AA_SUB_TERR2" },
- { G_RM_RA_OPA_SURF, "G_RM_RA_OPA_SURF" },
- { G_RM_RA_OPA_SURF2, "G_RM_RA_OPA_SURF2" },
- { G_RM_ZB_OPA_SURF, "G_RM_ZB_OPA_SURF" },
- { G_RM_ZB_OPA_SURF2, "G_RM_ZB_OPA_SURF2" },
- { G_RM_ZB_XLU_SURF, "G_RM_ZB_XLU_SURF" },
- { G_RM_ZB_XLU_SURF2, "G_RM_ZB_XLU_SURF2" },
- { G_RM_ZB_OPA_DECAL, "G_RM_ZB_OPA_DECAL" },
- { G_RM_ZB_OPA_DECAL2, "G_RM_ZB_OPA_DECAL2" },
- { G_RM_ZB_XLU_DECAL, "G_RM_ZB_XLU_DECAL" },
- { G_RM_ZB_XLU_DECAL2, "G_RM_ZB_XLU_DECAL2" },
- { G_RM_ZB_CLD_SURF, "G_RM_ZB_CLD_SURF" },
- { G_RM_ZB_CLD_SURF2, "G_RM_ZB_CLD_SURF2" },
- { G_RM_ZB_OVL_SURF, "G_RM_ZB_OVL_SURF" },
- { G_RM_ZB_OVL_SURF2, "G_RM_ZB_OVL_SURF2" },
- { G_RM_ZB_PCL_SURF, "G_RM_ZB_PCL_SURF" },
- { G_RM_ZB_PCL_SURF2, "G_RM_ZB_PCL_SURF2" },
- { G_RM_OPA_SURF, "G_RM_OPA_SURF" },
- { G_RM_OPA_SURF2, "G_RM_OPA_SURF2" },
- { G_RM_XLU_SURF, "G_RM_XLU_SURF" },
- { G_RM_XLU_SURF2, "G_RM_XLU_SURF2" },
- { G_RM_CLD_SURF, "G_RM_CLD_SURF" },
- { G_RM_CLD_SURF2, "G_RM_CLD_SURF2" },
- { G_RM_TEX_EDGE, "G_RM_TEX_EDGE" },
- { G_RM_TEX_EDGE2, "G_RM_TEX_EDGE2" },
- { G_RM_PCL_SURF, "G_RM_PCL_SURF" },
- { G_RM_PCL_SURF2, "G_RM_PCL_SURF2" },
- { G_RM_ADD, "G_RM_ADD" },
- { G_RM_ADD2, "G_RM_ADD2" },
- { G_RM_NOOP, "G_RM_NOOP" },
- { G_RM_NOOP2, "G_RM_NOOP2" },
- { G_RM_VISCVG, "G_RM_VISCVG" },
- { G_RM_VISCVG2, "G_RM_VISCVG2" },
- { G_RM_OPA_CI, "G_RM_OPA_CI" },
- { G_RM_OPA_CI2, "G_RM_OPA_CI2" },
- };
-
- for (int k = 0; k < sizeof(tblA) / 4; k++)
- {
- if ((dd & tblA[k]) == tblA[k])
- {
- if (tblA[k] > mode1)
- mode1 = tblA[k];
-
- int bp = 0;
- }
- }
-
- for (int k = 0; k < sizeof(tblB) / 4; k++)
- {
- if ((dd & tblB[k]) == tblB[k])
- {
- if (tblB[k] > mode2)
- mode2 = tblB[k];
-
- int bp = 0;
- }
- }
-
- sprintf(line, "gsDPSetRenderMode(%s, %s),", str[mode1].c_str(), str[mode2].c_str());
- }
- else
- sprintf(line, "gsSPSetOtherMode(0xE2, %i, %i, 0x%08X),", sft, nn + 1, dd);
- }
- break;
- case F3DZEXOpcode::G_SETOTHERMODE_H:
- {
- int ss = (data & 0x0000FF0000000000) >> 40;
- int nn = (data & 0x000000FF00000000) >> 32;
- int dd = (data & 0xFFFFFFFF);
-
- int sft = 32 - (nn + 1) - ss;
-
- if (sft == 14) // G_MDSFT_TEXTLUT
- {
- string types[] = { "G_TT_NONE", "G_TT_NONE", "G_TT_RGBA16", "G_TT_IA16" };
- sprintf(line, "gsDPSetTextureLUT(%s),", types[dd >> 14].c_str());
- }
- else
- sprintf(line, "gsSPSetOtherMode(0xE3, %i, %i, 0x%08X),", sft, nn + 1, dd);
- }
- break;
- case F3DZEXOpcode::G_SETTILE:
- {
- int fff = (data & 0b0000000011100000000000000000000000000000000000000000000000000000) >> 53;
- int ii = (data & 0b0000000000011000000000000000000000000000000000000000000000000000) >> 51;
- int nnnnnnnnn = (data & 0b0000000000000011111111100000000000000000000000000000000000000000) >> 41;
- int mmmmmmmmm = (data & 0b0000000000000000000000011111111100000000000000000000000000000000) >> 32;
- int ttt = (data & 0b0000000000000000000000000000000000000111000000000000000000000000) >> 24;
- int pppp = (data & 0b0000000000000000000000000000000000000000111100000000000000000000) >> 20;
- int cc = (data & 0b0000000000000000000000000000000000000000000011000000000000000000) >> 18;
- int aaaa = (data & 0b0000000000000000000000000000000000000000000000111100000000000000) >> 14;
- int ssss = (data & 0b0000000000000000000000000000000000000000000000000011110000000000) >> 10;
- int dd = (data & 0b0000000000000000000000000000000000000000000000000000001100000000) >> 8;
- int bbbb = (data & 0b0000000000000000000000000000000000000000000000000000000011110000) >> 4;
- int uuuu = (data & 0b0000000000000000000000000000000000000000000000000000000000001111);
-
- string fmtTbl[] = { "G_IM_FMT_RGBA", "G_IM_FMT_YUV", "G_IM_FMT_CI", "G_IM_FMT_IA", "G_IM_FMT_I" };
- string sizTbl[] = { "G_IM_SIZ_4b", "G_IM_SIZ_8b", "G_IM_SIZ_16b", "G_IM_SIZ_32b" };
-
- if (fff == (int)F3DZEXTexFormats::G_IM_FMT_CI)
- lastCISiz = (F3DZEXTexSizes)ii;
-
- lastTexSizTest = (F3DZEXTexSizes)ii;
-
- sprintf(line, "gsDPSetTile(%s, %s, %i, %i, %i, %i, %i, %i, %i, %i, %i, %i),", fmtTbl[fff].c_str(), sizTbl[ii].c_str(), nnnnnnnnn, mmmmmmmmm, ttt, pppp, cc, aaaa, ssss, dd, bbbb, uuuu);
- }
- break;
- case F3DZEXOpcode::G_SETTILESIZE:
- {
- int sss = (data & 0x00FFF00000000000) >> 44;
- int ttt = (data & 0x00000FFF00000000) >> 32;
- int uuu = (data & 0x0000000000FFF000) >> 12;
- int vvv = (data & 0x0000000000000FFF);
- int i = (data & 0x000000000F000000) >> 24;
-
- int shiftAmtW = 2;
- int shiftAmtH = 2;
-
- if (lastTexSizTest == F3DZEXTexSizes::G_IM_SIZ_8b && lastTexFmt == F3DZEXTexFormats::G_IM_FMT_IA)
- shiftAmtW = 3;
-
- //if (lastTexFmt == F3DZEXTexFormats::G_IM_FMT_I || lastTexFmt == F3DZEXTexFormats::G_IM_FMT_CI)
- if (lastTexSizTest == F3DZEXTexSizes::G_IM_SIZ_4b)
- shiftAmtW = 3;
-
- if (lastTexSizTest == F3DZEXTexSizes::G_IM_SIZ_4b && lastTexFmt == F3DZEXTexFormats::G_IM_FMT_IA)
- shiftAmtH = 3;
-
-
- lastTexWidth = (uuu >> shiftAmtW) + 1;
- lastTexHeight = (vvv >> shiftAmtH) + 1;
-
- if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
- printf("lastTexWidth: %i lastTexHeight: %i, lastTexSizTest: 0x%x, lastTexFmt: 0x%x\n", lastTexWidth, lastTexHeight, (uint32_t)lastTexSizTest, (uint32_t)lastTexFmt);
-
- if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
- printf("TextureGenCheck G_SETTILESIZE\n");
-
- TextureGenCheck(prefix);
-
- sprintf(line, "gsDPSetTileSize(%i, %i, %i, %i, %i),", i, sss, ttt, uuu, vvv);
- }
- break;
- case F3DZEXOpcode::G_LOADBLOCK:
- {
- int sss = (data & 0x00FFF00000000000) >> 48;
- int ttt = (data & 0x00000FFF00000000) >> 36;
- int i = (data & 0x000000000F000000) >> 24;
- int xxx = (data & 0x0000000000FFF000) >> 12;
- int ddd = (data & 0x0000000000000FFF);
-
- //lastTexHeight = (ddd + 1) / 16;
-
- lastTexLoaded = true;
-
- //TextureGenCheck(prefix);
-
- sprintf(line, "gsDPLoadBlock(%i, %i, %i, %i, %i),", i, sss, ttt, xxx, ddd);
- }
- break;
- case F3DZEXOpcode::G_TEXTURE:
- {
- int ____ = (data & 0x0000FFFF00000000) >> 32;
- int ssss = (data & 0x00000000FFFF0000) >> 16;
- int tttt = (data & 0x000000000000FFFF);
- int lll = (____ & 0x3800) >> 11;
- int ddd = (____ & 0x700) >> 8;
- int nnnnnnn = (____ & 0xFE) >> 1;
-
- sprintf(line, "gsSPTexture(%i, %i, %i, %i, %s),", ssss, tttt, lll, ddd, nnnnnnn == 1 ? "G_ON" : "G_OFF");
- }
- break;
- case F3DZEXOpcode::G_RDPSETOTHERMODE:
- {
- int hhhhhh = (data & 0x00FFFFFF00000000) >> 32;
- int llllllll = (data & 0x00000000FFFFFFFF);
-
- sprintf(line, "gsDPSetOtherMode(%i, %i),", hhhhhh, llllllll);
- }
- break;
- case F3DZEXOpcode::G_POPMTX:
- {
- sprintf(line, "gsSPPopMatrix(%li),", data);
- }
- break;
- case F3DZEXOpcode::G_LOADTLUT:
- {
- int t = (data & 0x0000000007000000) >> 24;
- int ccc = (data & 0x00000000003FF000) >> 14;
-
- lastTexWidth = sqrt(ccc + 1);
- lastTexHeight = sqrt(ccc + 1);
-
- lastTexLoaded = true;
- lastTexIsPalette = true;
-
- if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
- printf("TextureGenCheck G_LOADTLUT (lastCISiz: %i)\n", (uint32_t)lastCISiz);
-
- TextureGenCheck(prefix);
-
- sprintf(line, "gsDPLoadTLUTCmd(%i, %i),", t, ccc);
- }
- break;
- case F3DZEXOpcode::G_SETENVCOLOR:
- {
- uint8_t r = (uint8_t)((data & 0xFF000000) >> 24);
- uint8_t g = (uint8_t)((data & 0x00FF0000) >> 16);
- uint8_t b = (uint8_t)((data & 0xFF00FF00) >> 8);
- uint8_t a = (uint8_t)((data & 0x000000FF) >> 0);
-
- sprintf(line, "gsDPSetEnvColor(%i, %i, %i, %i),", r, g, b, a);
- }
- break;
- case F3DZEXOpcode::G_SETCOMBINE:
- {
- int a0 = (data & 0b000000011110000000000000000000000000000000000000000000000000000) >> 52;
- int c0 = (data & 0b000000000001111100000000000000000000000000000000000000000000000) >> 47;
- int aa0 = (data & 0b00000000000000011100000000000000000000000000000000000000000000) >> 44;
- int ac0 = (data & 0b00000000000000000011100000000000000000000000000000000000000000) >> 41;
- int a1 = (data & 0b000000000000000000000011110000000000000000000000000000000000000) >> 37;
- int c1 = (data & 0b000000000000000000000000001111100000000000000000000000000000000) >> 32;
- int b0 = (data & 0b000000000000000000000000000000011110000000000000000000000000000) >> 28;
- int b1 = (data & 0b000000000000000000000000000000000001111000000000000000000000000) >> 24;
- int aa1 = (data & 0b00000000000000000000000000000000000000111000000000000000000000) >> 21;
- int ac1 = (data & 0b00000000000000000000000000000000000000000111000000000000000000) >> 18;
- int d0 = (data & 0b000000000000000000000000000000000000000000000111000000000000000) >> 15;
- int ab0 = (data & 0b00000000000000000000000000000000000000000000000111000000000000) >> 12;
- int ad0 = (data & 0b00000000000000000000000000000000000000000000000000111000000000) >> 9;
- int d1 = (data & 0b000000000000000000000000000000000000000000000000000000111000000) >> 6;
- int ab1 = (data & 0b00000000000000000000000000000000000000000000000000000000111000) >> 3;
- int ad1 = (data & 0b00000000000000000000000000000000000000000000000000000000000111) >> 0;
-
- string modes[] = { "COMBINED", "TEXEL0", "TEXEL1", "PRIMITIVE", "SHADE", "ENVIRONMENT", "1", "COMBINED_ALPHA",
- "TEXEL0_ALPHA", "TEXEL1_ALPHA", "PRIMITIVE_ALPHA", "SHADE_ALPHA", "ENV_ALPHA", "LOD_FRACTION", "PRIM_LOD_FRAC", "K5",
- "17", "18", "19", "20", "21", "22", "23", "24",
- "25", "26", "27", "28", "29", "30", "31", "0" };
-
- string modes2[] = { "COMBINED", "TEXEL0", "TEXEL1", "PRIMITIVE", "SHADE", "ENVIRONMENT", "1", "0" };
-
- sprintf(line, "gsDPSetCombineLERP(%s, %s, %s, %s, %s, %s, %s, %s,\n %s, %s, %s, %s, %s, %s, %s, %s),",
- modes[a0].c_str(), modes[b0].c_str(), modes[c0].c_str(), modes[d0].c_str(),
- modes2[aa0].c_str(), modes2[ab0].c_str(), modes2[ac0].c_str(), modes2[ad0].c_str(),
- modes[a1].c_str(), modes[b1].c_str(), modes[c1].c_str(), modes[d1].c_str(),
- modes2[aa1].c_str(), modes2[ab1].c_str(), modes2[ac1].c_str(), modes2[ad1].c_str());
- }
- break;
- case F3DZEXOpcode::G_RDPLOADSYNC:
- sprintf(line, "gsDPLoadSync(),");
- break;
- case F3DZEXOpcode::G_RDPPIPESYNC:
- sprintf(line, "gsDPPipeSync(),");
- break;
- case F3DZEXOpcode::G_RDPTILESYNC:
- sprintf(line, "gsDPTileSync(),");
- break;
- case F3DZEXOpcode::G_RDPFULLSYNC:
- sprintf(line, "gsDPFullSync(),");
- break;
- case F3DZEXOpcode::G_ENDDL:
- sprintf(line, "gsSPEndDisplayList(),");
-
- if (Globals::Instance->verbosity >= VERBOSITY_DEBUG)
- printf("TextureGenCheck G_ENDDL\n");
-
- TextureGenCheck(prefix);
- break;
- case F3DZEXOpcode::G_RDPHALF_1:
- {
- uint64_t data2 = instructions[i + 1];
- uint32_t h = (data & 0xFFFFFFFF);
- F3DZEXOpcode opcode2 = (F3DZEXOpcode)(instructions[i + 1] >> 56);
-
- if (opcode2 == F3DZEXOpcode::G_BRANCH_Z)
- {
- uint32_t a = (data2 & 0x00FFF00000000000) >> 44;
- uint32_t b = (data2 & 0x00000FFF00000000) >> 32;
- uint32_t z = (data2 & 0x00000000FFFFFFFF) >> 0;
-
- //sprintf(line, "gsDPWord(%i, 0),", h);
- sprintf(line, "gsSPBranchLessZraw(%sDlist0x%06X, 0x%02X, 0x%02X),", prefix.c_str(), h & 0x00FFFFFF, (a / 5) | (b / 2), z);
-
- ZDisplayList* nList = new ZDisplayList(fileData, h & 0x00FFFFFF, GetDListLength(fileData, h & 0x00FFFFFF));
- nList->scene = scene;
- nList->parent = parent;
- otherDLists.push_back(nList);
-
- i++;
- }
- }
- break;
- /*case F3DZEXOpcode::G_BRANCH_Z:
- {
- uint8_t h = (data & 0xFFFFFFFF);
-
- sprintf(line, "gsSPBranchLessZraw(%i, %i, %i),", h);
- }
- break;*/
- case F3DZEXOpcode::G_MTX:
- {
- // TODO: FINISH THIS
- uint32_t pp = (data & 0x000000FF00000000) >> 32;
- uint32_t mm = (data & 0x00000000FFFFFFFF);
- std::string matrixRef = "";
-
- if (Globals::Instance->symbolMap.find(mm) != Globals::Instance->symbolMap.end())
- matrixRef = StringHelper::Sprintf("&%s", Globals::Instance->symbolMap[mm].c_str());
- else
- matrixRef = StringHelper::Sprintf("0x%08X", mm);
-
- sprintf(line, "gsSPMatrix(%s, 0x%02X),", matrixRef.c_str(), pp ^ 0x01);
- }
- break;
- default:
- sprintf(line, "// Opcode 0x%02X unimplemented!", (uint32_t)opcode);
- break;
- }
+ if (dListType == DListType::F3DZEX)
+ ParseF3DZEX((F3DZEXOpcode)opcode, data, i, prefix, line);
+ else
+ ParseF3DEX((F3DEXOpcode)opcode, data, i, prefix, line);
}
auto end = chrono::steady_clock::now();
@@ -1150,77 +1529,77 @@ string ZDisplayList::GetSourceOutputCode(const std::string& prefix)
}
}
- // Check for texture intersections
+ // Check for texture intersections
+ {
+ if (scene != nullptr && scene->textures.size() != 0)
{
- if (scene != nullptr && scene->textures.size() != 0)
- {
- vector> texturesSorted(scene->textures.begin(), scene->textures.end());
+ vector> texturesSorted(scene->textures.begin(), scene->textures.end());
- sort(texturesSorted.begin(), texturesSorted.end(), [](const auto& lhs, const auto& rhs)
+ sort(texturesSorted.begin(), texturesSorted.end(), [](const auto& lhs, const auto& rhs)
{
return lhs.first < rhs.first;
});
- for (int i = 0; i < texturesSorted.size() - 1; i++)
+ for (int i = 0; i < texturesSorted.size() - 1; i++)
+ {
+ int texSize = scene->textures[texturesSorted[i].first]->GetRawDataSize();
+
+ if ((texturesSorted[i].first + texSize) > texturesSorted[i + 1].first)
{
- int texSize = scene->textures[texturesSorted[i].first]->GetRawDataSize();
+ int intersectAmt = (texturesSorted[i].first + texSize) - texturesSorted[i + 1].first;
- if ((texturesSorted[i].first + texSize) > texturesSorted[i + 1].first)
+ defines += StringHelper::Sprintf("#define %sTex_%06X ((u32)%sTex_%06X + 0x%06X)\n", scene->GetName().c_str(), texturesSorted[i + 1].first, scene->GetName().c_str(),
+ texturesSorted[i].first, texturesSorted[i + 1].first - texturesSorted[i].first);
+
+ scene->parent->declarations.erase(texturesSorted[i + 1].first);
+ scene->textures.erase(texturesSorted[i + 1].first);
+ texturesSorted.erase(texturesSorted.begin() + i + 1);
+
+ i--;
+ }
+ }
+
+ scene->extDefines += defines;
+ }
+
+ {
+ vector> texturesSorted(textures.begin(), textures.end());
+
+ sort(texturesSorted.begin(), texturesSorted.end(), [](const auto& lhs, const auto& rhs)
+ {
+ return lhs.first < rhs.first;
+ });
+
+ for (int i = 0; i < texturesSorted.size() - 1; i++)
+ {
+ if (texturesSorted.size() == 0) // ?????
+ break;
+
+ int texSize = textures[texturesSorted[i].first]->GetRawDataSize();
+
+ if ((texturesSorted[i].first + texSize) > texturesSorted[i + 1].first)
+ {
+ int intersectAmt = (texturesSorted[i].first + texSize) - texturesSorted[i + 1].first;
+
+ // If we're working with a palette, resize it to its "real" dimensions
+ if (texturesSorted[i].second->isPalette)
{
- int intersectAmt = (texturesSorted[i].first + texSize) - texturesSorted[i + 1].first;
-
- defines += StringHelper::Sprintf("#define %sTex_%06X ((u32)%sTex_%06X + 0x%06X)\n", scene->GetName().c_str(), texturesSorted[i + 1].first, scene->GetName().c_str(),
+ texturesSorted[i].second->SetWidth((texturesSorted[i + 1].first - texturesSorted[i].first) / 2);
+ texturesSorted[i].second->SetHeight(1);
+ }
+ else
+ {
+ defines += StringHelper::Sprintf("#define %sTex_%06X ((u32)%sTex_%06X + 0x%06X)\n", prefix.c_str(), texturesSorted[i + 1].first, prefix.c_str(),
texturesSorted[i].first, texturesSorted[i + 1].first - texturesSorted[i].first);
- scene->parent->declarations.erase(texturesSorted[i + 1].first);
- scene->textures.erase(texturesSorted[i + 1].first);
+ textures.erase(texturesSorted[i + 1].first);
texturesSorted.erase(texturesSorted.begin() + i + 1);
i--;
}
}
-
- scene->extDefines += defines;
- }
-
- {
- vector> texturesSorted(textures.begin(), textures.end());
-
- sort(texturesSorted.begin(), texturesSorted.end(), [](const auto& lhs, const auto& rhs)
- {
- return lhs.first < rhs.first;
- });
-
- for (int i = 0; i < texturesSorted.size() - 1; i++)
- {
- if (texturesSorted.size() == 0) // ?????
- break;
-
- int texSize = textures[texturesSorted[i].first]->GetRawDataSize();
-
- if ((texturesSorted[i].first + texSize) > texturesSorted[i + 1].first)
- {
- int intersectAmt = (texturesSorted[i].first + texSize) - texturesSorted[i + 1].first;
-
- // If we're working with a palette, resize it to its "real" dimensions
- if (texturesSorted[i].second->isPalette)
- {
- texturesSorted[i].second->SetWidth((texturesSorted[i + 1].first - texturesSorted[i].first) / 2);
- texturesSorted[i].second->SetHeight(1);
- }
- else
- {
- defines += StringHelper::Sprintf("#define %sTex_%06X ((u32)%sTex_%06X + 0x%06X)\n", prefix.c_str(), texturesSorted[i + 1].first, prefix.c_str(),
- texturesSorted[i].first, texturesSorted[i + 1].first - texturesSorted[i].first);
-
- textures.erase(texturesSorted[i + 1].first);
- texturesSorted.erase(texturesSorted.begin() + i + 1);
-
- i--;
- }
- }
- }
}
+ }
// Generate Texture Declarations
for (pair item : textures)
@@ -1248,7 +1627,7 @@ string ZDisplayList::GetSourceOutputCode(const std::string& prefix)
}
}
-
+
if (parent != nullptr)
{
Declaration* decl = parent->AddDeclarationArray(rawDataIndex, DeclarationAlignment::None, GetRawDataSize(), "Gfx", StringHelper::Sprintf("%s", name.c_str()), 0, sourceOutput);
@@ -1320,7 +1699,7 @@ TextureType ZDisplayList::TexFormatToTexType(F3DZEXTexFormats fmt, F3DZEXTexSize
else if (fmt == F3DZEXTexFormats::G_IM_FMT_CI)
{
//if (siz == F3DZEXTexSizes::G_IM_SIZ_8b)
- return TextureType::Palette8bpp;
+ return TextureType::Palette8bpp;
}
else if (fmt == F3DZEXTexFormats::G_IM_FMT_IA)
{
diff --git a/tools/ZAPD/ZAPD/ZDisplayList.h b/tools/ZAPD/ZAPD/ZDisplayList.h
index dcfe6bb39d..c3f7fa2aa4 100644
--- a/tools/ZAPD/ZAPD/ZDisplayList.h
+++ b/tools/ZAPD/ZAPD/ZDisplayList.h
@@ -9,6 +9,60 @@
#include