mirror of
https://github.com/zeldaret/oot.git
synced 2024-11-27 04:10:30 +00:00
z_bg_menkuri_eye OK (#374)
* z_bg_menkuri_eye OK * Fixed up a few things in Update * Made all requested fixes.
This commit is contained in:
parent
eba7a30d86
commit
9891ac04c3
@ -1,11 +0,0 @@
|
||||
glabel BgMenkuriEye_Destroy
|
||||
/* 000D8 8089BD48 27BDFFE8 */ addiu $sp, $sp, 0xFFE8 ## $sp = FFFFFFE8
|
||||
/* 000DC 8089BD4C 00803025 */ or $a2, $a0, $zero ## $a2 = 00000000
|
||||
/* 000E0 8089BD50 AFBF0014 */ sw $ra, 0x0014($sp)
|
||||
/* 000E4 8089BD54 00A02025 */ or $a0, $a1, $zero ## $a0 = 00000000
|
||||
/* 000E8 8089BD58 0C016F32 */ jal Collider_DestroyJntSph
|
||||
/* 000EC 8089BD5C 24C50150 */ addiu $a1, $a2, 0x0150 ## $a1 = 00000150
|
||||
/* 000F0 8089BD60 8FBF0014 */ lw $ra, 0x0014($sp)
|
||||
/* 000F4 8089BD64 27BD0018 */ addiu $sp, $sp, 0x0018 ## $sp = 00000000
|
||||
/* 000F8 8089BD68 03E00008 */ jr $ra
|
||||
/* 000FC 8089BD6C 00000000 */ nop
|
@ -1,119 +0,0 @@
|
||||
.rdata
|
||||
glabel D_8089C0D0
|
||||
.asciz "../z_bg_menkuri_eye.c"
|
||||
.balign 4
|
||||
|
||||
glabel D_8089C0E8
|
||||
.asciz "../z_bg_menkuri_eye.c"
|
||||
.balign 4
|
||||
|
||||
glabel D_8089C100
|
||||
.asciz "../z_bg_menkuri_eye.c"
|
||||
.balign 4
|
||||
|
||||
.text
|
||||
glabel BgMenkuriEye_Draw
|
||||
/* 00270 8089BEE0 27BDFFA8 */ addiu $sp, $sp, 0xFFA8 ## $sp = FFFFFFA8
|
||||
/* 00274 8089BEE4 AFBF001C */ sw $ra, 0x001C($sp)
|
||||
/* 00278 8089BEE8 AFB10018 */ sw $s1, 0x0018($sp)
|
||||
/* 0027C 8089BEEC AFB00014 */ sw $s0, 0x0014($sp)
|
||||
/* 00280 8089BEF0 AFA5005C */ sw $a1, 0x005C($sp)
|
||||
/* 00284 8089BEF4 8CA50000 */ lw $a1, 0x0000($a1) ## 00000000
|
||||
/* 00288 8089BEF8 00808025 */ or $s0, $a0, $zero ## $s0 = 00000000
|
||||
/* 0028C 8089BEFC 3C06808A */ lui $a2, %hi(D_8089C0D0) ## $a2 = 808A0000
|
||||
/* 00290 8089BF00 24C6C0D0 */ addiu $a2, $a2, %lo(D_8089C0D0) ## $a2 = 8089C0D0
|
||||
/* 00294 8089BF04 27A4003C */ addiu $a0, $sp, 0x003C ## $a0 = FFFFFFE4
|
||||
/* 00298 8089BF08 24070124 */ addiu $a3, $zero, 0x0124 ## $a3 = 00000124
|
||||
/* 0029C 8089BF0C 0C031AB1 */ jal Graph_OpenDisps
|
||||
/* 002A0 8089BF10 00A08825 */ or $s1, $a1, $zero ## $s1 = 00000000
|
||||
/* 002A4 8089BF14 8FAF005C */ lw $t7, 0x005C($sp)
|
||||
/* 002A8 8089BF18 0C024F61 */ jal func_80093D84
|
||||
/* 002AC 8089BF1C 8DE40000 */ lw $a0, 0x0000($t7) ## 00000000
|
||||
/* 002B0 8089BF20 8FA4005C */ lw $a0, 0x005C($sp)
|
||||
/* 002B4 8089BF24 0C00B2D0 */ jal Flags_GetSwitch
|
||||
|
||||
/* 002B8 8089BF28 8605001C */ lh $a1, 0x001C($s0) ## 0000001C
|
||||
/* 002BC 8089BF2C 1040000A */ beq $v0, $zero, .L8089BF58
|
||||
/* 002C0 8089BF30 00003825 */ or $a3, $zero, $zero ## $a3 = 00000000
|
||||
/* 002C4 8089BF34 8E2202D0 */ lw $v0, 0x02D0($s1) ## 000002D0
|
||||
/* 002C8 8089BF38 3C08C800 */ lui $t0, 0xC800 ## $t0 = C8000000
|
||||
/* 002CC 8089BF3C 350800FF */ ori $t0, $t0, 0x00FF ## $t0 = C80000FF
|
||||
/* 002D0 8089BF40 24580008 */ addiu $t8, $v0, 0x0008 ## $t8 = 00000008
|
||||
/* 002D4 8089BF44 AE3802D0 */ sw $t8, 0x02D0($s1) ## 000002D0
|
||||
/* 002D8 8089BF48 3C19FB00 */ lui $t9, 0xFB00 ## $t9 = FB000000
|
||||
/* 002DC 8089BF4C AC590000 */ sw $t9, 0x0000($v0) ## 00000000
|
||||
/* 002E0 8089BF50 10000015 */ beq $zero, $zero, .L8089BFA8
|
||||
/* 002E4 8089BF54 AC480004 */ sw $t0, 0x0004($v0) ## 00000004
|
||||
.L8089BF58:
|
||||
/* 002E8 8089BF58 8609014C */ lh $t1, 0x014C($s0) ## 0000014C
|
||||
/* 002EC 8089BF5C 2401FFFF */ addiu $at, $zero, 0xFFFF ## $at = FFFFFFFF
|
||||
/* 002F0 8089BF60 3C0EFB00 */ lui $t6, 0xFB00 ## $t6 = FB000000
|
||||
/* 002F4 8089BF64 5521000A */ bnel $t1, $at, .L8089BF90
|
||||
/* 002F8 8089BF68 8E2202D0 */ lw $v0, 0x02D0($s1) ## 000002D0
|
||||
/* 002FC 8089BF6C 8E2202D0 */ lw $v0, 0x02D0($s1) ## 000002D0
|
||||
/* 00300 8089BF70 3C0BFB00 */ lui $t3, 0xFB00 ## $t3 = FB000000
|
||||
/* 00304 8089BF74 3C0CC800 */ lui $t4, 0xC800 ## $t4 = C8000000
|
||||
/* 00308 8089BF78 244A0008 */ addiu $t2, $v0, 0x0008 ## $t2 = 00000008
|
||||
/* 0030C 8089BF7C AE2A02D0 */ sw $t2, 0x02D0($s1) ## 000002D0
|
||||
/* 00310 8089BF80 AC4C0004 */ sw $t4, 0x0004($v0) ## 00000004
|
||||
/* 00314 8089BF84 10000008 */ beq $zero, $zero, .L8089BFA8
|
||||
/* 00318 8089BF88 AC4B0000 */ sw $t3, 0x0000($v0) ## 00000000
|
||||
/* 0031C 8089BF8C 8E2202D0 */ lw $v0, 0x02D0($s1) ## 000002D0
|
||||
.L8089BF90:
|
||||
/* 00320 8089BF90 3C0FC800 */ lui $t7, 0xC800 ## $t7 = C8000000
|
||||
/* 00324 8089BF94 35EF00FF */ ori $t7, $t7, 0x00FF ## $t7 = C80000FF
|
||||
/* 00328 8089BF98 244D0008 */ addiu $t5, $v0, 0x0008 ## $t5 = 00000008
|
||||
/* 0032C 8089BF9C AE2D02D0 */ sw $t5, 0x02D0($s1) ## 000002D0
|
||||
/* 00330 8089BFA0 AC4F0004 */ sw $t7, 0x0004($v0) ## 00000004
|
||||
/* 00334 8089BFA4 AC4E0000 */ sw $t6, 0x0000($v0) ## 00000000
|
||||
.L8089BFA8:
|
||||
/* 00338 8089BFA8 C60C0024 */ lwc1 $f12, 0x0024($s0) ## 00000024
|
||||
/* 0033C 8089BFAC C60E0028 */ lwc1 $f14, 0x0028($s0) ## 00000028
|
||||
/* 00340 8089BFB0 0C034261 */ jal Matrix_Translate
|
||||
/* 00344 8089BFB4 8E06002C */ lw $a2, 0x002C($s0) ## 0000002C
|
||||
/* 00348 8089BFB8 86040030 */ lh $a0, 0x0030($s0) ## 00000030
|
||||
/* 0034C 8089BFBC 86050032 */ lh $a1, 0x0032($s0) ## 00000032
|
||||
/* 00350 8089BFC0 86060034 */ lh $a2, 0x0034($s0) ## 00000034
|
||||
/* 00354 8089BFC4 0C034421 */ jal Matrix_RotateRPY
|
||||
/* 00358 8089BFC8 24070001 */ addiu $a3, $zero, 0x0001 ## $a3 = 00000001
|
||||
/* 0035C 8089BFCC C60C0050 */ lwc1 $f12, 0x0050($s0) ## 00000050
|
||||
/* 00360 8089BFD0 C60E0054 */ lwc1 $f14, 0x0054($s0) ## 00000054
|
||||
/* 00364 8089BFD4 8E060058 */ lw $a2, 0x0058($s0) ## 00000058
|
||||
/* 00368 8089BFD8 0C0342A3 */ jal Matrix_Scale
|
||||
/* 0036C 8089BFDC 24070001 */ addiu $a3, $zero, 0x0001 ## $a3 = 00000001
|
||||
/* 00370 8089BFE0 8E2202D0 */ lw $v0, 0x02D0($s1) ## 000002D0
|
||||
/* 00374 8089BFE4 3C19DA38 */ lui $t9, 0xDA38 ## $t9 = DA380000
|
||||
/* 00378 8089BFE8 37390003 */ ori $t9, $t9, 0x0003 ## $t9 = DA380003
|
||||
/* 0037C 8089BFEC 24580008 */ addiu $t8, $v0, 0x0008 ## $t8 = 00000008
|
||||
/* 00380 8089BFF0 AE3802D0 */ sw $t8, 0x02D0($s1) ## 000002D0
|
||||
/* 00384 8089BFF4 AC590000 */ sw $t9, 0x0000($v0) ## 00000000
|
||||
/* 00388 8089BFF8 8FA8005C */ lw $t0, 0x005C($sp)
|
||||
/* 0038C 8089BFFC 3C05808A */ lui $a1, %hi(D_8089C0E8) ## $a1 = 808A0000
|
||||
/* 00390 8089C000 24A5C0E8 */ addiu $a1, $a1, %lo(D_8089C0E8) ## $a1 = 8089C0E8
|
||||
/* 00394 8089C004 2406014B */ addiu $a2, $zero, 0x014B ## $a2 = 0000014B
|
||||
/* 00398 8089C008 00408025 */ or $s0, $v0, $zero ## $s0 = 00000000
|
||||
/* 0039C 8089C00C 0C0346A2 */ jal Matrix_NewMtx
|
||||
/* 003A0 8089C010 8D040000 */ lw $a0, 0x0000($t0) ## 00000000
|
||||
/* 003A4 8089C014 AE020004 */ sw $v0, 0x0004($s0) ## 00000004
|
||||
/* 003A8 8089C018 8E2202D0 */ lw $v0, 0x02D0($s1) ## 000002D0
|
||||
/* 003AC 8089C01C 3C0B0600 */ lui $t3, 0x0600 ## $t3 = 06000000
|
||||
/* 003B0 8089C020 256B2D20 */ addiu $t3, $t3, 0x2D20 ## $t3 = 06002D20
|
||||
/* 003B4 8089C024 24490008 */ addiu $t1, $v0, 0x0008 ## $t1 = 00000008
|
||||
/* 003B8 8089C028 AE2902D0 */ sw $t1, 0x02D0($s1) ## 000002D0
|
||||
/* 003BC 8089C02C 3C0ADE00 */ lui $t2, 0xDE00 ## $t2 = DE000000
|
||||
/* 003C0 8089C030 AC4A0000 */ sw $t2, 0x0000($v0) ## 00000000
|
||||
/* 003C4 8089C034 AC4B0004 */ sw $t3, 0x0004($v0) ## 00000004
|
||||
/* 003C8 8089C038 8FAC005C */ lw $t4, 0x005C($sp)
|
||||
/* 003CC 8089C03C 3C06808A */ lui $a2, %hi(D_8089C100) ## $a2 = 808A0000
|
||||
/* 003D0 8089C040 24C6C100 */ addiu $a2, $a2, %lo(D_8089C100) ## $a2 = 8089C100
|
||||
/* 003D4 8089C044 27A4003C */ addiu $a0, $sp, 0x003C ## $a0 = FFFFFFE4
|
||||
/* 003D8 8089C048 2407014F */ addiu $a3, $zero, 0x014F ## $a3 = 0000014F
|
||||
/* 003DC 8089C04C 0C031AD5 */ jal Graph_CloseDisps
|
||||
/* 003E0 8089C050 8D850000 */ lw $a1, 0x0000($t4) ## 00000000
|
||||
/* 003E4 8089C054 8FBF001C */ lw $ra, 0x001C($sp)
|
||||
/* 003E8 8089C058 8FB00014 */ lw $s0, 0x0014($sp)
|
||||
/* 003EC 8089C05C 8FB10018 */ lw $s1, 0x0018($sp)
|
||||
/* 003F0 8089C060 03E00008 */ jr $ra
|
||||
/* 003F4 8089C064 27BD0058 */ addiu $sp, $sp, 0x0058 ## $sp = 00000000
|
||||
/* 003F8 8089C068 00000000 */ nop
|
||||
/* 003FC 8089C06C 00000000 */ nop
|
@ -1,58 +0,0 @@
|
||||
glabel BgMenkuriEye_Init
|
||||
/* 00000 8089BC70 27BDFFC8 */ addiu $sp, $sp, 0xFFC8 ## $sp = FFFFFFC8
|
||||
/* 00004 8089BC74 AFA5003C */ sw $a1, 0x003C($sp)
|
||||
/* 00008 8089BC78 AFBF0024 */ sw $ra, 0x0024($sp)
|
||||
/* 0000C 8089BC7C AFB00020 */ sw $s0, 0x0020($sp)
|
||||
/* 00010 8089BC80 3C05808A */ lui $a1, %hi(D_8089C0C4) ## $a1 = 808A0000
|
||||
/* 00014 8089BC84 00808025 */ or $s0, $a0, $zero ## $s0 = 00000000
|
||||
/* 00018 8089BC88 0C01E037 */ jal Actor_ProcessInitChain
|
||||
|
||||
/* 0001C 8089BC8C 24A5C0C4 */ addiu $a1, $a1, %lo(D_8089C0C4) ## $a1 = 8089C0C4
|
||||
/* 00020 8089BC90 26050150 */ addiu $a1, $s0, 0x0150 ## $a1 = 00000150
|
||||
/* 00024 8089BC94 AFA5002C */ sw $a1, 0x002C($sp)
|
||||
/* 00028 8089BC98 0C016EFE */ jal Collider_InitJntSph
|
||||
/* 0002C 8089BC9C 8FA4003C */ lw $a0, 0x003C($sp)
|
||||
/* 00030 8089BCA0 3C07808A */ lui $a3, %hi(D_8089C0B4) ## $a3 = 808A0000
|
||||
/* 00034 8089BCA4 260E0170 */ addiu $t6, $s0, 0x0170 ## $t6 = 00000170
|
||||
/* 00038 8089BCA8 8FA5002C */ lw $a1, 0x002C($sp)
|
||||
/* 0003C 8089BCAC AFAE0010 */ sw $t6, 0x0010($sp)
|
||||
/* 00040 8089BCB0 24E7C0B4 */ addiu $a3, $a3, %lo(D_8089C0B4) ## $a3 = 8089C0B4
|
||||
/* 00044 8089BCB4 8FA4003C */ lw $a0, 0x003C($sp)
|
||||
/* 00048 8089BCB8 0C017014 */ jal Collider_SetJntSph
|
||||
/* 0004C 8089BCBC 02003025 */ or $a2, $s0, $zero ## $a2 = 00000000
|
||||
/* 00050 8089BCC0 C6040024 */ lwc1 $f4, 0x0024($s0) ## 00000024
|
||||
/* 00054 8089BCC4 8E19016C */ lw $t9, 0x016C($s0) ## 0000016C
|
||||
/* 00058 8089BCC8 4600218D */ trunc.w.s $f6, $f4
|
||||
/* 0005C 8089BCCC 44183000 */ mfc1 $t8, $f6
|
||||
/* 00060 8089BCD0 00000000 */ nop
|
||||
/* 00064 8089BCD4 A7380030 */ sh $t8, 0x0030($t9) ## 00000030
|
||||
/* 00068 8089BCD8 C6080028 */ lwc1 $f8, 0x0028($s0) ## 00000028
|
||||
/* 0006C 8089BCDC 8E0A016C */ lw $t2, 0x016C($s0) ## 0000016C
|
||||
/* 00070 8089BCE0 4600428D */ trunc.w.s $f10, $f8
|
||||
/* 00074 8089BCE4 44095000 */ mfc1 $t1, $f10
|
||||
/* 00078 8089BCE8 00000000 */ nop
|
||||
/* 0007C 8089BCEC A5490032 */ sh $t1, 0x0032($t2) ## 00000032
|
||||
/* 00080 8089BCF0 C610002C */ lwc1 $f16, 0x002C($s0) ## 0000002C
|
||||
/* 00084 8089BCF4 8E0D016C */ lw $t5, 0x016C($s0) ## 0000016C
|
||||
/* 00088 8089BCF8 4600848D */ trunc.w.s $f18, $f16
|
||||
/* 0008C 8089BCFC 440C9000 */ mfc1 $t4, $f18
|
||||
/* 00090 8089BD00 00000000 */ nop
|
||||
/* 00094 8089BD04 A5AC0034 */ sh $t4, 0x0034($t5) ## 00000034
|
||||
/* 00098 8089BD08 8E03016C */ lw $v1, 0x016C($s0) ## 0000016C
|
||||
/* 0009C 8089BD0C 846E002E */ lh $t6, 0x002E($v1) ## 0000002E
|
||||
/* 000A0 8089BD10 A46E0036 */ sh $t6, 0x0036($v1) ## 00000036
|
||||
/* 000A4 8089BD14 8605001C */ lh $a1, 0x001C($s0) ## 0000001C
|
||||
/* 000A8 8089BD18 0C00B2D0 */ jal Flags_GetSwitch
|
||||
|
||||
/* 000AC 8089BD1C 8FA4003C */ lw $a0, 0x003C($sp)
|
||||
/* 000B0 8089BD20 14400003 */ bne $v0, $zero, .L8089BD30
|
||||
/* 000B4 8089BD24 240FFFFF */ addiu $t7, $zero, 0xFFFF ## $t7 = FFFFFFFF
|
||||
/* 000B8 8089BD28 3C01808A */ lui $at, %hi(D_8089C1A0) ## $at = 808A0000
|
||||
/* 000BC 8089BD2C AC20C1A0 */ sw $zero, %lo(D_8089C1A0)($at)
|
||||
.L8089BD30:
|
||||
/* 000C0 8089BD30 A60F014C */ sh $t7, 0x014C($s0) ## 0000014C
|
||||
/* 000C4 8089BD34 8FBF0024 */ lw $ra, 0x0024($sp)
|
||||
/* 000C8 8089BD38 8FB00020 */ lw $s0, 0x0020($sp)
|
||||
/* 000CC 8089BD3C 27BD0038 */ addiu $sp, $sp, 0x0038 ## $sp = 00000000
|
||||
/* 000D0 8089BD40 03E00008 */ jr $ra
|
||||
/* 000D4 8089BD44 00000000 */ nop
|
@ -1,106 +0,0 @@
|
||||
glabel BgMenkuriEye_Update
|
||||
/* 00100 8089BD70 27BDFFE0 */ addiu $sp, $sp, 0xFFE0 ## $sp = FFFFFFE0
|
||||
/* 00104 8089BD74 AFB00018 */ sw $s0, 0x0018($sp)
|
||||
/* 00108 8089BD78 00808025 */ or $s0, $a0, $zero ## $s0 = 00000000
|
||||
/* 0010C 8089BD7C AFBF001C */ sw $ra, 0x001C($sp)
|
||||
/* 00110 8089BD80 AFA50024 */ sw $a1, 0x0024($sp)
|
||||
/* 00114 8089BD84 00A02025 */ or $a0, $a1, $zero ## $a0 = 00000000
|
||||
/* 00118 8089BD88 0C00B2D0 */ jal Flags_GetSwitch
|
||||
|
||||
/* 0011C 8089BD8C 8605001C */ lh $a1, 0x001C($s0) ## 0000001C
|
||||
/* 00120 8089BD90 54400012 */ bnel $v0, $zero, .L8089BDDC
|
||||
/* 00124 8089BD94 92040161 */ lbu $a0, 0x0161($s0) ## 00000161
|
||||
/* 00128 8089BD98 8602014C */ lh $v0, 0x014C($s0) ## 0000014C
|
||||
/* 0012C 8089BD9C 2401FFFF */ addiu $at, $zero, 0xFFFF ## $at = FFFFFFFF
|
||||
/* 00130 8089BDA0 5041000E */ beql $v0, $at, .L8089BDDC
|
||||
/* 00134 8089BDA4 92040161 */ lbu $a0, 0x0161($s0) ## 00000161
|
||||
/* 00138 8089BDA8 10400003 */ beq $v0, $zero, .L8089BDB8
|
||||
/* 0013C 8089BDAC 244EFFFF */ addiu $t6, $v0, 0xFFFF ## $t6 = FFFFFFFF
|
||||
/* 00140 8089BDB0 A60E014C */ sh $t6, 0x014C($s0) ## 0000014C
|
||||
/* 00144 8089BDB4 8602014C */ lh $v0, 0x014C($s0) ## 0000014C
|
||||
.L8089BDB8:
|
||||
/* 00148 8089BDB8 14400007 */ bne $v0, $zero, .L8089BDD8
|
||||
/* 0014C 8089BDBC 3C06808A */ lui $a2, %hi(D_8089C1A0) ## $a2 = 808A0000
|
||||
/* 00150 8089BDC0 240FFFFF */ addiu $t7, $zero, 0xFFFF ## $t7 = FFFFFFFF
|
||||
/* 00154 8089BDC4 24C6C1A0 */ addiu $a2, $a2, %lo(D_8089C1A0) ## $a2 = 8089C1A0
|
||||
/* 00158 8089BDC8 A60F014C */ sh $t7, 0x014C($s0) ## 0000014C
|
||||
/* 0015C 8089BDCC 8CD80000 */ lw $t8, 0x0000($a2) ## 8089C1A0
|
||||
/* 00160 8089BDD0 2719FFFF */ addiu $t9, $t8, 0xFFFF ## $t9 = FFFFFFFF
|
||||
/* 00164 8089BDD4 ACD90000 */ sw $t9, 0x0000($a2) ## 8089C1A0
|
||||
.L8089BDD8:
|
||||
/* 00168 8089BDD8 92040161 */ lbu $a0, 0x0161($s0) ## 00000161
|
||||
.L8089BDDC:
|
||||
/* 0016C 8089BDDC 3C06808A */ lui $a2, %hi(D_8089C1A0) ## $a2 = 808A0000
|
||||
/* 00170 8089BDE0 24C6C1A0 */ addiu $a2, $a2, %lo(D_8089C1A0) ## $a2 = 8089C1A0
|
||||
/* 00174 8089BDE4 30880002 */ andi $t0, $a0, 0x0002 ## $t0 = 00000000
|
||||
/* 00178 8089BDE8 5100002D */ beql $t0, $zero, .L8089BEA0
|
||||
/* 0017C 8089BDEC 8609014C */ lh $t1, 0x014C($s0) ## 0000014C
|
||||
/* 00180 8089BDF0 8E090158 */ lw $t1, 0x0158($s0) ## 00000158
|
||||
/* 00184 8089BDF4 860B00B6 */ lh $t3, 0x00B6($s0) ## 000000B6
|
||||
/* 00188 8089BDF8 852A0032 */ lh $t2, 0x0032($t1) ## 00000032
|
||||
/* 0018C 8089BDFC 014B1023 */ subu $v0, $t2, $t3
|
||||
/* 00190 8089BE00 00021400 */ sll $v0, $v0, 16
|
||||
/* 00194 8089BE04 00021403 */ sra $v0, $v0, 16
|
||||
/* 00198 8089BE08 04400003 */ bltz $v0, .L8089BE18
|
||||
/* 0019C 8089BE0C 00021823 */ subu $v1, $zero, $v0
|
||||
/* 001A0 8089BE10 10000001 */ beq $zero, $zero, .L8089BE18
|
||||
/* 001A4 8089BE14 00401825 */ or $v1, $v0, $zero ## $v1 = 00000000
|
||||
.L8089BE18:
|
||||
/* 001A8 8089BE18 28615001 */ slti $at, $v1, 0x5001
|
||||
/* 001AC 8089BE1C 54200020 */ bnel $at, $zero, .L8089BEA0
|
||||
/* 001B0 8089BE20 8609014C */ lh $t1, 0x014C($s0) ## 0000014C
|
||||
/* 001B4 8089BE24 860D014C */ lh $t5, 0x014C($s0) ## 0000014C
|
||||
/* 001B8 8089BE28 308CFFFD */ andi $t4, $a0, 0xFFFD ## $t4 = 00000000
|
||||
/* 001BC 8089BE2C 2401FFFF */ addiu $at, $zero, 0xFFFF ## $at = FFFFFFFF
|
||||
/* 001C0 8089BE30 15A1000F */ bne $t5, $at, .L8089BE70
|
||||
/* 001C4 8089BE34 A20C0161 */ sb $t4, 0x0161($s0) ## 00000161
|
||||
/* 001C8 8089BE38 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
|
||||
/* 001CC 8089BE3C 0C00BE0A */ jal Audio_PlayActorSound2
|
||||
|
||||
/* 001D0 8089BE40 24053847 */ addiu $a1, $zero, 0x3847 ## $a1 = 00003847
|
||||
/* 001D4 8089BE44 3C06808A */ lui $a2, %hi(D_8089C1A0) ## $a2 = 808A0000
|
||||
/* 001D8 8089BE48 24C6C1A0 */ addiu $a2, $a2, %lo(D_8089C1A0) ## $a2 = 8089C1A0
|
||||
/* 001DC 8089BE4C 8CCE0000 */ lw $t6, 0x0000($a2) ## 8089C1A0
|
||||
/* 001E0 8089BE50 24180004 */ addiu $t8, $zero, 0x0004 ## $t8 = 00000004
|
||||
/* 001E4 8089BE54 25C20001 */ addiu $v0, $t6, 0x0001 ## $v0 = 00000001
|
||||
/* 001E8 8089BE58 28410005 */ slti $at, $v0, 0x0005
|
||||
/* 001EC 8089BE5C 14200003 */ bne $at, $zero, .L8089BE6C
|
||||
/* 001F0 8089BE60 ACC20000 */ sw $v0, 0x0000($a2) ## 8089C1A0
|
||||
/* 001F4 8089BE64 10000002 */ beq $zero, $zero, .L8089BE70
|
||||
/* 001F8 8089BE68 ACD80000 */ sw $t8, 0x0000($a2) ## 8089C1A0
|
||||
.L8089BE6C:
|
||||
/* 001FC 8089BE6C ACC20000 */ sw $v0, 0x0000($a2) ## 8089C1A0
|
||||
.L8089BE70:
|
||||
/* 00200 8089BE70 241901A0 */ addiu $t9, $zero, 0x01A0 ## $t9 = 000001A0
|
||||
/* 00204 8089BE74 A619014C */ sh $t9, 0x014C($s0) ## 0000014C
|
||||
/* 00208 8089BE78 8CC80000 */ lw $t0, 0x0000($a2) ## 8089C1A0
|
||||
/* 0020C 8089BE7C 24010004 */ addiu $at, $zero, 0x0004 ## $at = 00000004
|
||||
/* 00210 8089BE80 8FA40024 */ lw $a0, 0x0024($sp)
|
||||
/* 00214 8089BE84 55010006 */ bnel $t0, $at, .L8089BEA0
|
||||
/* 00218 8089BE88 8609014C */ lh $t1, 0x014C($s0) ## 0000014C
|
||||
/* 0021C 8089BE8C 0C00B2DD */ jal Flags_SetSwitch
|
||||
|
||||
/* 00220 8089BE90 8605001C */ lh $a1, 0x001C($s0) ## 0000001C
|
||||
/* 00224 8089BE94 0C01E221 */ jal func_80078884
|
||||
/* 00228 8089BE98 24044802 */ addiu $a0, $zero, 0x4802 ## $a0 = 00004802
|
||||
/* 0022C 8089BE9C 8609014C */ lh $t1, 0x014C($s0) ## 0000014C
|
||||
.L8089BEA0:
|
||||
/* 00230 8089BEA0 2401FFFF */ addiu $at, $zero, 0xFFFF ## $at = FFFFFFFF
|
||||
/* 00234 8089BEA4 8FA40024 */ lw $a0, 0x0024($sp)
|
||||
/* 00238 8089BEA8 15210005 */ bne $t1, $at, .L8089BEC0
|
||||
/* 0023C 8089BEAC 26060150 */ addiu $a2, $s0, 0x0150 ## $a2 = 00000150
|
||||
/* 00240 8089BEB0 3C010001 */ lui $at, 0x0001 ## $at = 00010000
|
||||
/* 00244 8089BEB4 34211E60 */ ori $at, $at, 0x1E60 ## $at = 00011E60
|
||||
/* 00248 8089BEB8 0C01767D */ jal CollisionCheck_SetAC
|
||||
## CollisionCheck_setAC
|
||||
/* 0024C 8089BEBC 00812821 */ addu $a1, $a0, $at
|
||||
.L8089BEC0:
|
||||
/* 00250 8089BEC0 02002025 */ or $a0, $s0, $zero ## $a0 = 00000000
|
||||
/* 00254 8089BEC4 0C00B56E */ jal Actor_SetHeight
|
||||
|
||||
/* 00258 8089BEC8 24050000 */ addiu $a1, $zero, 0x0000 ## $a1 = 00000000
|
||||
/* 0025C 8089BECC 8FBF001C */ lw $ra, 0x001C($sp)
|
||||
/* 00260 8089BED0 8FB00018 */ lw $s0, 0x0018($sp)
|
||||
/* 00264 8089BED4 27BD0020 */ addiu $sp, $sp, 0x0020 ## $sp = 00000000
|
||||
/* 00268 8089BED8 03E00008 */ jr $ra
|
||||
/* 0026C 8089BEDC 00000000 */ nop
|
@ -1,14 +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 .bss
|
||||
|
||||
.balign 16
|
||||
|
||||
glabel D_8089C1A0
|
||||
.space 0x10
|
||||
|
@ -1,25 +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_Menkuri_Eye_InitVars
|
||||
.word 0x00620100, 0x00000020, 0x004D0000, 0x000001B0
|
||||
.word BgMenkuriEye_Init
|
||||
.word BgMenkuriEye_Destroy
|
||||
.word BgMenkuriEye_Update
|
||||
.word BgMenkuriEye_Draw
|
||||
glabel D_8089C090
|
||||
.word 0x04000000, 0x00000000, 0x00000000, 0x0001F820, 0x00000000, 0x00010000, 0x01000000, 0x00000000, 0x000E0064
|
||||
glabel D_8089C0B4
|
||||
.word 0x0A000900, 0x20000000, 0x00000001
|
||||
.word D_8089C090
|
||||
glabel D_8089C0C4
|
||||
.word 0x48500064, 0x00000000, 0x00000000
|
||||
|
@ -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_8089C120
|
||||
.incbin "baserom/ovl_Bg_Menkuri_Eye", 0x4B0, 0x00000080
|
4
spec
4
spec
@ -1045,9 +1045,7 @@ endseg
|
||||
beginseg
|
||||
name "ovl_Bg_Menkuri_Eye"
|
||||
include "build/src/overlays/actors/ovl_Bg_Menkuri_Eye/z_bg_menkuri_eye.o"
|
||||
include "build/data/overlays/actors/z_bg_menkuri_eye.data.o"
|
||||
include "build/data/overlays/actors/z_bg_menkuri_eye.bss.o"
|
||||
include "build/data/overlays/actors/z_bg_menkuri_eye.reloc.o"
|
||||
include "build/src/overlays/actors/ovl_Bg_Menkuri_Eye/ovl_Bg_Menkuri_Eye_reloc.o"
|
||||
endseg
|
||||
|
||||
beginseg
|
||||
|
@ -15,7 +15,6 @@ void BgMenkuriEye_Destroy(Actor* thisx, GlobalContext* globalCtx);
|
||||
void BgMenkuriEye_Update(Actor* thisx, GlobalContext* globalCtx);
|
||||
void BgMenkuriEye_Draw(Actor* thisx, GlobalContext* globalCtx);
|
||||
|
||||
/*
|
||||
const ActorInit Bg_Menkuri_Eye_InitVars = {
|
||||
ACTOR_BG_MENKURI_EYE,
|
||||
ACTORTYPE_BG,
|
||||
@ -27,11 +26,104 @@ const ActorInit Bg_Menkuri_Eye_InitVars = {
|
||||
(ActorFunc)BgMenkuriEye_Update,
|
||||
(ActorFunc)BgMenkuriEye_Draw,
|
||||
};
|
||||
*/
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Menkuri_Eye/BgMenkuriEye_Init.s")
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Menkuri_Eye/BgMenkuriEye_Destroy.s")
|
||||
extern Gfx D_06002D20[];
|
||||
s32 D_8089C1A0;
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Menkuri_Eye/BgMenkuriEye_Update.s")
|
||||
static ColliderJntSphItemInit sJntSphItemsInit[1] = {
|
||||
{
|
||||
{ 0x04, { 0x00000000, 0x00, 0x00 }, { 0x0001F820, 0x00, 0x00 }, 0x00, 0x01, 0x00 },
|
||||
{ 1, { { 0, 0, 0 }, 14 }, 100 },
|
||||
},
|
||||
};
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/overlays/actors/ovl_Bg_Menkuri_Eye/BgMenkuriEye_Draw.s")
|
||||
static ColliderJntSphInit sJntSphInit = {
|
||||
{ COLTYPE_UNK10, 0x00, 0x09, 0x00, 0x20, COLSHAPE_JNTSPH },
|
||||
1,
|
||||
sJntSphItemsInit,
|
||||
};
|
||||
|
||||
static InitChainEntry sInitChain[] = {
|
||||
ICHAIN_VEC3F_DIV1000(scale, 100, ICHAIN_STOP),
|
||||
};
|
||||
|
||||
void BgMenkuriEye_Init(Actor* thisx, GlobalContext* globalCtx) {
|
||||
BgMenkuriEye* this = THIS;
|
||||
ColliderJntSphItem* colliderList;
|
||||
|
||||
Actor_ProcessInitChain(&this->actor, sInitChain);
|
||||
Collider_InitJntSph(globalCtx, &this->collider);
|
||||
Collider_SetJntSph(globalCtx, &this->collider, &this->actor, &sJntSphInit, this->colliderItems);
|
||||
this->collider.list->dim.worldSphere.center.x = this->actor.posRot.pos.x;
|
||||
this->collider.list->dim.worldSphere.center.y = this->actor.posRot.pos.y;
|
||||
this->collider.list->dim.worldSphere.center.z = this->actor.posRot.pos.z;
|
||||
colliderList = this->collider.list;
|
||||
colliderList->dim.worldSphere.radius = colliderList->dim.modelSphere.radius;
|
||||
if (!Flags_GetSwitch(globalCtx, this->actor.params)) {
|
||||
D_8089C1A0 = 0;
|
||||
}
|
||||
this->framesUntilDisable = -1;
|
||||
}
|
||||
|
||||
void BgMenkuriEye_Destroy(Actor* thisx, GlobalContext* globalCtx) {
|
||||
BgMenkuriEye* this = THIS;
|
||||
|
||||
Collider_DestroyJntSph(globalCtx, &this->collider);
|
||||
}
|
||||
|
||||
void BgMenkuriEye_Update(Actor* thisx, GlobalContext* globalCtx) {
|
||||
BgMenkuriEye* this = THIS;
|
||||
|
||||
if (!Flags_GetSwitch(globalCtx, this->actor.params)) {
|
||||
if (this->framesUntilDisable != -1) {
|
||||
if (this->framesUntilDisable != 0) {
|
||||
this->framesUntilDisable -= 1;
|
||||
}
|
||||
if (this->framesUntilDisable == 0) {
|
||||
this->framesUntilDisable = -1;
|
||||
D_8089C1A0 -= 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
if ((this->collider.base.acFlags & 2) &&
|
||||
(ABS((s16)(this->collider.base.ac->posRot.rot.y - this->actor.shape.rot.y)) > 0x5000)) {
|
||||
this->collider.base.acFlags &= ~0x2;
|
||||
if (this->framesUntilDisable == -1) {
|
||||
Audio_PlayActorSound2(&this->actor, NA_SE_EN_AMOS_DAMAGE);
|
||||
D_8089C1A0 += 1;
|
||||
D_8089C1A0 = CLAMP_MAX(D_8089C1A0, 4);
|
||||
}
|
||||
this->framesUntilDisable = 416;
|
||||
if (D_8089C1A0 == 4) {
|
||||
Flags_SetSwitch(globalCtx, this->actor.params);
|
||||
func_80078884(NA_SE_SY_CORRECT_CHIME);
|
||||
}
|
||||
}
|
||||
if (this->framesUntilDisable == -1) {
|
||||
CollisionCheck_SetAC(globalCtx, &globalCtx->colChkCtx, &this->collider.base);
|
||||
}
|
||||
Actor_SetHeight(&this->actor, 0.0f);
|
||||
}
|
||||
|
||||
void BgMenkuriEye_Draw(Actor* thisx, GlobalContext* globalCtx) {
|
||||
BgMenkuriEye* this = THIS;
|
||||
s32 pad;
|
||||
|
||||
OPEN_DISPS(globalCtx->state.gfxCtx, "../z_bg_menkuri_eye.c", 292);
|
||||
func_80093D84(globalCtx->state.gfxCtx);
|
||||
if (Flags_GetSwitch(globalCtx, this->actor.params)) {
|
||||
gDPSetEnvColor(oGfxCtx->polyXlu.p++, 200, 0, 0, 255);
|
||||
} else if (this->framesUntilDisable == -1) {
|
||||
gDPSetEnvColor(oGfxCtx->polyXlu.p++, 200, 0, 0, 0);
|
||||
} else {
|
||||
gDPSetEnvColor(oGfxCtx->polyXlu.p++, 200, 0, 0, 255);
|
||||
}
|
||||
Matrix_Translate(this->actor.posRot.pos.x, this->actor.posRot.pos.y, this->actor.posRot.pos.z, 0);
|
||||
Matrix_RotateRPY(this->actor.posRot.rot.x, this->actor.posRot.rot.y, this->actor.posRot.rot.z, 1);
|
||||
Matrix_Scale(this->actor.scale.x, this->actor.scale.y, this->actor.scale.z, 1);
|
||||
gSPMatrix(oGfxCtx->polyXlu.p++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_bg_menkuri_eye.c", 331),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
||||
gSPDisplayList(oGfxCtx->polyXlu.p++, D_06002D20);
|
||||
CLOSE_DISPS(globalCtx->state.gfxCtx, "../z_bg_menkuri_eye.c", 335);
|
||||
}
|
||||
|
@ -8,9 +8,9 @@ struct BgMenkuriEye;
|
||||
|
||||
typedef struct BgMenkuriEye {
|
||||
/* 0x0000 */ Actor actor;
|
||||
/* 0x014C */ char unk_14C[0x4];
|
||||
/* 0x0150 */ Collider collider;
|
||||
/* 0x0168 */ char unk_168[0x48];
|
||||
/* 0x014C */ s16 framesUntilDisable;
|
||||
/* 0x0150 */ ColliderJntSph collider;
|
||||
/* 0x0170 */ ColliderJntSphItem colliderItems[1];
|
||||
} BgMenkuriEye; // size = 0x01B0
|
||||
|
||||
extern const ActorInit Bg_Menkuri_Eye_InitVars;
|
||||
|
@ -922,3 +922,6 @@ D_060055A8 = 0x060055A8;
|
||||
// z_en_dy_extra
|
||||
D_0601BFB0 = 0x0601BFB0;
|
||||
D_0601C160 = 0x0601C160;
|
||||
|
||||
// z_bg_menkuri_eye
|
||||
D_06002D20 = 0x06002D20;
|
||||
|
Loading…
Reference in New Issue
Block a user