diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Destroy.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Destroy.s deleted file mode 100644 index 1a03c4be06..0000000000 --- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Destroy.s +++ /dev/null @@ -1,4 +0,0 @@ -glabel BgSpot16Doughnut_Destroy -/* 001A0 808B65E0 AFA40000 */ sw $a0, 0x0000($sp) -/* 001A4 808B65E4 03E00008 */ jr $ra -/* 001A8 808B65E8 AFA50004 */ sw $a1, 0x0004($sp) diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Draw.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Draw.s deleted file mode 100644 index 45b74028fe..0000000000 --- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Draw.s +++ /dev/null @@ -1,141 +0,0 @@ -.rdata -glabel D_808B6A68 - .asciz "../z_bg_spot16_doughnut.c" - .balign 4 - -glabel D_808B6A84 - .asciz "../z_bg_spot16_doughnut.c" - .balign 4 - -glabel D_808B6AA0 - .asciz "../z_bg_spot16_doughnut.c" - .balign 4 - -.text -glabel BgSpot16Doughnut_Draw -/* 002A8 808B66E8 27BDFF80 */ addiu $sp, $sp, 0xFF80 ## $sp = FFFFFF80 -/* 002AC 808B66EC 3C0F0001 */ lui $t7, 0x0001 ## $t7 = 00010000 -/* 002B0 808B66F0 AFBF003C */ sw $ra, 0x003C($sp) -/* 002B4 808B66F4 AFB00038 */ sw $s0, 0x0038($sp) -/* 002B8 808B66F8 AFA40080 */ sw $a0, 0x0080($sp) -/* 002BC 808B66FC AFA50084 */ sw $a1, 0x0084($sp) -/* 002C0 808B6700 01E57821 */ addu $t7, $t7, $a1 -/* 002C4 808B6704 8DEF1DE4 */ lw $t7, 0x1DE4($t7) ## 00011DE4 -/* 002C8 808B6708 3C06808B */ lui $a2, %hi(D_808B6A68) ## $a2 = 808B0000 -/* 002CC 808B670C 24C66A68 */ addiu $a2, $a2, %lo(D_808B6A68) ## $a2 = 808B6A68 -/* 002D0 808B6710 31F8FFFF */ andi $t8, $t7, 0xFFFF ## $t8 = 00000000 -/* 002D4 808B6714 AFB80078 */ sw $t8, 0x0078($sp) -/* 002D8 808B6718 8CA50000 */ lw $a1, 0x0000($a1) ## 00000000 -/* 002DC 808B671C 27A40060 */ addiu $a0, $sp, 0x0060 ## $a0 = FFFFFFE0 -/* 002E0 808B6720 240700D2 */ addiu $a3, $zero, 0x00D2 ## $a3 = 000000D2 -/* 002E4 808B6724 0C031AB1 */ jal Graph_OpenDisps -/* 002E8 808B6728 00A08025 */ or $s0, $a1, $zero ## $s0 = 00000000 -/* 002EC 808B672C 8FB90084 */ lw $t9, 0x0084($sp) -/* 002F0 808B6730 0C024F61 */ jal func_80093D84 -/* 002F4 808B6734 8F240000 */ lw $a0, 0x0000($t9) ## 00000000 -/* 002F8 808B6738 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 002FC 808B673C 3C0BDA38 */ lui $t3, 0xDA38 ## $t3 = DA380000 -/* 00300 808B6740 356B0003 */ ori $t3, $t3, 0x0003 ## $t3 = DA380003 -/* 00304 808B6744 244A0008 */ addiu $t2, $v0, 0x0008 ## $t2 = 00000008 -/* 00308 808B6748 AE0A02D0 */ sw $t2, 0x02D0($s0) ## 000002D0 -/* 0030C 808B674C AC4B0000 */ sw $t3, 0x0000($v0) ## 00000000 -/* 00310 808B6750 8FAC0084 */ lw $t4, 0x0084($sp) -/* 00314 808B6754 3C05808B */ lui $a1, %hi(D_808B6A84) ## $a1 = 808B0000 -/* 00318 808B6758 24A56A84 */ addiu $a1, $a1, %lo(D_808B6A84) ## $a1 = 808B6A84 -/* 0031C 808B675C 8D840000 */ lw $a0, 0x0000($t4) ## 00000000 -/* 00320 808B6760 240600D5 */ addiu $a2, $zero, 0x00D5 ## $a2 = 000000D5 -/* 00324 808B6764 0C0346A2 */ jal Matrix_NewMtx -/* 00328 808B6768 AFA2005C */ sw $v0, 0x005C($sp) -/* 0032C 808B676C 8FA3005C */ lw $v1, 0x005C($sp) -/* 00330 808B6770 3C0EDB06 */ lui $t6, 0xDB06 ## $t6 = DB060000 -/* 00334 808B6774 35CE0020 */ ori $t6, $t6, 0x0020 ## $t6 = DB060020 -/* 00338 808B6778 AC620004 */ sw $v0, 0x0004($v1) ## 00000004 -/* 0033C 808B677C 8FA90080 */ lw $t1, 0x0080($sp) -/* 00340 808B6780 8FA80078 */ lw $t0, 0x0078($sp) -/* 00344 808B6784 00002825 */ or $a1, $zero, $zero ## $a1 = 00000000 -/* 00348 808B6788 952D014C */ lhu $t5, 0x014C($t1) ## 0000014C -/* 0034C 808B678C 00003825 */ or $a3, $zero, $zero ## $a3 = 00000000 -/* 00350 808B6790 240A0010 */ addiu $t2, $zero, 0x0010 ## $t2 = 00000010 -/* 00354 808B6794 31AF0001 */ andi $t7, $t5, 0x0001 ## $t7 = 00000000 -/* 00358 808B6798 11E0002B */ beq $t7, $zero, .L808B6848 -/* 0035C 808B679C 00083023 */ subu $a2, $zero, $t0 -/* 00360 808B67A0 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 00364 808B67A4 00080823 */ subu $at, $zero, $t0 -/* 00368 808B67A8 00016840 */ sll $t5, $at, 1 -/* 0036C 808B67AC 24580008 */ addiu $t8, $v0, 0x0008 ## $t8 = 00000008 -/* 00370 808B67B0 AE1802D0 */ sw $t8, 0x02D0($s0) ## 000002D0 -/* 00374 808B67B4 AC4E0000 */ sw $t6, 0x0000($v0) ## 00000000 -/* 00378 808B67B8 8FB90084 */ lw $t9, 0x0084($sp) -/* 0037C 808B67BC 24180020 */ addiu $t8, $zero, 0x0020 ## $t8 = 00000020 -/* 00380 808B67C0 240B0020 */ addiu $t3, $zero, 0x0020 ## $t3 = 00000020 -/* 00384 808B67C4 8F240000 */ lw $a0, 0x0000($t9) ## 00000000 -/* 00388 808B67C8 240C0001 */ addiu $t4, $zero, 0x0001 ## $t4 = 00000001 -/* 0038C 808B67CC 240F0010 */ addiu $t7, $zero, 0x0010 ## $t7 = 00000010 -/* 00390 808B67D0 AFAF0024 */ sw $t7, 0x0024($sp) -/* 00394 808B67D4 AFAC0018 */ sw $t4, 0x0018($sp) -/* 00398 808B67D8 AFB80028 */ sw $t8, 0x0028($sp) -/* 0039C 808B67DC AFAD0020 */ sw $t5, 0x0020($sp) -/* 003A0 808B67E0 AFA8001C */ sw $t0, 0x001C($sp) -/* 003A4 808B67E4 AFAB0014 */ sw $t3, 0x0014($sp) -/* 003A8 808B67E8 AFAA0010 */ sw $t2, 0x0010($sp) -/* 003AC 808B67EC 0C0253D0 */ jal Gfx_TwoTexScroll -/* 003B0 808B67F0 AFA20058 */ sw $v0, 0x0058($sp) -/* 003B4 808B67F4 8FA30058 */ lw $v1, 0x0058($sp) -/* 003B8 808B67F8 3C19FB00 */ lui $t9, 0xFB00 ## $t9 = FB000000 -/* 003BC 808B67FC 3C01FF00 */ lui $at, 0xFF00 ## $at = FF000000 -/* 003C0 808B6800 AC620004 */ sw $v0, 0x0004($v1) ## 00000004 -/* 003C4 808B6804 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 003C8 808B6808 3C18DE00 */ lui $t8, 0xDE00 ## $t8 = DE000000 -/* 003CC 808B680C 244E0008 */ addiu $t6, $v0, 0x0008 ## $t6 = 00000008 -/* 003D0 808B6810 AE0E02D0 */ sw $t6, 0x02D0($s0) ## 000002D0 -/* 003D4 808B6814 AC590000 */ sw $t9, 0x0000($v0) ## 00000000 -/* 003D8 808B6818 8FAA0080 */ lw $t2, 0x0080($sp) -/* 003DC 808B681C 3C0E0600 */ lui $t6, 0x0600 ## $t6 = 06000000 -/* 003E0 808B6820 25CE0660 */ addiu $t6, $t6, 0x0660 ## $t6 = 06000660 -/* 003E4 808B6824 914C0150 */ lbu $t4, 0x0150($t2) ## 00000150 -/* 003E8 808B6828 01816825 */ or $t5, $t4, $at ## $t5 = FF000000 -/* 003EC 808B682C AC4D0004 */ sw $t5, 0x0004($v0) ## 00000004 -/* 003F0 808B6830 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 003F4 808B6834 244F0008 */ addiu $t7, $v0, 0x0008 ## $t7 = 00000008 -/* 003F8 808B6838 AE0F02D0 */ sw $t7, 0x02D0($s0) ## 000002D0 -/* 003FC 808B683C AC4E0004 */ sw $t6, 0x0004($v0) ## 00000004 -/* 00400 808B6840 10000019 */ beq $zero, $zero, .L808B68A8 -/* 00404 808B6844 AC580000 */ sw $t8, 0x0000($v0) ## 00000000 -.L808B6848: -/* 00408 808B6848 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 0040C 808B684C 3C0AFB00 */ lui $t2, 0xFB00 ## $t2 = FB000000 -/* 00410 808B6850 2401FF00 */ addiu $at, $zero, 0xFF00 ## $at = FFFFFF00 -/* 00414 808B6854 24590008 */ addiu $t9, $v0, 0x0008 ## $t9 = 00000008 -/* 00418 808B6858 AE1902D0 */ sw $t9, 0x02D0($s0) ## 000002D0 -/* 0041C 808B685C AC4A0000 */ sw $t2, 0x0000($v0) ## 00000000 -/* 00420 808B6860 912C0150 */ lbu $t4, 0x0150($t1) ## 00000150 -/* 00424 808B6864 3C18FA00 */ lui $t8, 0xFA00 ## $t8 = FA000000 -/* 00428 808B6868 240EFFFF */ addiu $t6, $zero, 0xFFFF ## $t6 = FFFFFFFF -/* 0042C 808B686C 01816825 */ or $t5, $t4, $at ## $t5 = FFFFFF00 -/* 00430 808B6870 AC4D0004 */ sw $t5, 0x0004($v0) ## 00000004 -/* 00434 808B6874 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 00438 808B6878 3C0B0600 */ lui $t3, 0x0600 ## $t3 = 06000000 -/* 0043C 808B687C 256B0FC0 */ addiu $t3, $t3, 0x0FC0 ## $t3 = 06000FC0 -/* 00440 808B6880 244F0008 */ addiu $t7, $v0, 0x0008 ## $t7 = 00000008 -/* 00444 808B6884 AE0F02D0 */ sw $t7, 0x02D0($s0) ## 000002D0 -/* 00448 808B6888 AC4E0004 */ sw $t6, 0x0004($v0) ## 00000004 -/* 0044C 808B688C AC580000 */ sw $t8, 0x0000($v0) ## 00000000 -/* 00450 808B6890 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 00454 808B6894 3C0ADE00 */ lui $t2, 0xDE00 ## $t2 = DE000000 -/* 00458 808B6898 24590008 */ addiu $t9, $v0, 0x0008 ## $t9 = 00000008 -/* 0045C 808B689C AE1902D0 */ sw $t9, 0x02D0($s0) ## 000002D0 -/* 00460 808B68A0 AC4B0004 */ sw $t3, 0x0004($v0) ## 00000004 -/* 00464 808B68A4 AC4A0000 */ sw $t2, 0x0000($v0) ## 00000000 -.L808B68A8: -/* 00468 808B68A8 8FAC0084 */ lw $t4, 0x0084($sp) -/* 0046C 808B68AC 3C06808B */ lui $a2, %hi(D_808B6AA0) ## $a2 = 808B0000 -/* 00470 808B68B0 24C66AA0 */ addiu $a2, $a2, %lo(D_808B6AA0) ## $a2 = 808B6AA0 -/* 00474 808B68B4 27A40060 */ addiu $a0, $sp, 0x0060 ## $a0 = FFFFFFE0 -/* 00478 808B68B8 240700EE */ addiu $a3, $zero, 0x00EE ## $a3 = 000000EE -/* 0047C 808B68BC 0C031AD5 */ jal Graph_CloseDisps -/* 00480 808B68C0 8D850000 */ lw $a1, 0x0000($t4) ## 00000000 -/* 00484 808B68C4 8FBF003C */ lw $ra, 0x003C($sp) -/* 00488 808B68C8 8FB00038 */ lw $s0, 0x0038($sp) -/* 0048C 808B68CC 27BD0080 */ addiu $sp, $sp, 0x0080 ## $sp = 00000000 -/* 00490 808B68D0 03E00008 */ jr $ra -/* 00494 808B68D4 00000000 */ nop diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Init.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Init.s deleted file mode 100644 index a32972cbb8..0000000000 --- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Init.s +++ /dev/null @@ -1,136 +0,0 @@ -.rdata -glabel D_808B6A30 - .asciz "%f\n" - .balign 4 - -glabel D_808B6A3C - .asciz "(spot16 ドーナツ雲)(arg_data 0x%04x)\n" - .balign 4 - -.late_rodata -glabel D_808B6B10 - .word 0x38D1B717 - -.text -glabel BgSpot16Doughnut_Init -/* 00000 808B6440 27BDFFE0 */ addiu $sp, $sp, 0xFFE0 ## $sp = FFFFFFE0 -/* 00004 808B6444 AFA50024 */ sw $a1, 0x0024($sp) -/* 00008 808B6448 AFBF001C */ sw $ra, 0x001C($sp) -/* 0000C 808B644C AFB00018 */ sw $s0, 0x0018($sp) -/* 00010 808B6450 3C05808B */ lui $a1, %hi(D_808B6A10) ## $a1 = 808B0000 -/* 00014 808B6454 00808025 */ or $s0, $a0, $zero ## $s0 = 00000000 -/* 00018 808B6458 0C01E037 */ jal Actor_ProcessInitChain - -/* 0001C 808B645C 24A56A10 */ addiu $a1, $a1, %lo(D_808B6A10) ## $a1 = 808B6A10 -/* 00020 808B6460 3C053DCC */ lui $a1, 0x3DCC ## $a1 = 3DCC0000 -/* 00024 808B6464 34A5CCCD */ ori $a1, $a1, 0xCCCD ## $a1 = 3DCCCCCD -/* 00028 808B6468 0C00B58B */ jal Actor_SetScale - -/* 0002C 808B646C 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000 -/* 00030 808B6470 8603001C */ lh $v1, 0x001C($s0) ## 0000001C -/* 00034 808B6474 240E00FF */ addiu $t6, $zero, 0x00FF ## $t6 = 000000FF -/* 00038 808B6478 24010001 */ addiu $at, $zero, 0x0001 ## $at = 00000001 -/* 0003C 808B647C A600014C */ sh $zero, 0x014C($s0) ## 0000014C -/* 00040 808B6480 A20E0150 */ sb $t6, 0x0150($s0) ## 00000150 -/* 00044 808B6484 10610008 */ beq $v1, $at, .L808B64A8 -/* 00048 808B6488 00601025 */ or $v0, $v1, $zero ## $v0 = 00000000 -/* 0004C 808B648C 24010002 */ addiu $at, $zero, 0x0002 ## $at = 00000002 -/* 00050 808B6490 10410005 */ beq $v0, $at, .L808B64A8 -/* 00054 808B6494 24010003 */ addiu $at, $zero, 0x0003 ## $at = 00000003 -/* 00058 808B6498 10410003 */ beq $v0, $at, .L808B64A8 -/* 0005C 808B649C 24010004 */ addiu $at, $zero, 0x0004 ## $at = 00000004 -/* 00060 808B64A0 14410015 */ bne $v0, $at, .L808B64F8 -/* 00064 808B64A4 8FA90024 */ lw $t1, 0x0024($sp) -.L808B64A8: -/* 00068 808B64A8 00037840 */ sll $t7, $v1, 1 -/* 0006C 808B64AC 3C18808B */ lui $t8, %hi(D_808B6A1C) ## $t8 = 808B0000 -/* 00070 808B64B0 030FC021 */ addu $t8, $t8, $t7 -/* 00074 808B64B4 87186A1C */ lh $t8, %lo(D_808B6A1C)($t8) -/* 00078 808B64B8 3C01808B */ lui $at, %hi(D_808B6B10) ## $at = 808B0000 -/* 0007C 808B64BC C4286B10 */ lwc1 $f8, %lo(D_808B6B10)($at) -/* 00080 808B64C0 44982000 */ mtc1 $t8, $f4 ## $f4 = -0.00 -/* 00084 808B64C4 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000 -/* 00088 808B64C8 468021A0 */ cvt.s.w $f6, $f4 -/* 0008C 808B64CC 46083282 */ mul.s $f10, $f6, $f8 -/* 00090 808B64D0 44055000 */ mfc1 $a1, $f10 -/* 00094 808B64D4 0C00B58B */ jal Actor_SetScale - -/* 00098 808B64D8 00000000 */ nop -/* 0009C 808B64DC 3C19808B */ lui $t9, %hi(func_808B68D8) ## $t9 = 808B0000 -/* 000A0 808B64E0 3C08808B */ lui $t0, %hi(func_808B6680) ## $t0 = 808B0000 -/* 000A4 808B64E4 273968D8 */ addiu $t9, $t9, %lo(func_808B68D8) ## $t9 = 808B68D8 -/* 000A8 808B64E8 25086680 */ addiu $t0, $t0, %lo(func_808B6680) ## $t0 = 808B6680 -/* 000AC 808B64EC AE190134 */ sw $t9, 0x0134($s0) ## 00000134 -/* 000B0 808B64F0 10000036 */ beq $zero, $zero, .L808B65CC -/* 000B4 808B64F4 AE080130 */ sw $t0, 0x0130($s0) ## 00000130 -.L808B64F8: -/* 000B8 808B64F8 852200A4 */ lh $v0, 0x00A4($t1) ## 000000A4 -/* 000BC 808B64FC 24010023 */ addiu $at, $zero, 0x0023 ## $at = 00000023 -/* 000C0 808B6500 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000 -/* 000C4 808B6504 1041000E */ beq $v0, $at, .L808B6540 -/* 000C8 808B6508 3C053C93 */ lui $a1, 0x3C93 ## $a1 = 3C930000 -/* 000CC 808B650C 24010024 */ addiu $at, $zero, 0x0024 ## $at = 00000024 -/* 000D0 808B6510 1041000B */ beq $v0, $at, .L808B6540 -/* 000D4 808B6514 24010025 */ addiu $at, $zero, 0x0025 ## $at = 00000025 -/* 000D8 808B6518 10410009 */ beq $v0, $at, .L808B6540 -/* 000DC 808B651C 24010052 */ addiu $at, $zero, 0x0052 ## $at = 00000052 -/* 000E0 808B6520 1441000B */ bne $v0, $at, .L808B6550 -/* 000E4 808B6524 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000 -/* 000E8 808B6528 3C053D23 */ lui $a1, 0x3D23 ## $a1 = 3D230000 -/* 000EC 808B652C 34A5D70A */ ori $a1, $a1, 0xD70A ## $a1 = 3D23D70A -/* 000F0 808B6530 0C00B58B */ jal Actor_SetScale - -/* 000F4 808B6534 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000 -/* 000F8 808B6538 10000009 */ beq $zero, $zero, .L808B6560 -/* 000FC 808B653C C6100050 */ lwc1 $f16, 0x0050($s0) ## 00000050 -.L808B6540: -/* 00100 808B6540 0C00B58B */ jal Actor_SetScale - -/* 00104 808B6544 34A574BC */ ori $a1, $a1, 0x74BC ## $a1 = 000074BC -/* 00108 808B6548 10000005 */ beq $zero, $zero, .L808B6560 -/* 0010C 808B654C C6100050 */ lwc1 $f16, 0x0050($s0) ## 00000050 -.L808B6550: -/* 00110 808B6550 3C053DCC */ lui $a1, 0x3DCC ## $a1 = 3DCC0000 -/* 00114 808B6554 0C00B58B */ jal Actor_SetScale - -/* 00118 808B6558 34A5CCCD */ ori $a1, $a1, 0xCCCD ## $a1 = 3DCCCCCD -/* 0011C 808B655C C6100050 */ lwc1 $f16, 0x0050($s0) ## 00000050 -.L808B6560: -/* 00120 808B6560 3C04808B */ lui $a0, %hi(D_808B6A30) ## $a0 = 808B0000 -/* 00124 808B6564 24846A30 */ addiu $a0, $a0, %lo(D_808B6A30) ## $a0 = 808B6A30 -/* 00128 808B6568 460084A1 */ cvt.d.s $f18, $f16 -/* 0012C 808B656C 44079000 */ mfc1 $a3, $f18 -/* 00130 808B6570 44069800 */ mfc1 $a2, $f19 -/* 00134 808B6574 0C00084C */ jal osSyncPrintf - -/* 00138 808B6578 00000000 */ nop -/* 0013C 808B657C 3C028016 */ lui $v0, %hi(gSaveContext) -/* 00140 808B6580 2442E660 */ addiu $v0, %lo(gSaveContext) -/* 00144 808B6584 8C4A0004 */ lw $t2, 0x0004($v0) ## 8015E664 -/* 00148 808B6588 3C04808B */ lui $a0, %hi(D_808B6A3C) ## $a0 = 808B0000 -/* 0014C 808B658C 24846A3C */ addiu $a0, $a0, %lo(D_808B6A3C) ## $a0 = 808B6A3C -/* 00150 808B6590 55400006 */ bnel $t2, $zero, .L808B65AC -/* 00154 808B6594 960D014C */ lhu $t5, 0x014C($s0) ## 0000014C -/* 00158 808B6598 944B0ED8 */ lhu $t3, 0x0ED8($v0) ## 8015F538 -/* 0015C 808B659C 316C8000 */ andi $t4, $t3, 0x8000 ## $t4 = 00000000 -/* 00160 808B65A0 51800006 */ beql $t4, $zero, .L808B65BC -/* 00164 808B65A4 960F014C */ lhu $t7, 0x014C($s0) ## 0000014C -/* 00168 808B65A8 960D014C */ lhu $t5, 0x014C($s0) ## 0000014C -.L808B65AC: -/* 0016C 808B65AC 31AEFFFE */ andi $t6, $t5, 0xFFFE ## $t6 = 00000000 -/* 00170 808B65B0 10000004 */ beq $zero, $zero, .L808B65C4 -/* 00174 808B65B4 A60E014C */ sh $t6, 0x014C($s0) ## 0000014C -/* 00178 808B65B8 960F014C */ lhu $t7, 0x014C($s0) ## 0000014C -.L808B65BC: -/* 0017C 808B65BC 35F80001 */ ori $t8, $t7, 0x0001 ## $t8 = 00000001 -/* 00180 808B65C0 A618014C */ sh $t8, 0x014C($s0) ## 0000014C -.L808B65C4: -/* 00184 808B65C4 0C00084C */ jal osSyncPrintf - -/* 00188 808B65C8 8605001C */ lh $a1, 0x001C($s0) ## 0000001C -.L808B65CC: -/* 0018C 808B65CC 8FBF001C */ lw $ra, 0x001C($sp) -/* 00190 808B65D0 8FB00018 */ lw $s0, 0x0018($sp) -/* 00194 808B65D4 27BD0020 */ addiu $sp, $sp, 0x0020 ## $sp = 00000000 -/* 00198 808B65D8 03E00008 */ jr $ra -/* 0019C 808B65DC 00000000 */ nop diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Update.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Update.s deleted file mode 100644 index 02cbae05c9..0000000000 --- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Update.s +++ /dev/null @@ -1,43 +0,0 @@ -glabel BgSpot16Doughnut_Update -/* 001AC 808B65EC 9482014C */ lhu $v0, 0x014C($a0) ## 0000014C -/* 001B0 808B65F0 304E0001 */ andi $t6, $v0, 0x0001 ## $t6 = 00000000 -/* 001B4 808B65F4 55C0000E */ bnel $t6, $zero, .L808B6630 -/* 001B8 808B65F8 90A91D6C */ lbu $t1, 0x1D6C($a1) ## 00001D6C -/* 001BC 808B65FC 848F00B6 */ lh $t7, 0x00B6($a0) ## 000000B6 -/* 001C0 808B6600 90830150 */ lbu $v1, 0x0150($a0) ## 00000150 -/* 001C4 808B6604 240800FF */ addiu $t0, $zero, 0x00FF ## $t0 = 000000FF -/* 001C8 808B6608 25F8FFE0 */ addiu $t8, $t7, 0xFFE0 ## $t8 = FFFFFFE0 -/* 001CC 808B660C 286100FF */ slti $at, $v1, 0x00FF -/* 001D0 808B6610 10200004 */ beq $at, $zero, .L808B6624 -/* 001D4 808B6614 A49800B6 */ sh $t8, 0x00B6($a0) ## 000000B6 -/* 001D8 808B6618 24790005 */ addiu $t9, $v1, 0x0005 ## $t9 = 00000005 -/* 001DC 808B661C 03E00008 */ jr $ra -/* 001E0 808B6620 A0990150 */ sb $t9, 0x0150($a0) ## 00000150 -.L808B6624: -/* 001E4 808B6624 03E00008 */ jr $ra -/* 001E8 808B6628 A0880150 */ sb $t0, 0x0150($a0) ## 00000150 -.L808B662C: -/* 001EC 808B662C 90A91D6C */ lbu $t1, 0x1D6C($a1) ## 00001D6C -.L808B6630: -/* 001F0 808B6630 11200011 */ beq $t1, $zero, .L808B6678 -/* 001F4 808B6634 00000000 */ nop -/* 001F8 808B6638 8CA31D94 */ lw $v1, 0x1D94($a1) ## 00001D94 -/* 001FC 808B663C 1060000E */ beq $v1, $zero, .L808B6678 -/* 00200 808B6640 00000000 */ nop -/* 00204 808B6644 946A0000 */ lhu $t2, 0x0000($v1) ## 00000000 -/* 00208 808B6648 24010002 */ addiu $at, $zero, 0x0002 ## $at = 00000002 -/* 0020C 808B664C 1541000A */ bne $t2, $at, .L808B6678 -/* 00210 808B6650 00000000 */ nop -/* 00214 808B6654 90830150 */ lbu $v1, 0x0150($a0) ## 00000150 -/* 00218 808B6658 304CFFFE */ andi $t4, $v0, 0xFFFE ## $t4 = 00000000 -/* 0021C 808B665C 28610006 */ slti $at, $v1, 0x0006 -/* 00220 808B6660 14200003 */ bne $at, $zero, .L808B6670 -/* 00224 808B6664 246BFFFB */ addiu $t3, $v1, 0xFFFB ## $t3 = FFFFFFFB -/* 00228 808B6668 03E00008 */ jr $ra -/* 0022C 808B666C A08B0150 */ sb $t3, 0x0150($a0) ## 00000150 -.L808B6670: -/* 00230 808B6670 A0800150 */ sb $zero, 0x0150($a0) ## 00000150 -/* 00234 808B6674 A48C014C */ sh $t4, 0x014C($a0) ## 0000014C -.L808B6678: -/* 00238 808B6678 03E00008 */ jr $ra -/* 0023C 808B667C 00000000 */ nop diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B6680.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B6680.s deleted file mode 100644 index 8944fdfa61..0000000000 --- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B6680.s +++ /dev/null @@ -1,36 +0,0 @@ -.late_rodata -glabel D_808B6B14 - .word 0x3B03126E, 0x00000000, 0x00000000 - -.text -glabel func_808B6680 -/* 00240 808B6680 27BDFFE8 */ addiu $sp, $sp, 0xFFE8 ## $sp = FFFFFFE8 -/* 00244 808B6684 AFBF0014 */ sw $ra, 0x0014($sp) -/* 00248 808B6688 AFA5001C */ sw $a1, 0x001C($sp) -/* 0024C 808B668C 90820150 */ lbu $v0, 0x0150($a0) ## 00000150 -/* 00250 808B6690 28410006 */ slti $at, $v0, 0x0006 -/* 00254 808B6694 14200003 */ bne $at, $zero, .L808B66A4 -/* 00258 808B6698 244EFFFB */ addiu $t6, $v0, 0xFFFB ## $t6 = FFFFFFFB -/* 0025C 808B669C 10000004 */ beq $zero, $zero, .L808B66B0 -/* 00260 808B66A0 A08E0150 */ sb $t6, 0x0150($a0) ## 00000150 -.L808B66A4: -/* 00264 808B66A4 0C00B55C */ jal Actor_Kill - -/* 00268 808B66A8 AFA40018 */ sw $a0, 0x0018($sp) -/* 0026C 808B66AC 8FA40018 */ lw $a0, 0x0018($sp) -.L808B66B0: -/* 00270 808B66B0 848F00B6 */ lh $t7, 0x00B6($a0) ## 000000B6 -/* 00274 808B66B4 3C01808B */ lui $at, %hi(D_808B6B14) ## $at = 808B0000 -/* 00278 808B66B8 C4840050 */ lwc1 $f4, 0x0050($a0) ## 00000050 -/* 0027C 808B66BC 25F8FFE0 */ addiu $t8, $t7, 0xFFE0 ## $t8 = FFFFFFE0 -/* 00280 808B66C0 A49800B6 */ sh $t8, 0x00B6($a0) ## 000000B6 -/* 00284 808B66C4 C4266B14 */ lwc1 $f6, %lo(D_808B6B14)($at) -/* 00288 808B66C8 46062200 */ add.s $f8, $f4, $f6 -/* 0028C 808B66CC 44054000 */ mfc1 $a1, $f8 -/* 00290 808B66D0 0C00B58B */ jal Actor_SetScale - -/* 00294 808B66D4 00000000 */ nop -/* 00298 808B66D8 8FBF0014 */ lw $ra, 0x0014($sp) -/* 0029C 808B66DC 27BD0018 */ addiu $sp, $sp, 0x0018 ## $sp = 00000000 -/* 002A0 808B66E0 03E00008 */ jr $ra -/* 002A4 808B66E4 00000000 */ nop diff --git a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B68D8.s b/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B68D8.s deleted file mode 100644 index 3c238f9269..0000000000 --- a/asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B68D8.s +++ /dev/null @@ -1,85 +0,0 @@ -.rdata -glabel D_808B6ABC - .asciz "../z_bg_spot16_doughnut.c" - .balign 4 - -glabel D_808B6AD8 - .asciz "../z_bg_spot16_doughnut.c" - .balign 4 - -glabel D_808B6AF4 - .asciz "../z_bg_spot16_doughnut.c" - .balign 4 - -.text -glabel func_808B68D8 -/* 00498 808B68D8 27BDFFB0 */ addiu $sp, $sp, 0xFFB0 ## $sp = FFFFFFB0 -/* 0049C 808B68DC AFBF001C */ sw $ra, 0x001C($sp) -/* 004A0 808B68E0 AFB00018 */ sw $s0, 0x0018($sp) -/* 004A4 808B68E4 AFA40050 */ sw $a0, 0x0050($sp) -/* 004A8 808B68E8 AFA50054 */ sw $a1, 0x0054($sp) -/* 004AC 808B68EC 8CA50000 */ lw $a1, 0x0000($a1) ## 00000000 -/* 004B0 808B68F0 3C06808B */ lui $a2, %hi(D_808B6ABC) ## $a2 = 808B0000 -/* 004B4 808B68F4 24C66ABC */ addiu $a2, $a2, %lo(D_808B6ABC) ## $a2 = 808B6ABC -/* 004B8 808B68F8 27A40038 */ addiu $a0, $sp, 0x0038 ## $a0 = FFFFFFE8 -/* 004BC 808B68FC 240700F5 */ addiu $a3, $zero, 0x00F5 ## $a3 = 000000F5 -/* 004C0 808B6900 0C031AB1 */ jal Graph_OpenDisps -/* 004C4 808B6904 00A08025 */ or $s0, $a1, $zero ## $s0 = 00000000 -/* 004C8 808B6908 8FAF0054 */ lw $t7, 0x0054($sp) -/* 004CC 808B690C 0C024F61 */ jal func_80093D84 -/* 004D0 808B6910 8DE40000 */ lw $a0, 0x0000($t7) ## 00000000 -/* 004D4 808B6914 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 004D8 808B6918 3C19DA38 */ lui $t9, 0xDA38 ## $t9 = DA380000 -/* 004DC 808B691C 37390003 */ ori $t9, $t9, 0x0003 ## $t9 = DA380003 -/* 004E0 808B6920 24580008 */ addiu $t8, $v0, 0x0008 ## $t8 = 00000008 -/* 004E4 808B6924 AE1802D0 */ sw $t8, 0x02D0($s0) ## 000002D0 -/* 004E8 808B6928 AC590000 */ sw $t9, 0x0000($v0) ## 00000000 -/* 004EC 808B692C 8FA80054 */ lw $t0, 0x0054($sp) -/* 004F0 808B6930 3C05808B */ lui $a1, %hi(D_808B6AD8) ## $a1 = 808B0000 -/* 004F4 808B6934 24A56AD8 */ addiu $a1, $a1, %lo(D_808B6AD8) ## $a1 = 808B6AD8 -/* 004F8 808B6938 8D040000 */ lw $a0, 0x0000($t0) ## 00000000 -/* 004FC 808B693C 240600F8 */ addiu $a2, $zero, 0x00F8 ## $a2 = 000000F8 -/* 00500 808B6940 0C0346A2 */ jal Matrix_NewMtx -/* 00504 808B6944 AFA20034 */ sw $v0, 0x0034($sp) -/* 00508 808B6948 8FA30034 */ lw $v1, 0x0034($sp) -/* 0050C 808B694C 3C0AFB00 */ lui $t2, 0xFB00 ## $t2 = FB000000 -/* 00510 808B6950 2401FF00 */ addiu $at, $zero, 0xFF00 ## $at = FFFFFF00 -/* 00514 808B6954 AC620004 */ sw $v0, 0x0004($v1) ## 00000004 -/* 00518 808B6958 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 0051C 808B695C 3C18FA00 */ lui $t8, 0xFA00 ## $t8 = FA000000 -/* 00520 808B6960 2419FFFF */ addiu $t9, $zero, 0xFFFF ## $t9 = FFFFFFFF -/* 00524 808B6964 24490008 */ addiu $t1, $v0, 0x0008 ## $t1 = 00000008 -/* 00528 808B6968 AE0902D0 */ sw $t1, 0x02D0($s0) ## 000002D0 -/* 0052C 808B696C AC4A0000 */ sw $t2, 0x0000($v0) ## 00000000 -/* 00530 808B6970 8FAB0050 */ lw $t3, 0x0050($sp) -/* 00534 808B6974 3C0A0600 */ lui $t2, 0x0600 ## $t2 = 06000000 -/* 00538 808B6978 254A0FC0 */ addiu $t2, $t2, 0x0FC0 ## $t2 = 06000FC0 -/* 0053C 808B697C 916D0150 */ lbu $t5, 0x0150($t3) ## 00000150 -/* 00540 808B6980 3C09DE00 */ lui $t1, 0xDE00 ## $t1 = DE000000 -/* 00544 808B6984 3C06808B */ lui $a2, %hi(D_808B6AF4) ## $a2 = 808B0000 -/* 00548 808B6988 01A17025 */ or $t6, $t5, $at ## $t6 = FFFFFF00 -/* 0054C 808B698C AC4E0004 */ sw $t6, 0x0004($v0) ## 00000004 -/* 00550 808B6990 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 00554 808B6994 24C66AF4 */ addiu $a2, $a2, %lo(D_808B6AF4) ## $a2 = 808B6AF4 -/* 00558 808B6998 27A40038 */ addiu $a0, $sp, 0x0038 ## $a0 = FFFFFFE8 -/* 0055C 808B699C 244F0008 */ addiu $t7, $v0, 0x0008 ## $t7 = 00000008 -/* 00560 808B69A0 AE0F02D0 */ sw $t7, 0x02D0($s0) ## 000002D0 -/* 00564 808B69A4 AC590004 */ sw $t9, 0x0004($v0) ## 00000004 -/* 00568 808B69A8 AC580000 */ sw $t8, 0x0000($v0) ## 00000000 -/* 0056C 808B69AC 8E0202D0 */ lw $v0, 0x02D0($s0) ## 000002D0 -/* 00570 808B69B0 24070100 */ addiu $a3, $zero, 0x0100 ## $a3 = 00000100 -/* 00574 808B69B4 24480008 */ addiu $t0, $v0, 0x0008 ## $t0 = 00000008 -/* 00578 808B69B8 AE0802D0 */ sw $t0, 0x02D0($s0) ## 000002D0 -/* 0057C 808B69BC AC4A0004 */ sw $t2, 0x0004($v0) ## 00000004 -/* 00580 808B69C0 AC490000 */ sw $t1, 0x0000($v0) ## 00000000 -/* 00584 808B69C4 8FAB0054 */ lw $t3, 0x0054($sp) -/* 00588 808B69C8 0C031AD5 */ jal Graph_CloseDisps -/* 0058C 808B69CC 8D650000 */ lw $a1, 0x0000($t3) ## 00000000 -/* 00590 808B69D0 8FBF001C */ lw $ra, 0x001C($sp) -/* 00594 808B69D4 8FB00018 */ lw $s0, 0x0018($sp) -/* 00598 808B69D8 27BD0050 */ addiu $sp, $sp, 0x0050 ## $sp = 00000000 -/* 0059C 808B69DC 03E00008 */ jr $ra -/* 005A0 808B69E0 00000000 */ nop -/* 005A4 808B69E4 00000000 */ nop -/* 005A8 808B69E8 00000000 */ nop -/* 005AC 808B69EC 00000000 */ nop diff --git a/data/overlays/actors/z_bg_spot16_doughnut.data.s b/data/overlays/actors/z_bg_spot16_doughnut.data.s deleted file mode 100644 index b8ed653f1c..0000000000 --- a/data/overlays/actors/z_bg_spot16_doughnut.data.s +++ /dev/null @@ -1,22 +0,0 @@ -.include "macro.inc" - - # assembler directives - .set noat # allow manual use of $at - .set noreorder # don't insert nops after branches - .set gp=64 # allow use of 64-bit general purpose registers - -.section .data - -.balign 16 - -glabel Bg_Spot16_Doughnut_InitVars - .word 0x00E50600, 0x00000000, 0x017A0000, 0x00000154 -.word BgSpot16Doughnut_Init -.word BgSpot16Doughnut_Destroy -.word BgSpot16Doughnut_Update -.word BgSpot16Doughnut_Draw -glabel D_808B6A10 - .word 0xB0F4157C, 0xB0F81388, 0x30FC1388 -glabel D_808B6A1C - .word 0x00000000, 0x004600D2, 0x012C0000, 0x00000000, 0x00000000 - diff --git a/data/overlays/actors/z_bg_spot16_doughnut.reloc.s b/data/overlays/actors/z_bg_spot16_doughnut.reloc.s deleted file mode 100644 index f730dd9727..0000000000 --- a/data/overlays/actors/z_bg_spot16_doughnut.reloc.s +++ /dev/null @@ -1,13 +0,0 @@ -.include "macro.inc" - - # assembler directives - .set noat # allow manual use of $at - .set noreorder # don't insert nops after branches - .set gp=64 # allow use of 64-bit general purpose registers - -.section .rodata - -.balign 16 - -glabel D_808B6B20 - .incbin "baserom/ovl_Bg_Spot16_Doughnut", 0x6E0, 0x000000A0 diff --git a/spec b/spec index 92921997d2..09e611eb15 100644 --- a/spec +++ b/spec @@ -1363,8 +1363,7 @@ endseg beginseg name "ovl_Bg_Spot16_Doughnut" include "build/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.o" - include "build/data/overlays/actors/z_bg_spot16_doughnut.data.o" - include "build/data/overlays/actors/z_bg_spot16_doughnut.reloc.o" + include "build/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut_reloc.o" endseg beginseg diff --git a/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c b/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c index 773c6ceca8..996d29a836 100644 --- a/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c +++ b/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.c @@ -1,4 +1,11 @@ +/* + * File: z_bg_spot16_doughnut.c + * Overlay: ovl_Bg_Spot16_Doughnut + * Description: Death Mountain cloud circle + */ + #include "z_bg_spot16_doughnut.h" +#include #define FLAGS 0x00000000 @@ -9,7 +16,9 @@ void BgSpot16Doughnut_Destroy(Actor* thisx, GlobalContext* globalCtx); void BgSpot16Doughnut_Update(Actor* thisx, GlobalContext* globalCtx); void BgSpot16Doughnut_Draw(Actor* thisx, GlobalContext* globalCtx); -/* +void BgSpot16Doughnut_UpdateExpanding(Actor* thisx, GlobalContext* globalCtx); +void BgSpot16Doughnut_DrawExpanding(Actor* thisx, GlobalContext* globalCtx); + const ActorInit Bg_Spot16_Doughnut_InitVars = { ACTOR_BG_SPOT16_DOUGHNUT, ACTORTYPE_PROP, @@ -21,15 +30,136 @@ const ActorInit Bg_Spot16_Doughnut_InitVars = { (ActorFunc)BgSpot16Doughnut_Update, (ActorFunc)BgSpot16Doughnut_Draw, }; -*/ -#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Init.s") -#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Destroy.s") +static InitChainEntry sInitChain[] = { + ICHAIN_F32(unk_F4, 5500, ICHAIN_CONTINUE), + ICHAIN_F32(unk_F8, 5000, ICHAIN_CONTINUE), + ICHAIN_F32(unk_FC, 5000, ICHAIN_STOP), +}; -#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Update.s") +static s16 sScales[] = { + 0, 0, 70, 210, 300, +}; -#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B6680.s") +extern Gfx D_06000660[]; +extern Gfx D_06000FC0[]; -#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/BgSpot16Doughnut_Draw.s") +void BgSpot16Doughnut_Init(Actor* thisx, GlobalContext* globalCtx) { + BgSpot16Doughnut* this = THIS; + s32 params; -#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Spot16_Doughnut/func_808B68D8.s") + Actor_ProcessInitChain(&this->actor, sInitChain); + Actor_SetScale(&this->actor, 0.1f); + this->fireFlag = 0; + this->envColorAlpha = 0xFF; + params = this->actor.params; + if (params == 1 || params == 2 || params == 3 || params == 4) { + Actor_SetScale(&this->actor, sScales[this->actor.params] * 1.0e-4f); + this->actor.draw = BgSpot16Doughnut_DrawExpanding; + this->actor.update = BgSpot16Doughnut_UpdateExpanding; + } else { + // Scales this actor for scenes where it is featured in the background, + // Death Mountain itself falls into the default case. + switch (globalCtx->sceneNum) { + case SCENE_SPOT01: + Actor_SetScale(&this->actor, 0.04f); + break; + case SCENE_SHRINE: + case SCENE_SHRINE_N: + case SCENE_SHRINE_R: + Actor_SetScale(&this->actor, 0.018f); + break; + default: + Actor_SetScale(&this->actor, 0.1f); + break; + } + osSyncPrintf(VT_FGCOL(CYAN) "%f" VT_RST "\n", this->actor.scale.x); + if (LINK_IS_CHILD || gSaveContext.eventChkInf[2] & 0x8000) { + this->fireFlag &= ~1; + } else { + this->fireFlag |= 1; + } + osSyncPrintf("(spot16 ドーナツ雲)(arg_data 0x%04x)\n", this->actor.params); + } +} + +void BgSpot16Doughnut_Destroy(Actor* thisx, GlobalContext* globalCtx) { +} + +void BgSpot16Doughnut_Update(Actor* thisx, GlobalContext* globalCtx) { + BgSpot16Doughnut* this = THIS; + + if (!(this->fireFlag & 1)) { + this->actor.shape.rot.y -= 0x20; + if (this->envColorAlpha < 0xFF) { + this->envColorAlpha += 5; + } else { + this->envColorAlpha = 0xFF; + } + } else if (globalCtx->csCtx.state != 0 && globalCtx->csCtx.npcActions[2] != NULL && + globalCtx->csCtx.npcActions[2]->action == 2) { + if (this->envColorAlpha >= 6) { + this->envColorAlpha -= 5; + } else { + this->envColorAlpha = 0; + this->fireFlag &= ~1; + } + } +} + +// Update function for outwardly expanding and dissipating +void BgSpot16Doughnut_UpdateExpanding(Actor* thisx, GlobalContext* globalCtx) { + BgSpot16Doughnut* this = THIS; + + if (this->envColorAlpha >= 6) { + this->envColorAlpha -= 5; + } else { + Actor_Kill(&this->actor); + } + this->actor.shape.rot.y -= 0x20; + Actor_SetScale(&this->actor, this->actor.scale.x + 0.0019999998f); +} + +void BgSpot16Doughnut_Draw(Actor* thisx, GlobalContext* globalCtx) { + BgSpot16Doughnut* this = THIS; + u32 scroll; + GraphicsContext* gfxCtx; + Gfx* dispRefs[5]; + + scroll = globalCtx->gameplayFrames & 0xFFFF; + gfxCtx = globalCtx->state.gfxCtx; + Graph_OpenDisps(dispRefs, globalCtx->state.gfxCtx, "../z_bg_spot16_doughnut.c", 210); + func_80093D84(globalCtx->state.gfxCtx); + if (1) {} + gSPMatrix(gfxCtx->polyXlu.p++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_spot16_doughnut.c", 213), + G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); + if (this->fireFlag & 1) { + gSPSegment( + gfxCtx->polyXlu.p++, 0x08, + Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, scroll * (-1), 0, 16, 32, 1, scroll, scroll * (-2), 16, 32)); + gDPSetEnvColor(gfxCtx->polyXlu.p++, 0xFF, 0x00, 0x00, this->envColorAlpha); + gSPDisplayList(gfxCtx->polyXlu.p++, D_06000660); + } else { + gDPSetEnvColor(gfxCtx->polyXlu.p++, 0xFF, 0xFF, 0xFF, this->envColorAlpha); + gDPSetPrimColor(gfxCtx->polyXlu.p++, 0, 0, 0xFF, 0xFF, 0xFF, 0xFF); + gSPDisplayList(gfxCtx->polyXlu.p++, D_06000FC0); + } + Graph_CloseDisps(dispRefs, globalCtx->state.gfxCtx, "../z_bg_spot16_doughnut.c", 238); +} + +// Draw function for outwardly expanding and dissipating +void BgSpot16Doughnut_DrawExpanding(Actor* thisx, GlobalContext* globalCtx) { + BgSpot16Doughnut* this = THIS; + GraphicsContext* gfxCtx; + Gfx* dispRefs[4]; + + gfxCtx = globalCtx->state.gfxCtx; + Graph_OpenDisps(dispRefs, globalCtx->state.gfxCtx, "../z_bg_spot16_doughnut.c", 245); + func_80093D84(globalCtx->state.gfxCtx); + gSPMatrix(gfxCtx->polyXlu.p++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_spot16_doughnut.c", 248), + G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW); + gDPSetEnvColor(gfxCtx->polyXlu.p++, 0xFF, 0xFF, 0xFF, this->envColorAlpha); + gDPSetPrimColor(gfxCtx->polyXlu.p++, 0, 0, 0xFF, 0xFF, 0xFF, 0xFF); + gSPDisplayList(gfxCtx->polyXlu.p++, D_06000FC0); + Graph_CloseDisps(dispRefs, globalCtx->state.gfxCtx, "../z_bg_spot16_doughnut.c", 256); +} diff --git a/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.h b/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.h index cd6c181f40..ae8048c24c 100644 --- a/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.h +++ b/src/overlays/actors/ovl_Bg_Spot16_Doughnut/z_bg_spot16_doughnut.h @@ -8,7 +8,9 @@ struct BgSpot16Doughnut; typedef struct BgSpot16Doughnut { /* 0x0000 */ Actor actor; - /* 0x014C */ char unk_14C[0x8]; + /* 0x014C */ u16 fireFlag; + /* 0x014E */ char pad[0x02]; + /* 0x0150 */ u8 envColorAlpha; } BgSpot16Doughnut; // size = 0x0154 extern const ActorInit Bg_Spot16_Doughnut_InitVars; diff --git a/undefined_syms.txt b/undefined_syms.txt index 19b4fbc8a6..26ab25a25b 100644 --- a/undefined_syms.txt +++ b/undefined_syms.txt @@ -625,3 +625,6 @@ D_06003128 = 0x06003128; D_060042AC = 0x060042AC; D_060059B0 = 0x060059B0; +// z_Bg_Spot16_Doughnut +D_06000660 = 0x06000660; +D_06000FC0 = 0x06000FC0;