I am trying to separate my game into regions. I followed instructions here
https://docs.textadventures.co.uk/quest/showing_a_map.html
and used
set (player, "saved_map_for_" + from.name, player.grid_coordinates)
if (HasAttribute(player, "saved_map_for_" + to.name)) {
player.grid_coordinates = GetAttribute(player, "saved_map_for_" + to.name)
}
else {
player.grid_coordinates = null
}
player.parent = to
JS.Grid_ClearAllLayers ()
Grid_Redraw
Grid_DrawPlayerInRoom (game.pov.parent)
For purposes, let's say the 3 regions are one-room regions, which are: town, quarry and forest. In the town, I have a sign with a verb "Travel to" that, when used does this
options = Split("The forest's center.;The caves.;Nevermind.", ";")
ShowMenu ("Where do you travel to?", options, true) {
switch (result) {
case ("The forest's center.") {
TeleportTo (Forest_Clearing)
}
case ("The caves.") {
TeleportTo (Quarry)
}
case ("Nevermind.") {
}
}
}
In the town and quarry, there is one object that takes them back to the town.
The problem is that when returning for a region, there is a 1x1 blank room loaded in.
https://cdn.discordapp.com/attachments/721434407155662848/1152046166750539846/image.png
(Also sometimes it feels like the map bugs out and the player icon [yellow dot] keeps in one room even if you keep moving around, but I couldn't recreate it this time.)