diff --git a/src/accessories/CleanUpHelper.ttslua b/src/accessories/CleanUpHelper.ttslua index c452c7f3..b016bf36 100644 --- a/src/accessories/CleanUpHelper.ttslua +++ b/src/accessories/CleanUpHelper.ttslua @@ -5,7 +5,7 @@ Cleans up the table for the next scenario in a campaign: - use the IGNORE_TAG to exclude objects from tidying (default: "CleanUpHelper_Ignore") --]] -local playAreaApi = require("core/PlayAreaApi") +local tokenSpawnTracker = require("core/token/TokenSpawnTracker") -- enable this for debugging local SHOW_RAYS = false @@ -175,6 +175,7 @@ function cleanUp() removeBlessCurse() removeLines() discardHands() + TokenSpawnTracker.resetAll() printToAll("Tidying main play area...", "White") startLuaCoroutine(self, "tidyPlayareaCoroutine") @@ -231,7 +232,7 @@ end -- gets the GUID of a custom data helper (if present) and adds it to the ignore list function ignoreCustomDataHelper() local playArea = getObjectFromGUID("721ba2") - local guid = playArea.getVar("custom_data_helper_guid") + local guid = playArea.getVar("customDataHelper") if guid then table.insert(IGNORE_GUIDS, guid) end end @@ -321,8 +322,6 @@ function tidyPlayareaCoroutine() end end - playAreaApi.resetSpawnedCards() - printToAll("Tidying playermats and agenda mat...", "White") startLuaCoroutine(self, "tidyPlayerMatCoroutine") return 1