top of page
How to Set Custom Healing Place Coordinates
2.15
Description Loading...
Credits
Defa
How To
Go to free space and add the following anchor
^data.maps.heal.mapcoord[index. x. y.]1This adds a new table at data.maps.heal.mapcoord
index: set this field to the same number you use as argument for sethealingplace
x: x coordinate of the tile you want the player to be on
y: y coordinate of the tile you want the player to be on
You can use this table to override the default (hardcoded) coordinates for certain maps like the player's house, Indigo Plateau Pokémon Center, One Island Pokémon Center and any other Pokémon Center with the standard layout
Add this routine to free space and note the offset:
ldr r2, heal
sub r0, r6, #1
lsl r0, r0, #2
add r1, r0, r2
ldrh r1, [r1, #0]
strb r1, [r4, #0]
add r2, r2, #2
add r0, r0, r2
ldrh r2, [r0, #0]
strb r2, [r4, #1]
mov r0, #255
strb r0, [r4, #2]
ldr r0, respawn
loop:
ldrb r1, [r0] @index field
cmp r1, #255 @FF byte, table end
beq backvanilla
cmp r1, r6 @index from GetHealLocationIndexFromMapGroupAndNum
beq match
add r0, r0, #3 @next row
b loop
match:
ldrb r1, [r0, #1] @x field
strh r1, [r4, #4] @warp-x
ldrb r1, [r0, #2] @y field
strh r1, [r4, #6] @warp-y
ldr r0, =(0x080BFDF5) @back to after if-compare
bx r0
backvanilla:
ldrb r1, [r4]
ldrb r2, [r4, #1]
ldr r3, =(0x080BFD6D) @back to if-compare
bx r3
heal: .word <data.maps.heal.map>
respawn: .word <data.maps.heal.mapcoord>Go to 0BFD54 and change 00 48 00 47 49 01 40 09 to 00 48 00 47 XX XX XX 08
XX XX XX being the noted offset+1 in little endian
Happy Hacking!
bottom of page


