Merge pull request #951 from argonui/deck-import

Updated deck importer to skip removed mats
This commit is contained in:
dscarpac 2024-11-01 18:27:09 -05:00 committed by GitHub
commit 884ddc2b4e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -201,7 +201,8 @@ function loadDecksCoroutine()
if not allCardsBagApi.isIndexReady() then return end
matsWithInvestigator = playermatApi.getUsedMatColors()
for _, matColor in ipairs({ "White", "Orange", "Green", "Red" }) do
local matObjects = guidReferenceApi.getObjectsByType("Playermat")
for matColor, _ in pairs(matObjects) do
local deckId = _G[string.lower(matColor) .. "DeckId"]
if deckId ~= nil and deckId ~= "" then
buildDeck(matColor, deckId)