summaryrefslogtreecommitdiff
path: root/src/poweruphax.S
diff options
context:
space:
mode:
Diffstat (limited to 'src/poweruphax.S')
-rw-r--r--src/poweruphax.S99
1 files changed, 97 insertions, 2 deletions
diff --git a/src/poweruphax.S b/src/poweruphax.S
index 7181b4d..43480c3 100644
--- a/src/poweruphax.S
+++ b/src/poweruphax.S
@@ -691,11 +691,11 @@ AcPyDtorHS:
mr r30, r3
cmpwi r3, 0
- beq oops
+ beq oops2
lwz r3, 0x2D08(r30)
li r4, 1
bl __dt__21dHammerSuitRenderer_cFv
-oops:
+oops2:
mr r3, r30
mr r4, r31
@@ -737,11 +737,106 @@ AcPyDrawHS:
addi r1, r1, 0x10
blr
+
+
+# DO IT AGAIN
+.global Wm2dPlayerCtorHS
+Wm2dPlayerCtorHS:
+ stwu r1, -0x10(r1)
+ mflr r0
+ stw r0, 0x14(r1)
+ stw r31, 0xC(r1)
+ mr r31, r3
+
+ bl build__21dHammerSuitRenderer_cFv
+ stw r3, 0x384(r31)
+
+ mr r3, r31
+ lwz r31, 0xC(r1)
+ lwz r0, 0x14(r1)
+ mtlr r0
+ addi r1, r1, 0x10
+ blr
+
+.global Wm2dPlayerDtorHS
+Wm2dPlayerDtorHS:
+ stwu r1, -0x10(r1)
+ mflr r0
+ stw r0, 0x14(r1)
+ stw r31, 0xC(r1)
+ stw r30, 8(r1)
+
+ mr r31, r4
+ mr r30, r3
+
+ cmpwi r3, 0
+ beq oops
+ lwz r3, 0x384(r30)
+ li r4, 1
+ bl __dt__21dHammerSuitRenderer_cFv
+oops:
+
+ mr r3, r30
+ mr r4, r31
+ bl RealWm2dPlayerDtor
+
+ lwz r30, 8(r1)
+ lwz r31, 0xC(r1)
+ lwz r0, 0x14(r1)
+ mtlr r0
+ addi r1, r1, 0x10
+ blr
+
+.global Wm2dPlayerSetMeUpHS
+Wm2dPlayerSetMeUpHS:
+ # partway in: r27 = this
+ lwz r3, 0x384(r27)
+ lwz r4, 0x128(r27)
+ li r5, 1
+ bl setup__21dHammerSuitRenderer_cFP21dPlayerModelHandler_ci
+
+ # epilogue
+ addi r11, r1, 0x20
+ bl _restgpr_27
+ lwz r0, 0x24(r1)
+ mtlr r0
+ addi r1, r1, 0x20
+ blr
+
+.global Wm2dPlayerDrawHS
+Wm2dPlayerDrawHS:
+ # dicks (a very insightful comment)
+ lbz r0, 0x261(r3)
+ cmpwi r0, 0
+ beqlr
+
+ stwu r1, -0x10(r1)
+ mflr r0
+ stw r0, 0x14(r1)
+ stw r31, 0xC(r1)
+ mr r31, r3
+
+ lwz r3, 0x384(r31)
+ bl draw__21dHammerSuitRenderer_cFv
+
+ lwz r3, 0x128(r31)
+ bl draw__21dPlayerModelHandler_cFv
+
+ lwz r0, 0x14(r1)
+ lwz r31, 0xC(r1)
+ mtlr r0
+ addi r1, r1, 0x10
+ blr
+
+.extern _restgpr_27
.extern RealAcPyDtor
+.extern RealWm2dPlayerDtor
.extern build__21dHammerSuitRenderer_cFv
.extern __dt__21dHammerSuitRenderer_cFv
+.extern setup__21dHammerSuitRenderer_cFP21dPlayerModelHandler_ci
.extern setup__21dHammerSuitRenderer_cFP21dPlayerModelHandler_c
.extern draw__21dHammerSuitRenderer_cFv
+.extern draw__21dPlayerModelHandler_cFv
.data