add Day of the Dragons (from Scourge)

This commit is contained in:
jendave
2011-08-06 14:27:45 +00:00
parent 7cffc70755
commit 308b7c5ed8
3 changed files with 76 additions and 0 deletions

1
.gitattributes vendored
View File

@@ -1160,6 +1160,7 @@ res/cardsfolder/dawnray_archer.txt -text svneol=native#text/plain
res/cardsfolder/dawnstrider.txt -text svneol=native#text/plain
res/cardsfolder/day_of_destiny.txt -text svneol=native#text/plain
res/cardsfolder/day_of_judgment.txt -text svneol=native#text/plain
res/cardsfolder/day_of_the_dragons.txt -text svneol=native#text/plain
res/cardsfolder/daze.txt -text svneol=native#text/plain
res/cardsfolder/deadapult.txt -text svneol=native#text/plain
res/cardsfolder/deadfall.txt -text svneol=native#text/plain

View File

@@ -0,0 +1,7 @@
Name:Day of the Dragons
ManaCost:4 U U U
Types:Enchantment
Text:When CARDNAME enters the battlefield, exile all creatures you control. Then put that many 5/5 red Dragon creature tokens with flying onto the battlefield.\r\nWhen CARDNAME leaves the battlefield, sacrifice all Dragons you control. Then return the exiled cards to the battlefield under your control.
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/day_of_the_dragons.jpg
End

View File

@@ -8154,6 +8154,74 @@ public class CardFactory implements NewConstants {
card.addSpellAbility(ability);
}//*************** END ************ END **************************
//*************** START *********** START **************************
else if(cardName.equals("Day of the Dragons")) {
final CardList exiled = new CardList();
final SpellAbility exileAll = new Ability(card, "0") {
@Override
public void resolve() {
CardList myCreatures = AllZoneUtil.getCreaturesInPlay(card.getController());
for(Card c:myCreatures) {
exiled.add(c);
AllZone.GameAction.exile(c);
}
for(int i = 0; i < exiled.size(); i++) {
CardFactoryUtil.makeToken("Dragon", "R 5 5 Dragon", card.getController(),
"R", new String[] {"Creature", "Dragon"}, 5, 5,
new String[] {"Flying"});
}
}
};
Command intoPlay = new Command() {
private static final long serialVersionUID = 7181675096954076868L;
public void execute() {
StringBuilder sb = new StringBuilder();
sb.append(cardName).append(" - ");
sb.append("exile all creatures you control. ");
sb.append("Then put that many 5/5 red Dragon creature tokens with flying onto the battlefield.");
exileAll.setStackDescription(sb.toString());
AllZone.Stack.add(exileAll);
}
};
final SpellAbility returnAll = new Ability(card, "0") {
@Override
public void resolve() {
CardList dragons = AllZoneUtil.getPlayerTypeInPlay(card.getController(), "Dragon");
for(Card c:dragons) {
AllZone.GameAction.sacrifice(c);
}
for(Card c:exiled) {
AllZone.GameAction.moveToPlay(c);
}
exiled.clear();
}
};
Command leavesPlay = new Command() {
private static final long serialVersionUID = -5553218901524553718L;
public void execute() {
StringBuilder sb = new StringBuilder();
sb.append(cardName).append(" - ");
sb.append("sacrifice all Dragons you control. ");
sb.append("Then return the exiled cards to the battlefield under your control.");
returnAll.setStackDescription(sb.toString());
AllZone.Stack.add(returnAll);
}
};
card.addComesIntoPlayCommand(intoPlay);
card.addLeavesPlayCommand(leavesPlay);
}//*************** END ************ END **************************
return postFactoryKeywords(card);
}//getCard2