This is handled in the "OnSelectNumber" function. If you are using a custom deck file, that would be "deck.number". Do note, that it only gets a parameter listing the possible numbers to choose from, and that those are not necessarily in the order you would assume. For example, returning "1" might cause the AI to select 5 cards, if the first choice is 5. Also, since there is no card parameter, you have to handle the detection of the situation manually, for example by setting the GlobalActivatedCardID variable (or your own custom variable) on activation of komushroomo's effect.
Use it like this:
function SylvanStartup(deck)
...
deck.number = SylvanNumber
end
function SylvanNumber(choices)
if GlobalActivatedCardID == 99641328 then -- Sylvan Komushroomo
return 1 -- or 5, whatever works
end
end
Good luck! Sylvans are a hard deck to play for me as a human. Making the AI play it properly could be quite a challenge.
Edited by user
2016-04-04T11:39:40Z
|
Reason: Not specified