Deal encounter cards to players' hands
This commit is contained in:
parent
daa2170ca8
commit
e35c5bdefd
@ -245,17 +245,7 @@ end
|
|||||||
|
|
||||||
-- draw the provided card to the requesting playermat
|
-- draw the provided card to the requesting playermat
|
||||||
function actualEncounterCardDraw(card, params)
|
function actualEncounterCardDraw(card, params)
|
||||||
local metadata = JSON.decode(card.getGMNotes()) or {}
|
card.deal(1, params.matColor)
|
||||||
local DATA_HELPER = guidReferenceApi.getObjectByOwnerAndType("Mythos", "DataHelper")
|
|
||||||
|
|
||||||
-- draw hidden cards facedown
|
|
||||||
local faceUpRotation = 0
|
|
||||||
if metadata.hidden or DATA_HELPER.call('checkHiddenCard', card.getName()) then
|
|
||||||
faceUpRotation = 180
|
|
||||||
end
|
|
||||||
|
|
||||||
local rot = playermatApi.returnRotation(params.matColor):setAt("z", faceUpRotation)
|
|
||||||
deckLib.placeOrMergeIntoDeck(card, params.position, rot)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
-- gets the discard pile and shuffles it into the encounter deck
|
-- gets the discard pile and shuffles it into the encounter deck
|
||||||
|
Loading…
Reference in New Issue
Block a user