added Cemetery Reaper

master
beholder 2011-08-25 11:51:08 +02:00
parent 0f59074ce7
commit 96aa0a3acd
3 changed files with 68 additions and 0 deletions

View File

@ -368,6 +368,19 @@ toughness=4
ability=flying ability=flying
timing=main timing=main
>Cemetery Reaper
image=http://magiccards.info/scans/en/m10/87.jpg
value=4
rarity=R
type=Creature
subtype=Zombie
color=b
converted=3
cost={1}{B}{B}
power=2
toughness=2
timing=fmain
>Cerodon Yearling >Cerodon Yearling
image=http://magiccards.info/scans/en/pch/86.jpg image=http://magiccards.info/scans/en/pch/86.jpg
value=3 value=3

View File

@ -0,0 +1,49 @@
package magic.card;
import magic.data.TokenCardDefinitions;
import magic.model.*;
import magic.model.action.MagicMoveCardAction;
import magic.model.action.MagicPlayTokenAction;
import magic.model.action.MagicRemoveCardAction;
import magic.model.choice.MagicTargetChoice;
import magic.model.condition.MagicCondition;
import magic.model.event.*;
import magic.model.target.MagicGraveyardTargetPicker;
public class Cemetery_Reaper {
public static final MagicPermanentActivation A = new MagicPermanentActivation(
new MagicCondition[]{MagicCondition.CAN_TAP_CONDITION,MagicManaCost.TWO_BLACK.getCondition()},
new MagicActivationHints(MagicTiming.Token),
"Token") {
@Override
public MagicEvent[] getCostEvent(final MagicSource source) {
return new MagicEvent[]{new MagicPayManaCostTapEvent(source,source.getController(),MagicManaCost.TWO_BLACK)};
}
@Override
public MagicEvent getPermanentEvent(final MagicPermanent source,final MagicPayedCost payedCost) {
return new MagicEvent(
source,
source.getController(),
MagicTargetChoice.TARGET_CREATURE_CARD_FROM_ALL_GRAVEYARDS,
MagicGraveyardTargetPicker.getInstance(),
new Object[]{source.getController()},
this,
"Exile target creature card from a graveyard. " +
"Put a 2/2 black Zombie creature token onto the battlefield.");
}
@Override
public void executeEvent(
final MagicGame game,
final MagicEvent event,
final Object[] data,
final Object[] choiceResults) {
final MagicCard card=event.getTarget(game,choiceResults,0);
if (card!=null) {
final MagicPlayer player=(MagicPlayer)data[0];
game.doAction(new MagicRemoveCardAction(card,MagicLocationType.Graveyard));
game.doAction(new MagicMoveCardAction(card,MagicLocationType.Graveyard,MagicLocationType.Exile));
game.doAction(new MagicPlayTokenAction(player,TokenCardDefinitions.ZOMBIE_TOKEN_CARD));
}
}
};
}

View File

@ -18,6 +18,7 @@ public class MagicStaticLocalVariable extends MagicDummyLocalVariable {
private static int bloodmarkMentor; private static int bloodmarkMentor;
private static int boartuskLiege; private static int boartuskLiege;
private static int captainOfTheWatch; private static int captainOfTheWatch;
private static int cemeteryReaper;
private static int creakwoodLiege; private static int creakwoodLiege;
private static int cumberStone; private static int cumberStone;
private static int deathbringerLiege; private static int deathbringerLiege;
@ -101,6 +102,10 @@ public class MagicStaticLocalVariable extends MagicDummyLocalVariable {
if (count > 0 && permanent.hasSubType(MagicSubType.Soldier)) { if (count > 0 && permanent.hasSubType(MagicSubType.Soldier)) {
both += getOtherCount(captainOfTheWatch,permanent,count); both += getOtherCount(captainOfTheWatch,permanent,count);
} }
count = controller.getCount(cemeteryReaper);
if (count > 0 && permanent.hasSubType(MagicSubType.Zombie)) {
both += getOtherCount(cemeteryReaper,permanent,count);
}
count = controller.getCount(goblinChieftain); count = controller.getCount(goblinChieftain);
if (count > 0 && permanent.hasSubType(MagicSubType.Goblin)) { if (count > 0 && permanent.hasSubType(MagicSubType.Goblin)) {
both += getOtherCount(goblinChieftain,permanent,count); both += getOtherCount(goblinChieftain,permanent,count);
@ -232,6 +237,7 @@ public class MagicStaticLocalVariable extends MagicDummyLocalVariable {
bloodmarkMentor=definitions.getCard("Bloodmark Mentor").getIndex(); bloodmarkMentor=definitions.getCard("Bloodmark Mentor").getIndex();
boartuskLiege=definitions.getCard("Boartusk Liege").getIndex(); boartuskLiege=definitions.getCard("Boartusk Liege").getIndex();
captainOfTheWatch=definitions.getCard("Captain of the Watch").getIndex(); captainOfTheWatch=definitions.getCard("Captain of the Watch").getIndex();
cemeteryReaper=definitions.getCard("Cemetery Reaper").getIndex();
creakwoodLiege=definitions.getCard("Creakwood Liege").getIndex(); creakwoodLiege=definitions.getCard("Creakwood Liege").getIndex();
cumberStone=definitions.getCard("Cumber Stone").getIndex(); cumberStone=definitions.getCard("Cumber Stone").getIndex();
deathbringerLiege=definitions.getCard("Deathbringer Liege").getIndex(); deathbringerLiege=definitions.getCard("Deathbringer Liege").getIndex();