From 2050c457b7aaf14e0dc6e6b2b4793da1be6f828b Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Sat, 4 Jul 2020 13:39:01 -0300 Subject: Update some old, precarious code --- npc/config/location.txt | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'npc/config') diff --git a/npc/config/location.txt b/npc/config/location.txt index 5a069545b..04b2c84d7 100644 --- a/npc/config/location.txt +++ b/npc/config/location.txt @@ -18,3 +18,18 @@ OnInit: //debugmes "Locmaster: Index 5: %s [%s.gat (%d, %d)]", $@LOCMASTER_LOC$[5], $@LOCMASTER_MAP$[5], $@LOCMASTER_X[5], $@LOCMASTER_Y[5]; end; } + +// Resaves your respawn point +function script ResaveRespawn { + .@i=array_find($@LOCMASTER_LOC$, LOCATION$); + savepoint $@LOCMASTER_MAP$[.@i], $@LOCMASTER_X[.@i], $@LOCMASTER_Y[.@i]; + return; +} + +// Warps you to last visited town +function script ReturnTown { + .@i=array_find($@LOCMASTER_LOC$, LOCATION$); + warp $@LOCMASTER_MAP$[.@i], $@LOCMASTER_X[.@i], $@LOCMASTER_Y[.@i]; + return; +} + -- cgit v1.2.3-60-g2f50