added function

This commit is contained in:
dscarpac 2024-11-01 19:26:46 -05:00
parent 0958f6fa7e
commit 3881c32ed3

View File

@ -257,6 +257,14 @@ end
-- handle card drawing via number typing for multihanded gameplay -- handle card drawing via number typing for multihanded gameplay
-- (and additionally allow Norman Withers to draw multiple cards via number) -- (and additionally allow Norman Withers to draw multiple cards via number)
function onObjectNumberTyped(hoveredObject, playerColor, number) function onObjectNumberTyped(hoveredObject, playerColor, number)
-- adds cards to appropriate hand for Attachment Helper
if hoveredObject.getName() == "Attachment Helper" then
local matColor = playermatApi.getMatColorByPosition(hoveredObject.getPosition())
local handColor = playermatApi.getPlayerColor(matColor)
hoveredObject.deal(number, handColor)
return true
end
-- only continue for decks or cards -- only continue for decks or cards
if hoveredObject.type ~= "Deck" and hoveredObject.type ~= "Card" then return end if hoveredObject.type ~= "Deck" and hoveredObject.type ~= "Card" then return end