mirror of
https://github.com/pmret/papermario.git
synced 2024-11-18 08:52:40 +01:00
3315d6010f
* all non-world rodata migrated * data disasm * kinda working * updated yaml * bloop * linker header * configure 2.0 * bin * mass rename to remove code_ * pause rename * battle partner stuff * whew * more renames * more renames * more renaming * it builds! * updates * remove main prefix * one more thing * crc, yay0 * .data, .rodata, .bss * img * dead_atan2 * it buildsgit add -A * split battle/partner/6FAD10 * rm &s on sleepy_sheep syms * sha1sum ninja rule description * OK but commented out PaperMarioMapFS and PaperMarioNpcSprites * uncomment * fix mapfs * match func_8003CFB4 * . * clean up and name npc_iter_no_op * npc.c * enable cc warnings * name npc_find_near * use singular options.asset_path * smores * cc_dsl only when needed * kinda fix configure for splat refactor2 * ok! * new msg format * remove old msg format docs * slight bug fixes, splat adjustment * git subrepo pull (merge) --force tools/splat subrepo: subdir: "tools/splat" merged: "cfc140bb76" upstream: origin: "https://github.com/ethteck/splat.git" branch: "master" commit: "cfc140bb76" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * git subrepo pull (merge) --force tools/splat subrepo: subdir: "tools/splat" merged: "85349befcd" upstream: origin: "https://github.com/ethteck/splat.git" branch: "master" commit: "85349befcd" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" * Update symbol addrs * git subrepo pull tools/splat subrepo: subdir: "tools/splat" merged: "a44631e194" upstream: origin: "https://github.com/ethteck/splat.git" branch: "master" commit: "a44631e194" git-subrepo: version: "0.4.3" origin: "https://github.com/ingydotnet/git-subrepo" commit: "2f68596" Co-authored-by: Alex Bates <hi@imalex.xyz>
198 lines
9.8 KiB
ArmAsm
198 lines
9.8 KiB
ArmAsm
.set noat # allow manual use of $at
|
|
.set noreorder # don't insert nops after branches
|
|
|
|
glabel func_8004C228
|
|
/* 27628 8004C228 27BDFFD8 */ addiu $sp, $sp, -0x28
|
|
/* 2762C 8004C22C AFB20018 */ sw $s2, 0x18($sp)
|
|
/* 27630 8004C230 0080902D */ daddu $s2, $a0, $zero
|
|
/* 27634 8004C234 AFB00010 */ sw $s0, 0x10($sp)
|
|
/* 27638 8004C238 00A0802D */ daddu $s0, $a1, $zero
|
|
/* 2763C 8004C23C AFB10014 */ sw $s1, 0x14($sp)
|
|
/* 27640 8004C240 00C0882D */ daddu $s1, $a2, $zero
|
|
/* 27644 8004C244 AFBF0020 */ sw $ra, 0x20($sp)
|
|
/* 27648 8004C248 AFB3001C */ sw $s3, 0x1c($sp)
|
|
/* 2764C 8004C24C 920300A9 */ lbu $v1, 0xa9($s0)
|
|
/* 27650 8004C250 10600006 */ beqz $v1, .L8004C26C
|
|
/* 27654 8004C254 00E0982D */ daddu $s3, $a3, $zero
|
|
/* 27658 8004C258 24020001 */ addiu $v0, $zero, 1
|
|
/* 2765C 8004C25C 1062003D */ beq $v1, $v0, .L8004C354
|
|
/* 27660 8004C260 0240202D */ daddu $a0, $s2, $zero
|
|
/* 27664 8004C264 08013134 */ j .L8004C4D0
|
|
/* 27668 8004C268 AE000000 */ sw $zero, ($s0)
|
|
.L8004C26C:
|
|
/* 2766C 8004C26C 92230045 */ lbu $v1, 0x45($s1)
|
|
/* 27670 8004C270 924200BC */ lbu $v0, 0xbc($s2)
|
|
/* 27674 8004C274 54620096 */ bnel $v1, $v0, .L8004C4D0
|
|
/* 27678 8004C278 AE000000 */ sw $zero, ($s0)
|
|
/* 2767C 8004C27C 9202009A */ lbu $v0, 0x9a($s0)
|
|
/* 27680 8004C280 30420010 */ andi $v0, $v0, 0x10
|
|
/* 27684 8004C284 14400017 */ bnez $v0, .L8004C2E4
|
|
/* 27688 8004C288 00000000 */ nop
|
|
/* 2768C 8004C28C 8E02001C */ lw $v0, 0x1c($s0)
|
|
/* 27690 8004C290 86040060 */ lh $a0, 0x60($s0)
|
|
/* 27694 8004C294 9442001E */ lhu $v0, 0x1e($v0)
|
|
/* 27698 8004C298 860300A4 */ lh $v1, 0xa4($s0)
|
|
/* 2769C 8004C29C 00822023 */ subu $a0, $a0, $v0
|
|
/* 276A0 8004C2A0 0C014D6A */ jal func_800535A8
|
|
/* 276A4 8004C2A4 00832021 */ addu $a0, $a0, $v1
|
|
/* 276A8 8004C2A8 8E02001C */ lw $v0, 0x1c($s0)
|
|
/* 276AC 8004C2AC C4420020 */ lwc1 $f2, 0x20($v0)
|
|
/* 276B0 8004C2B0 46020002 */ mul.s $f0, $f0, $f2
|
|
/* 276B4 8004C2B4 00000000 */ nop
|
|
/* 276B8 8004C2B8 E6000058 */ swc1 $f0, 0x58($s0)
|
|
/* 276BC 8004C2BC C6220004 */ lwc1 $f2, 4($s1)
|
|
/* 276C0 8004C2C0 46001032 */ c.eq.s $f2, $f0
|
|
/* 276C4 8004C2C4 00000000 */ nop
|
|
/* 276C8 8004C2C8 45010006 */ bc1t .L8004C2E4
|
|
/* 276CC 8004C2CC 00000000 */ nop
|
|
/* 276D0 8004C2D0 92220043 */ lbu $v0, 0x43($s1)
|
|
/* 276D4 8004C2D4 34420008 */ ori $v0, $v0, 8
|
|
/* 276D8 8004C2D8 A2220043 */ sb $v0, 0x43($s1)
|
|
/* 276DC 8004C2DC C6000058 */ lwc1 $f0, 0x58($s0)
|
|
/* 276E0 8004C2E0 E6200004 */ swc1 $f0, 4($s1)
|
|
.L8004C2E4:
|
|
/* 276E4 8004C2E4 9202009A */ lbu $v0, 0x9a($s0)
|
|
/* 276E8 8004C2E8 30420008 */ andi $v0, $v0, 8
|
|
/* 276EC 8004C2EC 14400004 */ bnez $v0, .L8004C300
|
|
/* 276F0 8004C2F0 00000000 */ nop
|
|
/* 276F4 8004C2F4 920200A8 */ lbu $v0, 0xa8($s0)
|
|
/* 276F8 8004C2F8 14400002 */ bnez $v0, .L8004C304
|
|
/* 276FC 8004C2FC 0040182D */ daddu $v1, $v0, $zero
|
|
.L8004C300:
|
|
/* 27700 8004C300 9203009B */ lbu $v1, 0x9b($s0)
|
|
.L8004C304:
|
|
/* 27704 8004C304 9222000E */ lbu $v0, 0xe($s1)
|
|
/* 27708 8004C308 10430005 */ beq $v0, $v1, .L8004C320
|
|
/* 2770C 8004C30C 0240202D */ daddu $a0, $s2, $zero
|
|
/* 27710 8004C310 92220043 */ lbu $v0, 0x43($s1)
|
|
/* 27714 8004C314 A223000E */ sb $v1, 0xe($s1)
|
|
/* 27718 8004C318 34420010 */ ori $v0, $v0, 0x10
|
|
/* 2771C 8004C31C A2220043 */ sb $v0, 0x43($s1)
|
|
.L8004C320:
|
|
/* 27720 8004C320 0C01313D */ jal func_8004C4F4
|
|
/* 27724 8004C324 0200282D */ daddu $a1, $s0, $zero
|
|
/* 27728 8004C328 0040202D */ daddu $a0, $v0, $zero
|
|
/* 2772C 8004C32C 86230040 */ lh $v1, 0x40($s1)
|
|
/* 27730 8004C330 00041400 */ sll $v0, $a0, 0x10
|
|
/* 27734 8004C334 00021403 */ sra $v0, $v0, 0x10
|
|
/* 27738 8004C338 10620067 */ beq $v1, $v0, .L8004C4D8
|
|
/* 2773C 8004C33C 00000000 */ nop
|
|
/* 27740 8004C340 9222003D */ lbu $v0, 0x3d($s1)
|
|
/* 27744 8004C344 A6240040 */ sh $a0, 0x40($s1)
|
|
/* 27748 8004C348 34420020 */ ori $v0, $v0, 0x20
|
|
/* 2774C 8004C34C 08013136 */ j .L8004C4D8
|
|
/* 27750 8004C350 A222003D */ sb $v0, 0x3d($s1)
|
|
.L8004C354:
|
|
/* 27754 8004C354 0C0132DD */ jal func_8004CB74
|
|
/* 27758 8004C358 0200282D */ daddu $a1, $s0, $zero
|
|
/* 2775C 8004C35C 0240202D */ daddu $a0, $s2, $zero
|
|
/* 27760 8004C360 0C0132C8 */ jal func_8004CB20
|
|
/* 27764 8004C364 0200282D */ daddu $a1, $s0, $zero
|
|
/* 27768 8004C368 0240202D */ daddu $a0, $s2, $zero
|
|
/* 2776C 8004C36C 0C0132D5 */ jal func_8004CB54
|
|
/* 27770 8004C370 0200282D */ daddu $a1, $s0, $zero
|
|
/* 27774 8004C374 0240202D */ daddu $a0, $s2, $zero
|
|
/* 27778 8004C378 0C0132EF */ jal func_8004CBBC
|
|
/* 2777C 8004C37C 0200282D */ daddu $a1, $s0, $zero
|
|
/* 27780 8004C380 8E040000 */ lw $a0, ($s0)
|
|
/* 27784 8004C384 90830000 */ lbu $v1, ($a0)
|
|
/* 27788 8004C388 24840001 */ addiu $a0, $a0, 1
|
|
/* 2778C 8004C38C AE040000 */ sw $a0, ($s0)
|
|
/* 27790 8004C390 3063007F */ andi $v1, $v1, 0x7f
|
|
/* 27794 8004C394 00031040 */ sll $v0, $v1, 1
|
|
/* 27798 8004C398 00431021 */ addu $v0, $v0, $v1
|
|
/* 2779C 8004C39C 000210C0 */ sll $v0, $v0, 3
|
|
/* 277A0 8004C3A0 00431821 */ addu $v1, $v0, $v1
|
|
/* 277A4 8004C3A4 90820000 */ lbu $v0, ($a0)
|
|
/* 277A8 8004C3A8 00033080 */ sll $a2, $v1, 2
|
|
/* 277AC 8004C3AC 3042000F */ andi $v0, $v0, 0xf
|
|
/* 277B0 8004C3B0 000210C0 */ sll $v0, $v0, 3
|
|
/* 277B4 8004C3B4 10400006 */ beqz $v0, .L8004C3D0
|
|
/* 277B8 8004C3B8 A20200A1 */ sb $v0, 0xa1($s0)
|
|
/* 277BC 8004C3BC 8E440060 */ lw $a0, 0x60($s2)
|
|
/* 277C0 8004C3C0 0C013436 */ jal func_8004D0D8
|
|
/* 277C4 8004C3C4 304500FF */ andi $a1, $v0, 0xff
|
|
/* 277C8 8004C3C8 080130F5 */ j .L8004C3D4
|
|
/* 277CC 8004C3CC 00021400 */ sll $v0, $v0, 0x10
|
|
.L8004C3D0:
|
|
/* 277D0 8004C3D0 00031480 */ sll $v0, $v1, 0x12
|
|
.L8004C3D4:
|
|
/* 277D4 8004C3D4 AE020060 */ sw $v0, 0x60($s0)
|
|
/* 277D8 8004C3D8 9202009A */ lbu $v0, 0x9a($s0)
|
|
/* 277DC 8004C3DC 30420010 */ andi $v0, $v0, 0x10
|
|
/* 277E0 8004C3E0 10400006 */ beqz $v0, .L8004C3FC
|
|
/* 277E4 8004C3E4 00000000 */ nop
|
|
/* 277E8 8004C3E8 8E02001C */ lw $v0, 0x1c($s0)
|
|
/* 277EC 8004C3EC 86030060 */ lh $v1, 0x60($s0)
|
|
/* 277F0 8004C3F0 9442001E */ lhu $v0, 0x1e($v0)
|
|
/* 277F4 8004C3F4 08013105 */ j .L8004C414
|
|
/* 277F8 8004C3F8 00623023 */ subu $a2, $v1, $v0
|
|
.L8004C3FC:
|
|
/* 277FC 8004C3FC 8E03001C */ lw $v1, 0x1c($s0)
|
|
/* 27800 8004C400 86020060 */ lh $v0, 0x60($s0)
|
|
/* 27804 8004C404 9463001E */ lhu $v1, 0x1e($v1)
|
|
/* 27808 8004C408 860400A4 */ lh $a0, 0xa4($s0)
|
|
/* 2780C 8004C40C 00431023 */ subu $v0, $v0, $v1
|
|
/* 27810 8004C410 00443021 */ addu $a2, $v0, $a0
|
|
.L8004C414:
|
|
/* 27814 8004C414 0C014D6A */ jal func_800535A8
|
|
/* 27818 8004C418 00C0202D */ daddu $a0, $a2, $zero
|
|
/* 2781C 8004C41C 8E02001C */ lw $v0, 0x1c($s0)
|
|
/* 27820 8004C420 C4420020 */ lwc1 $f2, 0x20($v0)
|
|
/* 27824 8004C424 46020002 */ mul.s $f0, $f0, $f2
|
|
/* 27828 8004C428 00000000 */ nop
|
|
/* 2782C 8004C42C E6000058 */ swc1 $f0, 0x58($s0)
|
|
/* 27830 8004C430 92230045 */ lbu $v1, 0x45($s1)
|
|
/* 27834 8004C434 924200BC */ lbu $v0, 0xbc($s2)
|
|
/* 27838 8004C438 0043102B */ sltu $v0, $v0, $v1
|
|
/* 2783C 8004C43C 54400026 */ bnel $v0, $zero, .L8004C4D8
|
|
/* 27840 8004C440 A20000A9 */ sb $zero, 0xa9($s0)
|
|
/* 27844 8004C444 0220202D */ daddu $a0, $s1, $zero
|
|
/* 27848 8004C448 0C014D4E */ jal func_80053538
|
|
/* 2784C 8004C44C 326500FF */ andi $a1, $s3, 0xff
|
|
/* 27850 8004C450 9202009A */ lbu $v0, 0x9a($s0)
|
|
/* 27854 8004C454 30420008 */ andi $v0, $v0, 8
|
|
/* 27858 8004C458 14400004 */ bnez $v0, .L8004C46C
|
|
/* 2785C 8004C45C 00000000 */ nop
|
|
/* 27860 8004C460 920200A8 */ lbu $v0, 0xa8($s0)
|
|
/* 27864 8004C464 54400003 */ bnel $v0, $zero, .L8004C474
|
|
/* 27868 8004C468 A222000E */ sb $v0, 0xe($s1)
|
|
.L8004C46C:
|
|
/* 2786C 8004C46C 9202009B */ lbu $v0, 0x9b($s0)
|
|
/* 27870 8004C470 A222000E */ sb $v0, 0xe($s1)
|
|
.L8004C474:
|
|
/* 27874 8004C474 0240202D */ daddu $a0, $s2, $zero
|
|
/* 27878 8004C478 9202009C */ lbu $v0, 0x9c($s0)
|
|
/* 2787C 8004C47C 0200282D */ daddu $a1, $s0, $zero
|
|
/* 27880 8004C480 0C01313D */ jal func_8004C4F4
|
|
/* 27884 8004C484 A222000F */ sb $v0, 0xf($s1)
|
|
/* 27888 8004C488 A6220040 */ sh $v0, 0x40($s1)
|
|
/* 2788C 8004C48C 8E020010 */ lw $v0, 0x10($s0)
|
|
/* 27890 8004C490 AE220014 */ sw $v0, 0x14($s1)
|
|
/* 27894 8004C494 8E020014 */ lw $v0, 0x14($s0)
|
|
/* 27898 8004C498 AE220018 */ sw $v0, 0x18($s1)
|
|
/* 2789C 8004C49C 8E02001C */ lw $v0, 0x1c($s0)
|
|
/* 278A0 8004C4A0 AE220000 */ sw $v0, ($s1)
|
|
/* 278A4 8004C4A4 C6000058 */ lwc1 $f0, 0x58($s0)
|
|
/* 278A8 8004C4A8 24020002 */ addiu $v0, $zero, 2
|
|
/* 278AC 8004C4AC A2220043 */ sb $v0, 0x43($s1)
|
|
/* 278B0 8004C4B0 E6200004 */ swc1 $f0, 4($s1)
|
|
/* 278B4 8004C4B4 924200BC */ lbu $v0, 0xbc($s2)
|
|
/* 278B8 8004C4B8 A2220045 */ sb $v0, 0x45($s1)
|
|
/* 278BC 8004C4BC A2220044 */ sb $v0, 0x44($s1)
|
|
/* 278C0 8004C4C0 924200BE */ lbu $v0, 0xbe($s2)
|
|
/* 278C4 8004C4C4 A2220010 */ sb $v0, 0x10($s1)
|
|
/* 278C8 8004C4C8 08013136 */ j .L8004C4D8
|
|
/* 278CC 8004C4CC A20000A9 */ sb $zero, 0xa9($s0)
|
|
.L8004C4D0:
|
|
/* 278D0 8004C4D0 A6000096 */ sh $zero, 0x96($s0)
|
|
/* 278D4 8004C4D4 A2000098 */ sb $zero, 0x98($s0)
|
|
.L8004C4D8:
|
|
/* 278D8 8004C4D8 8FBF0020 */ lw $ra, 0x20($sp)
|
|
/* 278DC 8004C4DC 8FB3001C */ lw $s3, 0x1c($sp)
|
|
/* 278E0 8004C4E0 8FB20018 */ lw $s2, 0x18($sp)
|
|
/* 278E4 8004C4E4 8FB10014 */ lw $s1, 0x14($sp)
|
|
/* 278E8 8004C4E8 8FB00010 */ lw $s0, 0x10($sp)
|
|
/* 278EC 8004C4EC 03E00008 */ jr $ra
|
|
/* 278F0 8004C4F0 27BD0028 */ addiu $sp, $sp, 0x28
|