convert Gelectrode to triggers

This commit is contained in:
jendave
2011-08-06 19:19:30 +00:00
parent 0fc2be53a1
commit a2d1124c77
2 changed files with 3 additions and 45 deletions

View File

@@ -1,9 +1,11 @@
Name:Gelectrode
ManaCost:1 U R
Types:Creature Weird
Text:Whenever you cast an instant or sorcery spell, you may untap Gelectrode.
Text:no text
PT:0/1
A:AB$DealDamage | Cost$ T | Tgt$ TgtCP | NumDmg$ 1 | SpellDescription$ CARDNAME deals 1 damage to target creature or player.
T:Mode$ SpellCast | ValidCard$ Card.Instant+YouCtrl,Card.Sorcery+YouCtrl | TriggerZones$ Battlefield | Execute$ TrigUntap | Optional$ True | TriggerDescription$ Whenever you cast an instant or sorcery spell, you may untap CARDNAME.
SVar:TrigUntap:AB$Untap | Cost$ 0 | Defined$ Self
SVar:Rarity:Uncommon
SVar:Picture:http://www.wizards.com/global/images/magic/general/gelectrode.jpg
SetInfo:GPT|Uncommon|http://magiccards.info/scans/en/gp/113.jpg

View File

@@ -186,7 +186,6 @@ public class GameActionUtil {
playCard_Shorecrasher_Mimic(c);
playCard_Woodlurker_Mimic(c);
playCard_Forced_Fruition(c);
playCard_Gelectrode(c);
playCard_Standstill(c);
playCard_Sigil_of_the_Empty_Throne(c);
playCard_Curse_of_Wizardry(c);
@@ -1135,49 +1134,6 @@ public class GameActionUtil {
}
} // Dovescape
public static void playCard_Gelectrode(Card c) {
final Player controller = c.getController();
final PlayerZone play = AllZone.getZone(Constant.Zone.Battlefield, controller);
CardList list = new CardList();
list.addAll(play.getCards());
list = list.getName("Gelectrode");
if (list.size() > 0 && (c.getType().contains("Instant") || c.getType().contains("Sorcery")) && !c.isCopiedSpell()) {
for (int i = 0; i < list.size(); i++) {
final Card card = list.get(i);
Ability ability2 = new Ability(card, "0") {
@Override
public void resolve() {
if (card.getController().equals(AllZone.HumanPlayer)) {
String question = "You cast an instant or sorcery spell, will you untap Gelectrode?";
if (GameActionUtil.showYesNoDialog(card, question)) {
card.untap();
}
}
if (card.getController().equals(AllZone.ComputerPlayer)) {
card.untap();
}
}
}; // ability2
StringBuilder sb = new StringBuilder();
sb.append(card.getName()).append(" - ").append(c.getController());
sb.append(" played an instant or sorcery spell and may untap Gelectrode.");
ability2.setStackDescription(sb.toString());
AllZone.Stack.add(ability2);
}
}
}// Gelectrode
public static void playCard_Forced_Fruition(Card c) {
CardList list = AllZoneUtil.getCardsInPlay("Forced Fruition");