mirror of
https://github.com/pmret/papermario.git
synced 2024-11-18 17:02:46 +01:00
133 lines
6.2 KiB
ArmAsm
133 lines
6.2 KiB
ArmAsm
.set noat # allow manual use of $at
|
|
.set noreorder # don't insert nops after branches
|
|
|
|
|
|
glabel func_8005736C
|
|
/* 03276C 8005736C 27BDFFD0 */ addiu $sp, $sp, -0x30
|
|
/* 032770 80057370 AFB50024 */ sw $s5, 0x24($sp)
|
|
/* 032774 80057374 00C0A82D */ daddu $s5, $a2, $zero
|
|
/* 032778 80057378 AFB3001C */ sw $s3, 0x1c($sp)
|
|
/* 03277C 8005737C 00A0982D */ daddu $s3, $a1, $zero
|
|
/* 032780 80057380 AFB40020 */ sw $s4, 0x20($sp)
|
|
/* 032784 80057384 00E0A02D */ daddu $s4, $a3, $zero
|
|
/* 032788 80057388 308400FF */ andi $a0, $a0, 0xff
|
|
/* 03278C 8005738C 00041140 */ sll $v0, $a0, 5
|
|
/* 032790 80057390 00441023 */ subu $v0, $v0, $a0
|
|
/* 032794 80057394 3C038008 */ lui $v1, 0x8008
|
|
/* 032798 80057398 8C638E54 */ lw $v1, -0x71ac($v1)
|
|
/* 03279C 8005739C 00021080 */ sll $v0, $v0, 2
|
|
/* 0327A0 800573A0 AFBF0028 */ sw $ra, 0x28($sp)
|
|
/* 0327A4 800573A4 AFB20018 */ sw $s2, 0x18($sp)
|
|
/* 0327A8 800573A8 AFB10014 */ sw $s1, 0x14($sp)
|
|
/* 0327AC 800573AC AFB00010 */ sw $s0, 0x10($sp)
|
|
/* 0327B0 800573B0 8C63001C */ lw $v1, 0x1c($v1)
|
|
/* 0327B4 800573B4 93B20043 */ lbu $s2, 0x43($sp)
|
|
/* 0327B8 800573B8 00628021 */ addu $s0, $v1, $v0
|
|
/* 0327BC 800573BC 8E050064 */ lw $a1, 0x64($s0)
|
|
/* 0327C0 800573C0 8E030068 */ lw $v1, 0x68($s0)
|
|
/* 0327C4 800573C4 00A3102A */ slt $v0, $a1, $v1
|
|
/* 0327C8 800573C8 14400029 */ bnez $v0, .L80057470
|
|
/* 0327CC 800573CC 26110048 */ addiu $s1, $s0, 0x48
|
|
/* 0327D0 800573D0 3C028008 */ lui $v0, 0x8008
|
|
/* 0327D4 800573D4 24428181 */ addiu $v0, $v0, -0x7e7f
|
|
/* 0327D8 800573D8 90420000 */ lbu $v0, ($v0)
|
|
/* 0327DC 800573DC 1440000E */ bnez $v0, .L80057418
|
|
/* 0327E0 800573E0 AE030064 */ sw $v1, 0x64($s0)
|
|
/* 0327E4 800573E4 3C048008 */ lui $a0, 0x8008
|
|
/* 0327E8 800573E8 24848E60 */ addiu $a0, $a0, -0x71a0
|
|
/* 0327EC 800573EC 8603004E */ lh $v1, 0x4e($s0)
|
|
/* 0327F0 800573F0 84820080 */ lh $v0, 0x80($a0)
|
|
/* 0327F4 800573F4 00620018 */ mult $v1, $v0
|
|
/* 0327F8 800573F8 00004012 */ mflo $t0
|
|
/* 0327FC 800573FC 000813C3 */ sra $v0, $t0, 0xf
|
|
/* 032800 80057400 A6020050 */ sh $v0, 0x50($s0)
|
|
/* 032804 80057404 84820080 */ lh $v0, 0x80($a0)
|
|
/* 032808 80057408 00620018 */ mult $v1, $v0
|
|
/* 03280C 8005740C 00004012 */ mflo $t0
|
|
/* 032810 80057410 08015D26 */ j .L80057498
|
|
/* 032814 80057414 000813C3 */ sra $v0, $t0, 0xf
|
|
|
|
.L80057418:
|
|
/* 032818 80057418 8602004C */ lh $v0, 0x4c($s0)
|
|
/* 03281C 8005741C 8603004E */ lh $v1, 0x4e($s0)
|
|
/* 032820 80057420 00021040 */ sll $v0, $v0, 1
|
|
/* 032824 80057424 3C018008 */ lui $at, 0x8008
|
|
/* 032828 80057428 00220821 */ addu $at, $at, $v0
|
|
/* 03282C 8005742C 84228E60 */ lh $v0, -0x71a0($at)
|
|
/* 032830 80057430 00620018 */ mult $v1, $v0
|
|
/* 032834 80057434 8603004C */ lh $v1, 0x4c($s0)
|
|
/* 032838 80057438 00004012 */ mflo $t0
|
|
/* 03283C 8005743C 000813C3 */ sra $v0, $t0, 0xf
|
|
/* 032840 80057440 A6020050 */ sh $v0, 0x50($s0)
|
|
/* 032844 80057444 2402007F */ addiu $v0, $zero, 0x7f
|
|
/* 032848 80057448 00431023 */ subu $v0, $v0, $v1
|
|
/* 03284C 8005744C 00021040 */ sll $v0, $v0, 1
|
|
/* 032850 80057450 8603004E */ lh $v1, 0x4e($s0)
|
|
/* 032854 80057454 3C018008 */ lui $at, 0x8008
|
|
/* 032858 80057458 00220821 */ addu $at, $at, $v0
|
|
/* 03285C 8005745C 84228E60 */ lh $v0, -0x71a0($at)
|
|
/* 032860 80057460 00620018 */ mult $v1, $v0
|
|
/* 032864 80057464 00004012 */ mflo $t0
|
|
/* 032868 80057468 08015D26 */ j .L80057498
|
|
/* 03286C 8005746C 000813C3 */ sra $v0, $t0, 0xf
|
|
|
|
.L80057470:
|
|
/* 032870 80057470 86040050 */ lh $a0, 0x50($s0)
|
|
/* 032874 80057474 8606005A */ lh $a2, 0x5a($s0)
|
|
/* 032878 80057478 0C016001 */ jal func_80058004
|
|
/* 03287C 8005747C 96070058 */ lhu $a3, 0x58($s0)
|
|
/* 032880 80057480 86040052 */ lh $a0, 0x52($s0)
|
|
/* 032884 80057484 8E050064 */ lw $a1, 0x64($s0)
|
|
/* 032888 80057488 86060060 */ lh $a2, 0x60($s0)
|
|
/* 03288C 8005748C 9607005E */ lhu $a3, 0x5e($s0)
|
|
/* 032890 80057490 0C016001 */ jal func_80058004
|
|
/* 032894 80057494 A6020050 */ sh $v0, 0x50($s0)
|
|
.L80057498:
|
|
/* 032898 80057498 A6020052 */ sh $v0, 0x52($s0)
|
|
/* 03289C 8005749C 86220008 */ lh $v0, 8($s1)
|
|
/* 0328A0 800574A0 14400002 */ bnez $v0, .L800574AC
|
|
/* 0328A4 800574A4 24020001 */ addiu $v0, $zero, 1
|
|
/* 0328A8 800574A8 A6220008 */ sh $v0, 8($s1)
|
|
.L800574AC:
|
|
/* 0328AC 800574AC 8622000A */ lh $v0, 0xa($s1)
|
|
/* 0328B0 800574B0 14400004 */ bnez $v0, .L800574C4
|
|
/* 0328B4 800574B4 00131400 */ sll $v0, $s3, 0x10
|
|
/* 0328B8 800574B8 24020001 */ addiu $v0, $zero, 1
|
|
/* 0328BC 800574BC A622000A */ sh $v0, 0xa($s1)
|
|
/* 0328C0 800574C0 00131400 */ sll $v0, $s3, 0x10
|
|
.L800574C4:
|
|
/* 0328C4 800574C4 00021403 */ sra $v0, $v0, 0x10
|
|
/* 0328C8 800574C8 00420018 */ mult $v0, $v0
|
|
/* 0328CC 800574CC 328200FF */ andi $v0, $s4, 0xff
|
|
/* 0328D0 800574D0 324300FF */ andi $v1, $s2, 0xff
|
|
/* 0328D4 800574D4 AE20001C */ sw $zero, 0x1c($s1)
|
|
/* 0328D8 800574D8 AE350020 */ sw $s5, 0x20($s1)
|
|
/* 0328DC 800574DC A6220004 */ sh $v0, 4($s1)
|
|
/* 0328E0 800574E0 00004012 */ mflo $t0
|
|
/* 0328E4 800574E4 000813C3 */ sra $v0, $t0, 0xf
|
|
/* 0328E8 800574E8 A6220006 */ sh $v0, 6($s1)
|
|
/* 0328EC 800574EC 00031040 */ sll $v0, $v1, 1
|
|
/* 0328F0 800574F0 3C018008 */ lui $at, 0x8008
|
|
/* 0328F4 800574F4 00220821 */ addu $at, $at, $v0
|
|
/* 0328F8 800574F8 94228E60 */ lhu $v0, -0x71a0($at)
|
|
/* 0328FC 800574FC A622000C */ sh $v0, 0xc($s1)
|
|
/* 032900 80057500 2402007F */ addiu $v0, $zero, 0x7f
|
|
/* 032904 80057504 00431023 */ subu $v0, $v0, $v1
|
|
/* 032908 80057508 00021040 */ sll $v0, $v0, 1
|
|
/* 03290C 8005750C 3C038008 */ lui $v1, 0x8008
|
|
/* 032910 80057510 00621821 */ addu $v1, $v1, $v0
|
|
/* 032914 80057514 94638E60 */ lhu $v1, -0x71a0($v1)
|
|
/* 032918 80057518 24020001 */ addiu $v0, $zero, 1
|
|
/* 03291C 8005751C AE220024 */ sw $v0, 0x24($s1)
|
|
/* 032920 80057520 A623000E */ sh $v1, 0xe($s1)
|
|
/* 032924 80057524 8FBF0028 */ lw $ra, 0x28($sp)
|
|
/* 032928 80057528 8FB50024 */ lw $s5, 0x24($sp)
|
|
/* 03292C 8005752C 8FB40020 */ lw $s4, 0x20($sp)
|
|
/* 032930 80057530 8FB3001C */ lw $s3, 0x1c($sp)
|
|
/* 032934 80057534 8FB20018 */ lw $s2, 0x18($sp)
|
|
/* 032938 80057538 8FB10014 */ lw $s1, 0x14($sp)
|
|
/* 03293C 8005753C 8FB00010 */ lw $s0, 0x10($sp)
|
|
/* 032940 80057540 03E00008 */ jr $ra
|
|
/* 032944 80057544 27BD0030 */ addiu $sp, $sp, 0x30
|
|
|