papermario/asm/nonmatchings/code_796FC0/func_802A1518_7974D8.s

1055 lines
55 KiB
ArmAsm
Raw Normal View History

2021-01-10 15:52:28 +01:00
.set noat # allow manual use of $at
.set noreorder # don't insert nops after branches
glabel func_802A1518_7974D8
/* 7974D8 802A1518 27BDFF68 */ addiu $sp, $sp, -0x98
/* 7974DC 802A151C AFB50054 */ sw $s5, 0x54($sp)
/* 7974E0 802A1520 3C15800E */ lui $s5, %hi(gBattleStatus+0xD8)
/* 7974E4 802A1524 8EB5C148 */ lw $s5, %lo(gBattleStatus+0xD8)($s5)
/* 7974E8 802A1528 AFBE0060 */ sw $fp, 0x60($sp)
/* 7974EC 802A152C 0080F02D */ daddu $fp, $a0, $zero
/* 7974F0 802A1530 AFBF0064 */ sw $ra, 0x64($sp)
/* 7974F4 802A1534 AFB7005C */ sw $s7, 0x5c($sp)
/* 7974F8 802A1538 AFB60058 */ sw $s6, 0x58($sp)
/* 7974FC 802A153C AFB40050 */ sw $s4, 0x50($sp)
/* 797500 802A1540 AFB3004C */ sw $s3, 0x4c($sp)
/* 797504 802A1544 AFB20048 */ sw $s2, 0x48($sp)
/* 797508 802A1548 AFB10044 */ sw $s1, 0x44($sp)
/* 79750C 802A154C AFB00040 */ sw $s0, 0x40($sp)
/* 797510 802A1550 F7BE0090 */ sdc1 $f30, 0x90($sp)
/* 797514 802A1554 F7BC0088 */ sdc1 $f28, 0x88($sp)
/* 797518 802A1558 F7BA0080 */ sdc1 $f26, 0x80($sp)
/* 79751C 802A155C F7B80078 */ sdc1 $f24, 0x78($sp)
/* 797520 802A1560 F7B60070 */ sdc1 $f22, 0x70($sp)
/* 797524 802A1564 F7B40068 */ sdc1 $f20, 0x68($sp)
/* 797528 802A1568 8FC2000C */ lw $v0, 0xc($fp)
/* 79752C 802A156C 10A00007 */ beqz $a1, .L802A158C
/* 797530 802A1570 26B1000C */ addiu $s1, $s5, 0xc
/* 797534 802A1574 3C01802A */ lui $at, %hi(D_802A3838)
/* 797538 802A1578 AC203838 */ sw $zero, %lo(D_802A3838)($at)
/* 79753C 802A157C 0C0B1EAF */ jal get_variable
/* 797540 802A1580 8C450000 */ lw $a1, ($v0)
/* 797544 802A1584 AFC20078 */ sw $v0, 0x78($fp)
/* 797548 802A1588 AFC00070 */ sw $zero, 0x70($fp)
.L802A158C:
/* 79754C 802A158C 82A3040C */ lb $v1, 0x40c($s5)
/* 797550 802A1590 24020001 */ addiu $v0, $zero, 1
/* 797554 802A1594 14620040 */ bne $v1, $v0, .L802A1698
/* 797558 802A1598 00000000 */ nop
/* 79755C 802A159C 0C09A75B */ jal get_actor
/* 797560 802A15A0 86A40428 */ lh $a0, 0x428($s5)
/* 797564 802A15A4 0040802D */ daddu $s0, $v0, $zero
/* 797568 802A15A8 1200039D */ beqz $s0, .L802A2420
/* 79756C 802A15AC 24020002 */ addiu $v0, $zero, 2
/* 797570 802A15B0 82A50426 */ lb $a1, 0x426($s5)
/* 797574 802A15B4 0C099117 */ jal get_actor_part
/* 797578 802A15B8 0200202D */ daddu $a0, $s0, $zero
/* 79757C 802A15BC 86020150 */ lh $v0, 0x150($s0)
/* 797580 802A15C0 C6000144 */ lwc1 $f0, 0x144($s0)
/* 797584 802A15C4 8E030000 */ lw $v1, ($s0)
/* 797588 802A15C8 44821000 */ mtc1 $v0, $f2
/* 79758C 802A15CC 00000000 */ nop
/* 797590 802A15D0 468010A0 */ cvt.s.w $f2, $f2
/* 797594 802A15D4 30620800 */ andi $v0, $v1, 0x800
/* 797598 802A15D8 1040000D */ beqz $v0, .L802A1610
/* 79759C 802A15DC 46020700 */ add.s $f28, $f0, $f2
/* 7975A0 802A15E0 86020152 */ lh $v0, 0x152($s0)
/* 7975A4 802A15E4 C6000148 */ lwc1 $f0, 0x148($s0)
/* 7975A8 802A15E8 44821000 */ mtc1 $v0, $f2
/* 7975AC 802A15EC 00000000 */ nop
/* 7975B0 802A15F0 468010A0 */ cvt.s.w $f2, $f2
/* 7975B4 802A15F4 92020191 */ lbu $v0, 0x191($s0)
/* 7975B8 802A15F8 46020000 */ add.s $f0, $f0, $f2
/* 7975BC 802A15FC 44821000 */ mtc1 $v0, $f2
/* 7975C0 802A1600 00000000 */ nop
/* 7975C4 802A1604 468010A0 */ cvt.s.w $f2, $f2
/* 7975C8 802A1608 080A859F */ j .L802A167C
/* 7975CC 802A160C 46020601 */ sub.s $f24, $f0, $f2
.L802A1610:
/* 7975D0 802A1610 30628000 */ andi $v0, $v1, 0x8000
/* 7975D4 802A1614 1440000D */ bnez $v0, .L802A164C
/* 7975D8 802A1618 00000000 */ nop
/* 7975DC 802A161C 86020152 */ lh $v0, 0x152($s0)
/* 7975E0 802A1620 C6000148 */ lwc1 $f0, 0x148($s0)
/* 7975E4 802A1624 44821000 */ mtc1 $v0, $f2
/* 7975E8 802A1628 00000000 */ nop
/* 7975EC 802A162C 468010A0 */ cvt.s.w $f2, $f2
/* 7975F0 802A1630 92020191 */ lbu $v0, 0x191($s0)
/* 7975F4 802A1634 46020000 */ add.s $f0, $f0, $f2
/* 7975F8 802A1638 44821000 */ mtc1 $v0, $f2
/* 7975FC 802A163C 00000000 */ nop
/* 797600 802A1640 468010A0 */ cvt.s.w $f2, $f2
/* 797604 802A1644 080A859F */ j .L802A167C
/* 797608 802A1648 46001600 */ add.s $f24, $f2, $f0
.L802A164C:
/* 79760C 802A164C 86020152 */ lh $v0, 0x152($s0)
/* 797610 802A1650 C6020148 */ lwc1 $f2, 0x148($s0)
/* 797614 802A1654 44820000 */ mtc1 $v0, $f0
/* 797618 802A1658 00000000 */ nop
/* 79761C 802A165C 46800020 */ cvt.s.w $f0, $f0
/* 797620 802A1660 92020191 */ lbu $v0, 0x191($s0)
/* 797624 802A1664 46001080 */ add.s $f2, $f2, $f0
/* 797628 802A1668 00021040 */ sll $v0, $v0, 1
/* 79762C 802A166C 44820000 */ mtc1 $v0, $f0
/* 797630 802A1670 00000000 */ nop
/* 797634 802A1674 46800020 */ cvt.s.w $f0, $f0
/* 797638 802A1678 46001600 */ add.s $f24, $f2, $f0
.L802A167C:
/* 79763C 802A167C 86020154 */ lh $v0, 0x154($s0)
/* 797640 802A1680 C602014C */ lwc1 $f2, 0x14c($s0)
/* 797644 802A1684 44820000 */ mtc1 $v0, $f0
/* 797648 802A1688 00000000 */ nop
/* 79764C 802A168C 46800020 */ cvt.s.w $f0, $f0
/* 797650 802A1690 080A85AB */ j .L802A16AC
/* 797654 802A1694 46001680 */ add.s $f26, $f2, $f0
.L802A1698:
/* 797658 802A1698 3C014280 */ lui $at, 0x4280
/* 79765C 802A169C 4481E000 */ mtc1 $at, $f28
/* 797660 802A16A0 3C0142A0 */ lui $at, 0x42a0
/* 797664 802A16A4 4481C000 */ mtc1 $at, $f24
/* 797668 802A16A8 4480D000 */ mtc1 $zero, $f26
.L802A16AC:
/* 79766C 802A16AC 8FC30070 */ lw $v1, 0x70($fp)
/* 797670 802A16B0 18600077 */ blez $v1, .L802A1890
/* 797674 802A16B4 2862000A */ slti $v0, $v1, 0xa
/* 797678 802A16B8 14400006 */ bnez $v0, .L802A16D4
/* 79767C 802A16BC 0000902D */ daddu $s2, $zero, $zero
/* 797680 802A16C0 2402000A */ addiu $v0, $zero, 0xa
/* 797684 802A16C4 1062003B */ beq $v1, $v0, .L802A17B4
/* 797688 802A16C8 2C620016 */ sltiu $v0, $v1, 0x16
/* 79768C 802A16CC 080A8625 */ j .L802A1894
/* 797690 802A16D0 00000000 */ nop
.L802A16D4:
/* 797694 802A16D4 24160014 */ addiu $s6, $zero, 0x14
/* 797698 802A16D8 2417000A */ addiu $s7, $zero, 0xa
/* 79769C 802A16DC 3C13802A */ lui $s3, %hi(D_802A37F8)
/* 7976A0 802A16E0 267337F8 */ addiu $s3, $s3, %lo(D_802A37F8)
/* 7976A4 802A16E4 3C0141A0 */ lui $at, 0x41a0
/* 7976A8 802A16E8 4481A000 */ mtc1 $at, $f20
/* 7976AC 802A16EC 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 7976B0 802A16F0 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 7976B4 802A16F4 3C013F80 */ lui $at, 0x3f80
/* 7976B8 802A16F8 4481B000 */ mtc1 $at, $f22
/* 7976BC 802A16FC 8C42000C */ lw $v0, 0xc($v0)
/* 7976C0 802A1700 2414005C */ addiu $s4, $zero, 0x5c
/* 7976C4 802A1704 AFA20028 */ sw $v0, 0x28($sp)
.L802A1708:
/* 7976C8 802A1708 8FC20078 */ lw $v0, 0x78($fp)
/* 7976CC 802A170C 14400003 */ bnez $v0, .L802A171C
/* 7976D0 802A1710 00121880 */ sll $v1, $s2, 2
/* 7976D4 802A1714 52400021 */ beql $s2, $zero, .L802A179C
/* 7976D8 802A1718 26730004 */ addiu $s3, $s3, 4
.L802A171C:
/* 7976DC 802A171C 8FA80028 */ lw $t0, 0x28($sp)
/* 7976E0 802A1720 8E620000 */ lw $v0, ($s3)
/* 7976E4 802A1724 10400004 */ beqz $v0, .L802A1738
/* 7976E8 802A1728 01148021 */ addu $s0, $t0, $s4
/* 7976EC 802A172C 2442FFFF */ addiu $v0, $v0, -1
/* 7976F0 802A1730 080A85E6 */ j .L802A1798
/* 7976F4 802A1734 AE620000 */ sw $v0, ($s3)
.L802A1738:
/* 7976F8 802A1738 3C08802A */ lui $t0, %hi(D_802A3514)
/* 7976FC 802A173C 25083514 */ addiu $t0, $t0, %lo(D_802A3514)
/* 797700 802A1740 00681021 */ addu $v0, $v1, $t0
/* 797704 802A1744 AE760000 */ sw $s6, ($s3)
/* 797708 802A1748 8C420000 */ lw $v0, ($v0)
/* 79770C 802A174C 1C400009 */ bgtz $v0, .L802A1774
/* 797710 802A1750 E7B40010 */ swc1 $f20, 0x10($sp)
/* 797714 802A1754 E7B40014 */ swc1 $f20, 0x14($sp)
/* 797718 802A1758 E7B60018 */ swc1 $f22, 0x18($sp)
/* 79771C 802A175C AFB7001C */ sw $s7, 0x1c($sp)
/* 797720 802A1760 AFB60020 */ sw $s6, 0x20($sp)
/* 797724 802A1764 8E050010 */ lw $a1, 0x10($s0)
/* 797728 802A1768 8E060014 */ lw $a2, 0x14($s0)
/* 79772C 802A176C 080A85E4 */ j .L802A1790
/* 797730 802A1770 8E070018 */ lw $a3, 0x18($s0)
.L802A1774:
/* 797734 802A1774 E7B40014 */ swc1 $f20, 0x14($sp)
/* 797738 802A1778 E7B60018 */ swc1 $f22, 0x18($sp)
/* 79773C 802A177C AFB7001C */ sw $s7, 0x1c($sp)
/* 797740 802A1780 AFB60020 */ sw $s6, 0x20($sp)
/* 797744 802A1784 8E050004 */ lw $a1, 4($s0)
/* 797748 802A1788 8E060008 */ lw $a2, 8($s0)
/* 79774C 802A178C 8E07000C */ lw $a3, 0xc($s0)
.L802A1790:
/* 797750 802A1790 0C01C8D4 */ jal func_80072350
/* 797754 802A1794 24040004 */ addiu $a0, $zero, 4
.L802A1798:
/* 797758 802A1798 26730004 */ addiu $s3, $s3, 4
.L802A179C:
/* 79775C 802A179C 26520001 */ addiu $s2, $s2, 1
/* 797760 802A17A0 2A420008 */ slti $v0, $s2, 8
/* 797764 802A17A4 1440FFD8 */ bnez $v0, .L802A1708
/* 797768 802A17A8 2694001C */ addiu $s4, $s4, 0x1c
/* 79776C 802A17AC 080A8623 */ j .L802A188C
/* 797770 802A17B0 00000000 */ nop
.L802A17B4:
/* 797774 802A17B4 24160014 */ addiu $s6, $zero, 0x14
/* 797778 802A17B8 2417000A */ addiu $s7, $zero, 0xa
/* 79777C 802A17BC 3C13802A */ lui $s3, %hi(D_802A37F8)
/* 797780 802A17C0 267337F8 */ addiu $s3, $s3, %lo(D_802A37F8)
/* 797784 802A17C4 3C0141A0 */ lui $at, 0x41a0
/* 797788 802A17C8 4481A000 */ mtc1 $at, $f20
/* 79778C 802A17CC 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 797790 802A17D0 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 797794 802A17D4 3C013F80 */ lui $at, 0x3f80
/* 797798 802A17D8 4481B000 */ mtc1 $at, $f22
/* 79779C 802A17DC 8C42000C */ lw $v0, 0xc($v0)
/* 7977A0 802A17E0 2414005C */ addiu $s4, $zero, 0x5c
/* 7977A4 802A17E4 AFA20028 */ sw $v0, 0x28($sp)
.L802A17E8:
/* 7977A8 802A17E8 8FC20078 */ lw $v0, 0x78($fp)
/* 7977AC 802A17EC 14400003 */ bnez $v0, .L802A17FC
/* 7977B0 802A17F0 00121880 */ sll $v1, $s2, 2
/* 7977B4 802A17F4 52400021 */ beql $s2, $zero, .L802A187C
/* 7977B8 802A17F8 26730004 */ addiu $s3, $s3, 4
.L802A17FC:
/* 7977BC 802A17FC 8FA80028 */ lw $t0, 0x28($sp)
/* 7977C0 802A1800 8E620000 */ lw $v0, ($s3)
/* 7977C4 802A1804 10400004 */ beqz $v0, .L802A1818
/* 7977C8 802A1808 01148021 */ addu $s0, $t0, $s4
/* 7977CC 802A180C 2442FFFF */ addiu $v0, $v0, -1
/* 7977D0 802A1810 080A861E */ j .L802A1878
/* 7977D4 802A1814 AE620000 */ sw $v0, ($s3)
.L802A1818:
/* 7977D8 802A1818 3C08802A */ lui $t0, %hi(D_802A3534)
/* 7977DC 802A181C 25083534 */ addiu $t0, $t0, %lo(D_802A3534)
/* 7977E0 802A1820 00681021 */ addu $v0, $v1, $t0
/* 7977E4 802A1824 AE760000 */ sw $s6, ($s3)
/* 7977E8 802A1828 8C420000 */ lw $v0, ($v0)
/* 7977EC 802A182C 1C400009 */ bgtz $v0, .L802A1854
/* 7977F0 802A1830 E7B40010 */ swc1 $f20, 0x10($sp)
/* 7977F4 802A1834 E7B40014 */ swc1 $f20, 0x14($sp)
/* 7977F8 802A1838 E7B60018 */ swc1 $f22, 0x18($sp)
/* 7977FC 802A183C AFB7001C */ sw $s7, 0x1c($sp)
/* 797800 802A1840 AFB60020 */ sw $s6, 0x20($sp)
/* 797804 802A1844 8E050010 */ lw $a1, 0x10($s0)
/* 797808 802A1848 8E060014 */ lw $a2, 0x14($s0)
/* 79780C 802A184C 080A861C */ j .L802A1870
/* 797810 802A1850 8E070018 */ lw $a3, 0x18($s0)
.L802A1854:
/* 797814 802A1854 E7B40014 */ swc1 $f20, 0x14($sp)
/* 797818 802A1858 E7B60018 */ swc1 $f22, 0x18($sp)
/* 79781C 802A185C AFB7001C */ sw $s7, 0x1c($sp)
/* 797820 802A1860 AFB60020 */ sw $s6, 0x20($sp)
/* 797824 802A1864 8E050004 */ lw $a1, 4($s0)
/* 797828 802A1868 8E060008 */ lw $a2, 8($s0)
/* 79782C 802A186C 8E07000C */ lw $a3, 0xc($s0)
.L802A1870:
/* 797830 802A1870 0C01C8D4 */ jal func_80072350
/* 797834 802A1874 24040004 */ addiu $a0, $zero, 4
.L802A1878:
/* 797838 802A1878 26730004 */ addiu $s3, $s3, 4
.L802A187C:
/* 79783C 802A187C 26520001 */ addiu $s2, $s2, 1
/* 797840 802A1880 2A420008 */ slti $v0, $s2, 8
/* 797844 802A1884 1440FFD8 */ bnez $v0, .L802A17E8
/* 797848 802A1888 2694001C */ addiu $s4, $s4, 0x1c
.L802A188C:
/* 79784C 802A188C 8FC30070 */ lw $v1, 0x70($fp)
.L802A1890:
/* 797850 802A1890 2C620016 */ sltiu $v0, $v1, 0x16
.L802A1894:
/* 797854 802A1894 104002E1 */ beqz $v0, .L802A241C
/* 797858 802A1898 00031080 */ sll $v0, $v1, 2
/* 79785C 802A189C 3C01802A */ lui $at, %hi(D_802A3790)
/* 797860 802A18A0 00220821 */ addu $at, $at, $v0
/* 797864 802A18A4 8C223790 */ lw $v0, %lo(D_802A3790)($at)
/* 797868 802A18A8 00400008 */ jr $v0
/* 79786C 802A18AC 00000000 */ nop
/* 797870 802A18B0 C6B40144 */ lwc1 $f20, 0x144($s5)
/* 797874 802A18B4 C6BE014C */ lwc1 $f30, 0x14c($s5)
/* 797878 802A18B8 92A20191 */ lbu $v0, 0x191($s5)
/* 79787C 802A18BC C6A20148 */ lwc1 $f2, 0x148($s5)
/* 797880 802A18C0 3C0141F0 */ lui $at, 0x41f0
/* 797884 802A18C4 44812000 */ mtc1 $at, $f4
/* 797888 802A18C8 44820000 */ mtc1 $v0, $f0
/* 79788C 802A18CC 00000000 */ nop
/* 797890 802A18D0 46800020 */ cvt.s.w $f0, $f0
/* 797894 802A18D4 46001080 */ add.s $f2, $f2, $f0
/* 797898 802A18D8 3C014316 */ lui $at, 0x4316
/* 79789C 802A18DC 44810000 */ mtc1 $at, $f0
/* 7978A0 802A18E0 E6340000 */ swc1 $f20, ($s1)
/* 7978A4 802A18E4 46041580 */ add.s $f22, $f2, $f4
/* 7978A8 802A18E8 E63E0008 */ swc1 $f30, 8($s1)
/* 7978AC 802A18EC E634000C */ swc1 $f20, 0xc($s1)
/* 7978B0 802A18F0 4600B000 */ add.s $f0, $f22, $f0
/* 7978B4 802A18F4 E63E0014 */ swc1 $f30, 0x14($s1)
/* 7978B8 802A18F8 E6360010 */ swc1 $f22, 0x10($s1)
/* 7978BC 802A18FC E6200004 */ swc1 $f0, 4($s1)
/* 7978C0 802A1900 8FC20078 */ lw $v0, 0x78($fp)
/* 7978C4 802A1904 54400008 */ bnel $v0, $zero, .L802A1928
/* 7978C8 802A1908 24040001 */ addiu $a0, $zero, 1
/* 7978CC 802A190C 4405A000 */ mfc1 $a1, $f20
/* 7978D0 802A1910 4406B000 */ mfc1 $a2, $f22
/* 7978D4 802A1914 4407F000 */ mfc1 $a3, $f30
/* 7978D8 802A1918 3C013F80 */ lui $at, 0x3f80
/* 7978DC 802A191C 44810000 */ mtc1 $at, $f0
/* 7978E0 802A1920 080A864F */ j .L802A193C
/* 7978E4 802A1924 0000202D */ daddu $a0, $zero, $zero
.L802A1928:
/* 7978E8 802A1928 4405A000 */ mfc1 $a1, $f20
/* 7978EC 802A192C 4406B000 */ mfc1 $a2, $f22
/* 7978F0 802A1930 4407F000 */ mfc1 $a3, $f30
/* 7978F4 802A1934 3C013F80 */ lui $at, 0x3f80
/* 7978F8 802A1938 44810000 */ mtc1 $at, $f0
.L802A193C:
/* 7978FC 802A193C AFA00014 */ sw $zero, 0x14($sp)
/* 797900 802A1940 0C01C964 */ jal func_80072590
/* 797904 802A1944 E7A00010 */ swc1 $f0, 0x10($sp)
/* 797908 802A1948 3C01802A */ lui $at, %hi(D_802A37F0)
/* 79790C 802A194C AC2237F0 */ sw $v0, %lo(D_802A37F0)($at)
/* 797910 802A1950 3C014240 */ lui $at, 0x4240
/* 797914 802A1954 44810000 */ mtc1 $at, $f0
/* 797918 802A1958 3C03802A */ lui $v1, %hi(D_802A37F0)
/* 79791C 802A195C 8C6337F0 */ lw $v1, %lo(D_802A37F0)($v1)
/* 797920 802A1960 E620004C */ swc1 $f0, 0x4c($s1)
/* 797924 802A1964 8C62000C */ lw $v0, 0xc($v1)
/* 797928 802A1968 AC40003C */ sw $zero, 0x3c($v0)
/* 79792C 802A196C 8C62000C */ lw $v0, 0xc($v1)
/* 797930 802A1970 C620004C */ lwc1 $f0, 0x4c($s1)
/* 797934 802A1974 E4400048 */ swc1 $f0, 0x48($v0)
/* 797938 802A1978 8C62000C */ lw $v0, 0xc($v1)
/* 79793C 802A197C 3C0141F0 */ lui $at, 0x41f0
/* 797940 802A1980 44810000 */ mtc1 $at, $f0
/* 797944 802A1984 AC400024 */ sw $zero, 0x24($v0)
/* 797948 802A1988 8C62000C */ lw $v0, 0xc($v1)
/* 79794C 802A198C 0000902D */ daddu $s2, $zero, $zero
/* 797950 802A1990 E4400058 */ swc1 $f0, 0x58($v0)
/* 797954 802A1994 8C62000C */ lw $v0, 0xc($v1)
/* 797958 802A1998 3C0140A0 */ lui $at, 0x40a0
/* 79795C 802A199C 44810000 */ mtc1 $at, $f0
/* 797960 802A19A0 3C10802A */ lui $s0, %hi(D_802A37F8)
/* 797964 802A19A4 261037F8 */ addiu $s0, $s0, %lo(D_802A37F8)
/* 797968 802A19A8 E4400040 */ swc1 $f0, 0x40($v0)
.L802A19AC:
/* 79796C 802A19AC 0C00A67F */ jal rand_int
/* 797970 802A19B0 24040014 */ addiu $a0, $zero, 0x14
/* 797974 802A19B4 AE020000 */ sw $v0, ($s0)
/* 797978 802A19B8 26520001 */ addiu $s2, $s2, 1
/* 79797C 802A19BC 2A420008 */ slti $v0, $s2, 8
/* 797980 802A19C0 1440FFFA */ bnez $v0, .L802A19AC
/* 797984 802A19C4 26100004 */ addiu $s0, $s0, 4
/* 797988 802A19C8 8FC30078 */ lw $v1, 0x78($fp)
/* 79798C 802A19CC 24020028 */ addiu $v0, $zero, 0x28
/* 797990 802A19D0 14600004 */ bnez $v1, .L802A19E4
/* 797994 802A19D4 AFC20074 */ sw $v0, 0x74($fp)
/* 797998 802A19D8 3C048000 */ lui $a0, 0x8000
/* 79799C 802A19DC 080A867B */ j .L802A19EC
/* 7979A0 802A19E0 34840068 */ ori $a0, $a0, 0x68
.L802A19E4:
/* 7979A4 802A19E4 3C048000 */ lui $a0, 0x8000
/* 7979A8 802A19E8 34840069 */ ori $a0, $a0, 0x69
.L802A19EC:
/* 7979AC 802A19EC 0C05272D */ jal play_sound
/* 7979B0 802A19F0 00000000 */ nop
/* 7979B4 802A19F4 24020001 */ addiu $v0, $zero, 1
/* 7979B8 802A19F8 080A8907 */ j .L802A241C
/* 7979BC 802A19FC AFC20070 */ sw $v0, 0x70($fp)
/* 7979C0 802A1A00 C6200010 */ lwc1 $f0, 0x10($s1)
/* 7979C4 802A1A04 C6240004 */ lwc1 $f4, 4($s1)
/* 7979C8 802A1A08 46040001 */ sub.s $f0, $f0, $f4
/* 7979CC 802A1A0C 3C014120 */ lui $at, 0x4120
/* 7979D0 802A1A10 44811000 */ mtc1 $at, $f2
/* 7979D4 802A1A14 3C03802A */ lui $v1, %hi(D_802A37F0)
/* 7979D8 802A1A18 8C6337F0 */ lw $v1, %lo(D_802A37F0)($v1)
/* 7979DC 802A1A1C 46020003 */ div.s $f0, $f0, $f2
/* 7979E0 802A1A20 46002100 */ add.s $f4, $f4, $f0
/* 7979E4 802A1A24 C6200000 */ lwc1 $f0, ($s1)
/* 7979E8 802A1A28 E6240004 */ swc1 $f4, 4($s1)
/* 7979EC 802A1A2C 8C62000C */ lw $v0, 0xc($v1)
/* 7979F0 802A1A30 E440004C */ swc1 $f0, 0x4c($v0)
/* 7979F4 802A1A34 8C62000C */ lw $v0, 0xc($v1)
/* 7979F8 802A1A38 C6200004 */ lwc1 $f0, 4($s1)
/* 7979FC 802A1A3C E4400050 */ swc1 $f0, 0x50($v0)
/* 797A00 802A1A40 8C62000C */ lw $v0, 0xc($v1)
/* 797A04 802A1A44 C6200008 */ lwc1 $f0, 8($s1)
/* 797A08 802A1A48 E4400054 */ swc1 $f0, 0x54($v0)
/* 797A0C 802A1A4C 8C62000C */ lw $v0, 0xc($v1)
/* 797A10 802A1A50 AC40003C */ sw $zero, 0x3c($v0)
/* 797A14 802A1A54 8C62000C */ lw $v0, 0xc($v1)
/* 797A18 802A1A58 C620004C */ lwc1 $f0, 0x4c($s1)
/* 797A1C 802A1A5C E4400048 */ swc1 $f0, 0x48($v0)
/* 797A20 802A1A60 8C62000C */ lw $v0, 0xc($v1)
/* 797A24 802A1A64 AC400024 */ sw $zero, 0x24($v0)
/* 797A28 802A1A68 8FC20074 */ lw $v0, 0x74($fp)
/* 797A2C 802A1A6C 14400177 */ bnez $v0, .L802A204C
/* 797A30 802A1A70 2442FFFF */ addiu $v0, $v0, -1
/* 797A34 802A1A74 24020014 */ addiu $v0, $zero, 0x14
/* 797A38 802A1A78 AFC20074 */ sw $v0, 0x74($fp)
/* 797A3C 802A1A7C 24020002 */ addiu $v0, $zero, 2
/* 797A40 802A1A80 080A8907 */ j .L802A241C
/* 797A44 802A1A84 AFC20070 */ sw $v0, 0x70($fp)
/* 797A48 802A1A88 8FC20074 */ lw $v0, 0x74($fp)
/* 797A4C 802A1A8C 1440016F */ bnez $v0, .L802A204C
/* 797A50 802A1A90 2442FFFF */ addiu $v0, $v0, -1
/* 797A54 802A1A94 0C093903 */ jal func_8024E40C
/* 797A58 802A1A98 24040002 */ addiu $a0, $zero, 2
/* 797A5C 802A1A9C 0C093936 */ jal move_cam_over
/* 797A60 802A1AA0 2404000A */ addiu $a0, $zero, 0xa
/* 797A64 802A1AA4 2402000F */ addiu $v0, $zero, 0xf
/* 797A68 802A1AA8 AFC20074 */ sw $v0, 0x74($fp)
/* 797A6C 802A1AAC 24020003 */ addiu $v0, $zero, 3
/* 797A70 802A1AB0 080A8907 */ j .L802A241C
/* 797A74 802A1AB4 AFC20070 */ sw $v0, 0x70($fp)
/* 797A78 802A1AB8 C624004C */ lwc1 $f4, 0x4c($s1)
/* 797A7C 802A1ABC 3C0141C0 */ lui $at, 0x41c0
/* 797A80 802A1AC0 44810000 */ mtc1 $at, $f0
/* 797A84 802A1AC4 00000000 */ nop
/* 797A88 802A1AC8 46040001 */ sub.s $f0, $f0, $f4
/* 797A8C 802A1ACC 3C013E00 */ lui $at, 0x3e00
/* 797A90 802A1AD0 44811000 */ mtc1 $at, $f2
/* 797A94 802A1AD4 00000000 */ nop
/* 797A98 802A1AD8 46020002 */ mul.s $f0, $f0, $f2
/* 797A9C 802A1ADC 00000000 */ nop
/* 797AA0 802A1AE0 46002100 */ add.s $f4, $f4, $f0
/* 797AA4 802A1AE4 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 797AA8 802A1AE8 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 797AAC 802A1AEC E624004C */ swc1 $f4, 0x4c($s1)
/* 797AB0 802A1AF0 8C42000C */ lw $v0, 0xc($v0)
/* 797AB4 802A1AF4 E4440048 */ swc1 $f4, 0x48($v0)
/* 797AB8 802A1AF8 8FC20074 */ lw $v0, 0x74($fp)
/* 797ABC 802A1AFC 54400153 */ bnel $v0, $zero, .L802A204C
/* 797AC0 802A1B00 2442FFFF */ addiu $v0, $v0, -1
/* 797AC4 802A1B04 2403001E */ addiu $v1, $zero, 0x1e
/* 797AC8 802A1B08 24120007 */ addiu $s2, $zero, 7
/* 797ACC 802A1B0C 3C02802A */ lui $v0, %hi(D_802A3834)
/* 797AD0 802A1B10 24423834 */ addiu $v0, $v0, %lo(D_802A3834)
/* 797AD4 802A1B14 E63C000C */ swc1 $f28, 0xc($s1)
/* 797AD8 802A1B18 E6380010 */ swc1 $f24, 0x10($s1)
/* 797ADC 802A1B1C E63A0014 */ swc1 $f26, 0x14($s1)
.L802A1B20:
/* 797AE0 802A1B20 AC430000 */ sw $v1, ($v0)
/* 797AE4 802A1B24 2652FFFF */ addiu $s2, $s2, -1
/* 797AE8 802A1B28 0641FFFD */ bgez $s2, .L802A1B20
/* 797AEC 802A1B2C 2442FFFC */ addiu $v0, $v0, -4
/* 797AF0 802A1B30 8FC20078 */ lw $v0, 0x78($fp)
/* 797AF4 802A1B34 14400002 */ bnez $v0, .L802A1B40
/* 797AF8 802A1B38 24040649 */ addiu $a0, $zero, 0x649
/* 797AFC 802A1B3C 24040648 */ addiu $a0, $zero, 0x648
.L802A1B40:
/* 797B00 802A1B40 0C05272D */ jal play_sound
/* 797B04 802A1B44 00000000 */ nop
/* 797B08 802A1B48 24020004 */ addiu $v0, $zero, 4
/* 797B0C 802A1B4C 080A8907 */ j .L802A241C
/* 797B10 802A1B50 AFC20070 */ sw $v0, 0x70($fp)
/* 797B14 802A1B54 C624004C */ lwc1 $f4, 0x4c($s1)
/* 797B18 802A1B58 3C014240 */ lui $at, 0x4240
/* 797B1C 802A1B5C 44811000 */ mtc1 $at, $f2
/* 797B20 802A1B60 00000000 */ nop
/* 797B24 802A1B64 46041081 */ sub.s $f2, $f2, $f4
/* 797B28 802A1B68 3C013E80 */ lui $at, 0x3e80
/* 797B2C 802A1B6C 44810000 */ mtc1 $at, $f0
/* 797B30 802A1B70 00000000 */ nop
/* 797B34 802A1B74 46001082 */ mul.s $f2, $f2, $f0
/* 797B38 802A1B78 00000000 */ nop
/* 797B3C 802A1B7C 0000B82D */ daddu $s7, $zero, $zero
/* 797B40 802A1B80 02E0902D */ daddu $s2, $s7, $zero
/* 797B44 802A1B84 3C13802A */ lui $s3, %hi(D_802A3818)
/* 797B48 802A1B88 26733818 */ addiu $s3, $s3, %lo(D_802A3818)
/* 797B4C 802A1B8C 0260A82D */ daddu $s5, $s3, $zero
/* 797B50 802A1B90 46022100 */ add.s $f4, $f4, $f2
/* 797B54 802A1B94 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 797B58 802A1B98 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 797B5C 802A1B9C 02E0A02D */ daddu $s4, $s7, $zero
/* 797B60 802A1BA0 E624004C */ swc1 $f4, 0x4c($s1)
/* 797B64 802A1BA4 8C42000C */ lw $v0, 0xc($v0)
/* 797B68 802A1BA8 3C10802A */ lui $s0, %hi(D_802A3514)
/* 797B6C 802A1BAC 26103514 */ addiu $s0, $s0, %lo(D_802A3514)
/* 797B70 802A1BB0 E4440048 */ swc1 $f4, 0x48($v0)
.L802A1BB4:
/* 797B74 802A1BB4 5240004F */ beql $s2, $zero, .L802A1CF4
/* 797B78 802A1BB8 26730004 */ addiu $s3, $s3, 4
/* 797B7C 802A1BBC 8E020000 */ lw $v0, ($s0)
/* 797B80 802A1BC0 04410013 */ bgez $v0, .L802A1C10
/* 797B84 802A1BC4 00000000 */ nop
/* 797B88 802A1BC8 C6340000 */ lwc1 $f20, ($s1)
/* 797B8C 802A1BCC C638000C */ lwc1 $f24, 0xc($s1)
/* 797B90 802A1BD0 C6360004 */ lwc1 $f22, 4($s1)
/* 797B94 802A1BD4 4614C181 */ sub.s $f6, $f24, $f20
/* 797B98 802A1BD8 C63C0010 */ lwc1 $f28, 0x10($s1)
/* 797B9C 802A1BDC C63E0008 */ lwc1 $f30, 8($s1)
/* 797BA0 802A1BE0 4616E001 */ sub.s $f0, $f28, $f22
/* 797BA4 802A1BE4 C63A0014 */ lwc1 $f26, 0x14($s1)
/* 797BA8 802A1BE8 461ED081 */ sub.s $f2, $f26, $f30
/* 797BAC 802A1BEC 4606A180 */ add.s $f6, $f20, $f6
/* 797BB0 802A1BF0 4600B106 */ mov.s $f4, $f22
/* 797BB4 802A1BF4 46002100 */ add.s $f4, $f4, $f0
/* 797BB8 802A1BF8 4600F006 */ mov.s $f0, $f30
/* 797BBC 802A1BFC 46020000 */ add.s $f0, $f0, $f2
/* 797BC0 802A1C00 E6260000 */ swc1 $f6, ($s1)
/* 797BC4 802A1C04 E6240004 */ swc1 $f4, 4($s1)
/* 797BC8 802A1C08 080A873C */ j .L802A1CF0
/* 797BCC 802A1C0C E6200008 */ swc1 $f0, 8($s1)
.L802A1C10:
/* 797BD0 802A1C10 10400004 */ beqz $v0, .L802A1C24
/* 797BD4 802A1C14 24170001 */ addiu $s7, $zero, 1
/* 797BD8 802A1C18 2442FFFF */ addiu $v0, $v0, -1
/* 797BDC 802A1C1C 080A873C */ j .L802A1CF0
/* 797BE0 802A1C20 AE020000 */ sw $v0, ($s0)
.L802A1C24:
/* 797BE4 802A1C24 C6340000 */ lwc1 $f20, ($s1)
/* 797BE8 802A1C28 C6360004 */ lwc1 $f22, 4($s1)
/* 797BEC 802A1C2C C63E0008 */ lwc1 $f30, 8($s1)
/* 797BF0 802A1C30 C638000C */ lwc1 $f24, 0xc($s1)
/* 797BF4 802A1C34 C63C0010 */ lwc1 $f28, 0x10($s1)
/* 797BF8 802A1C38 C63A0014 */ lwc1 $f26, 0x14($s1)
/* 797BFC 802A1C3C 4600A306 */ mov.s $f12, $f20
/* 797C00 802A1C40 4406C000 */ mfc1 $a2, $f24
/* 797C04 802A1C44 4407D000 */ mfc1 $a3, $f26
/* 797C08 802A1C48 0C00A7B5 */ jal dist2D
/* 797C0C 802A1C4C 4600F386 */ mov.s $f14, $f30
/* 797C10 802A1C50 02951021 */ addu $v0, $s4, $s5
/* 797C14 802A1C54 4614C101 */ sub.s $f4, $f24, $f20
/* 797C18 802A1C58 C4460000 */ lwc1 $f6, ($v0)
/* 797C1C 802A1C5C 468031A0 */ cvt.s.w $f6, $f6
/* 797C20 802A1C60 C6220000 */ lwc1 $f2, ($s1)
/* 797C24 802A1C64 46062103 */ div.s $f4, $f4, $f6
/* 797C28 802A1C68 46041080 */ add.s $f2, $f2, $f4
/* 797C2C 802A1C6C 4616E101 */ sub.s $f4, $f28, $f22
/* 797C30 802A1C70 E6220000 */ swc1 $f2, ($s1)
/* 797C34 802A1C74 C4460000 */ lwc1 $f6, ($v0)
/* 797C38 802A1C78 468031A0 */ cvt.s.w $f6, $f6
/* 797C3C 802A1C7C C6220004 */ lwc1 $f2, 4($s1)
/* 797C40 802A1C80 46062103 */ div.s $f4, $f4, $f6
/* 797C44 802A1C84 46041080 */ add.s $f2, $f2, $f4
/* 797C48 802A1C88 461ED101 */ sub.s $f4, $f26, $f30
/* 797C4C 802A1C8C E6220004 */ swc1 $f2, 4($s1)
/* 797C50 802A1C90 C4460000 */ lwc1 $f6, ($v0)
/* 797C54 802A1C94 468031A0 */ cvt.s.w $f6, $f6
/* 797C58 802A1C98 C6220008 */ lwc1 $f2, 8($s1)
/* 797C5C 802A1C9C 46062103 */ div.s $f4, $f4, $f6
/* 797C60 802A1CA0 46041080 */ add.s $f2, $f2, $f4
/* 797C64 802A1CA4 E6220008 */ swc1 $f2, 8($s1)
/* 797C68 802A1CA8 8C420000 */ lw $v0, ($v0)
/* 797C6C 802A1CAC 14570007 */ bne $v0, $s7, .L802A1CCC
/* 797C70 802A1CB0 46000106 */ mov.s $f4, $f0
/* 797C74 802A1CB4 2402FFFF */ addiu $v0, $zero, -1
/* 797C78 802A1CB8 AE020000 */ sw $v0, ($s0)
/* 797C7C 802A1CBC E6380000 */ swc1 $f24, ($s1)
/* 797C80 802A1CC0 E63C0004 */ swc1 $f28, 4($s1)
/* 797C84 802A1CC4 080A8739 */ j .L802A1CE4
/* 797C88 802A1CC8 E63A0008 */ swc1 $f26, 8($s1)
.L802A1CCC:
/* 797C8C 802A1CCC 3C014270 */ lui $at, 0x4270
/* 797C90 802A1CD0 44810000 */ mtc1 $at, $f0
/* 797C94 802A1CD4 C6220004 */ lwc1 $f2, 4($s1)
/* 797C98 802A1CD8 46002003 */ div.s $f0, $f4, $f0
/* 797C9C 802A1CDC 46001080 */ add.s $f2, $f2, $f0
/* 797CA0 802A1CE0 E6220004 */ swc1 $f2, 4($s1)
.L802A1CE4:
/* 797CA4 802A1CE4 8E620000 */ lw $v0, ($s3)
/* 797CA8 802A1CE8 2442FFFF */ addiu $v0, $v0, -1
/* 797CAC 802A1CEC AE620000 */ sw $v0, ($s3)
.L802A1CF0:
/* 797CB0 802A1CF0 26730004 */ addiu $s3, $s3, 4
.L802A1CF4:
/* 797CB4 802A1CF4 26940004 */ addiu $s4, $s4, 4
/* 797CB8 802A1CF8 26520001 */ addiu $s2, $s2, 1
/* 797CBC 802A1CFC 2A420002 */ slti $v0, $s2, 2
/* 797CC0 802A1D00 1440FFAC */ bnez $v0, .L802A1BB4
/* 797CC4 802A1D04 26100004 */ addiu $s0, $s0, 4
/* 797CC8 802A1D08 3C03802A */ lui $v1, %hi(D_802A37F0)
/* 797CCC 802A1D0C 8C6337F0 */ lw $v1, %lo(D_802A37F0)($v1)
/* 797CD0 802A1D10 C6200000 */ lwc1 $f0, ($s1)
/* 797CD4 802A1D14 8C62000C */ lw $v0, 0xc($v1)
/* 797CD8 802A1D18 E440004C */ swc1 $f0, 0x4c($v0)
/* 797CDC 802A1D1C 8C62000C */ lw $v0, 0xc($v1)
/* 797CE0 802A1D20 C6200004 */ lwc1 $f0, 4($s1)
/* 797CE4 802A1D24 E4400050 */ swc1 $f0, 0x50($v0)
/* 797CE8 802A1D28 8C62000C */ lw $v0, 0xc($v1)
/* 797CEC 802A1D2C C6200008 */ lwc1 $f0, 8($s1)
/* 797CF0 802A1D30 E4400054 */ swc1 $f0, 0x54($v0)
/* 797CF4 802A1D34 8C62000C */ lw $v0, 0xc($v1)
/* 797CF8 802A1D38 C6200000 */ lwc1 $f0, ($s1)
/* 797CFC 802A1D3C E4400004 */ swc1 $f0, 4($v0)
/* 797D00 802A1D40 8C62000C */ lw $v0, 0xc($v1)
/* 797D04 802A1D44 AC400008 */ sw $zero, 8($v0)
/* 797D08 802A1D48 8C62000C */ lw $v0, 0xc($v1)
/* 797D0C 802A1D4C C6200008 */ lwc1 $f0, 8($s1)
/* 797D10 802A1D50 16E001B2 */ bnez $s7, .L802A241C
/* 797D14 802A1D54 E440000C */ swc1 $f0, 0xc($v0)
/* 797D18 802A1D58 C620000C */ lwc1 $f0, 0xc($s1)
/* 797D1C 802A1D5C C6220010 */ lwc1 $f2, 0x10($s1)
/* 797D20 802A1D60 C6240014 */ lwc1 $f4, 0x14($s1)
/* 797D24 802A1D64 E6200000 */ swc1 $f0, ($s1)
/* 797D28 802A1D68 E6220004 */ swc1 $f2, 4($s1)
/* 797D2C 802A1D6C E6240008 */ swc1 $f4, 8($s1)
/* 797D30 802A1D70 8C62000C */ lw $v0, 0xc($v1)
/* 797D34 802A1D74 E440004C */ swc1 $f0, 0x4c($v0)
/* 797D38 802A1D78 8C62000C */ lw $v0, 0xc($v1)
/* 797D3C 802A1D7C C6200004 */ lwc1 $f0, 4($s1)
/* 797D40 802A1D80 E4400050 */ swc1 $f0, 0x50($v0)
/* 797D44 802A1D84 8C62000C */ lw $v0, 0xc($v1)
/* 797D48 802A1D88 C6200008 */ lwc1 $f0, 8($s1)
/* 797D4C 802A1D8C 0000902D */ daddu $s2, $zero, $zero
/* 797D50 802A1D90 E4400054 */ swc1 $f0, 0x54($v0)
/* 797D54 802A1D94 8C62000C */ lw $v0, 0xc($v1)
/* 797D58 802A1D98 C6200000 */ lwc1 $f0, ($s1)
/* 797D5C 802A1D9C 24070001 */ addiu $a3, $zero, 1
/* 797D60 802A1DA0 E4400004 */ swc1 $f0, 4($v0)
/* 797D64 802A1DA4 8C62000C */ lw $v0, 0xc($v1)
/* 797D68 802A1DA8 2406FFFD */ addiu $a2, $zero, -3
/* 797D6C 802A1DAC AC400008 */ sw $zero, 8($v0)
/* 797D70 802A1DB0 8C62000C */ lw $v0, 0xc($v1)
/* 797D74 802A1DB4 C6200008 */ lwc1 $f0, 8($s1)
/* 797D78 802A1DB8 3C05802A */ lui $a1, %hi(D_802A3514)
/* 797D7C 802A1DBC 24A53514 */ addiu $a1, $a1, %lo(D_802A3514)
/* 797D80 802A1DC0 E440000C */ swc1 $f0, 0xc($v0)
/* 797D84 802A1DC4 8C63000C */ lw $v1, 0xc($v1)
/* 797D88 802A1DC8 2404005C */ addiu $a0, $zero, 0x5c
/* 797D8C 802A1DCC AFA30028 */ sw $v1, 0x28($sp)
.L802A1DD0:
/* 797D90 802A1DD0 8FC20078 */ lw $v0, 0x78($fp)
/* 797D94 802A1DD4 14400003 */ bnez $v0, .L802A1DE4
/* 797D98 802A1DD8 00000000 */ nop
/* 797D9C 802A1DDC 52400008 */ beql $s2, $zero, .L802A1E00
/* 797DA0 802A1DE0 24A50004 */ addiu $a1, $a1, 4
.L802A1DE4:
/* 797DA4 802A1DE4 8FA80028 */ lw $t0, 0x28($sp)
/* 797DA8 802A1DE8 ACA70000 */ sw $a3, ($a1)
/* 797DAC 802A1DEC 01048021 */ addu $s0, $t0, $a0
/* 797DB0 802A1DF0 8E020000 */ lw $v0, ($s0)
/* 797DB4 802A1DF4 00461024 */ and $v0, $v0, $a2
/* 797DB8 802A1DF8 AE020000 */ sw $v0, ($s0)
/* 797DBC 802A1DFC 24A50004 */ addiu $a1, $a1, 4
.L802A1E00:
/* 797DC0 802A1E00 26520001 */ addiu $s2, $s2, 1
/* 797DC4 802A1E04 2A420008 */ slti $v0, $s2, 8
/* 797DC8 802A1E08 1440FFF1 */ bnez $v0, .L802A1DD0
/* 797DCC 802A1E0C 2484001C */ addiu $a0, $a0, 0x1c
/* 797DD0 802A1E10 0C093903 */ jal func_8024E40C
/* 797DD4 802A1E14 24040003 */ addiu $a0, $zero, 3
/* 797DD8 802A1E18 0C093936 */ jal move_cam_over
/* 797DDC 802A1E1C 2404001E */ addiu $a0, $zero, 0x1e
/* 797DE0 802A1E20 2402000F */ addiu $v0, $zero, 0xf
/* 797DE4 802A1E24 AFC20074 */ sw $v0, 0x74($fp)
/* 797DE8 802A1E28 24020005 */ addiu $v0, $zero, 5
/* 797DEC 802A1E2C 080A8907 */ j .L802A241C
/* 797DF0 802A1E30 AFC20070 */ sw $v0, 0x70($fp)
/* 797DF4 802A1E34 8FC20074 */ lw $v0, 0x74($fp)
/* 797DF8 802A1E38 14400084 */ bnez $v0, .L802A204C
/* 797DFC 802A1E3C 2442FFFF */ addiu $v0, $v0, -1
/* 797E00 802A1E40 3C05802A */ lui $a1, %hi(D_802A37F0)
/* 797E04 802A1E44 8CA537F0 */ lw $a1, %lo(D_802A37F0)($a1)
/* 797E08 802A1E48 A6200064 */ sh $zero, 0x64($s1)
/* 797E0C 802A1E4C 8CA2000C */ lw $v0, 0xc($a1)
/* 797E10 802A1E50 AC40003C */ sw $zero, 0x3c($v0)
/* 797E14 802A1E54 8CA2000C */ lw $v0, 0xc($a1)
/* 797E18 802A1E58 AC400024 */ sw $zero, 0x24($v0)
/* 797E1C 802A1E5C 8FC20078 */ lw $v0, 0x78($fp)
/* 797E20 802A1E60 1040000F */ beqz $v0, .L802A1EA0
/* 797E24 802A1E64 240400F0 */ addiu $a0, $zero, 0xf0
/* 797E28 802A1E68 8CA2000C */ lw $v0, 0xc($a1)
/* 797E2C 802A1E6C AC440018 */ sw $a0, 0x18($v0)
/* 797E30 802A1E70 8CA3000C */ lw $v1, 0xc($a1)
/* 797E34 802A1E74 24020050 */ addiu $v0, $zero, 0x50
/* 797E38 802A1E78 AC62001C */ sw $v0, 0x1c($v1)
/* 797E3C 802A1E7C 8CA3000C */ lw $v1, 0xc($a1)
/* 797E40 802A1E80 240200C8 */ addiu $v0, $zero, 0xc8
/* 797E44 802A1E84 AC620020 */ sw $v0, 0x20($v1)
/* 797E48 802A1E88 8CA2000C */ lw $v0, 0xc($a1)
/* 797E4C 802A1E8C AC440028 */ sw $a0, 0x28($v0)
/* 797E50 802A1E90 8CA2000C */ lw $v0, 0xc($a1)
/* 797E54 802A1E94 AC44002C */ sw $a0, 0x2c($v0)
/* 797E58 802A1E98 8CA2000C */ lw $v0, 0xc($a1)
/* 797E5C 802A1E9C AC440030 */ sw $a0, 0x30($v0)
.L802A1EA0:
/* 797E60 802A1EA0 3C04802A */ lui $a0, %hi(D_802A33A8)
/* 797E64 802A1EA4 248433A8 */ addiu $a0, $a0, %lo(D_802A33A8)
/* 797E68 802A1EA8 2405000A */ addiu $a1, $zero, 0xa
/* 797E6C 802A1EAC 0C0B0CF8 */ jal start_script
/* 797E70 802A1EB0 0000302D */ daddu $a2, $zero, $zero
/* 797E74 802A1EB4 C6200000 */ lwc1 $f0, ($s1)
/* 797E78 802A1EB8 3C013F00 */ lui $at, 0x3f00
/* 797E7C 802A1EBC 44811000 */ mtc1 $at, $f2
/* 797E80 802A1EC0 4600020D */ trunc.w.s $f8, $f0
/* 797E84 802A1EC4 E4480084 */ swc1 $f8, 0x84($v0)
/* 797E88 802A1EC8 C6200004 */ lwc1 $f0, 4($s1)
/* 797E8C 802A1ECC 46020002 */ mul.s $f0, $f0, $f2
/* 797E90 802A1ED0 00000000 */ nop
/* 797E94 802A1ED4 4600020D */ trunc.w.s $f8, $f0
/* 797E98 802A1ED8 E4480088 */ swc1 $f8, 0x88($v0)
/* 797E9C 802A1EDC C6200008 */ lwc1 $f0, 8($s1)
/* 797EA0 802A1EE0 4600020D */ trunc.w.s $f8, $f0
/* 797EA4 802A1EE4 E448008C */ swc1 $f8, 0x8c($v0)
/* 797EA8 802A1EE8 8FC30078 */ lw $v1, 0x78($fp)
/* 797EAC 802A1EEC AC4300AC */ sw $v1, 0xac($v0)
/* 797EB0 802A1EF0 0C05272D */ jal play_sound
/* 797EB4 802A1EF4 2404024A */ addiu $a0, $zero, 0x24a
/* 797EB8 802A1EF8 2402002D */ addiu $v0, $zero, 0x2d
/* 797EBC 802A1EFC AFC20074 */ sw $v0, 0x74($fp)
/* 797EC0 802A1F00 24020006 */ addiu $v0, $zero, 6
/* 797EC4 802A1F04 080A8907 */ j .L802A241C
/* 797EC8 802A1F08 AFC20070 */ sw $v0, 0x70($fp)
/* 797ECC 802A1F0C 96220064 */ lhu $v0, 0x64($s1)
/* 797ED0 802A1F10 2442001E */ addiu $v0, $v0, 0x1e
/* 797ED4 802A1F14 A6220064 */ sh $v0, 0x64($s1)
/* 797ED8 802A1F18 00021400 */ sll $v0, $v0, 0x10
/* 797EDC 802A1F1C 00021403 */ sra $v0, $v0, 0x10
/* 797EE0 802A1F20 28420100 */ slti $v0, $v0, 0x100
/* 797EE4 802A1F24 14400002 */ bnez $v0, .L802A1F30
/* 797EE8 802A1F28 240200FF */ addiu $v0, $zero, 0xff
/* 797EEC 802A1F2C A6220064 */ sh $v0, 0x64($s1)
.L802A1F30:
/* 797EF0 802A1F30 3C04802A */ lui $a0, %hi(D_802A37F0)
/* 797EF4 802A1F34 8C8437F0 */ lw $a0, %lo(D_802A37F0)($a0)
/* 797EF8 802A1F38 86220064 */ lh $v0, 0x64($s1)
/* 797EFC 802A1F3C 8C83000C */ lw $v1, 0xc($a0)
/* 797F00 802A1F40 AC62003C */ sw $v0, 0x3c($v1)
/* 797F04 802A1F44 8C83000C */ lw $v1, 0xc($a0)
/* 797F08 802A1F48 86220064 */ lh $v0, 0x64($s1)
/* 797F0C 802A1F4C AC620024 */ sw $v0, 0x24($v1)
/* 797F10 802A1F50 8FC20074 */ lw $v0, 0x74($fp)
/* 797F14 802A1F54 1440003D */ bnez $v0, .L802A204C
/* 797F18 802A1F58 2442FFFF */ addiu $v0, $v0, -1
/* 797F1C 802A1F5C 8FC20078 */ lw $v0, 0x78($fp)
/* 797F20 802A1F60 24030001 */ addiu $v1, $zero, 1
/* 797F24 802A1F64 3C01802A */ lui $at, %hi(D_802A3838)
/* 797F28 802A1F68 AC233838 */ sw $v1, %lo(D_802A3838)($at)
/* 797F2C 802A1F6C 14400012 */ bnez $v0, .L802A1FB8
/* 797F30 802A1F70 2402000F */ addiu $v0, $zero, 0xf
/* 797F34 802A1F74 82A2040C */ lb $v0, 0x40c($s5)
/* 797F38 802A1F78 1443000F */ bne $v0, $v1, .L802A1FB8
/* 797F3C 802A1F7C 2402000F */ addiu $v0, $zero, 0xf
/* 797F40 802A1F80 86A40428 */ lh $a0, 0x428($s5)
/* 797F44 802A1F84 0C09A75B */ jal get_actor
/* 797F48 802A1F88 00000000 */ nop
/* 797F4C 802A1F8C 82A50426 */ lb $a1, 0x426($s5)
/* 797F50 802A1F90 0C099117 */ jal get_actor_part
/* 797F54 802A1F94 0040202D */ daddu $a0, $v0, $zero
/* 797F58 802A1F98 8C42007C */ lw $v0, 0x7c($v0)
/* 797F5C 802A1F9C 3C030008 */ lui $v1, 8
/* 797F60 802A1FA0 00431024 */ and $v0, $v0, $v1
/* 797F64 802A1FA4 10400003 */ beqz $v0, .L802A1FB4
/* 797F68 802A1FA8 24020014 */ addiu $v0, $zero, 0x14
/* 797F6C 802A1FAC 080A8907 */ j .L802A241C
/* 797F70 802A1FB0 AFC20070 */ sw $v0, 0x70($fp)
.L802A1FB4:
/* 797F74 802A1FB4 2402000F */ addiu $v0, $zero, 0xf
.L802A1FB8:
/* 797F78 802A1FB8 AFC20074 */ sw $v0, 0x74($fp)
/* 797F7C 802A1FBC 24020007 */ addiu $v0, $zero, 7
/* 797F80 802A1FC0 080A8907 */ j .L802A241C
/* 797F84 802A1FC4 AFC20070 */ sw $v0, 0x70($fp)
/* 797F88 802A1FC8 8FC20074 */ lw $v0, 0x74($fp)
/* 797F8C 802A1FCC 1440001F */ bnez $v0, .L802A204C
/* 797F90 802A1FD0 2442FFFF */ addiu $v0, $v0, -1
/* 797F94 802A1FD4 2402000A */ addiu $v0, $zero, 0xa
/* 797F98 802A1FD8 AFC20074 */ sw $v0, 0x74($fp)
/* 797F9C 802A1FDC 24020008 */ addiu $v0, $zero, 8
/* 797FA0 802A1FE0 080A8907 */ j .L802A241C
/* 797FA4 802A1FE4 AFC20070 */ sw $v0, 0x70($fp)
/* 797FA8 802A1FE8 96220064 */ lhu $v0, 0x64($s1)
/* 797FAC 802A1FEC 2442FFE2 */ addiu $v0, $v0, -0x1e
/* 797FB0 802A1FF0 A6220064 */ sh $v0, 0x64($s1)
/* 797FB4 802A1FF4 00021400 */ sll $v0, $v0, 0x10
/* 797FB8 802A1FF8 04420001 */ bltzl $v0, .L802A2000
/* 797FBC 802A1FFC A6200064 */ sh $zero, 0x64($s1)
.L802A2000:
/* 797FC0 802A2000 3C04802A */ lui $a0, %hi(D_802A37F0)
/* 797FC4 802A2004 8C8437F0 */ lw $a0, %lo(D_802A37F0)($a0)
/* 797FC8 802A2008 86220064 */ lh $v0, 0x64($s1)
/* 797FCC 802A200C 8C83000C */ lw $v1, 0xc($a0)
/* 797FD0 802A2010 AC62003C */ sw $v0, 0x3c($v1)
/* 797FD4 802A2014 8C83000C */ lw $v1, 0xc($a0)
/* 797FD8 802A2018 86220064 */ lh $v0, 0x64($s1)
/* 797FDC 802A201C AC620024 */ sw $v0, 0x24($v1)
/* 797FE0 802A2020 8FC20074 */ lw $v0, 0x74($fp)
/* 797FE4 802A2024 14400009 */ bnez $v0, .L802A204C
/* 797FE8 802A2028 2442FFFF */ addiu $v0, $v0, -1
/* 797FEC 802A202C 2402000A */ addiu $v0, $zero, 0xa
/* 797FF0 802A2030 AFC20074 */ sw $v0, 0x74($fp)
/* 797FF4 802A2034 24020009 */ addiu $v0, $zero, 9
/* 797FF8 802A2038 080A8907 */ j .L802A241C
/* 797FFC 802A203C AFC20070 */ sw $v0, 0x70($fp)
/* 798000 802A2040 8FC20074 */ lw $v0, 0x74($fp)
/* 798004 802A2044 10400003 */ beqz $v0, .L802A2054
/* 798008 802A2048 2442FFFF */ addiu $v0, $v0, -1
.L802A204C:
/* 79800C 802A204C 080A8907 */ j .L802A241C
/* 798010 802A2050 AFC20074 */ sw $v0, 0x74($fp)
.L802A2054:
/* 798014 802A2054 3C01432A */ lui $at, 0x432a
/* 798018 802A2058 44810000 */ mtc1 $at, $f0
/* 79801C 802A205C 24020014 */ addiu $v0, $zero, 0x14
/* 798020 802A2060 4600C000 */ add.s $f0, $f24, $f0
/* 798024 802A2064 E63C000C */ swc1 $f28, 0xc($s1)
/* 798028 802A2068 E63A0014 */ swc1 $f26, 0x14($s1)
/* 79802C 802A206C E6200010 */ swc1 $f0, 0x10($s1)
/* 798030 802A2070 AFC20074 */ sw $v0, 0x74($fp)
/* 798034 802A2074 2402000A */ addiu $v0, $zero, 0xa
/* 798038 802A2078 080A8907 */ j .L802A241C
/* 79803C 802A207C AFC20070 */ sw $v0, 0x70($fp)
/* 798040 802A2080 8FC20074 */ lw $v0, 0x74($fp)
/* 798044 802A2084 10400010 */ beqz $v0, .L802A20C8
/* 798048 802A2088 2442FFFF */ addiu $v0, $v0, -1
/* 79804C 802A208C 1440000E */ bnez $v0, .L802A20C8
/* 798050 802A2090 AFC20074 */ sw $v0, 0x74($fp)
/* 798054 802A2094 8FC20078 */ lw $v0, 0x78($fp)
/* 798058 802A2098 54400006 */ bnel $v0, $zero, .L802A20B4
/* 79805C 802A209C 24040249 */ addiu $a0, $zero, 0x249
/* 798060 802A20A0 24040248 */ addiu $a0, $zero, 0x248
/* 798064 802A20A4 0C05269B */ jal func_80149A6C
/* 798068 802A20A8 24050001 */ addiu $a1, $zero, 1
/* 79806C 802A20AC 080A8830 */ j .L802A20C0
/* 798070 802A20B0 24040648 */ addiu $a0, $zero, 0x648
.L802A20B4:
/* 798074 802A20B4 0C05269B */ jal func_80149A6C
/* 798078 802A20B8 24050001 */ addiu $a1, $zero, 1
/* 79807C 802A20BC 24040649 */ addiu $a0, $zero, 0x649
.L802A20C0:
/* 798080 802A20C0 0C05272D */ jal play_sound
/* 798084 802A20C4 00000000 */ nop
.L802A20C8:
/* 798088 802A20C8 0000B82D */ daddu $s7, $zero, $zero
/* 79808C 802A20CC 02E0902D */ daddu $s2, $s7, $zero
/* 798090 802A20D0 2405FFFF */ addiu $a1, $zero, -1
/* 798094 802A20D4 3C03802A */ lui $v1, %hi(D_802A3534)
/* 798098 802A20D8 24633534 */ addiu $v1, $v1, %lo(D_802A3534)
/* 79809C 802A20DC 3C014120 */ lui $at, 0x4120
/* 7980A0 802A20E0 44813000 */ mtc1 $at, $f6
/* 7980A4 802A20E4 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 7980A8 802A20E8 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 7980AC 802A20EC 3C013FF0 */ lui $at, 0x3ff0
/* 7980B0 802A20F0 44812800 */ mtc1 $at, $f5
/* 7980B4 802A20F4 44802000 */ mtc1 $zero, $f4
/* 7980B8 802A20F8 8C42000C */ lw $v0, 0xc($v0)
/* 7980BC 802A20FC 2404005C */ addiu $a0, $zero, 0x5c
/* 7980C0 802A2100 AFA20028 */ sw $v0, 0x28($sp)
.L802A2104:
/* 7980C4 802A2104 8FC20078 */ lw $v0, 0x78($fp)
/* 7980C8 802A2108 14400003 */ bnez $v0, .L802A2118
/* 7980CC 802A210C 00000000 */ nop
/* 7980D0 802A2110 5240001C */ beql $s2, $zero, .L802A2184
/* 7980D4 802A2114 24630004 */ addiu $v1, $v1, 4
.L802A2118:
/* 7980D8 802A2118 8FA80028 */ lw $t0, 0x28($sp)
/* 7980DC 802A211C 8C620000 */ lw $v0, ($v1)
/* 7980E0 802A2120 04400017 */ bltz $v0, .L802A2180
/* 7980E4 802A2124 01048021 */ addu $s0, $t0, $a0
/* 7980E8 802A2128 10400004 */ beqz $v0, .L802A213C
/* 7980EC 802A212C 24170001 */ addiu $s7, $zero, 1
/* 7980F0 802A2130 2442FFFF */ addiu $v0, $v0, -1
/* 7980F4 802A2134 080A8860 */ j .L802A2180
/* 7980F8 802A2138 AC620000 */ sw $v0, ($v1)
.L802A213C:
/* 7980FC 802A213C 8E020000 */ lw $v0, ($s0)
/* 798100 802A2140 C6160014 */ lwc1 $f22, 0x14($s0)
/* 798104 802A2144 34420002 */ ori $v0, $v0, 2
/* 798108 802A2148 AE020000 */ sw $v0, ($s0)
/* 79810C 802A214C C6200010 */ lwc1 $f0, 0x10($s1)
/* 798110 802A2150 46160001 */ sub.s $f0, $f0, $f22
/* 798114 802A2154 46060003 */ div.s $f0, $f0, $f6
/* 798118 802A2158 4600B000 */ add.s $f0, $f22, $f0
/* 79811C 802A215C E6000014 */ swc1 $f0, 0x14($s0)
/* 798120 802A2160 C6220010 */ lwc1 $f2, 0x10($s1)
/* 798124 802A2164 46020001 */ sub.s $f0, $f0, $f2
/* 798128 802A2168 46000005 */ abs.s $f0, $f0
/* 79812C 802A216C 46000021 */ cvt.d.s $f0, $f0
/* 798130 802A2170 4624003C */ c.lt.d $f0, $f4
/* 798134 802A2174 00000000 */ nop
/* 798138 802A2178 45030001 */ bc1tl .L802A2180
/* 79813C 802A217C AC650000 */ sw $a1, ($v1)
.L802A2180:
/* 798140 802A2180 24630004 */ addiu $v1, $v1, 4
.L802A2184:
/* 798144 802A2184 26520001 */ addiu $s2, $s2, 1
/* 798148 802A2188 2A420008 */ slti $v0, $s2, 8
/* 79814C 802A218C 1440FFDD */ bnez $v0, .L802A2104
/* 798150 802A2190 2484001C */ addiu $a0, $a0, 0x1c
/* 798154 802A2194 080A88FB */ j .L802A23EC
/* 798158 802A2198 00000000 */ nop
/* 79815C 802A219C 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 798160 802A21A0 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 798164 802A21A4 2404000F */ addiu $a0, $zero, 0xf
/* 798168 802A21A8 8C43000C */ lw $v1, 0xc($v0)
/* 79816C 802A21AC 24120007 */ addiu $s2, $zero, 7
/* 798170 802A21B0 AC60003C */ sw $zero, 0x3c($v1)
/* 798174 802A21B4 8C42000C */ lw $v0, 0xc($v0)
/* 798178 802A21B8 3C03802A */ lui $v1, %hi(D_802A3834)
/* 79817C 802A21BC 24633834 */ addiu $v1, $v1, %lo(D_802A3834)
/* 798180 802A21C0 AC400024 */ sw $zero, 0x24($v0)
.L802A21C4:
/* 798184 802A21C4 AC640000 */ sw $a0, ($v1)
/* 798188 802A21C8 2652FFFF */ addiu $s2, $s2, -1
/* 79818C 802A21CC 0641FFFD */ bgez $s2, .L802A21C4
/* 798190 802A21D0 2463FFFC */ addiu $v1, $v1, -4
/* 798194 802A21D4 8FC20078 */ lw $v0, 0x78($fp)
/* 798198 802A21D8 14400002 */ bnez $v0, .L802A21E4
/* 79819C 802A21DC 24040249 */ addiu $a0, $zero, 0x249
/* 7981A0 802A21E0 24040248 */ addiu $a0, $zero, 0x248
.L802A21E4:
/* 7981A4 802A21E4 0C05269B */ jal func_80149A6C
/* 7981A8 802A21E8 0000282D */ daddu $a1, $zero, $zero
/* 7981AC 802A21EC 24020015 */ addiu $v0, $zero, 0x15
/* 7981B0 802A21F0 080A8907 */ j .L802A241C
/* 7981B4 802A21F4 AFC20070 */ sw $v0, 0x70($fp)
/* 7981B8 802A21F8 0000B82D */ daddu $s7, $zero, $zero
/* 7981BC 802A21FC 02E0902D */ daddu $s2, $s7, $zero
/* 7981C0 802A2200 3C13802A */ lui $s3, %hi(D_802A3818)
/* 7981C4 802A2204 26733818 */ addiu $s3, $s3, %lo(D_802A3818)
/* 7981C8 802A2208 02E0282D */ daddu $a1, $s7, $zero
/* 7981CC 802A220C 24160008 */ addiu $s6, $zero, 8
/* 7981D0 802A2210 24150004 */ addiu $s5, $zero, 4
/* 7981D4 802A2214 3C03802A */ lui $v1, %hi(D_802A3554)
/* 7981D8 802A2218 24633554 */ addiu $v1, $v1, %lo(D_802A3554)
/* 7981DC 802A221C 0060A02D */ daddu $s4, $v1, $zero
/* 7981E0 802A2220 3C02802A */ lui $v0, %hi(D_802A37F0)
/* 7981E4 802A2224 8C4237F0 */ lw $v0, %lo(D_802A37F0)($v0)
/* 7981E8 802A2228 3C11802A */ lui $s1, %hi(D_802A3514)
/* 7981EC 802A222C 26313514 */ addiu $s1, $s1, %lo(D_802A3514)
/* 7981F0 802A2230 8C42000C */ lw $v0, 0xc($v0)
/* 7981F4 802A2234 2404005C */ addiu $a0, $zero, 0x5c
/* 7981F8 802A2238 AFA20028 */ sw $v0, 0x28($sp)
.L802A223C:
/* 7981FC 802A223C 8FC20078 */ lw $v0, 0x78($fp)
/* 798200 802A2240 14400003 */ bnez $v0, .L802A2250
/* 798204 802A2244 00000000 */ nop
/* 798208 802A2248 5240005F */ beql $s2, $zero, .L802A23C8
/* 79820C 802A224C 26730004 */ addiu $s3, $s3, 4
.L802A2250:
/* 798210 802A2250 8FA80028 */ lw $t0, 0x28($sp)
/* 798214 802A2254 8E220000 */ lw $v0, ($s1)
/* 798218 802A2258 04410015 */ bgez $v0, .L802A22B0
/* 79821C 802A225C 01048021 */ addu $s0, $t0, $a0
/* 798220 802A2260 02A31021 */ addu $v0, $s5, $v1
/* 798224 802A2264 C6140010 */ lwc1 $f20, 0x10($s0)
/* 798228 802A2268 C6980000 */ lwc1 $f24, ($s4)
/* 79822C 802A226C C45C0000 */ lwc1 $f28, ($v0)
/* 798230 802A2270 02C31021 */ addu $v0, $s6, $v1
/* 798234 802A2274 4614C181 */ sub.s $f6, $f24, $f20
/* 798238 802A2278 C6160014 */ lwc1 $f22, 0x14($s0)
/* 79823C 802A227C C61E0018 */ lwc1 $f30, 0x18($s0)
/* 798240 802A2280 4616E001 */ sub.s $f0, $f28, $f22
/* 798244 802A2284 C45A0000 */ lwc1 $f26, ($v0)
/* 798248 802A2288 461ED081 */ sub.s $f2, $f26, $f30
/* 79824C 802A228C 4606A180 */ add.s $f6, $f20, $f6
/* 798250 802A2290 4600B106 */ mov.s $f4, $f22
/* 798254 802A2294 46002100 */ add.s $f4, $f4, $f0
/* 798258 802A2298 4600F006 */ mov.s $f0, $f30
/* 79825C 802A229C 46020000 */ add.s $f0, $f0, $f2
/* 798260 802A22A0 E6060010 */ swc1 $f6, 0x10($s0)
/* 798264 802A22A4 E6040014 */ swc1 $f4, 0x14($s0)
/* 798268 802A22A8 080A88F1 */ j .L802A23C4
/* 79826C 802A22AC E6000018 */ swc1 $f0, 0x18($s0)
.L802A22B0:
/* 798270 802A22B0 10400004 */ beqz $v0, .L802A22C4
/* 798274 802A22B4 24170001 */ addiu $s7, $zero, 1
/* 798278 802A22B8 2442FFFF */ addiu $v0, $v0, -1
/* 79827C 802A22BC 080A88F1 */ j .L802A23C4
/* 798280 802A22C0 AE220000 */ sw $v0, ($s1)
.L802A22C4:
/* 798284 802A22C4 C6140010 */ lwc1 $f20, 0x10($s0)
/* 798288 802A22C8 C6160014 */ lwc1 $f22, 0x14($s0)
/* 79828C 802A22CC C61E0018 */ lwc1 $f30, 0x18($s0)
/* 798290 802A22D0 8E020000 */ lw $v0, ($s0)
/* 798294 802A22D4 4600A306 */ mov.s $f12, $f20
/* 798298 802A22D8 34420002 */ ori $v0, $v0, 2
/* 79829C 802A22DC AE020000 */ sw $v0, ($s0)
/* 7982A0 802A22E0 02C31021 */ addu $v0, $s6, $v1
/* 7982A4 802A22E4 C45A0000 */ lwc1 $f26, ($v0)
/* 7982A8 802A22E8 02A31021 */ addu $v0, $s5, $v1
/* 7982AC 802A22EC C6980000 */ lwc1 $f24, ($s4)
/* 7982B0 802A22F0 C45C0000 */ lwc1 $f28, ($v0)
/* 7982B4 802A22F4 4406C000 */ mfc1 $a2, $f24
/* 7982B8 802A22F8 4407D000 */ mfc1 $a3, $f26
/* 7982BC 802A22FC 4600F386 */ mov.s $f14, $f30
/* 7982C0 802A2300 AFA30030 */ sw $v1, 0x30($sp)
/* 7982C4 802A2304 AFA40034 */ sw $a0, 0x34($sp)
/* 7982C8 802A2308 0C00A7B5 */ jal dist2D
/* 7982CC 802A230C AFA50038 */ sw $a1, 0x38($sp)
/* 7982D0 802A2310 3C08802A */ lui $t0, %hi(D_802A3818)
/* 7982D4 802A2314 25083818 */ addiu $t0, $t0, %lo(D_802A3818)
/* 7982D8 802A2318 4614C101 */ sub.s $f4, $f24, $f20
/* 7982DC 802A231C 8FA50038 */ lw $a1, 0x38($sp)
/* 7982E0 802A2320 C6020010 */ lwc1 $f2, 0x10($s0)
/* 7982E4 802A2324 00A81021 */ addu $v0, $a1, $t0
/* 7982E8 802A2328 C4460000 */ lwc1 $f6, ($v0)
/* 7982EC 802A232C 468031A0 */ cvt.s.w $f6, $f6
/* 7982F0 802A2330 46062103 */ div.s $f4, $f4, $f6
/* 7982F4 802A2334 46041080 */ add.s $f2, $f2, $f4
/* 7982F8 802A2338 4616E101 */ sub.s $f4, $f28, $f22
/* 7982FC 802A233C E6020010 */ swc1 $f2, 0x10($s0)
/* 798300 802A2340 C4460000 */ lwc1 $f6, ($v0)
/* 798304 802A2344 468031A0 */ cvt.s.w $f6, $f6
/* 798308 802A2348 C6020014 */ lwc1 $f2, 0x14($s0)
/* 79830C 802A234C 46062103 */ div.s $f4, $f4, $f6
/* 798310 802A2350 46041080 */ add.s $f2, $f2, $f4
/* 798314 802A2354 461ED101 */ sub.s $f4, $f26, $f30
/* 798318 802A2358 E6020014 */ swc1 $f2, 0x14($s0)
/* 79831C 802A235C C4460000 */ lwc1 $f6, ($v0)
/* 798320 802A2360 468031A0 */ cvt.s.w $f6, $f6
/* 798324 802A2364 C6020018 */ lwc1 $f2, 0x18($s0)
/* 798328 802A2368 46062103 */ div.s $f4, $f4, $f6
/* 79832C 802A236C 46041080 */ add.s $f2, $f2, $f4
/* 798330 802A2370 E6020018 */ swc1 $f2, 0x18($s0)
/* 798334 802A2374 8C420000 */ lw $v0, ($v0)
/* 798338 802A2378 8FA30030 */ lw $v1, 0x30($sp)
/* 79833C 802A237C 8FA40034 */ lw $a0, 0x34($sp)
/* 798340 802A2380 14570007 */ bne $v0, $s7, .L802A23A0
/* 798344 802A2384 46000106 */ mov.s $f4, $f0
/* 798348 802A2388 2402FFFF */ addiu $v0, $zero, -1
/* 79834C 802A238C AE220000 */ sw $v0, ($s1)
/* 798350 802A2390 E6180010 */ swc1 $f24, 0x10($s0)
/* 798354 802A2394 E61C0014 */ swc1 $f28, 0x14($s0)
/* 798358 802A2398 080A88EE */ j .L802A23B8
/* 79835C 802A239C E61A0018 */ swc1 $f26, 0x18($s0)
.L802A23A0:
/* 798360 802A23A0 3C014270 */ lui $at, 0x4270
/* 798364 802A23A4 44810000 */ mtc1 $at, $f0
/* 798368 802A23A8 C6020014 */ lwc1 $f2, 0x14($s0)
/* 79836C 802A23AC 46002003 */ div.s $f0, $f4, $f0
/* 798370 802A23B0 46001080 */ add.s $f2, $f2, $f0
/* 798374 802A23B4 E6020014 */ swc1 $f2, 0x14($s0)
.L802A23B8:
/* 798378 802A23B8 8E620000 */ lw $v0, ($s3)
/* 79837C 802A23BC 2442FFFF */ addiu $v0, $v0, -1
/* 798380 802A23C0 AE620000 */ sw $v0, ($s3)
.L802A23C4:
/* 798384 802A23C4 26730004 */ addiu $s3, $s3, 4
.L802A23C8:
/* 798388 802A23C8 24A50004 */ addiu $a1, $a1, 4
/* 79838C 802A23CC 26D6000C */ addiu $s6, $s6, 0xc
/* 798390 802A23D0 26B5000C */ addiu $s5, $s5, 0xc
/* 798394 802A23D4 2694000C */ addiu $s4, $s4, 0xc
/* 798398 802A23D8 26310004 */ addiu $s1, $s1, 4
/* 79839C 802A23DC 26520001 */ addiu $s2, $s2, 1
/* 7983A0 802A23E0 2A420008 */ slti $v0, $s2, 8
/* 7983A4 802A23E4 1440FF95 */ bnez $v0, .L802A223C
/* 7983A8 802A23E8 2484001C */ addiu $a0, $a0, 0x1c
.L802A23EC:
/* 7983AC 802A23EC 16E0000C */ bnez $s7, .L802A2420
/* 7983B0 802A23F0 0000102D */ daddu $v0, $zero, $zero
/* 7983B4 802A23F4 3C03802A */ lui $v1, %hi(D_802A37F0)
/* 7983B8 802A23F8 8C6337F0 */ lw $v1, %lo(D_802A37F0)($v1)
/* 7983BC 802A23FC 24020002 */ addiu $v0, $zero, 2
/* 7983C0 802A2400 8C640000 */ lw $a0, ($v1)
/* 7983C4 802A2404 0040282D */ daddu $a1, $v0, $zero
/* 7983C8 802A2408 3C01802A */ lui $at, %hi(D_802A3838)
/* 7983CC 802A240C AC253838 */ sw $a1, %lo(D_802A3838)($at)
/* 7983D0 802A2410 34840010 */ ori $a0, $a0, 0x10
/* 7983D4 802A2414 080A8908 */ j .L802A2420
/* 7983D8 802A2418 AC640000 */ sw $a0, ($v1)
.L802A241C:
/* 7983DC 802A241C 0000102D */ daddu $v0, $zero, $zero
.L802A2420:
/* 7983E0 802A2420 8FBF0064 */ lw $ra, 0x64($sp)
/* 7983E4 802A2424 8FBE0060 */ lw $fp, 0x60($sp)
/* 7983E8 802A2428 8FB7005C */ lw $s7, 0x5c($sp)
/* 7983EC 802A242C 8FB60058 */ lw $s6, 0x58($sp)
/* 7983F0 802A2430 8FB50054 */ lw $s5, 0x54($sp)
/* 7983F4 802A2434 8FB40050 */ lw $s4, 0x50($sp)
/* 7983F8 802A2438 8FB3004C */ lw $s3, 0x4c($sp)
/* 7983FC 802A243C 8FB20048 */ lw $s2, 0x48($sp)
/* 798400 802A2440 8FB10044 */ lw $s1, 0x44($sp)
/* 798404 802A2444 8FB00040 */ lw $s0, 0x40($sp)
/* 798408 802A2448 D7BE0090 */ ldc1 $f30, 0x90($sp)
/* 79840C 802A244C D7BC0088 */ ldc1 $f28, 0x88($sp)
/* 798410 802A2450 D7BA0080 */ ldc1 $f26, 0x80($sp)
/* 798414 802A2454 D7B80078 */ ldc1 $f24, 0x78($sp)
/* 798418 802A2458 D7B60070 */ ldc1 $f22, 0x70($sp)
/* 79841C 802A245C D7B40068 */ ldc1 $f20, 0x68($sp)
/* 798420 802A2460 03E00008 */ jr $ra
/* 798424 802A2464 27BD0098 */ addiu $sp, $sp, 0x98