mirror of
https://github.com/pmret/papermario.git
synced 2024-11-19 01:12:28 +01:00
106 lines
5.5 KiB
ArmAsm
106 lines
5.5 KiB
ArmAsm
.set noat # allow manual use of $at
|
|
.set noreorder # don't insert nops after branches
|
|
|
|
glabel func_802181F0_5B16A0
|
|
/* 5B16A0 802181F0 27BDFFB8 */ addiu $sp, $sp, -0x48
|
|
/* 5B16A4 802181F4 AFB20018 */ sw $s2, 0x18($sp)
|
|
/* 5B16A8 802181F8 0080902D */ daddu $s2, $a0, $zero
|
|
/* 5B16AC 802181FC AFBF0028 */ sw $ra, 0x28($sp)
|
|
/* 5B16B0 80218200 AFB50024 */ sw $s5, 0x24($sp)
|
|
/* 5B16B4 80218204 AFB40020 */ sw $s4, 0x20($sp)
|
|
/* 5B16B8 80218208 AFB3001C */ sw $s3, 0x1c($sp)
|
|
/* 5B16BC 8021820C AFB10014 */ sw $s1, 0x14($sp)
|
|
/* 5B16C0 80218210 AFB00010 */ sw $s0, 0x10($sp)
|
|
/* 5B16C4 80218214 F7B80040 */ sdc1 $f24, 0x40($sp)
|
|
/* 5B16C8 80218218 F7B60038 */ sdc1 $f22, 0x38($sp)
|
|
/* 5B16CC 8021821C F7B40030 */ sdc1 $f20, 0x30($sp)
|
|
/* 5B16D0 80218220 8E50000C */ lw $s0, 0xc($s2)
|
|
/* 5B16D4 80218224 8E140000 */ lw $s4, ($s0)
|
|
/* 5B16D8 80218228 26100004 */ addiu $s0, $s0, 4
|
|
/* 5B16DC 8021822C 0C0B1EAF */ jal get_variable
|
|
/* 5B16E0 80218230 0280282D */ daddu $a1, $s4, $zero
|
|
/* 5B16E4 80218234 0040982D */ daddu $s3, $v0, $zero
|
|
/* 5B16E8 80218238 8E150000 */ lw $s5, ($s0)
|
|
/* 5B16EC 8021823C 26100004 */ addiu $s0, $s0, 4
|
|
/* 5B16F0 80218240 8E050000 */ lw $a1, ($s0)
|
|
/* 5B16F4 80218244 26100004 */ addiu $s0, $s0, 4
|
|
/* 5B16F8 80218248 0C0B210B */ jal get_float_variable
|
|
/* 5B16FC 8021824C 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B1700 80218250 8E050000 */ lw $a1, ($s0)
|
|
/* 5B1704 80218254 26100004 */ addiu $s0, $s0, 4
|
|
/* 5B1708 80218258 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B170C 8021825C 0C0B210B */ jal get_float_variable
|
|
/* 5B1710 80218260 46000606 */ mov.s $f24, $f0
|
|
/* 5B1714 80218264 8E050000 */ lw $a1, ($s0)
|
|
/* 5B1718 80218268 26100004 */ addiu $s0, $s0, 4
|
|
/* 5B171C 8021826C 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B1720 80218270 0C0B1EAF */ jal get_variable
|
|
/* 5B1724 80218274 46000506 */ mov.s $f20, $f0
|
|
/* 5B1728 80218278 8E050000 */ lw $a1, ($s0)
|
|
/* 5B172C 8021827C 26100004 */ addiu $s0, $s0, 4
|
|
/* 5B1730 80218280 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B1734 80218284 0C0B1EAF */ jal get_variable
|
|
/* 5B1738 80218288 0040882D */ daddu $s1, $v0, $zero
|
|
/* 5B173C 8021828C 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B1740 80218290 8E050000 */ lw $a1, ($s0)
|
|
/* 5B1744 80218294 0C0B210B */ jal get_float_variable
|
|
/* 5B1748 80218298 0040802D */ daddu $s0, $v0, $zero
|
|
/* 5B174C 8021829C 3C014334 */ lui $at, 0x4334
|
|
/* 5B1750 802182A0 44811000 */ mtc1 $at, $f2
|
|
/* 5B1754 802182A4 3C014049 */ lui $at, 0x4049
|
|
/* 5B1758 802182A8 34210FD8 */ ori $at, $at, 0xfd8
|
|
/* 5B175C 802182AC 44812000 */ mtc1 $at, $f4
|
|
/* 5B1760 802182B0 46020003 */ div.s $f0, $f0, $f2
|
|
/* 5B1764 802182B4 46040582 */ mul.s $f22, $f0, $f4
|
|
/* 5B1768 802182B8 00000000 */ nop
|
|
/* 5B176C 802182BC 4618A501 */ sub.s $f20, $f20, $f24
|
|
/* 5B1770 802182C0 3C013F00 */ lui $at, 0x3f00
|
|
/* 5B1774 802182C4 44810000 */ mtc1 $at, $f0
|
|
/* 5B1778 802182C8 00000000 */ nop
|
|
/* 5B177C 802182CC 4600A502 */ mul.s $f20, $f20, $f0
|
|
/* 5B1780 802182D0 00000000 */ nop
|
|
/* 5B1784 802182D4 12000007 */ beqz $s0, .L802182F4
|
|
/* 5B1788 802182D8 0233102A */ slt $v0, $s1, $s3
|
|
/* 5B178C 802182DC 10400005 */ beqz $v0, .L802182F4
|
|
/* 5B1790 802182E0 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B1794 802182E4 0220982D */ daddu $s3, $s1, $zero
|
|
/* 5B1798 802182E8 0280282D */ daddu $a1, $s4, $zero
|
|
/* 5B179C 802182EC 0C0B2026 */ jal set_variable
|
|
/* 5B17A0 802182F0 0220302D */ daddu $a2, $s1, $zero
|
|
.L802182F4:
|
|
/* 5B17A4 802182F4 3C014049 */ lui $at, 0x4049
|
|
/* 5B17A8 802182F8 34210FD8 */ ori $at, $at, 0xfd8
|
|
/* 5B17AC 802182FC 44810000 */ mtc1 $at, $f0
|
|
/* 5B17B0 80218300 44936000 */ mtc1 $s3, $f12
|
|
/* 5B17B4 80218304 00000000 */ nop
|
|
/* 5B17B8 80218308 46806320 */ cvt.s.w $f12, $f12
|
|
/* 5B17BC 8021830C 46006302 */ mul.s $f12, $f12, $f0
|
|
/* 5B17C0 80218310 00000000 */ nop
|
|
/* 5B17C4 80218314 44910000 */ mtc1 $s1, $f0
|
|
/* 5B17C8 80218318 00000000 */ nop
|
|
/* 5B17CC 8021831C 46800020 */ cvt.s.w $f0, $f0
|
|
/* 5B17D0 80218320 46006303 */ div.s $f12, $f12, $f0
|
|
/* 5B17D4 80218324 0C00A874 */ jal cos_rad
|
|
/* 5B17D8 80218328 46166300 */ add.s $f12, $f12, $f22
|
|
/* 5B17DC 8021832C 4600A002 */ mul.s $f0, $f20, $f0
|
|
/* 5B17E0 80218330 00000000 */ nop
|
|
/* 5B17E4 80218334 4614C080 */ add.s $f2, $f24, $f20
|
|
/* 5B17E8 80218338 46001081 */ sub.s $f2, $f2, $f0
|
|
/* 5B17EC 8021833C 0240202D */ daddu $a0, $s2, $zero
|
|
/* 5B17F0 80218340 44061000 */ mfc1 $a2, $f2
|
|
/* 5B17F4 80218344 0C0B2190 */ jal set_float_variable
|
|
/* 5B17F8 80218348 02A0282D */ daddu $a1, $s5, $zero
|
|
/* 5B17FC 8021834C 8FBF0028 */ lw $ra, 0x28($sp)
|
|
/* 5B1800 80218350 8FB50024 */ lw $s5, 0x24($sp)
|
|
/* 5B1804 80218354 8FB40020 */ lw $s4, 0x20($sp)
|
|
/* 5B1808 80218358 8FB3001C */ lw $s3, 0x1c($sp)
|
|
/* 5B180C 8021835C 8FB20018 */ lw $s2, 0x18($sp)
|
|
/* 5B1810 80218360 8FB10014 */ lw $s1, 0x14($sp)
|
|
/* 5B1814 80218364 8FB00010 */ lw $s0, 0x10($sp)
|
|
/* 5B1818 80218368 D7B80040 */ ldc1 $f24, 0x40($sp)
|
|
/* 5B181C 8021836C D7B60038 */ ldc1 $f22, 0x38($sp)
|
|
/* 5B1820 80218370 D7B40030 */ ldc1 $f20, 0x30($sp)
|
|
/* 5B1824 80218374 24020002 */ addiu $v0, $zero, 2
|
|
/* 5B1828 80218378 03E00008 */ jr $ra
|
|
/* 5B182C 8021837C 27BD0048 */ addiu $sp, $sp, 0x48
|