Discarding specific cards
by ubeefx
Moderators: ubeefx, beholder, melvin, ShawnieBoy, Lodici, CCGHQ Admins
Discarding specific cards
by PalladiaMors » 01 Mar 2015, 19:50
Hey guys, I've been trying to figure out for a while how to discard specific cards or card types in groovy form. The ability is found in script form in cards such as Fauna Shaman and Survival of the Fittest, but I can't find any cards in groovy form that do it. Unfortunately, the events section in the wiki isn't ready yet, so this isn't documented there. I believe it probably uses the DiscardCardEvent, but I'm not sure how to structure it in this case.
I think this could lead to a decent number of cards (Korlash, Heir to Blackblade, Hidden Horror). Appreciate any help, thanks!
I think this could lead to a decent number of cards (Korlash, Heir to Blackblade, Hidden Horror). Appreciate any help, thanks!
- PalladiaMors
- Posts: 343
- Joined: 12 Jul 2014, 17:40
- Has thanked: 36 times
- Been thanked: 22 times
Re: Discarding specific cards
by melvin » 02 Mar 2015, 00:38
check out MagicDiscardChosenEvent, eg:
- Code: Select all
new MagicDiscardChosenEvent(source, MagicTargetChoice.CREATURE_CARD_FROM_HAND)
-
melvin - AI Programmer
- Posts: 1062
- Joined: 21 Mar 2010, 12:26
- Location: Singapore
- Has thanked: 36 times
- Been thanked: 459 times
Re: Discarding specific cards
by PalladiaMors » 02 Mar 2015, 01:51
I'm getting "unable to resolve class MagicDiscardChosenCardEvent". Maybe I'm doing something wrong?
- PalladiaMors
- Posts: 343
- Joined: 12 Jul 2014, 17:40
- Has thanked: 36 times
- Been thanked: 22 times
Re: Discarding specific cards
by melvin » 02 Mar 2015, 02:16
My bad, typo in the earlier post. Should be MagicDiscardChosenEvent.
-
melvin - AI Programmer
- Posts: 1062
- Joined: 21 Mar 2010, 12:26
- Location: Singapore
- Has thanked: 36 times
- Been thanked: 459 times
4 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 16 guests