Merge pull request #511 from argonui/playermat-hider
Playermat Hider: intercept clicks and hide token pools
This commit is contained in:
commit
3393001f95
@ -3,7 +3,6 @@
|
|||||||
"ComponentTags_path": "ComponentTags.json",
|
"ComponentTags_path": "ComponentTags.json",
|
||||||
"CustomUIAssets_path": "CustomUIAssets.json",
|
"CustomUIAssets_path": "CustomUIAssets.json",
|
||||||
"DecalPallet_path": "DecalPallet.json",
|
"DecalPallet_path": "DecalPallet.json",
|
||||||
"Decals": [],
|
|
||||||
"GameComplexity": "",
|
"GameComplexity": "",
|
||||||
"GameMode": "Arkham Horror LCG - Super Complete Edition",
|
"GameMode": "Arkham Horror LCG - Super Complete Edition",
|
||||||
"GameType": "",
|
"GameType": "",
|
||||||
@ -172,6 +171,7 @@
|
|||||||
"TokenSpawnTracker.e3ffc9",
|
"TokenSpawnTracker.e3ffc9",
|
||||||
"TokenSource.124381",
|
"TokenSource.124381",
|
||||||
"GameData.3dbe47",
|
"GameData.3dbe47",
|
||||||
|
"PlayermatClickInterceptor.3dbe55",
|
||||||
"SCEDTour.0e5aa8",
|
"SCEDTour.0e5aa8",
|
||||||
"PlayerCards.2d30ee",
|
"PlayerCards.2d30ee",
|
||||||
"TokenRemover.39b175",
|
"TokenRemover.39b175",
|
||||||
|
45
objects/PlayermatClickInterceptor.3dbe55.json
Normal file
45
objects/PlayermatClickInterceptor.3dbe55.json
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
{
|
||||||
|
"AltLookAngle": {
|
||||||
|
"x": 0,
|
||||||
|
"y": 0,
|
||||||
|
"z": 0
|
||||||
|
},
|
||||||
|
"Autoraise": true,
|
||||||
|
"ColorDiffuse": {
|
||||||
|
"b": 0,
|
||||||
|
"g": 0,
|
||||||
|
"r": 0
|
||||||
|
},
|
||||||
|
"Description": "This object is used to hide playmats beneath the table.",
|
||||||
|
"DragSelectable": true,
|
||||||
|
"GMNotes": "",
|
||||||
|
"GUID": "3dbe55",
|
||||||
|
"Grid": true,
|
||||||
|
"GridProjection": false,
|
||||||
|
"Hands": false,
|
||||||
|
"HideWhenFaceDown": false,
|
||||||
|
"IgnoreFoW": false,
|
||||||
|
"LayoutGroupSortIndex": 0,
|
||||||
|
"Locked": true,
|
||||||
|
"LuaScriptState": "false",
|
||||||
|
"LuaScript_path": "PlayermatClickInterceptor.3dbe55.ttslua",
|
||||||
|
"MeasureMovement": false,
|
||||||
|
"Name": "BlockSquare",
|
||||||
|
"Nickname": "PlayermatClickInterceptor",
|
||||||
|
"Snap": true,
|
||||||
|
"Sticky": true,
|
||||||
|
"Tooltip": false,
|
||||||
|
"Transform": {
|
||||||
|
"posX": -27.94,
|
||||||
|
"posY": -0.5,
|
||||||
|
"posZ": 0,
|
||||||
|
"rotX": 0,
|
||||||
|
"rotY": 270,
|
||||||
|
"rotZ": 0,
|
||||||
|
"scaleX": 84,
|
||||||
|
"scaleY": 1.5,
|
||||||
|
"scaleZ": 70
|
||||||
|
},
|
||||||
|
"Value": 0,
|
||||||
|
"XmlUI": ""
|
||||||
|
}
|
15
objects/PlayermatClickInterceptor.3dbe55.ttslua
Normal file
15
objects/PlayermatClickInterceptor.3dbe55.ttslua
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
local interactable = false
|
||||||
|
|
||||||
|
function onSave() return JSON.encode(interactable) end
|
||||||
|
|
||||||
|
function onLoad(savedData)
|
||||||
|
if savedData and savedData ~= "" then
|
||||||
|
interactable = JSON.encode(savedData)
|
||||||
|
end
|
||||||
|
self.interactable = interactable
|
||||||
|
end
|
||||||
|
|
||||||
|
function setState(state)
|
||||||
|
interactable = state
|
||||||
|
self.interactable = interactable
|
||||||
|
end
|
@ -17,4 +17,17 @@ function onClick_hideShow(player, matColor)
|
|||||||
obj.setLock(pos.y > 0)
|
obj.setLock(pos.y > 0)
|
||||||
obj.setPosition(obj.getPosition() + Vector(0, mod, 0))
|
obj.setPosition(obj.getPosition() + Vector(0, mod, 0))
|
||||||
end
|
end
|
||||||
|
|
||||||
|
-- set state of interceptor block
|
||||||
|
local allMats = guidReferenceApi.getObjectsByType("Playermat")
|
||||||
|
local state = false
|
||||||
|
for owner, mat in pairs(allMats) do
|
||||||
|
if mat.getPosition().y < 0 then
|
||||||
|
state = true
|
||||||
|
break
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local interceptor = getObjectFromGUID("3dbe55")
|
||||||
|
interceptor.call("setState", state)
|
||||||
end
|
end
|
||||||
|
@ -30,9 +30,15 @@ local GuidReferences = {
|
|||||||
HandZone = "0285cc",
|
HandZone = "0285cc",
|
||||||
HorrorCounter = "7b5729",
|
HorrorCounter = "7b5729",
|
||||||
InvestigatorSkillTracker = "af7ed7",
|
InvestigatorSkillTracker = "af7ed7",
|
||||||
|
PoolResources = "0168ae",
|
||||||
|
PoolDamage = "b0ef6c",
|
||||||
|
PoolHorror = "ae1a4e",
|
||||||
|
PoolClues = "fae2f6",
|
||||||
|
PoolDoom = "16724b",
|
||||||
Playermat = "383d8b",
|
Playermat = "383d8b",
|
||||||
ResourceCounter = "cd15ac",
|
ResourceCounter = "cd15ac",
|
||||||
TokenDiscardZone = "457de5",
|
TokenDiscardZone = "457de5",
|
||||||
|
TokenRemover = "2ba7a5",
|
||||||
Trash = "5f896a"
|
Trash = "5f896a"
|
||||||
},
|
},
|
||||||
Red = {
|
Red = {
|
||||||
@ -42,9 +48,15 @@ local GuidReferences = {
|
|||||||
HandZone = "be2f17",
|
HandZone = "be2f17",
|
||||||
HorrorCounter = "beb964",
|
HorrorCounter = "beb964",
|
||||||
InvestigatorSkillTracker = "e74881",
|
InvestigatorSkillTracker = "e74881",
|
||||||
|
PoolResources = "fd617a",
|
||||||
|
PoolDamage = "93f4a0",
|
||||||
|
PoolHorror = "7bd2a0",
|
||||||
|
PoolClues = "3b2550",
|
||||||
|
PoolDoom = "16fcd6",
|
||||||
Playermat = "0840d5",
|
Playermat = "0840d5",
|
||||||
ResourceCounter = "a4b60d",
|
ResourceCounter = "a4b60d",
|
||||||
TokenDiscardZone = "457de6",
|
TokenDiscardZone = "457de6",
|
||||||
|
TokenRemover = "39b175",
|
||||||
Trash = "4b8594"
|
Trash = "4b8594"
|
||||||
},
|
},
|
||||||
Mythos = {
|
Mythos = {
|
||||||
|
Loading…
Reference in New Issue
Block a user