Merge pull request #38 from argonui/fortuneandfolly_fix

adding missing information for FaF
This commit is contained in:
Buhallin 2022-11-15 16:25:54 -08:00 committed by GitHub
commit 990871646e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 111 additions and 110 deletions

View File

@ -21,7 +21,8 @@
"TheBlobthatAteEverything.4dee5a", "TheBlobthatAteEverything.4dee5a",
"CurseoftheRougarou.db7039", "CurseoftheRougarou.db7039",
"GuardiansoftheAbyss.ee987d", "GuardiansoftheAbyss.ee987d",
"WaroftheOuterGods.fc7674" "WaroftheOuterGods.fc7674",
"FortuneandFolly.0dce91"
], ],
"ContainedObjects_path": "StandaloneScenarios.77a5f9", "ContainedObjects_path": "StandaloneScenarios.77a5f9",
"CustomMesh": { "CustomMesh": {

View File

@ -7,14 +7,11 @@ function log(message)
end end
end end
--[[ --[[ Known locations and clues. We check this to determine if we should atttempt to spawn clues,
Known locations and clues. We check this to determine if we should first we look for <LOCATION_NAME>_<GUID> and if we find nothing we look for <LOCATION_NAME>
atttempt to spawn clues, first we look for <LOCATION_NAME>_<GUID> and if format is [location_guid -> clueCount] ]]
we find nothing we look for <LOCATION_NAME> LOCATIONS_DATA = JSON.decode(
format is [location_guid -> clueCount] [[{
]]
LOCATIONS_DATA_JSON = [[
{
"Study": {"type": "perPlayer", "value": 2, "clueSide": "back"}, "Study": {"type": "perPlayer", "value": 2, "clueSide": "back"},
"Study_670914": {"type": "perPlayer", "value": 1, "clueSide": "back"}, "Study_670914": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Attic_377b20": {"type": "perPlayer", "value": 1, "clueSide": "back"}, "Attic_377b20": {"type": "perPlayer", "value": 1, "clueSide": "back"},
@ -712,15 +709,28 @@ LOCATIONS_DATA_JSON = [[
"Ye Olde Magick Shoppe": {"type": "perPlayer", "value": 1, "clueSide": "back"}, "Ye Olde Magick Shoppe": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Corrigan Industries": {"type": "perPlayer", "value": 1, "clueSide": "back"}, "Corrigan Industries": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Counting Room": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Guard Room": {"type": "perPlayer", "value": 2, "clueSide": "back"},
"Relic Room": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Security Office_b2d198": {"type": "perPlayer", "value": 2, "clueSide": "back"},
"Owner's Office": {"type": "perPlayer", "value": 3, "clueSide": "back"},
"High Roller's Table_226c6a": {"type": "perPlayer", "value": 2, "clueSide": "back"},
"High Roller's Table_804dbc": {"type": "perPlayer", "value": 2, "clueSide": "front"},
"Casino Lounge_169f16": {"type": "perPlayer", "value": 2, "clueSide": "back"},
"Casino Lounge_4af4eb": {"type": "perPlayer", "value": 2, "clueSide": "front"},
"Roulette Wheel": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Slot Machines": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Poker Table": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"Baccarat Table": {"type": "perPlayer", "value": 1, "clueSide": "back"},
"XXXX": {"type": "fixed", "value": 2, "clueSide": "back"}, "XXXX": {"type": "fixed", "value": 2, "clueSide": "back"},
"xxx": {"type": "perPlayer", "value": 2, "clueSide": "back"} "xxx": {"type": "perPlayer", "value": 2, "clueSide": "back"}
} }]]
]] )
--[[
Player cards with token counts and types -- Player cards with token counts and types
]] PLAYER_CARD_DATA = JSON.decode(
PLAYER_CARD_DATA_JSON = [[ [[{
{
"xxx": { "xxx": {
"tokenType": "resource", "tokenType": "resource",
"tokenCount": 3 "tokenCount": 3
@ -730,8 +740,8 @@ PLAYER_CARD_DATA_JSON = [[
"tokenType": "resource", "tokenType": "resource",
"tokenCount": 3 "tokenCount": 3
} }
} }]]
]] )
-- Encounter Cards with Hidden. -- Encounter Cards with Hidden.
HIDDEN_CARD_DATA = { HIDDEN_CARD_DATA = {
@ -766,88 +776,84 @@ HIDDEN_CARD_DATA = {
"Whispering Chaos (West)" "Whispering Chaos (West)"
} }
LOCATIONS_DATA = JSON.decode(LOCATIONS_DATA_JSON)
PLAYER_CARD_DATA = JSON.decode(PLAYER_CARD_DATA_JSON)
PLAYER_CARD_TOKEN_OFFSETS = { PLAYER_CARD_TOKEN_OFFSETS = {
[1] = { [1] = {
{ 0, 3, -0.2 }, { 0, 3, -0.2 }
}, },
[2] = { [2] = {
{ 0.4, 3, -0.2 }, { 0.4, 3, -0.2 },
{ -0.4, 3, -0.2 }, { -0.4, 3, -0.2 }
}, },
[3] = { [3] = {
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ 0.4, 3, -0.2 }, { 0.4, 3, -0.2 },
{ -0.4, 3, -0.2 }, { -0.4, 3, -0.2 }
}, },
[4] = { [4] = {
{ 0.4, 3, -0.9 }, { 0.4, 3, -0.9 },
{ -0.4, 3, -0.9 }, { -0.4, 3, -0.9 },
{ 0.4, 3, -0.2 }, { 0.4, 3, -0.2 },
{ -0.4, 3, -0.2 } { -0.4, 3, -0.2 }
}, },
[5] = { [5] = {
{ 0.7, 3, -0.9 }, { 0.7, 3, -0.9 },
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ -0.7, 3, -0.9 }, { -0.7, 3, -0.9 },
{ 0.4, 3, -0.2 }, { 0.4, 3, -0.2 },
{ -0.4, 3, -0.2 } { -0.4, 3, -0.2 }
}, },
[6] = { [6] = {
{ 0.7, 3, -0.9 }, { 0.7, 3, -0.9 },
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ -0.7, 3, -0.9 }, { -0.7, 3, -0.9 },
{ 0.7, 3, -0.2 }, { 0.7, 3, -0.2 },
{ 0, 3, -0.2 }, { 0, 3, -0.2 },
{ -0.7, 3, -0.2 }, { -0.7, 3, -0.2 }
}, },
[7] = { [7] = {
{ 0.7, 3, -0.9 }, { 0.7, 3, -0.9 },
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ -0.7, 3, -0.9 }, { -0.7, 3, -0.9 },
{ 0.7, 3, -0.2 }, { 0.7, 3, -0.2 },
{ 0, 3, -0.2 }, { 0, 3, -0.2 },
{ -0.7, 3, -0.2 }, { -0.7, 3, -0.2 },
{ 0, 3, 0.5 }, { 0, 3, 0.5 }
}, },
[8] = { [8] = {
{ 0.7, 3, -0.9 }, { 0.7, 3, -0.9 },
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ -0.7, 3, -0.9 }, { -0.7, 3, -0.9 },
{ 0.7, 3, -0.2 }, { 0.7, 3, -0.2 },
{ 0, 3, -0.2 }, { 0, 3, -0.2 },
{ -0.7, 3, -0.2 }, { -0.7, 3, -0.2 },
{ -0.35, 3, 0.5 }, { -0.35, 3, 0.5 },
{ 0.35, 3, 0.5 }, { 0.35, 3, 0.5 }
}, },
[9] = { [9] = {
{ 0.7, 3, -0.9 }, { 0.7, 3, -0.9 },
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ -0.7, 3, -0.9 }, { -0.7, 3, -0.9 },
{ 0.7, 3, -0.2 }, { 0.7, 3, -0.2 },
{ 0, 3, -0.2 }, { 0, 3, -0.2 },
{ -0.7, 3, -0.2 }, { -0.7, 3, -0.2 },
{ 0.7, 3, 0.5 }, { 0.7, 3, 0.5 },
{ 0, 3, 0.5 }, { 0, 3, 0.5 },
{ -0.7, 3, 0.5 }, { -0.7, 3, 0.5 }
}, },
[12] = { [12] = {
{ 0.7, 3, -0.9 }, { 0.7, 3, -0.9 },
{ 0, 3, -0.9 }, { 0, 3, -0.9 },
{ -0.7, 3, -0.9 }, { -0.7, 3, -0.9 },
{ 0.7, 3, -0.2 }, { 0.7, 3, -0.2 },
{ 0, 3, -0.2 }, { 0, 3, -0.2 },
{ -0.7, 3, -0.2 }, { -0.7, 3, -0.2 },
{ 0.7, 3, 0.5 }, { 0.7, 3, 0.5 },
{ 0, 3, 0.5 }, { 0, 3, 0.5 },
{ -0.7, 3, 0.5 }, { -0.7, 3, 0.5 },
{ 0.7, 3, 1.2 }, { 0.7, 3, 1.2 },
{ 0, 3, 1.2 }, { 0, 3, 1.2 },
{ -0.7, 3, 1.2 }, { -0.7, 3, 1.2 }
} }
} }
modeData = { modeData = {
@ -863,8 +869,8 @@ modeData = {
hard = { parent = 'Core Set', append = { 'elder' }, message = 'An additional token for the preparation of this scenario has been added to the bag.' }, hard = { parent = 'Core Set', append = { 'elder' }, message = 'An additional token for the preparation of this scenario has been added to the bag.' },
expert = { parent = 'Core Set', append = { 'elder' }, message = 'An additional token for the preparation of this scenario has been added to the bag.' } expert = { parent = 'Core Set', append = { 'elder' }, message = 'An additional token for the preparation of this scenario has been added to the bag.' }
}, },
-----------------The Dunwich Legacy
-----------------The Dunwich Legacy
['The Dunwich Legacy'] = { ['The Dunwich Legacy'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'red', 'blue' } },
@ -889,8 +895,8 @@ modeData = {
['Lost in Time and Space'] = { ['Lost in Time and Space'] = {
standalone = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } } standalone = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
-----------------The Path to Carcosa
-----------------The Path to Carcosa
['The Path to Carcosa'] = { ['The Path to Carcosa'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'skull', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'skull', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'skull', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'skull', 'red', 'blue' } },
@ -918,8 +924,8 @@ modeData = {
['Dim Carcosa'] = { ['Dim Carcosa'] = {
standalone = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'skull', 'red', 'blue' } } standalone = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'skull', 'red', 'blue' } }
}, },
-----------------The Forgotten Age
-----------------The Forgotten Age
['The Forgotten Age'] = { ['The Forgotten Age'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm2', 'm3', 'skull', 'skull', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm2', 'm3', 'skull', 'skull', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', '0', 'm1', 'm2', 'm2', 'm3', 'm5', 'skull', 'skull', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', '0', 'm1', 'm2', 'm2', 'm3', 'm5', 'skull', 'skull', 'elder', 'red', 'blue' } },
@ -949,7 +955,6 @@ modeData = {
}, },
-----------------The Circle Undone -----------------The Circle Undone
['The Circle Undone'] = { ['The Circle Undone'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm2', 'm3', 'skull', 'skull', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm2', 'm3', 'skull', 'skull', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'red', 'blue' } },
@ -978,9 +983,7 @@ modeData = {
standalone = { token = { 'p1', '0', '0', 'm1','m1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } } standalone = { token = { 'p1', '0', '0', 'm1','m1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
-----------------The Dream-Eaters -----------------The Dream-Eaters
['TDE_A'] = { ['TDE_A'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm2', 'm2', 'cultist', 'tablet', 'tablet', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm2', 'm2', 'cultist', 'tablet', 'tablet', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'cultist', 'tablet', 'tablet', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'cultist', 'tablet', 'tablet', 'red', 'blue' } },
@ -1012,7 +1015,6 @@ modeData = {
standalone = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'skull', 'cultist', 'elder', 'elder', 'red', 'blue' } } standalone = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'skull', 'cultist', 'elder', 'elder', 'red', 'blue' } }
}, },
-----------------The Innsmouth Conspiracy -----------------The Innsmouth Conspiracy
['The Innsmouth Conspiracy'] = { ['The Innsmouth Conspiracy'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'tablet', 'elder', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'tablet', 'elder', 'elder', 'red', 'blue' } },
@ -1031,7 +1033,6 @@ modeData = {
hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm4', 'm5', 'frost', 'frost', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } }, hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm4', 'm5', 'frost', 'frost', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm2', 'm2', 'm3', 'm4', 'm4', 'm5', 'm7', 'frost', 'frost', 'frost', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm2', 'm2', 'm3', 'm4', 'm4', 'm5', 'm7', 'frost', 'frost', 'frost', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } }
}, },
['City of the Elder Things'] = { ['City of the Elder Things'] = {
easy = { token = { 'p1', 'p1', 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'frost', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'frost', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
@ -1073,48 +1074,46 @@ modeData = {
hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
['Meowlathotep'] = { ['Meowlathotep'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
hard = { token = { '0', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, hard = { token = { '0', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm4', 'm5', 'm6', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm4', 'm5', 'm6', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
['WotOG'] = { ['WotOG'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'skull', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'skull', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'skull', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'skull', 'red', 'blue' } },
hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'skull', 'red', 'blue' } }, hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'skull', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'skull', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'skull', 'red', 'blue' } }
}, },
['Bad Blood'] = { ['Bad Blood'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
['Machinations'] = { ['Machinations'] = {
easy = { token = { 'p1', 'p1', 'p1', '0', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', 'p1', '0', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
hard = { token = { '0', '0', 'm1', 'm1', 'm1', 'm2', 'm3', 'm4', 'm6', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'elder', 'red', 'blue' } }, hard = { token = { '0', '0', 'm1', 'm1', 'm1', 'm2', 'm3', 'm4', 'm6', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'elder', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'elder', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'elder', 'red', 'blue' } }
}, },
['Red Tide'] = { ['Red Tide'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'm5', 'm6', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm2', 'm3', 'm4', 'm5', 'm6', 'm7', 'm8', 'skull', 'skull', 'cultist', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
['FaF'] = {
normal = { token = { 'p1', '0', '0', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
hard = { token = { '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm6', 'm7', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
},
--fan-made --fan-made
['Carnevale of Spiders'] = { ['Carnevale of Spiders'] = {
normal = { token = { 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm3', 'm4', 'm6', 'skull', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm3', 'm4', 'm6', 'skull', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
hard = { token = { 'p1', '0', '0', '0', 'm1', 'm1', 'm3', 'm4', 'm5', 'm6', 'm7', 'skull', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } } hard = { token = { 'p1', '0', '0', '0', 'm1', 'm1', 'm3', 'm4', 'm5', 'm6', 'm7', 'skull', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }
}, },
['The Nephew Calls'] = { ['The Nephew Calls'] = {
easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, easy = { token = { 'p1', 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
normal = { token = { 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'elder', 'red', 'blue' } },
@ -1329,41 +1328,42 @@ modeData = {
normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } }, normal = { token = { 'p1', '0', '0', 'm1', 'm1', 'm1', 'm2', 'm2', 'm3', 'm4', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } },
hard = { token = { '0', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } }, hard = { token = { '0', '0', '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm5', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } },
expert = { token = { '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm4', 'm5', 'm6', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } } expert = { token = { '0', 'm1', 'm1', 'm2', 'm2', 'm3', 'm3', 'm4', 'm4', 'm5', 'm6', 'm8', 'skull', 'skull', 'cultist', 'tablet', 'red', 'blue' } }
}, }
} }
function onSave() function onSave()
local globalState = JSON.encode(SPAWNED_PLAYER_CARD_GUIDS) local globalState = JSON.encode(SPAWNED_PLAYER_CARD_GUIDS)
log('saving global state: ' .. globalState) log('saving global state: ' .. globalState)
self.script_state = globalState return globalState
end end
function onload(save_state) function onLoad(save_state)
if save_state ~= '' then if save_state ~= '' then
log('loading global state: ' .. save_state) log('loading global state: ' .. save_state)
SPAWNED_PLAYER_CARD_GUIDS = JSON.decode(save_state) SPAWNED_PLAYER_CARD_GUIDS = JSON.decode(save_state)
else else
SPAWNED_PLAYER_CARD_GUIDS = {} SPAWNED_PLAYER_CARD_GUIDS = {}
end end
end end
function getSpawnedPlayerCardGuid(params) function getSpawnedPlayerCardGuid(params)
local guid = params[1] local guid = params[1]
if SPAWNED_PLAYER_CARD_GUIDS == nil then if SPAWNED_PLAYER_CARD_GUIDS == nil then
return nil return nil
else
return SPAWNED_PLAYER_CARD_GUIDS[guid]
end end
return SPAWNED_PLAYER_CARD_GUIDS[guid]
end end
function setSpawnedPlayerCardGuid(params) function setSpawnedPlayerCardGuid(params)
local guid = params[1] local guid = params[1]
local value = params[2] local value = params[2]
if SPAWNED_PLAYER_CARD_GUIDS ~= nil then if SPAWNED_PLAYER_CARD_GUIDS ~= nil then
SPAWNED_PLAYER_CARD_GUIDS[guid] = value SPAWNED_PLAYER_CARD_GUIDS[guid] = value
return true return true
else
return false
end end
return false
end end
function checkHiddenCard(name) function checkHiddenCard(name)
@ -1376,9 +1376,9 @@ function checkHiddenCard(name)
end end
function updateHiddenCards(args) function updateHiddenCards(args)
local custom_data_helper = getObjectFromGUID(args[1]) local custom_data_helper = getObjectFromGUID(args[1])
local data_hiddenCards = custom_data_helper.getTable("HIDDEN_CARD_DATA") local data_hiddenCards = custom_data_helper.getTable("HIDDEN_CARD_DATA")
for k, v in ipairs(data_hiddenCards) do for k, v in ipairs(data_hiddenCards) do
table.insert(HIDDEN_CARD_DATA, v) table.insert(HIDDEN_CARD_DATA, v)
end end
end end