mirror of
https://github.com/zeldaret/oot.git
synced 2024-11-27 12:20:27 +00:00
Finished decomp of code_800F7260 (1 non-matching) (#733)
* improved match * decomped * I dunno * matched Co-authored-by: petrie911 <pmontag@DESKTOP-LG8A167.localdomain>
This commit is contained in:
parent
cf78de2b11
commit
d141e39e77
@ -1,540 +0,0 @@
|
||||
.late_rodata
|
||||
glabel D_8014A638
|
||||
.float 10000000000
|
||||
|
||||
.text
|
||||
glabel func_800F7CEC
|
||||
/* B6EE8C 800F7CEC 27BDFF50 */ addiu $sp, $sp, -0xb0
|
||||
/* B6EE90 800F7CF0 AFB50044 */ sw $s5, 0x44($sp)
|
||||
/* B6EE94 800F7CF4 AFB3003C */ sw $s3, 0x3c($sp)
|
||||
/* B6EE98 800F7CF8 AFB10034 */ sw $s1, 0x34($sp)
|
||||
/* B6EE9C 800F7CFC 3C027FFF */ lui $v0, (0x7FFFFFFF >> 16) # lui $v0, 0x7fff
|
||||
/* B6EEA0 800F7D00 AFBF0054 */ sw $ra, 0x54($sp)
|
||||
/* B6EEA4 800F7D04 AFBE0050 */ sw $fp, 0x50($sp)
|
||||
/* B6EEA8 800F7D08 AFB7004C */ sw $s7, 0x4c($sp)
|
||||
/* B6EEAC 800F7D0C AFB60048 */ sw $s6, 0x48($sp)
|
||||
/* B6EEB0 800F7D10 AFB40040 */ sw $s4, 0x40($sp)
|
||||
/* B6EEB4 800F7D14 AFB20038 */ sw $s2, 0x38($sp)
|
||||
/* B6EEB8 800F7D18 AFB00030 */ sw $s0, 0x30($sp)
|
||||
/* B6EEBC 800F7D1C AFA400B0 */ sw $a0, 0xb0($sp)
|
||||
/* B6EEC0 800F7D20 00009825 */ move $s3, $zero
|
||||
/* B6EEC4 800F7D24 3442FFFF */ ori $v0, (0x7FFFFFFF & 0xFFFF) # ori $v0, $v0, 0xffff
|
||||
/* B6EEC8 800F7D28 27B10084 */ addiu $s1, $sp, 0x84
|
||||
/* B6EECC 800F7D2C 241500FF */ li $s5, 255
|
||||
/* B6EED0 800F7D30 00005825 */ move $t3, $zero
|
||||
.L800F7D34:
|
||||
/* B6EED4 800F7D34 000B70C0 */ sll $t6, $t3, 3
|
||||
/* B6EED8 800F7D38 256B0001 */ addiu $t3, $t3, 1
|
||||
/* B6EEDC 800F7D3C 316B00FF */ andi $t3, $t3, 0xff
|
||||
/* B6EEE0 800F7D40 29610003 */ slti $at, $t3, 3
|
||||
/* B6EEE4 800F7D44 022E3821 */ addu $a3, $s1, $t6
|
||||
/* B6EEE8 800F7D48 ACE20000 */ sw $v0, ($a3)
|
||||
/* B6EEEC 800F7D4C 1420FFF9 */ bnez $at, .L800F7D34
|
||||
/* B6EEF0 800F7D50 A0F50004 */ sb $s5, 4($a3)
|
||||
/* B6EEF4 800F7D54 93AF00B3 */ lbu $t7, 0xb3($sp)
|
||||
/* B6EEF8 800F7D58 3C198013 */ lui $t9, %hi(gSoundBanks) # $t9, 0x8013
|
||||
/* B6EEFC 800F7D5C 273933A8 */ addiu $t9, %lo(gSoundBanks) # addiu $t9, $t9, 0x33a8
|
||||
/* B6EF00 800F7D60 000FC080 */ sll $t8, $t7, 2
|
||||
/* B6EF04 800F7D64 0319B021 */ addu $s6, $t8, $t9
|
||||
/* B6EF08 800F7D68 8EC30000 */ lw $v1, ($s6)
|
||||
/* B6EF0C 800F7D6C 241E00FF */ li $fp, 255
|
||||
/* B6EF10 800F7D70 00008025 */ move $s0, $zero
|
||||
/* B6EF14 800F7D74 9074002D */ lbu $s4, 0x2d($v1)
|
||||
/* B6EF18 800F7D78 24170030 */ li $s7, 48
|
||||
/* B6EF1C 800F7D7C 240D0001 */ li $t5, 1
|
||||
/* B6EF20 800F7D80 53D40116 */ beql $fp, $s4, .L800F81DC
|
||||
/* B6EF24 800F7D84 240D0001 */ li $t5, 1
|
||||
.L800F7D88:
|
||||
/* B6EF28 800F7D88 02970019 */ multu $s4, $s7
|
||||
/* B6EF2C 800F7D8C 00003812 */ mflo $a3
|
||||
/* B6EF30 800F7D90 00671021 */ addu $v0, $v1, $a3
|
||||
/* B6EF34 800F7D94 9044002A */ lbu $a0, 0x2a($v0)
|
||||
/* B6EF38 800F7D98 55A4000C */ bnel $t5, $a0, .L800F7DCC
|
||||
/* B6EF3C 800F7D9C 944E0028 */ lhu $t6, 0x28($v0)
|
||||
/* B6EF40 800F7DA0 944E0028 */ lhu $t6, 0x28($v0)
|
||||
/* B6EF44 800F7DA4 31CF0C00 */ andi $t7, $t6, 0xc00
|
||||
/* B6EF48 800F7DA8 51E00008 */ beql $t7, $zero, .L800F7DCC
|
||||
/* B6EF4C 800F7DAC 944E0028 */ lhu $t6, 0x28($v0)
|
||||
/* B6EF50 800F7DB0 9058002B */ lbu $t8, 0x2b($v0)
|
||||
/* B6EF54 800F7DB4 2719FFFF */ addiu $t9, $t8, -1
|
||||
/* B6EF58 800F7DB8 A059002B */ sb $t9, 0x2b($v0)
|
||||
/* B6EF5C 800F7DBC 8EC30000 */ lw $v1, ($s6)
|
||||
/* B6EF60 800F7DC0 10000015 */ b .L800F7E18
|
||||
/* B6EF64 800F7DC4 00671021 */ addu $v0, $v1, $a3
|
||||
/* B6EF68 800F7DC8 944E0028 */ lhu $t6, 0x28($v0)
|
||||
.L800F7DCC:
|
||||
/* B6EF6C 800F7DCC 24010005 */ li $at, 5
|
||||
/* B6EF70 800F7DD0 31CF0C00 */ andi $t7, $t6, 0xc00
|
||||
/* B6EF74 800F7DD4 55E00011 */ bnezl $t7, .L800F7E1C
|
||||
/* B6EF78 800F7DD8 9058002B */ lbu $t8, 0x2b($v0)
|
||||
/* B6EF7C 800F7DDC 1481000E */ bne $a0, $at, .L800F7E18
|
||||
/* B6EF80 800F7DE0 00002825 */ move $a1, $zero
|
||||
/* B6EF84 800F7DE4 9044002E */ lbu $a0, 0x2e($v0)
|
||||
/* B6EF88 800F7DE8 3C010602 */ li $at, 0x06020000 # 0.000000
|
||||
/* B6EF8C 800F7DEC AFA70074 */ sw $a3, 0x74($sp)
|
||||
/* B6EF90 800F7DF0 00042200 */ sll $a0, $a0, 8
|
||||
/* B6EF94 800F7DF4 0C0396C8 */ jal func_800E5B20
|
||||
/* B6EF98 800F7DF8 00812025 */ or $a0, $a0, $at
|
||||
/* B6EF9C 800F7DFC 93A400B3 */ lbu $a0, 0xb3($sp)
|
||||
/* B6EFA0 800F7E00 0C03DED5 */ jal func_800F7B54
|
||||
/* B6EFA4 800F7E04 328500FF */ andi $a1, $s4, 0xff
|
||||
/* B6EFA8 800F7E08 8FA70074 */ lw $a3, 0x74($sp)
|
||||
/* B6EFAC 800F7E0C 8EC30000 */ lw $v1, ($s6)
|
||||
/* B6EFB0 800F7E10 240D0001 */ li $t5, 1
|
||||
/* B6EFB4 800F7E14 00671021 */ addu $v0, $v1, $a3
|
||||
.L800F7E18:
|
||||
/* B6EFB8 800F7E18 9058002B */ lbu $t8, 0x2b($v0)
|
||||
.L800F7E1C:
|
||||
/* B6EFBC 800F7E1C 93A400B3 */ lbu $a0, 0xb3($sp)
|
||||
/* B6EFC0 800F7E20 57000007 */ bnezl $t8, .L800F7E40
|
||||
/* B6EFC4 800F7E24 9059002A */ lbu $t9, 0x2a($v0)
|
||||
/* B6EFC8 800F7E28 0C03DED5 */ jal func_800F7B54
|
||||
/* B6EFCC 800F7E2C 328500FF */ andi $a1, $s4, 0xff
|
||||
/* B6EFD0 800F7E30 240D0001 */ li $t5, 1
|
||||
/* B6EFD4 800F7E34 100000E2 */ b .L800F81C0
|
||||
/* B6EFD8 800F7E38 8EC30000 */ lw $v1, ($s6)
|
||||
/* B6EFDC 800F7E3C 9059002A */ lbu $t9, 0x2a($v0)
|
||||
.L800F7E40:
|
||||
/* B6EFE0 800F7E40 00679021 */ addu $s2, $v1, $a3
|
||||
/* B6EFE4 800F7E44 132000DE */ beqz $t9, .L800F81C0
|
||||
/* B6EFE8 800F7E48 00000000 */ nop
|
||||
/* B6EFEC 800F7E4C 8E460000 */ lw $a2, ($s2)
|
||||
/* B6EFF0 800F7E50 3C0E8013 */ lui $t6, %hi(D_801333D4)
|
||||
/* B6EFF4 800F7E54 25CE33D4 */ addiu $t6, %lo(D_801333D4) # addiu $t6, $t6, 0x33d4
|
||||
/* B6EFF8 800F7E58 55C60005 */ bnel $t6, $a2, .L800F7E70
|
||||
/* B6EFFC 800F7E5C 8E4F0004 */ lw $t7, 4($s2)
|
||||
/* B6F000 800F7E60 44802000 */ mtc1 $zero, $f4
|
||||
/* B6F004 800F7E64 10000012 */ b .L800F7EB0
|
||||
/* B6F008 800F7E68 E644001C */ swc1 $f4, 0x1c($s2)
|
||||
/* B6F00C 800F7E6C 8E4F0004 */ lw $t7, 4($s2)
|
||||
.L800F7E70:
|
||||
/* B6F010 800F7E70 3C013F80 */ li $at, 0x3F800000 # 0.000000
|
||||
/* B6F014 800F7E74 44814000 */ mtc1 $at, $f8
|
||||
/* B6F018 800F7E78 C5E60000 */ lwc1 $f6, ($t7)
|
||||
/* B6F01C 800F7E7C C4CC0000 */ lwc1 $f12, ($a2)
|
||||
/* B6F020 800F7E80 8E580008 */ lw $t8, 8($s2)
|
||||
/* B6F024 800F7E84 46083002 */ mul.s $f0, $f6, $f8
|
||||
/* B6F028 800F7E88 44814000 */ mtc1 $at, $f8
|
||||
/* B6F02C 800F7E8C C7020000 */ lwc1 $f2, ($t8)
|
||||
/* B6F030 800F7E90 460C6282 */ mul.s $f10, $f12, $f12
|
||||
/* B6F034 800F7E94 00000000 */ nop
|
||||
/* B6F038 800F7E98 46000402 */ mul.s $f16, $f0, $f0
|
||||
/* B6F03C 800F7E9C 46105480 */ add.s $f18, $f10, $f16
|
||||
/* B6F040 800F7EA0 46021102 */ mul.s $f4, $f2, $f2
|
||||
/* B6F044 800F7EA4 46122180 */ add.s $f6, $f4, $f18
|
||||
/* B6F048 800F7EA8 46083282 */ mul.s $f10, $f6, $f8
|
||||
/* B6F04C 800F7EAC E64A001C */ swc1 $f10, 0x1c($s2)
|
||||
.L800F7EB0:
|
||||
/* B6F050 800F7EB0 96590026 */ lhu $t9, 0x26($s2)
|
||||
/* B6F054 800F7EB4 92480024 */ lbu $t0, 0x24($s2)
|
||||
/* B6F058 800F7EB8 3C014F00 */ li $at, 0x4F000000 # 0.000000
|
||||
/* B6F05C 800F7EBC 332E0010 */ andi $t6, $t9, 0x10
|
||||
/* B6F060 800F7EC0 11C0000F */ beqz $t6, .L800F7F00
|
||||
/* B6F064 800F7EC4 03C81023 */ subu $v0, $fp, $t0
|
||||
/* B6F068 800F7EC8 00420019 */ multu $v0, $v0
|
||||
/* B6F06C 800F7ECC C640001C */ lwc1 $f0, 0x1c($s2)
|
||||
/* B6F070 800F7ED0 00007812 */ mflo $t7
|
||||
/* B6F074 800F7ED4 000FC080 */ sll $t8, $t7, 2
|
||||
/* B6F078 800F7ED8 030FC023 */ subu $t8, $t8, $t7
|
||||
/* B6F07C 800F7EDC 0018C080 */ sll $t8, $t8, 2
|
||||
/* B6F080 800F7EE0 030FC023 */ subu $t8, $t8, $t7
|
||||
/* B6F084 800F7EE4 0018C080 */ sll $t8, $t8, 2
|
||||
/* B6F088 800F7EE8 030FC021 */ addu $t8, $t8, $t7
|
||||
/* B6F08C 800F7EEC 0018C0C0 */ sll $t8, $t8, 3
|
||||
/* B6F090 800F7EF0 030FC021 */ addu $t8, $t8, $t7
|
||||
/* B6F094 800F7EF4 0018C100 */ sll $t8, $t8, 4
|
||||
/* B6F098 800F7EF8 10000060 */ b .L800F807C
|
||||
/* B6F09C 800F7EFC AE580020 */ sw $t8, 0x20($s2)
|
||||
.L800F7F00:
|
||||
/* B6F0A0 800F7F00 C640001C */ lwc1 $f0, 0x1c($s2)
|
||||
/* B6F0A4 800F7F04 44818000 */ mtc1 $at, $f16
|
||||
/* B6F0A8 800F7F08 8E470008 */ lw $a3, 8($s2)
|
||||
/* B6F0AC 800F7F0C 3C014EE0 */ li $at, 0x4EE00000 # 0.000000
|
||||
/* B6F0B0 800F7F10 4600803C */ c.lt.s $f16, $f0
|
||||
/* B6F0B4 800F7F14 00000000 */ nop
|
||||
/* B6F0B8 800F7F18 45020018 */ bc1fl .L800F7F7C
|
||||
/* B6F0BC 800F7F1C 444EF800 */ cfc1 $t6, $31
|
||||
/* B6F0C0 800F7F20 44812000 */ mtc1 $at, $f4
|
||||
/* B6F0C4 800F7F24 8E460000 */ lw $a2, ($s2)
|
||||
/* B6F0C8 800F7F28 96450028 */ lhu $a1, 0x28($s2)
|
||||
/* B6F0CC 800F7F2C E644001C */ swc1 $f4, 0x1c($s2)
|
||||
/* B6F0D0 800F7F30 C4D20000 */ lwc1 $f18, ($a2)
|
||||
/* B6F0D4 800F7F34 3C048013 */ lui $a0, %hi(D_80133344) # $a0, 0x8013
|
||||
/* B6F0D8 800F7F38 24843344 */ addiu $a0, %lo(D_80133344) # addiu $a0, $a0, 0x3344
|
||||
/* B6F0DC 800F7F3C 460091A1 */ cvt.d.s $f6, $f18
|
||||
/* B6F0E0 800F7F40 F7A60010 */ sdc1 $f6, 0x10($sp)
|
||||
/* B6F0E4 800F7F44 8E590004 */ lw $t9, 4($s2)
|
||||
/* B6F0E8 800F7F48 C7280000 */ lwc1 $f8, ($t9)
|
||||
/* B6F0EC 800F7F4C 460042A1 */ cvt.d.s $f10, $f8
|
||||
/* B6F0F0 800F7F50 F7AA0018 */ sdc1 $f10, 0x18($sp)
|
||||
/* B6F0F4 800F7F54 C4F00000 */ lwc1 $f16, ($a3)
|
||||
/* B6F0F8 800F7F58 A3A800A9 */ sb $t0, 0xa9($sp)
|
||||
/* B6F0FC 800F7F5C 46008121 */ cvt.d.s $f4, $f16
|
||||
/* B6F100 800F7F60 0C00084C */ jal osSyncPrintf
|
||||
/* B6F104 800F7F64 F7A40020 */ sdc1 $f4, 0x20($sp)
|
||||
/* B6F108 800F7F68 93A800A9 */ lbu $t0, 0xa9($sp)
|
||||
/* B6F10C 800F7F6C 240D0001 */ li $t5, 1
|
||||
/* B6F110 800F7F70 8E470008 */ lw $a3, 8($s2)
|
||||
/* B6F114 800F7F74 C640001C */ lwc1 $f0, 0x1c($s2)
|
||||
/* B6F118 800F7F78 444EF800 */ cfc1 $t6, $31
|
||||
.L800F7F7C:
|
||||
/* B6F11C 800F7F7C 240F0001 */ li $t7, 1
|
||||
/* B6F120 800F7F80 44CFF800 */ ctc1 $t7, $31
|
||||
/* B6F124 800F7F84 96430028 */ lhu $v1, 0x28($s2)
|
||||
/* B6F128 800F7F88 03C81023 */ subu $v0, $fp, $t0
|
||||
/* B6F12C 800F7F8C 460004A4 */ cvt.w.s $f18, $f0
|
||||
/* B6F130 800F7F90 3C014F00 */ li $at, 0x4F000000 # 0.000000
|
||||
/* B6F134 800F7F94 444FF800 */ cfc1 $t7, $31
|
||||
/* B6F138 800F7F98 00000000 */ nop
|
||||
/* B6F13C 800F7F9C 31EF0078 */ andi $t7, $t7, 0x78
|
||||
/* B6F140 800F7FA0 51E00013 */ beql $t7, $zero, .L800F7FF0
|
||||
/* B6F144 800F7FA4 440F9000 */ mfc1 $t7, $f18
|
||||
/* B6F148 800F7FA8 44819000 */ mtc1 $at, $f18
|
||||
/* B6F14C 800F7FAC 240F0001 */ li $t7, 1
|
||||
/* B6F150 800F7FB0 46120481 */ sub.s $f18, $f0, $f18
|
||||
/* B6F154 800F7FB4 44CFF800 */ ctc1 $t7, $31
|
||||
/* B6F158 800F7FB8 00000000 */ nop
|
||||
/* B6F15C 800F7FBC 460094A4 */ cvt.w.s $f18, $f18
|
||||
/* B6F160 800F7FC0 444FF800 */ cfc1 $t7, $31
|
||||
/* B6F164 800F7FC4 00000000 */ nop
|
||||
/* B6F168 800F7FC8 31EF0078 */ andi $t7, $t7, 0x78
|
||||
/* B6F16C 800F7FCC 15E00005 */ bnez $t7, .L800F7FE4
|
||||
/* B6F170 800F7FD0 00000000 */ nop
|
||||
/* B6F174 800F7FD4 440F9000 */ mfc1 $t7, $f18
|
||||
/* B6F178 800F7FD8 3C018000 */ li $at, 0x80000000 # 0.000000
|
||||
/* B6F17C 800F7FDC 10000007 */ b .L800F7FFC
|
||||
/* B6F180 800F7FE0 01E17825 */ or $t7, $t7, $at
|
||||
.L800F7FE4:
|
||||
/* B6F184 800F7FE4 10000005 */ b .L800F7FFC
|
||||
/* B6F188 800F7FE8 240FFFFF */ li $t7, -1
|
||||
/* B6F18C 800F7FEC 440F9000 */ mfc1 $t7, $f18
|
||||
.L800F7FF0:
|
||||
/* B6F190 800F7FF0 00000000 */ nop
|
||||
/* B6F194 800F7FF4 05E0FFFB */ bltz $t7, .L800F7FE4
|
||||
/* B6F198 800F7FF8 00000000 */ nop
|
||||
.L800F7FFC:
|
||||
/* B6F19C 800F7FFC 00420019 */ multu $v0, $v0
|
||||
/* B6F1A0 800F8000 44CEF800 */ ctc1 $t6, $31
|
||||
/* B6F1A4 800F8004 44803000 */ mtc1 $zero, $f6
|
||||
/* B6F1A8 800F8008 3C0140C0 */ li $at, 0x40C00000 # 0.000000
|
||||
/* B6F1AC 800F800C 0000C012 */ mflo $t8
|
||||
/* B6F1B0 800F8010 0018C880 */ sll $t9, $t8, 2
|
||||
/* B6F1B4 800F8014 0338C823 */ subu $t9, $t9, $t8
|
||||
/* B6F1B8 800F8018 0019C880 */ sll $t9, $t9, 2
|
||||
/* B6F1BC 800F801C 0338C823 */ subu $t9, $t9, $t8
|
||||
/* B6F1C0 800F8020 0019C880 */ sll $t9, $t9, 2
|
||||
/* B6F1C4 800F8024 0338C821 */ addu $t9, $t9, $t8
|
||||
/* B6F1C8 800F8028 0019C8C0 */ sll $t9, $t9, 3
|
||||
/* B6F1CC 800F802C 0338C821 */ addu $t9, $t9, $t8
|
||||
/* B6F1D0 800F8030 0019C900 */ sll $t9, $t9, 4
|
||||
/* B6F1D4 800F8034 01F97021 */ addu $t6, $t7, $t9
|
||||
/* B6F1D8 800F8038 01C3C021 */ addu $t8, $t6, $v1
|
||||
/* B6F1DC 800F803C 03037823 */ subu $t7, $t8, $v1
|
||||
/* B6F1E0 800F8040 AE4F0020 */ sw $t7, 0x20($s2)
|
||||
/* B6F1E4 800F8044 C4E20000 */ lwc1 $f2, ($a3)
|
||||
/* B6F1E8 800F8048 4606103C */ c.lt.s $f2, $f6
|
||||
/* B6F1EC 800F804C 00000000 */ nop
|
||||
/* B6F1F0 800F8050 4500000A */ bc1f .L800F807C
|
||||
/* B6F1F4 800F8054 00000000 */ nop
|
||||
/* B6F1F8 800F8058 44815000 */ mtc1 $at, $f10
|
||||
/* B6F1FC 800F805C 46001207 */ neg.s $f8, $f2
|
||||
/* B6F200 800F8060 C640001C */ lwc1 $f0, 0x1c($s2)
|
||||
/* B6F204 800F8064 460A4402 */ mul.s $f16, $f8, $f10
|
||||
/* B6F208 800F8068 4600810D */ trunc.w.s $f4, $f16
|
||||
/* B6F20C 800F806C 440E2000 */ mfc1 $t6, $f4
|
||||
/* B6F210 800F8070 00000000 */ nop
|
||||
/* B6F214 800F8074 01EE7821 */ addu $t7, $t7, $t6
|
||||
/* B6F218 800F8078 AE4F0020 */ sw $t7, 0x20($s2)
|
||||
.L800F807C:
|
||||
/* B6F21C 800F807C 3C018015 */ lui $at, %hi(D_8014A638)
|
||||
/* B6F220 800F8080 C432A638 */ lwc1 $f18, %lo(D_8014A638)($at)
|
||||
/* B6F224 800F8084 3C0F8013 */ lui $t7, %hi(D_801333CC) # $t7, 0x8013
|
||||
/* B6F228 800F8088 4600903C */ c.lt.s $f18, $f0
|
||||
/* B6F22C 800F808C 00000000 */ nop
|
||||
/* B6F230 800F8090 45000016 */ bc1f .L800F80EC
|
||||
/* B6F234 800F8094 00000000 */ nop
|
||||
/* B6F238 800F8098 9259002A */ lbu $t9, 0x2a($s2)
|
||||
/* B6F23C 800F809C 24010004 */ li $at, 4
|
||||
/* B6F240 800F80A0 57210046 */ bnel $t9, $at, .L800F81BC
|
||||
/* B6F244 800F80A4 329000FF */ andi $s0, $s4, 0xff
|
||||
/* B6F248 800F80A8 9244002E */ lbu $a0, 0x2e($s2)
|
||||
/* B6F24C 800F80AC 3C010602 */ lui $at, 0x602
|
||||
/* B6F250 800F80B0 00002825 */ move $a1, $zero
|
||||
/* B6F254 800F80B4 00042200 */ sll $a0, $a0, 8
|
||||
/* B6F258 800F80B8 0C0396C8 */ jal func_800E5B20
|
||||
/* B6F25C 800F80BC 00812025 */ or $a0, $a0, $at
|
||||
/* B6F260 800F80C0 96580028 */ lhu $t8, 0x28($s2)
|
||||
/* B6F264 800F80C4 240D0001 */ li $t5, 1
|
||||
/* B6F268 800F80C8 93A400B3 */ lbu $a0, 0xb3($sp)
|
||||
/* B6F26C 800F80CC 330E0C00 */ andi $t6, $t8, 0xc00
|
||||
/* B6F270 800F80D0 51C0003A */ beql $t6, $zero, .L800F81BC
|
||||
/* B6F274 800F80D4 329000FF */ andi $s0, $s4, 0xff
|
||||
/* B6F278 800F80D8 0C03DED5 */ jal func_800F7B54
|
||||
/* B6F27C 800F80DC 328500FF */ andi $a1, $s4, 0xff
|
||||
/* B6F280 800F80E0 240D0001 */ li $t5, 1
|
||||
/* B6F284 800F80E4 10000034 */ b .L800F81B8
|
||||
/* B6F288 800F80E8 321400FF */ andi $s4, $s0, 0xff
|
||||
.L800F80EC:
|
||||
/* B6F28C 800F80EC 91EF33CC */ lbu $t7, %lo(D_801333CC)($t7)
|
||||
/* B6F290 800F80F0 93B800B3 */ lbu $t8, 0xb3($sp)
|
||||
/* B6F294 800F80F4 3C0A8013 */ lui $t2, %hi(D_80130578)
|
||||
/* B6F298 800F80F8 000FC8C0 */ sll $t9, $t7, 3
|
||||
/* B6F29C 800F80FC 032FC823 */ subu $t9, $t9, $t7
|
||||
/* B6F2A0 800F8100 03387021 */ addu $t6, $t9, $t8
|
||||
/* B6F2A4 800F8104 014E5021 */ addu $t2, $t2, $t6
|
||||
/* B6F2A8 800F8108 914A0578 */ lbu $t2, %lo(D_80130578)($t2)
|
||||
/* B6F2AC 800F810C 00005825 */ move $t3, $zero
|
||||
/* B6F2B0 800F8110 314900FF */ andi $t1, $t2, 0xff
|
||||
/* B6F2B4 800F8114 19200028 */ blez $t1, .L800F81B8
|
||||
/* B6F2B8 800F8118 01204025 */ move $t0, $t1
|
||||
/* B6F2BC 800F811C 000B78C0 */ sll $t7, $t3, 3
|
||||
.L800F8120:
|
||||
/* B6F2C0 800F8120 022F3821 */ addu $a3, $s1, $t7
|
||||
/* B6F2C4 800F8124 8CF90000 */ lw $t9, ($a3)
|
||||
/* B6F2C8 800F8128 8E430020 */ lw $v1, 0x20($s2)
|
||||
/* B6F2CC 800F812C 2502FFFF */ addiu $v0, $t0, -1
|
||||
/* B6F2D0 800F8130 304500FF */ andi $a1, $v0, 0xff
|
||||
/* B6F2D4 800F8134 0323082B */ sltu $at, $t9, $v1
|
||||
/* B6F2D8 800F8138 1420001A */ bnez $at, .L800F81A4
|
||||
/* B6F2DC 800F813C 01603025 */ move $a2, $t3
|
||||
/* B6F2E0 800F8140 026A082A */ slt $at, $s3, $t2
|
||||
/* B6F2E4 800F8144 10200003 */ beqz $at, .L800F8154
|
||||
/* B6F2E8 800F8148 304400FF */ andi $a0, $v0, 0xff
|
||||
/* B6F2EC 800F814C 26730001 */ addiu $s3, $s3, 1
|
||||
/* B6F2F0 800F8150 327300FF */ andi $s3, $s3, 0xff
|
||||
.L800F8154:
|
||||
/* B6F2F4 800F8154 00C4082A */ slt $at, $a2, $a0
|
||||
/* B6F2F8 800F8158 10200010 */ beqz $at, .L800F819C
|
||||
/* B6F2FC 800F815C 312B00FF */ andi $t3, $t1, 0xff
|
||||
/* B6F300 800F8160 00A01825 */ move $v1, $a1
|
||||
.L800F8164:
|
||||
/* B6F304 800F8164 000370C0 */ sll $t6, $v1, 3
|
||||
/* B6F308 800F8168 022E1021 */ addu $v0, $s1, $t6
|
||||
/* B6F30C 800F816C 8C4FFFF8 */ lw $t7, -8($v0)
|
||||
/* B6F310 800F8170 0005C0C0 */ sll $t8, $a1, 3
|
||||
/* B6F314 800F8174 02382021 */ addu $a0, $s1, $t8
|
||||
/* B6F318 800F8178 24A5FFFF */ addiu $a1, $a1, -1
|
||||
/* B6F31C 800F817C AC8F0000 */ sw $t7, ($a0)
|
||||
/* B6F320 800F8180 9059FFFC */ lbu $t9, -4($v0)
|
||||
/* B6F324 800F8184 30A500FF */ andi $a1, $a1, 0xff
|
||||
/* B6F328 800F8188 00C5082A */ slt $at, $a2, $a1
|
||||
/* B6F32C 800F818C 00A01825 */ move $v1, $a1
|
||||
/* B6F330 800F8190 1420FFF4 */ bnez $at, .L800F8164
|
||||
/* B6F334 800F8194 A0990004 */ sb $t9, 4($a0)
|
||||
/* B6F338 800F8198 8E430020 */ lw $v1, 0x20($s2)
|
||||
.L800F819C:
|
||||
/* B6F33C 800F819C ACE30000 */ sw $v1, ($a3)
|
||||
/* B6F340 800F81A0 A0F40004 */ sb $s4, 4($a3)
|
||||
.L800F81A4:
|
||||
/* B6F344 800F81A4 256B0001 */ addiu $t3, $t3, 1
|
||||
/* B6F348 800F81A8 316B00FF */ andi $t3, $t3, 0xff
|
||||
/* B6F34C 800F81AC 0168082A */ slt $at, $t3, $t0
|
||||
/* B6F350 800F81B0 5420FFDB */ bnezl $at, .L800F8120
|
||||
/* B6F354 800F81B4 000B78C0 */ sll $t7, $t3, 3
|
||||
.L800F81B8:
|
||||
/* B6F358 800F81B8 329000FF */ andi $s0, $s4, 0xff
|
||||
.L800F81BC:
|
||||
/* B6F35C 800F81BC 8EC30000 */ lw $v1, ($s6)
|
||||
.L800F81C0:
|
||||
/* B6F360 800F81C0 02170019 */ multu $s0, $s7
|
||||
/* B6F364 800F81C4 0000C012 */ mflo $t8
|
||||
/* B6F368 800F81C8 00787021 */ addu $t6, $v1, $t8
|
||||
/* B6F36C 800F81CC 91D4002D */ lbu $s4, 0x2d($t6)
|
||||
/* B6F370 800F81D0 17D4FEED */ bne $fp, $s4, .L800F7D88
|
||||
/* B6F374 800F81D4 00000000 */ nop
|
||||
/* B6F378 800F81D8 240D0001 */ li $t5, 1
|
||||
.L800F81DC:
|
||||
/* B6F37C 800F81DC 24170030 */ li $s7, 48
|
||||
/* B6F380 800F81E0 00005825 */ move $t3, $zero
|
||||
/* B6F384 800F81E4 1A600019 */ blez $s3, .L800F824C
|
||||
/* B6F388 800F81E8 02602825 */ move $a1, $s3
|
||||
/* B6F38C 800F81EC 24030003 */ li $v1, 3
|
||||
/* B6F390 800F81F0 24020002 */ li $v0, 2
|
||||
/* B6F394 800F81F4 000B78C0 */ sll $t7, $t3, 3
|
||||
.L800F81F8:
|
||||
/* B6F398 800F81F8 022FC821 */ addu $t9, $s1, $t7
|
||||
/* B6F39C 800F81FC 93380004 */ lbu $t8, 4($t9)
|
||||
/* B6F3A0 800F8200 8ECF0000 */ lw $t7, ($s6)
|
||||
/* B6F3A4 800F8204 256B0001 */ addiu $t3, $t3, 1
|
||||
/* B6F3A8 800F8208 03170019 */ multu $t8, $s7
|
||||
/* B6F3AC 800F820C 316B00FF */ andi $t3, $t3, 0xff
|
||||
/* B6F3B0 800F8210 24010004 */ li $at, 4
|
||||
/* B6F3B4 800F8214 00007012 */ mflo $t6
|
||||
/* B6F3B8 800F8218 01CF9021 */ addu $s2, $t6, $t7
|
||||
/* B6F3BC 800F821C 9244002A */ lbu $a0, 0x2a($s2)
|
||||
/* B6F3C0 800F8220 15A40003 */ bne $t5, $a0, .L800F8230
|
||||
/* B6F3C4 800F8224 00000000 */ nop
|
||||
/* B6F3C8 800F8228 10000004 */ b .L800F823C
|
||||
/* B6F3CC 800F822C A242002A */ sb $v0, 0x2a($s2)
|
||||
.L800F8230:
|
||||
/* B6F3D0 800F8230 54810003 */ bnel $a0, $at, .L800F8240
|
||||
/* B6F3D4 800F8234 0165082A */ slt $at, $t3, $a1
|
||||
/* B6F3D8 800F8238 A243002A */ sb $v1, 0x2a($s2)
|
||||
.L800F823C:
|
||||
/* B6F3DC 800F823C 0165082A */ slt $at, $t3, $a1
|
||||
.L800F8240:
|
||||
/* B6F3E0 800F8240 5420FFED */ bnezl $at, .L800F81F8
|
||||
/* B6F3E4 800F8244 000B78C0 */ sll $t7, $t3, 3
|
||||
/* B6F3E8 800F8248 00005825 */ move $t3, $zero
|
||||
.L800F824C:
|
||||
/* B6F3EC 800F824C 3C198013 */ lui $t9, %hi(D_801333CC) # $t9, 0x8013
|
||||
/* B6F3F0 800F8250 933933CC */ lbu $t9, %lo(D_801333CC)($t9)
|
||||
/* B6F3F4 800F8254 93A200B3 */ lbu $v0, 0xb3($sp)
|
||||
/* B6F3F8 800F8258 3C098013 */ lui $t1, %hi(D_80130578)
|
||||
/* B6F3FC 800F825C 0019C0C0 */ sll $t8, $t9, 3
|
||||
/* B6F400 800F8260 0319C023 */ subu $t8, $t8, $t9
|
||||
/* B6F404 800F8264 03027021 */ addu $t6, $t8, $v0
|
||||
/* B6F408 800F8268 012E4821 */ addu $t1, $t1, $t6
|
||||
/* B6F40C 800F826C 91290578 */ lbu $t1, %lo(D_80130578)($t1)
|
||||
/* B6F410 800F8270 00027880 */ sll $t7, $v0, 2
|
||||
/* B6F414 800F8274 01E27823 */ subu $t7, $t7, $v0
|
||||
/* B6F418 800F8278 19200075 */ blez $t1, .L800F8450
|
||||
/* B6F41C 800F827C 01204025 */ move $t0, $t1
|
||||
/* B6F420 800F8280 3C198017 */ lui $t9, %hi(D_8016E1B8) # $t9, 0x8017
|
||||
/* B6F424 800F8284 2739E1B8 */ addiu $t9, %lo(D_8016E1B8) # addiu $t9, $t9, -0x1e48
|
||||
/* B6F428 800F8288 000F78C0 */ sll $t7, $t7, 3
|
||||
/* B6F42C 800F828C 01F93021 */ addu $a2, $t7, $t9
|
||||
/* B6F430 800F8290 240C0003 */ li $t4, 3
|
||||
/* B6F434 800F8294 000BC0C0 */ sll $t8, $t3, 3
|
||||
.L800F8298:
|
||||
/* B6F438 800F8298 00D8A021 */ addu $s4, $a2, $t8
|
||||
/* B6F43C 800F829C 92850004 */ lbu $a1, 4($s4)
|
||||
/* B6F440 800F82A0 00001825 */ move $v1, $zero
|
||||
/* B6F444 800F82A4 17C50003 */ bne $fp, $a1, .L800F82B4
|
||||
/* B6F448 800F82A8 00A01025 */ move $v0, $a1
|
||||
/* B6F44C 800F82AC 10000034 */ b .L800F8380
|
||||
/* B6F450 800F82B0 24030001 */ li $v1, 1
|
||||
.L800F82B4:
|
||||
/* B6F454 800F82B4 00B70019 */ multu $a1, $s7
|
||||
/* B6F458 800F82B8 8ECF0000 */ lw $t7, ($s6)
|
||||
/* B6F45C 800F82BC 24010004 */ li $at, 4
|
||||
/* B6F460 800F82C0 00007012 */ mflo $t6
|
||||
/* B6F464 800F82C4 01CF9021 */ addu $s2, $t6, $t7
|
||||
/* B6F468 800F82C8 9244002A */ lbu $a0, 0x2a($s2)
|
||||
/* B6F46C 800F82CC 14810017 */ bne $a0, $at, .L800F832C
|
||||
/* B6F470 800F82D0 00000000 */ nop
|
||||
/* B6F474 800F82D4 96590028 */ lhu $t9, 0x28($s2)
|
||||
/* B6F478 800F82D8 93A400B3 */ lbu $a0, 0xb3($sp)
|
||||
/* B6F47C 800F82DC 240E0001 */ li $t6, 1
|
||||
/* B6F480 800F82E0 33380C00 */ andi $t8, $t9, 0xc00
|
||||
/* B6F484 800F82E4 5300000F */ beql $t8, $zero, .L800F8324
|
||||
/* B6F488 800F82E8 A24E002A */ sb $t6, 0x2a($s2)
|
||||
/* B6F48C 800F82EC AFA60074 */ sw $a2, 0x74($sp)
|
||||
/* B6F490 800F82F0 AFA80064 */ sw $t0, 0x64($sp)
|
||||
/* B6F494 800F82F4 A3A900AE */ sb $t1, 0xae($sp)
|
||||
/* B6F498 800F82F8 0C03DED5 */ jal func_800F7B54
|
||||
/* B6F49C 800F82FC A3AB00AC */ sb $t3, 0xac($sp)
|
||||
/* B6F4A0 800F8300 8FA60074 */ lw $a2, 0x74($sp)
|
||||
/* B6F4A4 800F8304 8FA80064 */ lw $t0, 0x64($sp)
|
||||
/* B6F4A8 800F8308 93A900AE */ lbu $t1, 0xae($sp)
|
||||
/* B6F4AC 800F830C 93AB00AC */ lbu $t3, 0xac($sp)
|
||||
/* B6F4B0 800F8310 240C0003 */ li $t4, 3
|
||||
/* B6F4B4 800F8314 240D0001 */ li $t5, 1
|
||||
/* B6F4B8 800F8318 10000019 */ b .L800F8380
|
||||
/* B6F4BC 800F831C 24030001 */ li $v1, 1
|
||||
/* B6F4C0 800F8320 A24E002A */ sb $t6, 0x2a($s2)
|
||||
.L800F8324:
|
||||
/* B6F4C4 800F8324 10000016 */ b .L800F8380
|
||||
/* B6F4C8 800F8328 24030001 */ li $v1, 1
|
||||
.L800F832C:
|
||||
/* B6F4CC 800F832C 14800004 */ bnez $a0, .L800F8340
|
||||
/* B6F4D0 800F8330 00000000 */ nop
|
||||
/* B6F4D4 800F8334 A2950004 */ sb $s5, 4($s4)
|
||||
/* B6F4D8 800F8338 10000011 */ b .L800F8380
|
||||
/* B6F4DC 800F833C 24030001 */ li $v1, 1
|
||||
.L800F8340:
|
||||
/* B6F4E0 800F8340 1900000D */ blez $t0, .L800F8378
|
||||
/* B6F4E4 800F8344 00002825 */ move $a1, $zero
|
||||
/* B6F4E8 800F8348 000578C0 */ sll $t7, $a1, 3
|
||||
.L800F834C:
|
||||
/* B6F4EC 800F834C 022F2021 */ addu $a0, $s1, $t7
|
||||
/* B6F4F0 800F8350 90990004 */ lbu $t9, 4($a0)
|
||||
/* B6F4F4 800F8354 54590004 */ bnel $v0, $t9, .L800F8368
|
||||
/* B6F4F8 800F8358 24A50001 */ addiu $a1, $a1, 1
|
||||
/* B6F4FC 800F835C A0950004 */ sb $s5, 4($a0)
|
||||
/* B6F500 800F8360 312500FF */ andi $a1, $t1, 0xff
|
||||
/* B6F504 800F8364 24A50001 */ addiu $a1, $a1, 1
|
||||
.L800F8368:
|
||||
/* B6F508 800F8368 30A500FF */ andi $a1, $a1, 0xff
|
||||
/* B6F50C 800F836C 00A8082A */ slt $at, $a1, $t0
|
||||
/* B6F510 800F8370 5420FFF6 */ bnezl $at, .L800F834C
|
||||
/* B6F514 800F8374 000578C0 */ sll $t7, $a1, 3
|
||||
.L800F8378:
|
||||
/* B6F518 800F8378 2673FFFF */ addiu $s3, $s3, -1
|
||||
/* B6F51C 800F837C 327300FF */ andi $s3, $s3, 0xff
|
||||
.L800F8380:
|
||||
/* B6F520 800F8380 15A3002E */ bne $t5, $v1, .L800F843C
|
||||
/* B6F524 800F8384 00605025 */ move $t2, $v1
|
||||
/* B6F528 800F8388 19000029 */ blez $t0, .L800F8430
|
||||
/* B6F52C 800F838C 00002825 */ move $a1, $zero
|
||||
/* B6F530 800F8390 0005C0C0 */ sll $t8, $a1, 3
|
||||
.L800F8394:
|
||||
/* B6F534 800F8394 02382021 */ addu $a0, $s1, $t8
|
||||
/* B6F538 800F8398 90870004 */ lbu $a3, 4($a0)
|
||||
/* B6F53C 800F839C 13C7001F */ beq $fp, $a3, .L800F841C
|
||||
/* B6F540 800F83A0 00E01025 */ move $v0, $a3
|
||||
/* B6F544 800F83A4 00F70019 */ multu $a3, $s7
|
||||
/* B6F548 800F83A8 8ECE0000 */ lw $t6, ($s6)
|
||||
/* B6F54C 800F83AC 00007812 */ mflo $t7
|
||||
/* B6F550 800F83B0 01CFC821 */ addu $t9, $t6, $t7
|
||||
/* B6F554 800F83B4 9338002A */ lbu $t8, 0x2a($t9)
|
||||
/* B6F558 800F83B8 51980019 */ beql $t4, $t8, .L800F8420
|
||||
/* B6F55C 800F83BC 24A50001 */ addiu $a1, $a1, 1
|
||||
/* B6F560 800F83C0 1900000E */ blez $t0, .L800F83FC
|
||||
/* B6F564 800F83C4 00008025 */ move $s0, $zero
|
||||
/* B6F568 800F83C8 001070C0 */ sll $t6, $s0, 3
|
||||
.L800F83CC:
|
||||
/* B6F56C 800F83CC 00CE7821 */ addu $t7, $a2, $t6
|
||||
/* B6F570 800F83D0 91F90004 */ lbu $t9, 4($t7)
|
||||
/* B6F574 800F83D4 54590004 */ bnel $v0, $t9, .L800F83E8
|
||||
/* B6F578 800F83D8 26100001 */ addiu $s0, $s0, 1
|
||||
/* B6F57C 800F83DC 00001825 */ move $v1, $zero
|
||||
/* B6F580 800F83E0 313000FF */ andi $s0, $t1, 0xff
|
||||
/* B6F584 800F83E4 26100001 */ addiu $s0, $s0, 1
|
||||
.L800F83E8:
|
||||
/* B6F588 800F83E8 321000FF */ andi $s0, $s0, 0xff
|
||||
/* B6F58C 800F83EC 0208082A */ slt $at, $s0, $t0
|
||||
/* B6F590 800F83F0 5420FFF6 */ bnezl $at, .L800F83CC
|
||||
/* B6F594 800F83F4 001070C0 */ sll $t6, $s0, 3
|
||||
/* B6F598 800F83F8 00605025 */ move $t2, $v1
|
||||
.L800F83FC:
|
||||
/* B6F59C 800F83FC 55AA0008 */ bnel $t5, $t2, .L800F8420
|
||||
/* B6F5A0 800F8400 24A50001 */ addiu $a1, $a1, 1
|
||||
/* B6F5A4 800F8404 25050001 */ addiu $a1, $t0, 1
|
||||
/* B6F5A8 800F8408 2673FFFF */ addiu $s3, $s3, -1
|
||||
/* B6F5AC 800F840C A2870004 */ sb $a3, 4($s4)
|
||||
/* B6F5B0 800F8410 A0950004 */ sb $s5, 4($a0)
|
||||
/* B6F5B4 800F8414 30A500FF */ andi $a1, $a1, 0xff
|
||||
/* B6F5B8 800F8418 327300FF */ andi $s3, $s3, 0xff
|
||||
.L800F841C:
|
||||
/* B6F5BC 800F841C 24A50001 */ addiu $a1, $a1, 1
|
||||
.L800F8420:
|
||||
/* B6F5C0 800F8420 30A500FF */ andi $a1, $a1, 0xff
|
||||
/* B6F5C4 800F8424 00A8082A */ slt $at, $a1, $t0
|
||||
/* B6F5C8 800F8428 5420FFDA */ bnezl $at, .L800F8394
|
||||
/* B6F5CC 800F842C 0005C0C0 */ sll $t8, $a1, 3
|
||||
.L800F8430:
|
||||
/* B6F5D0 800F8430 55050003 */ bnel $t0, $a1, .L800F8440
|
||||
/* B6F5D4 800F8434 256B0001 */ addiu $t3, $t3, 1
|
||||
/* B6F5D8 800F8438 A2950004 */ sb $s5, 4($s4)
|
||||
.L800F843C:
|
||||
/* B6F5DC 800F843C 256B0001 */ addiu $t3, $t3, 1
|
||||
.L800F8440:
|
||||
/* B6F5E0 800F8440 316B00FF */ andi $t3, $t3, 0xff
|
||||
/* B6F5E4 800F8444 0168082A */ slt $at, $t3, $t0
|
||||
/* B6F5E8 800F8448 5420FF93 */ bnezl $at, .L800F8298
|
||||
/* B6F5EC 800F844C 000BC0C0 */ sll $t8, $t3, 3
|
||||
.L800F8450:
|
||||
/* B6F5F0 800F8450 8FBF0054 */ lw $ra, 0x54($sp)
|
||||
/* B6F5F4 800F8454 8FB00030 */ lw $s0, 0x30($sp)
|
||||
/* B6F5F8 800F8458 8FB10034 */ lw $s1, 0x34($sp)
|
||||
/* B6F5FC 800F845C 8FB20038 */ lw $s2, 0x38($sp)
|
||||
/* B6F600 800F8460 8FB3003C */ lw $s3, 0x3c($sp)
|
||||
/* B6F604 800F8464 8FB40040 */ lw $s4, 0x40($sp)
|
||||
/* B6F608 800F8468 8FB50044 */ lw $s5, 0x44($sp)
|
||||
/* B6F60C 800F846C 8FB60048 */ lw $s6, 0x48($sp)
|
||||
/* B6F610 800F8470 8FB7004C */ lw $s7, 0x4c($sp)
|
||||
/* B6F614 800F8474 8FBE0050 */ lw $fp, 0x50($sp)
|
||||
/* B6F618 800F8478 03E00008 */ jr $ra
|
||||
/* B6F61C 800F847C 27BD00B0 */ addiu $sp, $sp, 0xb0
|
||||
|
@ -778,11 +778,11 @@ typedef struct {
|
||||
*
|
||||
*/
|
||||
|
||||
#define SFX_BANK_SHIFT(sfxId) ((sfxId >> 0xC) & 0xFF)
|
||||
#define SFX_BANK_SHIFT(sfxId) (((sfxId) >> 0xC) & 0xFF)
|
||||
|
||||
#define SFX_BANK_MASK(sfxId) (sfxId & 0xF000)
|
||||
#define SFX_BANK_MASK(sfxId) ((sfxId) & 0xF000)
|
||||
|
||||
#define SFX_INDEX(sfxId) (sfxId & 0x01FF)
|
||||
#define SFX_INDEX(sfxId) ((sfxId) & 0x01FF)
|
||||
#define SFX_BANK(sfxId) SFX_BANK_SHIFT(SFX_BANK_MASK(sfxId))
|
||||
|
||||
#endif
|
||||
|
@ -165,7 +165,7 @@ void func_800F74E0(u8 arg0, SoundBankEntry* arg1) {
|
||||
s32 phi_a0;
|
||||
u8 i = D_801333A4;
|
||||
|
||||
while (i != D_801333A0) {
|
||||
for (i; i != D_801333A0; i++) {
|
||||
phi_a0 = false;
|
||||
entry = &D_8016C9A0[i];
|
||||
switch (arg0) {
|
||||
@ -203,84 +203,84 @@ void func_800F74E0(u8 arg0, SoundBankEntry* arg1) {
|
||||
if (phi_a0) {
|
||||
entry->sfxId = 0;
|
||||
}
|
||||
i++;
|
||||
// i++;
|
||||
}
|
||||
}
|
||||
|
||||
#ifdef NON_EQUIVALENT
|
||||
// Mostly ok at the start, then runs into some reorderings near the assignments
|
||||
// of temp_s0 and temp_a2, inducing regalloc throughout the rest
|
||||
#ifdef NON_MATCHING
|
||||
// Down to a/v regalloc and some stuff where the compiler gets confused about reusing values. There's some fake matching
|
||||
// stuff to improve regalloc enough to verify equivalence.
|
||||
void func_800F7680(void) {
|
||||
u8 sp43;
|
||||
Struct_8013331C* temp_a2;
|
||||
SoundBankEntry* temp_s0;
|
||||
s32 phi_s5;
|
||||
Struct_800F738C* phi_t2;
|
||||
u16 flag1;
|
||||
u8 sp55;
|
||||
u8 phi_a1;
|
||||
u8 phi_t4;
|
||||
s32 phi_s1;
|
||||
Struct_800F738C* sp50;
|
||||
SoundBankEntry* temp_v0;
|
||||
Struct_8013331C* sp48;
|
||||
s32 phi_s5;
|
||||
u8 sp43;
|
||||
u8 phi_s1;
|
||||
u16 flag2;
|
||||
|
||||
phi_t2 = &D_8016C9A0[D_801333A4];
|
||||
sp50 = &D_8016C9A0[D_801333A4];
|
||||
phi_s1 = 0x80;
|
||||
if (phi_t2->sfxId == 0) {
|
||||
if (sp50->sfxId == 0) {
|
||||
return;
|
||||
}
|
||||
phi_s5 = SFX_BANK(phi_t2->sfxId);
|
||||
phi_s5 = SFX_BANK(sp50->sfxId);
|
||||
if ((1 << phi_s5) & D_801333F0) {
|
||||
func_800F2D6C(D_80133340, phi_t2->sfxId);
|
||||
phi_s5 = SFX_BANK(phi_t2->sfxId);
|
||||
func_800F2D6C(D_80133340, sp50->sfxId);
|
||||
phi_s5 = SFX_BANK(sp50->sfxId);
|
||||
}
|
||||
phi_t4 = 0;
|
||||
sp55 = 0;
|
||||
phi_a1 = gSoundBanks[phi_s5][0].next;
|
||||
while (phi_a1 != 0xFF && phi_a1 != 0) {
|
||||
if (gSoundBanks[phi_s5][phi_a1].posX == &phi_t2->pos->x) {
|
||||
temp_a2 = &D_8013331C[SFX_BANK_SHIFT(phi_t2->sfxId)][SFX_INDEX(phi_t2->sfxId)];
|
||||
temp_s0 = &gSoundBanks[phi_s5][phi_a1];
|
||||
if (!(temp_a2->unk_2 & 0x20) || temp_s0->unk_24 != temp_a2->unk_0) {
|
||||
if (temp_s0->unk_28 == phi_t2->sfxId) {
|
||||
phi_t4 = D_80130594[phi_s5][D_801333CC];
|
||||
} else {
|
||||
//!@bug possibly uninitialized sp43 ? confirm when matching
|
||||
if (phi_t4 == 0) {
|
||||
phi_s1 = phi_a1;
|
||||
sp43 = D_8013331C[SFX_BANK_SHIFT(temp_s0->unk_28)][SFX_INDEX(temp_s0->unk_28)].unk_0;
|
||||
} else if (temp_s0->unk_24 < sp43) {
|
||||
if (1) {}
|
||||
if (1) {}
|
||||
if (1) {}
|
||||
if (1) {}
|
||||
if (1) {}
|
||||
if (1) {}
|
||||
phi_s1 = phi_a1;
|
||||
sp43 = D_8013331C[SFX_BANK_SHIFT(temp_s0->unk_28)][SFX_INDEX(temp_s0->unk_28)].unk_0;
|
||||
}
|
||||
phi_t4++;
|
||||
if (phi_t4 == D_80130594[phi_s5][D_801333CC]) {
|
||||
phi_a1 = (temp_a2->unk_0 >= sp43) ? phi_s1 : 0;
|
||||
}
|
||||
}
|
||||
if (D_80130594[phi_s5][D_801333CC] == phi_t4) {
|
||||
if ((phi_t2->sfxId & 0xC00) || (temp_a2->unk_2 & 4) || phi_a1 == phi_s1) {
|
||||
if ((gSoundBanks[phi_s5][phi_a1].unk_26 & 8) && gSoundBanks[phi_s5][phi_a1].unk_2A != 1) {
|
||||
func_800F731C(gSoundBanks[phi_s5][phi_a1].unk_2E);
|
||||
}
|
||||
gSoundBanks[phi_s5][phi_a1].unk_C = phi_t2->unk_8;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_28 = phi_t2->sfxId;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_2A = 1;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_2B = 2;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_10 = phi_t2->unk_C;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_14 = phi_t2->unk_10;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_18 = phi_t2->unk_14;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_26 = temp_a2->unk_2;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_24 = temp_a2->unk_0;
|
||||
} else if (gSoundBanks[phi_s5][phi_a1].unk_2A == 5) {
|
||||
gSoundBanks[phi_s5][phi_a1].unk_2A = 4;
|
||||
}
|
||||
phi_a1 = 0;
|
||||
}
|
||||
} else {
|
||||
if (gSoundBanks[phi_s5][phi_a1].posX == &sp50->pos->x) {
|
||||
sp48 = &D_8013331C[SFX_BANK_SHIFT(sp50->sfxId)][SFX_INDEX(sp50->sfxId)];
|
||||
if (!(!(sp48->unk_2 & 0x20) || sp48->unk_0 != gSoundBanks[phi_s5][phi_a1].unk_24)) {
|
||||
return;
|
||||
}
|
||||
if (gSoundBanks[phi_s5][phi_a1].unk_28 == sp50->sfxId) {
|
||||
sp55 = D_80130594[D_801333CC][phi_s5];
|
||||
} else {
|
||||
//!@bug possibly uninitialized sp43 ? confirm when matching
|
||||
if (sp55 == 0) {
|
||||
phi_s1 = phi_a1;
|
||||
flag1 = gSoundBanks[phi_s5][phi_a1].unk_28 & 0xFFFF;
|
||||
sp43 = D_8013331C[SFX_BANK_SHIFT(flag1)][SFX_INDEX(flag1)].unk_0;
|
||||
} else if (gSoundBanks[phi_s5][phi_a1].unk_24 < sp43) {
|
||||
phi_s1 = phi_a1;
|
||||
flag1 = gSoundBanks[phi_s5][phi_a1].unk_28 & 0xFFFF;
|
||||
sp43 = D_8013331C[SFX_BANK_SHIFT(flag1)][SFX_INDEX(flag1)].unk_0;
|
||||
}
|
||||
sp55++;
|
||||
if (sp55 == D_80130594[D_801333CC][phi_s5]) {
|
||||
phi_a1 = (sp48->unk_0 >= sp43) ? phi_s1 : 0;
|
||||
}
|
||||
}
|
||||
if (D_80130594[D_801333CC][phi_s5] == sp55) {
|
||||
flag2 = sp50->sfxId & 0xC00; // Problem is around here
|
||||
sp48 = &D_8013331C[SFX_BANK_SHIFT(sp50->sfxId)][SFX_INDEX(sp50->sfxId)];
|
||||
if ((flag2) || (D_8013331C[SFX_BANK_SHIFT(sp50->sfxId)][SFX_INDEX(sp50->sfxId)].unk_2 & 4) ||
|
||||
(phi_a1 == phi_s1)) {
|
||||
if ((gSoundBanks[phi_s5][phi_a1].unk_26 & 8) && gSoundBanks[phi_s5][phi_a1].unk_2A != 1) {
|
||||
func_800F731C(gSoundBanks[phi_s5][phi_a1].unk_2E);
|
||||
}
|
||||
gSoundBanks[phi_s5][phi_a1].unk_C = sp50->unk_8;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_28 = sp50->sfxId;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_2A = 1;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_2B = 2;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_10 = sp50->unk_C;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_14 = sp50->unk_10;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_18 = sp50->unk_14;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_26 = sp48->unk_2;
|
||||
gSoundBanks[phi_s5][phi_a1].unk_24 = sp48->unk_0;
|
||||
if (!sp48->unk_2) {}
|
||||
} else if (gSoundBanks[phi_s5][phi_a1].unk_2A == 5) {
|
||||
gSoundBanks[phi_s5][phi_a1].unk_2A = 4;
|
||||
}
|
||||
phi_a1 = 0;
|
||||
}
|
||||
}
|
||||
if (phi_a1 != 0) {
|
||||
phi_a1 = gSoundBanks[phi_s5][phi_a1].next;
|
||||
@ -288,26 +288,26 @@ void func_800F7680(void) {
|
||||
}
|
||||
if (gSoundBanks[phi_s5][D_8016E1A8[phi_s5]].next != 0xFF && phi_a1 != 0) {
|
||||
phi_a1 = D_8016E1A8[phi_s5];
|
||||
temp_s0 = &gSoundBanks[phi_s5][phi_a1];
|
||||
temp_s0->posX = &phi_t2->pos->x;
|
||||
temp_s0->posY = &phi_t2->pos->y;
|
||||
temp_s0->posZ = &phi_t2->pos->z;
|
||||
temp_s0->unk_C = phi_t2->unk_8;
|
||||
temp_s0->unk_10 = phi_t2->unk_C;
|
||||
temp_s0->unk_14 = phi_t2->unk_10;
|
||||
temp_s0->unk_18 = phi_t2->unk_14;
|
||||
temp_a2 = &D_8013331C[SFX_BANK_SHIFT(phi_t2->sfxId)][SFX_INDEX(phi_t2->sfxId)];
|
||||
temp_s0->unk_26 = temp_a2->unk_2;
|
||||
temp_s0->unk_24 = temp_a2->unk_0;
|
||||
temp_s0->unk_28 = phi_t2->sfxId;
|
||||
temp_s0->unk_2A = 1;
|
||||
temp_s0->unk_2B = 2;
|
||||
temp_s0->prev = D_8016E1A0[phi_s5];
|
||||
temp_v0 = &gSoundBanks[phi_s5][phi_a1];
|
||||
temp_v0->posX = &sp50->pos->x;
|
||||
temp_v0->posY = &sp50->pos->y;
|
||||
temp_v0->posZ = &sp50->pos->z;
|
||||
temp_v0->unk_C = sp50->unk_8;
|
||||
temp_v0->unk_10 = sp50->unk_C;
|
||||
temp_v0->unk_14 = sp50->unk_10;
|
||||
temp_v0->unk_18 = sp50->unk_14;
|
||||
sp48 = &D_8013331C[SFX_BANK_SHIFT(sp50->sfxId)][SFX_INDEX(sp50->sfxId)];
|
||||
temp_v0->unk_26 = sp48->unk_2;
|
||||
temp_v0->unk_24 = sp48->unk_0;
|
||||
temp_v0->unk_28 = sp50->sfxId;
|
||||
temp_v0->unk_2A = 1;
|
||||
temp_v0->unk_2B = 2;
|
||||
temp_v0->prev = D_8016E1A0[phi_s5];
|
||||
gSoundBanks[phi_s5][D_8016E1A0[phi_s5]].next = D_8016E1A8[phi_s5];
|
||||
D_8016E1A0[phi_s5] = D_8016E1A8[phi_s5];
|
||||
D_8016E1A8[phi_s5] = gSoundBanks[phi_s5][D_8016E1A8[phi_s5]].next;
|
||||
gSoundBanks[phi_s5][D_8016E1A8[phi_s5]].prev = 0xFF;
|
||||
temp_s0->next = 0xFF;
|
||||
temp_v0->next = 0xFF;
|
||||
}
|
||||
}
|
||||
#else
|
||||
@ -342,7 +342,159 @@ void func_800F7B54(u8 bankId, u8 bankIndex) {
|
||||
}
|
||||
}
|
||||
|
||||
#pragma GLOBAL_ASM("asm/non_matchings/code/code_800F7260/func_800F7CEC.s")
|
||||
void func_800F7CEC(u8 arg0) {
|
||||
u8 phi_a1;
|
||||
u8 spAE;
|
||||
u8 phi_s4;
|
||||
u8 spAC;
|
||||
u8 phi_s3;
|
||||
u8 phi_s0;
|
||||
u8 spA9;
|
||||
u8 phi_v1_5;
|
||||
u8 temp1;
|
||||
u8 temp2;
|
||||
u16 temp3;
|
||||
f32 tempf1;
|
||||
SoundBankEntry* temp_s2;
|
||||
Struct_800F7CEC sp84[3];
|
||||
Struct_800F7CEC* temp_s4_3;
|
||||
s32 pad;
|
||||
|
||||
phi_s3 = 0;
|
||||
for (spAC = 0; spAC < 3; spAC++) {
|
||||
sp84[spAC].unk_0 = 0x7FFFFFFF;
|
||||
sp84[spAC].unk_4 = 0xFF;
|
||||
}
|
||||
phi_s4 = gSoundBanks[arg0][0].next;
|
||||
phi_s0 = 0;
|
||||
while (phi_s4 != 0xFF) {
|
||||
if ((1 == gSoundBanks[arg0][phi_s4].unk_2A) && (gSoundBanks[arg0][phi_s4].unk_28 & 0xC00)) {
|
||||
gSoundBanks[arg0][phi_s4].unk_2B--;
|
||||
} else if (!(gSoundBanks[arg0][phi_s4].unk_28 & 0xC00) && (gSoundBanks[arg0][phi_s4].unk_2A == 5)) {
|
||||
func_800E5B20((gSoundBanks[arg0][phi_s4].unk_2E << 8) | 0x6020000, 0);
|
||||
func_800F7B54(arg0, phi_s4);
|
||||
}
|
||||
if (gSoundBanks[arg0][phi_s4].unk_2B == 0) {
|
||||
func_800F7B54(arg0, phi_s4);
|
||||
} else if (gSoundBanks[arg0][phi_s4].unk_2A != 0) {
|
||||
temp_s2 = &gSoundBanks[arg0][phi_s4];
|
||||
|
||||
if (&D_801333D4.x == temp_s2[0].posX) {
|
||||
temp_s2->unk_1C = 0.0f;
|
||||
} else {
|
||||
tempf1 = *temp_s2->posY * 1;
|
||||
temp_s2->unk_1C = (SQ(*temp_s2->posX) + SQ(tempf1) + SQ(*temp_s2->posZ)) * 1;
|
||||
}
|
||||
spA9 = temp_s2->unk_24;
|
||||
if (temp_s2->unk_26 & 0x10) {
|
||||
temp_s2->unk_20 = SQ(0xFF - spA9) * 0x1690;
|
||||
} else {
|
||||
if (temp_s2->unk_1C > 0x7FFFFFD0) {
|
||||
temp_s2->unk_1C = 0x70000008;
|
||||
osSyncPrintf(D_80133344, temp_s2->unk_28, temp_s2->posX, temp_s2->posZ, *temp_s2->posX,
|
||||
*temp_s2->posY, *temp_s2->posZ);
|
||||
}
|
||||
temp3 = temp_s2->unk_28;
|
||||
temp_s2->unk_20 = (u32)temp_s2->unk_1C + (SQ(0xFF - spA9) * 0x1690) + temp3 - temp3;
|
||||
if (*temp_s2->posZ < 0.0f) {
|
||||
temp_s2->unk_20 += (s32)(-*temp_s2->posZ * 6.0f);
|
||||
}
|
||||
}
|
||||
if (temp_s2->unk_1C > 1.0e10f) {
|
||||
if (temp_s2->unk_2A == 4) {
|
||||
func_800E5B20((temp_s2->unk_2E << 8) | 0x6020000, 0);
|
||||
if (temp_s2->unk_28 & 0xC00) {
|
||||
func_800F7B54(arg0, phi_s4);
|
||||
phi_s4 = phi_s0;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
spAE = D_80130578[D_801333CC][arg0];
|
||||
for (spAC = 0; spAC < spAE; spAC++) {
|
||||
if (sp84[spAC].unk_0 >= temp_s2->unk_20) {
|
||||
if (phi_s3 < D_80130578[D_801333CC][arg0]) {
|
||||
phi_s3++;
|
||||
}
|
||||
for (phi_a1 = spAE - 1; phi_a1 > spAC; phi_a1--) {
|
||||
sp84[phi_a1].unk_0 = sp84[phi_a1 - 1].unk_0;
|
||||
sp84[phi_a1].unk_4 = sp84[phi_a1 - 1].unk_4;
|
||||
}
|
||||
sp84[spAC].unk_0 = temp_s2->unk_20;
|
||||
sp84[spAC].unk_4 = phi_s4;
|
||||
spAC = spAE;
|
||||
}
|
||||
}
|
||||
}
|
||||
phi_s0 = phi_s4;
|
||||
}
|
||||
phi_s4 = gSoundBanks[arg0][phi_s0].next;
|
||||
}
|
||||
for (spAC = 0; spAC < phi_s3; spAC++) {
|
||||
temp_s2 = &gSoundBanks[arg0][sp84[spAC].unk_4];
|
||||
if (temp_s2->unk_2A == 1) {
|
||||
temp_s2->unk_2A = 2;
|
||||
} else if (temp_s2->unk_2A == 4) {
|
||||
temp_s2->unk_2A = 3;
|
||||
}
|
||||
}
|
||||
|
||||
spAE = D_80130578[D_801333CC][arg0];
|
||||
for (spAC = 0; spAC < spAE; spAC++) {
|
||||
phi_v1_5 = 0;
|
||||
temp_s4_3 = &D_8016E1B8[arg0][spAC];
|
||||
temp1 = temp_s4_3->unk_4;
|
||||
|
||||
if (temp_s4_3->unk_4 == 0xFF) {
|
||||
phi_v1_5 = 1;
|
||||
} else {
|
||||
temp_s2 = &gSoundBanks[arg0][temp_s4_3[0].unk_4];
|
||||
if (temp_s2->unk_2A == 4) {
|
||||
if (temp_s2->unk_28 & 0xC00) {
|
||||
func_800F7B54(arg0, temp_s4_3->unk_4);
|
||||
} else {
|
||||
temp_s2->unk_2A = 1;
|
||||
}
|
||||
phi_v1_5 = 1;
|
||||
} else if (temp_s2->unk_2A == 0) {
|
||||
temp_s4_3->unk_4 = 0xFF;
|
||||
phi_v1_5 = 1;
|
||||
} else {
|
||||
for (phi_a1 = 0; phi_a1 < spAE; phi_a1++) {
|
||||
if (temp_s4_3->unk_4 == sp84[phi_a1].unk_4) {
|
||||
sp84[phi_a1].unk_4 = 0xFF;
|
||||
phi_a1 = spAE;
|
||||
}
|
||||
}
|
||||
phi_s3--;
|
||||
}
|
||||
}
|
||||
|
||||
if (phi_v1_5 == 1) {
|
||||
for (phi_a1 = 0; phi_a1 < spAE; phi_a1++) {
|
||||
temp2 = sp84[phi_a1].unk_4;
|
||||
if ((temp2 != 0xFF) && (gSoundBanks[arg0][temp2].unk_2A != 3)) {
|
||||
for (phi_s0 = 0; phi_s0 < spAE; phi_s0++) {
|
||||
if (temp2 == D_8016E1B8[arg0][phi_s0].unk_4) {
|
||||
phi_v1_5 = 0;
|
||||
phi_s0 = spAE;
|
||||
}
|
||||
}
|
||||
if (phi_v1_5 == 1) {
|
||||
temp_s4_3->unk_4 = temp2;
|
||||
|
||||
sp84[phi_a1].unk_4 = 0xFF;
|
||||
|
||||
phi_a1 = spAE + 1;
|
||||
phi_s3--;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (phi_a1 == spAE) {
|
||||
temp_s4_3->unk_4 = 0xFF;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void func_800F8480(u8 bankId) {
|
||||
u8 bankIndex;
|
||||
|
Loading…
Reference in New Issue
Block a user