From 7296ba2038a76b14ebcf8fed0efcc6fe573f75e9 Mon Sep 17 00:00:00 2001 From: Chr1Z93 Date: Sun, 31 Dec 2023 13:32:44 +0100 Subject: [PATCH 1/3] QoL update --- src/accessories/CleanUpHelper.ttslua | 3 +++ src/core/Global.ttslua | 1 - src/core/PlayArea.ttslua | 5 +++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/accessories/CleanUpHelper.ttslua b/src/accessories/CleanUpHelper.ttslua index 9c146992..022f9e2b 100644 --- a/src/accessories/CleanUpHelper.ttslua +++ b/src/accessories/CleanUpHelper.ttslua @@ -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 diff --git a/src/core/Global.ttslua b/src/core/Global.ttslua index 6ab57fbf..4313748c 100644 --- a/src/core/Global.ttslua +++ b/src/core/Global.ttslua @@ -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 diff --git a/src/core/PlayArea.ttslua b/src/core/PlayArea.ttslua index 1e3b67fa..dbd5781e 100644 --- a/src/core/PlayArea.ttslua +++ b/src/core/PlayArea.ttslua @@ -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) From 20a24eb12c9efc5461729c490807de45039fb1ec Mon Sep 17 00:00:00 2001 From: Chr1Z93 Date: Sun, 31 Dec 2023 13:41:53 +0100 Subject: [PATCH 2/3] fixed wrong bracket placement --- src/core/GameKeyHandler.ttslua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/core/GameKeyHandler.ttslua b/src/core/GameKeyHandler.ttslua index 6766a828..83e719b0 100644 --- a/src/core/GameKeyHandler.ttslua +++ b/src/core/GameKeyHandler.ttslua @@ -70,7 +70,7 @@ function discardObject(playerColor, hoveredObject) -- discard tokens / tiles on cards / decks if hoveredObject.type ~= "Tile" then - for _, obj in ipairs(searchLib.onObject(hoveredObject), "isTileOrToken") do + for _, obj in ipairs(searchLib.onObject(hoveredObject, "isTileOrToken")) do table.insert(discardTheseObjects, obj) end end From 40d07d5864cbd07d2146cc7ed60e3409ebd00c9e Mon Sep 17 00:00:00 2001 From: Chr1Z93 Date: Mon, 1 Jan 2024 11:53:42 +0100 Subject: [PATCH 3/3] rehosted obj file from pastebin --- objects/OfficialStandaloneChallengeScenarios.0ef5c8.json | 2 +- objects/ReturntoTheCircleUndone.757324.json | 2 +- objects/ReturntoTheDunwichLegacy.ce9130.json | 2 +- objects/ReturntoTheForgottenAge.479ff3.json | 2 +- objects/ReturntoThePathtoCarcosa.e9889a.json | 2 +- objects/ReturntotheNightoftheZealot.56270d.json | 2 +- src/core/Global.ttslua | 2 +- 7 files changed, 7 insertions(+), 7 deletions(-) diff --git a/objects/OfficialStandaloneChallengeScenarios.0ef5c8.json b/objects/OfficialStandaloneChallengeScenarios.0ef5c8.json index 24a3cf87..a2bc84c9 100644 --- a/objects/OfficialStandaloneChallengeScenarios.0ef5c8.json +++ b/objects/OfficialStandaloneChallengeScenarios.0ef5c8.json @@ -34,7 +34,7 @@ }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/1758068588410895356/0B5F0CCD29DEC12514840D7B9CD2329B635A79A6/", "MaterialIndex": 3, - "MeshURL": "http://pastebin.com/raw.php?i=uWAmuNZ2", + "MeshURL": "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/", "NormalURL": "", "TypeIndex": 6 }, diff --git a/objects/ReturntoTheCircleUndone.757324.json b/objects/ReturntoTheCircleUndone.757324.json index a851cdd1..68b75164 100644 --- a/objects/ReturntoTheCircleUndone.757324.json +++ b/objects/ReturntoTheCircleUndone.757324.json @@ -27,7 +27,7 @@ }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/1697277388086852852/6FD56D74FDDDA5626A3B72E788993EC651AD25E1/", "MaterialIndex": 3, - "MeshURL": "http://pastebin.com/raw.php?i=uWAmuNZ2", + "MeshURL": "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/", "NormalURL": "", "TypeIndex": 0 }, diff --git a/objects/ReturntoTheDunwichLegacy.ce9130.json b/objects/ReturntoTheDunwichLegacy.ce9130.json index a7b19102..c84c7206 100644 --- a/objects/ReturntoTheDunwichLegacy.ce9130.json +++ b/objects/ReturntoTheDunwichLegacy.ce9130.json @@ -27,7 +27,7 @@ }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/762723517667592476/36D86649503A49A36AA97B7B72C6150E4C2BE333/", "MaterialIndex": 3, - "MeshURL": "http://pastebin.com/raw.php?i=uWAmuNZ2", + "MeshURL": "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/", "NormalURL": "", "TypeIndex": 0 }, diff --git a/objects/ReturntoTheForgottenAge.479ff3.json b/objects/ReturntoTheForgottenAge.479ff3.json index 2a8144c0..68dfae46 100644 --- a/objects/ReturntoTheForgottenAge.479ff3.json +++ b/objects/ReturntoTheForgottenAge.479ff3.json @@ -27,7 +27,7 @@ }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/1474319121423613924/490D56D20C6AE0547D67D942513396E8D0584A4A/", "MaterialIndex": 3, - "MeshURL": "http://pastebin.com/raw.php?i=uWAmuNZ2", + "MeshURL": "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/", "NormalURL": "", "TypeIndex": 0 }, diff --git a/objects/ReturntoThePathtoCarcosa.e9889a.json b/objects/ReturntoThePathtoCarcosa.e9889a.json index d01aa6e3..6a78c62d 100644 --- a/objects/ReturntoThePathtoCarcosa.e9889a.json +++ b/objects/ReturntoThePathtoCarcosa.e9889a.json @@ -27,7 +27,7 @@ }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/762723517667556656/9638E8CE7F209B50634B202C9EF4B0BDB4993BBB/", "MaterialIndex": 3, - "MeshURL": "http://pastebin.com/raw.php?i=uWAmuNZ2", + "MeshURL": "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/", "NormalURL": "", "TypeIndex": 0 }, diff --git a/objects/ReturntotheNightoftheZealot.56270d.json b/objects/ReturntotheNightoftheZealot.56270d.json index 99fbed35..01368121 100644 --- a/objects/ReturntotheNightoftheZealot.56270d.json +++ b/objects/ReturntotheNightoftheZealot.56270d.json @@ -27,7 +27,7 @@ }, "DiffuseURL": "http://cloud-3.steamusercontent.com/ugc/762723517667598054/18C06F0F20D9D4651E6736FB609E2D41F4D1964E/", "MaterialIndex": 3, - "MeshURL": "http://pastebin.com/raw.php?i=uWAmuNZ2", + "MeshURL": "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/", "NormalURL": "", "TypeIndex": 0 }, diff --git a/src/core/Global.ttslua b/src/core/Global.ttslua index 6ab57fbf..c4621e1e 100644 --- a/src/core/Global.ttslua +++ b/src/core/Global.ttslua @@ -834,7 +834,7 @@ function onClick_spawnPlaceholder() local meshTable = { big = "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/core_h_MSH.obj", small = "https://raw.githubusercontent.com/RobMayer/TTSLibrary/master/advboxes/tuckbox_h_MSH.obj", - wide = "http://pastebin.com/raw.php?i=uWAmuNZ2" + wide = "http://cloud-3.steamusercontent.com/ugc/2278324073260846176/33EFCAF30567F8756F665BE5A2A6502E9C61C7F7/" } local scaleTable = {