papermario/ver/jp/asm/nonmatchings/41B70/func_80066770.s
Ethan Roseman 3315d6010f
Splat refactor (#257)
* 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>
2021-04-13 16:47:52 +09:00

59 lines
2.4 KiB
ArmAsm

.set noat # allow manual use of $at
.set noreorder # don't insert nops after branches
glabel func_80066770
/* 41B70 80066770 40085000 */ mfc0 $t0, $10
/* 41B74 80066774 40840000 */ mtc0 $a0, $0
/* 41B78 80066778 40852800 */ mtc0 $a1, $5
/* 41B7C 8006677C 8FA90014 */ lw $t1, 0x14($sp)
/* 41B80 80066780 2401FFFF */ addiu $at, $zero, -1
/* 41B84 80066784 11210004 */ beq $t1, $at, .L80066798
/* 41B88 80066788 240C0001 */ addiu $t4, $zero, 1
/* 41B8C 8006678C 240A001E */ addiu $t2, $zero, 0x1e
/* 41B90 80066790 10000002 */ b .L8006679C
/* 41B94 80066794 00C93025 */ or $a2, $a2, $t1
.L80066798:
/* 41B98 80066798 240A001F */ addiu $t2, $zero, 0x1f
.L8006679C:
/* 41B9C 8006679C 40865000 */ mtc0 $a2, $10
/* 41BA0 800667A0 2401FFFF */ addiu $at, $zero, -1
/* 41BA4 800667A4 10E10006 */ beq $a3, $at, .L800667C0
/* 41BA8 800667A8 00000000 */ nop
/* 41BAC 800667AC 00075982 */ srl $t3, $a3, 6
/* 41BB0 800667B0 016A5825 */ or $t3, $t3, $t2
/* 41BB4 800667B4 408B1000 */ mtc0 $t3, $2
/* 41BB8 800667B8 10000002 */ b .L800667C4
/* 41BBC 800667BC 00000000 */ nop
.L800667C0:
/* 41BC0 800667C0 408C1000 */ mtc0 $t4, $2
.L800667C4:
/* 41BC4 800667C4 8FAB0010 */ lw $t3, 0x10($sp)
/* 41BC8 800667C8 2401FFFF */ addiu $at, $zero, -1
/* 41BCC 800667CC 11610006 */ beq $t3, $at, .L800667E8
/* 41BD0 800667D0 00000000 */ nop
/* 41BD4 800667D4 000B5982 */ srl $t3, $t3, 6
/* 41BD8 800667D8 016A5825 */ or $t3, $t3, $t2
/* 41BDC 800667DC 408B1800 */ mtc0 $t3, $3
/* 41BE0 800667E0 10000007 */ b .L80066800
/* 41BE4 800667E4 00000000 */ nop
.L800667E8:
/* 41BE8 800667E8 408C1800 */ mtc0 $t4, $3
/* 41BEC 800667EC 2401FFFF */ addiu $at, $zero, -1
/* 41BF0 800667F0 14E10003 */ bne $a3, $at, .L80066800
/* 41BF4 800667F4 00000000 */ nop
/* 41BF8 800667F8 3C0B8000 */ lui $t3, 0x8000
/* 41BFC 800667FC 408B5000 */ mtc0 $t3, $10
.L80066800:
/* 41C00 80066800 00000000 */ nop
/* 41C04 80066804 42000002 */ tlbwi
/* 41C08 80066808 00000000 */ nop
/* 41C0C 8006680C 00000000 */ nop
/* 41C10 80066810 00000000 */ nop
/* 41C14 80066814 00000000 */ nop
/* 41C18 80066818 40885000 */ mtc0 $t0, $10
/* 41C1C 8006681C 03E00008 */ jr $ra
/* 41C20 80066820 00000000 */ nop
/* 41C24 80066824 00000000 */ nop
/* 41C28 80066828 00000000 */ nop
/* 41C2C 8006682C 00000000 */ nop