mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-20 12:48:00 +00:00
convert Warp Artifact to triggers
This commit is contained in:
@@ -1,8 +1,10 @@
|
|||||||
Name:Warp Artifact
|
Name:Warp Artifact
|
||||||
ManaCost:B B
|
ManaCost:B B
|
||||||
Types:Enchantment Aura
|
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
|
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:Rarity:Rare
|
||||||
SVar:Picture:http://www.wizards.com/global/images/magic/general/warp_artifact.jpg
|
SVar:Picture:http://www.wizards.com/global/images/magic/general/warp_artifact.jpg
|
||||||
SetInfo:LEA|Rare|http://magiccards.info/scans/en/al/42.jpg
|
SetInfo:LEA|Rare|http://magiccards.info/scans/en/al/42.jpg
|
||||||
|
|||||||
@@ -50,7 +50,6 @@ public class GameActionUtil {
|
|||||||
upkeep_Feedback();
|
upkeep_Feedback();
|
||||||
upkeep_Farmstead();
|
upkeep_Farmstead();
|
||||||
upkeep_Unstable_Mutation();
|
upkeep_Unstable_Mutation();
|
||||||
upkeep_Warp_Artifact();
|
|
||||||
|
|
||||||
/* Converteded to AF Trigger
|
/* Converteded to AF Trigger
|
||||||
upkeep_Plague_Spitter();
|
upkeep_Plague_Spitter();
|
||||||
@@ -4948,44 +4947,6 @@ public class GameActionUtil {
|
|||||||
}
|
}
|
||||||
}//upkeep_Farmstead()
|
}//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() {
|
private static void upkeep_Wanderlust() {
|
||||||
final String auraName = "Wanderlust";
|
final String auraName = "Wanderlust";
|
||||||
final Player player = AllZone.Phase.getPlayerTurn();
|
final Player player = AllZone.Phase.getPlayerTurn();
|
||||||
|
|||||||
Reference in New Issue
Block a user