-
-
Save sp1187/e850b03c1da193ff418bdd813eb9829d to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.headersize 0x80245000 //configure RAM - ROM difference | |
.org 0x80252448 //RAM address | |
jal elevator | |
nop | |
.headersize 0x80283280 //switch section | |
.org 0x803843e0 //RAM address | |
elevator: | |
lui t1, 0x8036 | |
lw t1, 0x1158 (t1) //Mario object | |
lw t0, 0x0214 (t1) | |
beq t0, r0, @@skip | |
nop | |
lwc1 f2, 0x00b0 (t0) | |
lui t2, 0x8034 | |
lwc1 f4, 0xb1bc (t2) //Mario Y speed | |
mtc1 r0, f6 | |
c.lt.s f2, f6 | |
nop | |
bc1t @@skip | |
nop | |
add.s f4, f2, f4 | |
swc1 f4, 0xb1bc (t2) //Mario Y speed | |
lwc1 f18, 0xb1b0 (t2) //Mario Y position | |
add.s f18, f18, f2 | |
swc1 f18, 0xb1b0 (t2) //Mario Y position | |
@@skip: | |
jr ra | |
nop |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment