convert Warp Artifact to triggers

This commit is contained in:
jendave
2011-08-06 19:08:40 +00:00
parent ff31801d08
commit bd77dc4794
2 changed files with 3 additions and 40 deletions

View File

@@ -1,8 +1,10 @@
Name:Warp Artifact
ManaCost:B B
Types:Enchantment Aura
Text:At the beginning of the upkeep of enchanted artifact's controller, Warp Artifact deals 1 damage to that player.
Text:no text
K:Enchant Artifact Curse
T:Mode$ Phase | Phase$ Upkeep | ValidPlayer$ EnchantedController | TriggerZones$ Battlefield | Execute$ TrigDamage | TriggerDescription$ At the beginning of the upkeep of enchanted artifact's controller, CARDNAME deals 1 damage to that player.
SVar:TrigDamage:AB$DealDamage | Cost$ 0 | Defined$ EnchantedController | NumDmg$ 1
SVar:Rarity:Rare
SVar:Picture:http://www.wizards.com/global/images/magic/general/warp_artifact.jpg
SetInfo:LEA|Rare|http://magiccards.info/scans/en/al/42.jpg

View File

@@ -50,7 +50,6 @@ public class GameActionUtil {
upkeep_Feedback();
upkeep_Farmstead();
upkeep_Unstable_Mutation();
upkeep_Warp_Artifact();
/* Converteded to AF Trigger
upkeep_Plague_Spitter();
@@ -4948,44 +4947,6 @@ public class GameActionUtil {
}
}//upkeep_Farmstead()
private static void upkeep_Warp_Artifact() {
final String auraName = "Warp Artifact";
final Player player = AllZone.Phase.getPlayerTurn();
PlayerZone playZone = AllZone.getZone(Constant.Zone.Battlefield, player);
CardList list = new CardList(playZone.getCards());
list = list.filter(new CardListFilter() {
public boolean addCard(Card c) {
return c.isArtifact() && c.isEnchanted();
}
});
if(list.size() > 0) {
Ability ability;
for(Card target:list) {
if(target.isEnchantedBy(auraName)) {
CardList auras = new CardList(target.getEnchantedBy().toArray());
auras = auras.getName(auraName);
for(Card aura:auras) {
final Card source = aura;
ability = new Ability(aura, "0") {
@Override
public void resolve() {
player.addDamage(1, source);
}
};
StringBuilder sb = new StringBuilder();
sb.append(auraName).append(" - deals 1 damage to ").append(player);
ability.setStackDescription(sb.toString());
AllZone.Stack.add(ability);
}
}
}
}//list > 0
}//upkeep_Warp_Artifact()
private static void upkeep_Wanderlust() {
final String auraName = "Wanderlust";
final Player player = AllZone.Phase.getPlayerTurn();