mirror of
https://github.com/pmret/papermario.git
synced 2024-11-18 17:02:46 +01:00
85 lines
3.9 KiB
ArmAsm
85 lines
3.9 KiB
ArmAsm
.set noat # allow manual use of $at
|
|
.set noreorder # don't insert nops after branches
|
|
|
|
|
|
glabel func_8003DFA0
|
|
/* 0193A0 8003DFA0 27BDFFD0 */ addiu $sp, $sp, -0x30
|
|
/* 0193A4 8003DFA4 AFB1001C */ sw $s1, 0x1c($sp)
|
|
/* 0193A8 8003DFA8 0080882D */ daddu $s1, $a0, $zero
|
|
/* 0193AC 8003DFAC 3C048007 */ lui $a0, 0x8007
|
|
/* 0193B0 8003DFB0 24847C30 */ addiu $a0, $a0, 0x7c30
|
|
/* 0193B4 8003DFB4 AFBF0020 */ sw $ra, 0x20($sp)
|
|
/* 0193B8 8003DFB8 AFB00018 */ sw $s0, 0x18($sp)
|
|
/* 0193BC 8003DFBC F7B40028 */ sdc1 $f20, 0x28($sp)
|
|
/* 0193C0 8003DFC0 94820000 */ lhu $v0, ($a0)
|
|
/* 0193C4 8003DFC4 24430001 */ addiu $v1, $v0, 1
|
|
/* 0193C8 8003DFC8 00021400 */ sll $v0, $v0, 0x10
|
|
/* 0193CC 8003DFCC 00021403 */ sra $v0, $v0, 0x10
|
|
/* 0193D0 8003DFD0 28420004 */ slti $v0, $v0, 4
|
|
/* 0193D4 8003DFD4 14400039 */ bnez $v0, .L8003E0BC
|
|
/* 0193D8 8003DFD8 A4830000 */ sh $v1, ($a0)
|
|
/* 0193DC 8003DFDC C62C000C */ lwc1 $f12, 0xc($s1)
|
|
/* 0193E0 8003DFE0 A4800000 */ sh $zero, ($a0)
|
|
/* 0193E4 8003DFE4 0C00A6C9 */ jal clamp_angle
|
|
/* 0193E8 8003DFE8 46006307 */ neg.s $f12, $f12
|
|
/* 0193EC 8003DFEC 3C0140C9 */ lui $at, 0x40c9
|
|
/* 0193F0 8003DFF0 34210FD0 */ ori $at, $at, 0xfd0
|
|
/* 0193F4 8003DFF4 44811000 */ mtc1 $at, $f2
|
|
/* 0193F8 8003DFF8 00000000 */ nop
|
|
/* 0193FC 8003DFFC 46020502 */ mul.s $f20, $f0, $f2
|
|
/* 019400 8003E000 00000000 */ nop
|
|
/* 019404 8003E004 3C0143B4 */ lui $at, 0x43b4
|
|
/* 019408 8003E008 44810000 */ mtc1 $at, $f0
|
|
/* 01940C 8003E00C 00000000 */ nop
|
|
/* 019410 8003E010 4600A503 */ div.s $f20, $f20, $f0
|
|
/* 019414 8003E014 0C00A85B */ jal sin_rad
|
|
/* 019418 8003E018 4600A306 */ mov.s $f12, $f20
|
|
/* 01941C 8003E01C 4600A306 */ mov.s $f12, $f20
|
|
/* 019420 8003E020 0C00A874 */ jal cos_rad
|
|
/* 019424 8003E024 46000506 */ mov.s $f20, $f0
|
|
/* 019428 8003E028 862200A6 */ lh $v0, 0xa6($s1)
|
|
/* 01942C 8003E02C 44821000 */ mtc1 $v0, $f2
|
|
/* 019430 8003E030 00000000 */ nop
|
|
/* 019434 8003E034 468010A0 */ cvt.s.w $f2, $f2
|
|
/* 019438 8003E038 46141502 */ mul.s $f20, $f2, $f20
|
|
/* 01943C 8003E03C 00000000 */ nop
|
|
/* 019440 8003E040 46001082 */ mul.s $f2, $f2, $f0
|
|
/* 019444 8003E044 00000000 */ nop
|
|
/* 019448 8003E048 3C013E4C */ lui $at, 0x3e4c
|
|
/* 01944C 8003E04C 3421CCCD */ ori $at, $at, 0xcccd
|
|
/* 019450 8003E050 44810000 */ mtc1 $at, $f0
|
|
/* 019454 8003E054 00000000 */ nop
|
|
/* 019458 8003E058 4600A502 */ mul.s $f20, $f20, $f0
|
|
/* 01945C 8003E05C 00000000 */ nop
|
|
/* 019460 8003E060 46001082 */ mul.s $f2, $f2, $f0
|
|
/* 019464 8003E064 00000000 */ nop
|
|
/* 019468 8003E068 3C013FC0 */ lui $at, 0x3fc0
|
|
/* 01946C 8003E06C 44817000 */ mtc1 $at, $f14
|
|
/* 019470 8003E070 C620003C */ lwc1 $f0, 0x3c($s1)
|
|
/* 019474 8003E074 460E0380 */ add.s $f14, $f0, $f14
|
|
/* 019478 8003E078 C6200040 */ lwc1 $f0, 0x40($s1)
|
|
/* 01947C 8003E07C 3C108007 */ lui $s0, 0x8007
|
|
/* 019480 8003E080 26107C34 */ addiu $s0, $s0, 0x7c34
|
|
/* 019484 8003E084 46020000 */ add.s $f0, $f0, $f2
|
|
/* 019488 8003E088 C624000C */ lwc1 $f4, 0xc($s1)
|
|
/* 01948C 8003E08C C62C0038 */ lwc1 $f12, 0x38($s1)
|
|
/* 019490 8003E090 46002107 */ neg.s $f4, $f4
|
|
/* 019494 8003E094 44072000 */ mfc1 $a3, $f4
|
|
/* 019498 8003E098 46146300 */ add.s $f12, $f12, $f20
|
|
/* 01949C 8003E09C 44060000 */ mfc1 $a2, $f0
|
|
/* 0194A0 8003E0A0 C6000000 */ lwc1 $f0, ($s0)
|
|
/* 0194A4 8003E0A4 46800020 */ cvt.s.w $f0, $f0
|
|
/* 0194A8 8003E0A8 0C01BF44 */ jal func_8006FD10
|
|
/* 0194AC 8003E0AC E7A00010 */ swc1 $f0, 0x10($sp)
|
|
/* 0194B0 8003E0B0 8E020000 */ lw $v0, ($s0)
|
|
/* 0194B4 8003E0B4 2C420001 */ sltiu $v0, $v0, 1
|
|
/* 0194B8 8003E0B8 AE020000 */ sw $v0, ($s0)
|
|
.L8003E0BC:
|
|
/* 0194BC 8003E0BC 8FBF0020 */ lw $ra, 0x20($sp)
|
|
/* 0194C0 8003E0C0 8FB1001C */ lw $s1, 0x1c($sp)
|
|
/* 0194C4 8003E0C4 8FB00018 */ lw $s0, 0x18($sp)
|
|
/* 0194C8 8003E0C8 D7B40028 */ ldc1 $f20, 0x28($sp)
|
|
/* 0194CC 8003E0CC 03E00008 */ jr $ra
|
|
/* 0194D0 8003E0D0 27BD0030 */ addiu $sp, $sp, 0x30
|
|
|