From 6f0f6570de93c761d7836ba51f20e1e572833a10 Mon Sep 17 00:00:00 2001 From: beholder Date: Sat, 24 Sep 2011 15:37:50 +0200 Subject: [PATCH] added Cobbled Wings and Crossway Vampire --- resources/magic/data/cards2.txt | 24 ++++++++++++++++++ src/magic/card/Crossway_Vampire.java | 38 ++++++++++++++++++++++++++++ 2 files changed, 62 insertions(+) create mode 100644 src/magic/card/Crossway_Vampire.java diff --git a/resources/magic/data/cards2.txt b/resources/magic/data/cards2.txt index 2b83dc75a0..84ab77b44c 100644 --- a/resources/magic/data/cards2.txt +++ b/resources/magic/data/cards2.txt @@ -4081,6 +4081,30 @@ cost={5}{R} pt=4/4 timing=main +>Cobbled Wings +image=http://magiccards.info/scans/en/isd/219.jpg +value=2 +rarity=C +type=Artifact +subtype=Equipment +converted=2 +cost={2} +equip={1} +given_ability=flying +timing=equipment + +>Crossway Vampire +image=http://magiccards.info/scans/en/isd/135.jpg +value=3 +rarity=C +type=Creature +subtype=Vampire +color=r +converted=3 +cost={1}{R}{R} +pt=3/2 +timing=fmain + >Morkrut Banshee image=http://magiccards.info/scans/en/isd/110.jpg value=4 diff --git a/src/magic/card/Crossway_Vampire.java b/src/magic/card/Crossway_Vampire.java new file mode 100644 index 0000000000..f9112367dd --- /dev/null +++ b/src/magic/card/Crossway_Vampire.java @@ -0,0 +1,38 @@ +package magic.card; + +import magic.model.MagicAbility; +import magic.model.MagicGame; +import magic.model.MagicPermanent; +import magic.model.MagicPlayer; +import magic.model.action.MagicPermanentAction; +import magic.model.action.MagicSetAbilityAction; +import magic.model.choice.MagicTargetChoice; +import magic.model.event.MagicEvent; +import magic.model.target.MagicNoCombatTargetPicker; +import magic.model.trigger.MagicWhenComesIntoPlayTrigger; + + +public class Crossway_Vampire { + public static final MagicWhenComesIntoPlayTrigger T = new MagicWhenComesIntoPlayTrigger() { + @Override + public MagicEvent executeTrigger(final MagicGame game,final MagicPermanent permanent, final MagicPlayer player) { + return new MagicEvent( + permanent, + player, + MagicTargetChoice.TARGET_CREATURE, + new MagicNoCombatTargetPicker(false,true,false), + MagicEvent.NO_DATA, + this, + "Target creature$ can't block this turn."); + } + + @Override + public void executeEvent(final MagicGame game,final MagicEvent event,final Object data[],final Object[] choiceResults) { + event.processTargetPermanent(game,choiceResults,0,new MagicPermanentAction() { + public void doAction(final MagicPermanent creature) { + game.doAction(new MagicSetAbilityAction(creature,MagicAbility.CannotBlock)); + } + }); + } + }; +}