My source of the fixed teleporter:
Spoiler for Hiden:
Hook: 80246A88
.set STORAGE, 0x80001650
.set BUTTON_MINUS, 0x1000
.set BUTTON_ONE, 0x200
.set BUTTON_ADDRESS, 0x8037A640
lis r12, STORAGE@ha
lis r10, BUTTON_ADDRESS@ha
lhz r10, BUTTON_ADDRESS@l (r10)
andi. r9, r10, BUTTON_MINUS
beq- _NOSTORE
lwz r11, 0 (r5)
stw r11, STORAGE@l (r12)
lwz r11, 8 (r5)
stw r11, STORAGE + 4@l (r12)
_NOSTORE:
andi. r9, r10, BUTTON_ONE
beq- _NOLOAD
lwz r11, STORAGE@l (r12)
stw r11, 0 (r5)
lwz r11, STORAGE + 4@l (r12)
stw r11, 8 (r5)
_NOLOAD:
lfs f0,8(r5)
Note that there are x y z coordinates but only x and z are actually used.
The height is always 0.
http://geckocodes.org/?c=RHAP01now with less code and more safety. lwz/stw use SIMM so offset needs @ha for initial lis
I'm also not too keen on using the 0x80000000-0x80001800 area for storage as it's not defined for such things. setting up variables in your .s would be better