QoL update
This commit is contained in:
parent
6b0a889724
commit
7296ba2038
@ -245,6 +245,9 @@ function tidyPlayareaCoroutine()
|
||||
local trash = guidReferenceApi.getObjectByOwnerAndType("Mythos", "Trash")
|
||||
local playAreaZone = guidReferenceApi.getObjectByOwnerAndType("Mythos", "PlayAreaZone")
|
||||
|
||||
-- reset the playarea image by not providing an image
|
||||
playAreaApi.updateSurface()
|
||||
|
||||
if playAreaZone == nil then
|
||||
printToAll("Scripting zone for main play area could not be found!", "Red")
|
||||
elseif trash == nil then
|
||||
|
@ -20,7 +20,6 @@ ENCOUNTER_DECK_DISCARD_POSITION = { -3.85, 1, 10.38 }
|
||||
-- GUIDs that will not be interactable (e.g. parts of the table)
|
||||
local NOT_INTERACTABLE = {
|
||||
"6161b4", -- Decoration-Map
|
||||
"721ba2", -- PlayArea
|
||||
"9f334f", -- MythosArea
|
||||
"463022", -- Panel behind tentacle stand
|
||||
"f182ee", -- InvestigatorCount
|
||||
|
@ -61,6 +61,7 @@ function onSave()
|
||||
end
|
||||
|
||||
function onLoad(savedData)
|
||||
self.interactable = false -- this needs to be here since the playarea will be reloaded when the image changes
|
||||
local loadedData = JSON.decode(savedData) or {}
|
||||
locations = loadedData.trackedLocations or {}
|
||||
currentScenario = loadedData.currentScenario
|
||||
@ -84,10 +85,10 @@ function updateSurface(newURL)
|
||||
|
||||
if newURL ~= "" and newURL ~= nil and newURL ~= DEFAULT_URL then
|
||||
customInfo.image = newURL
|
||||
broadcastToAll("New Playmat Image Applied", { 0.2, 0.9, 0.2 })
|
||||
broadcastToAll("New Playarea Image Applied", { 0.2, 0.9, 0.2 })
|
||||
else
|
||||
customInfo.image = DEFAULT_URL
|
||||
broadcastToAll("Default Playmat Image Applied", { 0.2, 0.9, 0.2 })
|
||||
broadcastToAll("Default Playarea Image Applied", { 0.2, 0.9, 0.2 })
|
||||
end
|
||||
|
||||
self.setCustomObject(customInfo)
|
||||
|
Loading…
Reference in New Issue
Block a user