diff options
-rw-r--r-- | spritetex.yaml | 33 | ||||
-rw-r--r-- | src/spritetex.S | 63 |
2 files changed, 77 insertions, 19 deletions
diff --git a/spritetex.yaml b/spritetex.yaml index feeec7c..0981298 100644 --- a/spritetex.yaml +++ b/spritetex.yaml @@ -70,6 +70,13 @@ hooks: target_func: 'TEX_Buzzy'
+ - name: TEX_BuzzyShell
+ type: branch_insn
+ branch_type: bl
+ src_addr_pal: 0x80A67540
+ target_func: 'TEX_BuzzyShell'
+ + - name: TEX_SpikeTop
type: branch_insn
branch_type: bl
@@ -77,11 +84,18 @@ hooks: target_func: 'TEX_SpikeTop'
+# - name: TEX_SpinyShell
+# type: branch_insn
+# branch_type: bl
+# src_addr_pal: 0x8003DBF8
+# target_func: 'TEX_SpinyShell'
+ + - name: TEX_Spiny
type: branch_insn
branch_type: bl
- src_addr_pal: 0x80038208
- target_func: 'TEX_Spiny'
+ src_addr_pal: 0x8003DD0C
+ target_func: 'TEX_Spiny' - name: TEX_SpringBlock
@@ -105,10 +119,17 @@ hooks: target_func: 'TEX_Koopa'
+ - name: TEX_KoopaShell
+ type: branch_insn
+ branch_type: bl
+ src_addr_pal: 0x80A72644
+ target_func: 'TEX_Koopa'
+ + - name: TEX_Gabon
type: branch_insn
branch_type: bl
- src_addr_pal: 0x80A00284
+ src_addr_pal: 0x80A00290
target_func: 'TEX_Gabon'
@@ -122,14 +143,14 @@ hooks: - name: TEX_Switch
type: branch_insn
branch_type: bl
- src_addr_pal: 0x80A19EC8
+ src_addr_pal: 0x80A19ED4
target_func: 'TEX_Switch'
- name: TEX_WiggleShroom
type: branch_insn
branch_type: bl
- src_addr_pal: 0x800BC9D8
+ src_addr_pal: 0x800BC9D8 target_func: 'TEX_WiggleShroom'
@@ -164,7 +185,7 @@ hooks: - name: TEX_Parabeetle
type: branch_insn
branch_type: bl
- src_addr_pal: 0x80A83254
+ src_addr_pal: 0x80A83260
target_func: 'TEX_Parabeetle'
diff --git a/src/spritetex.S b/src/spritetex.S index 504cf5f..920036c 100644 --- a/src/spritetex.S +++ b/src/spritetex.S @@ -121,6 +121,13 @@ TEX_Buzzy: andi. r5, r5, 0xF
b GetTexFilenameForR5
+.global TEX_BuzzyShell
+TEX_BuzzyShell:
+ lwz r5, 4(r3)
+ srwi r5, r5, 24
+ andi. r5, r5, 0xF
+ b GetTexFilenameForR5
+
.global TEX_SpikeTop
TEX_SpikeTop:
@@ -132,7 +139,15 @@ TEX_SpikeTop: .global TEX_Spiny
TEX_Spiny:
- lwz r5, 4(r27)
+ lwz r5, 4(r30)
+ srwi r5, r5, 24
+ andi. r5, r5, 0xF
+ b GetTexFilenameForR5
+ + +.global TEX_SpinyShell
+TEX_SpinyShell:
+ lwz r5, 4(r3)
srwi r5, r5, 24
andi. r5, r5, 0xF
b GetTexFilenameForR5
@@ -156,14 +171,9 @@ TEX_Coaster: .global TEX_Koopa
TEX_Koopa:
-<<<<<<< HEAD lwz r5, 4(r29)
srwi r5, r5, 24
andi. r5, r5, 0xF -======= - lwz r5, 4(r30)
- andi. r5, r5, 0xF
->>>>>>> 6e93a3612c2d4ce6e11ab53d2490eb30c0e262bf b GetTexFilenameForR5
@@ -193,12 +203,43 @@ TEX_Switch: .global TEX_WiggleShroom
TEX_WiggleShroom:
- lwz r5, 4(r30)
- # This could be r29, or r28 + lwz r5, 4(r4)
+ # This sprite is pretty complex + # The register with THIS is r29 + # before the loading function, + # it passes it into r3, and then mr's + # it into r30. r3 is then overwritten. + # Then, it puts r31 into r5, r30 partly + # into r3 and partly into r4. Why? + # So, the possibilities for THIS are + # r30, r3, and r4, no? In the next function, + # r30 is stored over before our getFile, as + # are r29/r28. + srwi r5, r5, 24
andi. r5, r5, 0xF
b GetTexFilenameForR5
+ lwz r5, 4(r3)
+ srwi r5, r5, 24
+ andi. r5, r5, 0xF
+ b GetTexFilenameForR5
+ + lwz r5, 4(r29)
+ srwi r5, r5, 24
+ andi. r5, r5, 0xF
+ b GetTexFilenameForR5
+ + lwz r5, 4(r30)
+ srwi r5, r5, 24
+ andi. r5, r5, 0xF
+ b GetTexFilenameForR5
+ + lwz r5, 4(r31)
+ srwi r5, r5, 24
+ andi. r5, r5, 0xF
+ b GetTexFilenameForR5
+ .global TEX_Bramball
TEX_Bramball:
@@ -292,11 +333,7 @@ TEX_Boo: TEX_Midway:
lwz r5, 4(r29)
srwi r5, r5, 24
-<<<<<<< HEAD andi. r5, r5, 0xFF -======= - andi. r5, r5, 0xF
->>>>>>> 6e93a3612c2d4ce6e11ab53d2490eb30c0e262bf b GetTexFilenameForR5
@@ -310,7 +347,7 @@ TEX_Goal: .global TEX_StretchMush
TEX_StretchMush:
- lwz r5, 4(r30)
+ lwz r5, 4(r27)
srwi r5, r5, 24
andi. r5, r5, 0xF b GetTexFilenameForR5
|