forked from External/mage
[TDC] Implement Bone Devourer
This commit is contained in:
parent
3b90fb428a
commit
42c4aa8d2f
2 changed files with 64 additions and 0 deletions
63
Mage.Sets/src/mage/cards/b/BoneDevourer.java
Normal file
63
Mage.Sets/src/mage/cards/b/BoneDevourer.java
Normal file
|
|
@ -0,0 +1,63 @@
|
|||
package mage.cards.b;
|
||||
|
||||
import mage.MageInt;
|
||||
import mage.abilities.Ability;
|
||||
import mage.abilities.common.DiesSourceTriggeredAbility;
|
||||
import mage.abilities.common.EntersBattlefieldAbility;
|
||||
import mage.abilities.dynamicvalue.DynamicValue;
|
||||
import mage.abilities.dynamicvalue.common.CountersSourceCount;
|
||||
import mage.abilities.dynamicvalue.common.CreaturesDiedThisTurnCount;
|
||||
import mage.abilities.effects.common.DrawCardSourceControllerEffect;
|
||||
import mage.abilities.effects.common.LoseLifeSourceControllerEffect;
|
||||
import mage.abilities.effects.common.counter.AddCountersSourceEffect;
|
||||
import mage.abilities.hint.common.CreaturesDiedThisTurnHint;
|
||||
import mage.abilities.keyword.FlashAbility;
|
||||
import mage.abilities.keyword.FlyingAbility;
|
||||
import mage.cards.CardImpl;
|
||||
import mage.cards.CardSetInfo;
|
||||
import mage.constants.CardType;
|
||||
import mage.constants.SubType;
|
||||
import mage.counters.CounterType;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author TheElk801
|
||||
*/
|
||||
public final class BoneDevourer extends CardImpl {
|
||||
|
||||
private static final DynamicValue xValue = new CountersSourceCount(null);
|
||||
|
||||
public BoneDevourer(UUID ownerId, CardSetInfo setInfo) {
|
||||
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{3}{B}");
|
||||
|
||||
this.subtype.add(SubType.DRAGON);
|
||||
this.power = new MageInt(2);
|
||||
this.toughness = new MageInt(2);
|
||||
|
||||
// Flash
|
||||
this.addAbility(FlashAbility.getInstance());
|
||||
|
||||
// Flying
|
||||
this.addAbility(FlyingAbility.getInstance());
|
||||
|
||||
// This creature enters with a number of +1/+1 counters on it equal to the number of creatures that died this turn.
|
||||
this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(
|
||||
CounterType.P1P1.createInstance(), CreaturesDiedThisTurnCount.instance, false
|
||||
), "with a number of +1/+1 counters on it equal to the number of creatures that died this turn").addHint(CreaturesDiedThisTurnHint.instance));
|
||||
|
||||
// When this creature dies, you draw X cards and you lose X life, where X is the number of +1/+1 counters on it.
|
||||
Ability ability = new DiesSourceTriggeredAbility(new DrawCardSourceControllerEffect(xValue).setText("you draw X cards"));
|
||||
ability.addEffect(new LoseLifeSourceControllerEffect(xValue));
|
||||
this.addAbility(ability);
|
||||
}
|
||||
|
||||
private BoneDevourer(final BoneDevourer card) {
|
||||
super(card);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BoneDevourer copy() {
|
||||
return new BoneDevourer(this);
|
||||
}
|
||||
}
|
||||
|
|
@ -58,6 +58,7 @@ public final class TarkirDragonstormCommander extends ExpansionSet {
|
|||
cards.add(new SetCardInfo("Blasphemous Act", 207, Rarity.RARE, mage.cards.b.BlasphemousAct.class));
|
||||
cards.add(new SetCardInfo("Blight Pile", 174, Rarity.UNCOMMON, mage.cards.b.BlightPile.class));
|
||||
cards.add(new SetCardInfo("Bojuka Bog", 341, Rarity.COMMON, mage.cards.b.BojukaBog.class));
|
||||
cards.add(new SetCardInfo("Bone Devourer", 26, Rarity.RARE, mage.cards.b.BoneDevourer.class));
|
||||
cards.add(new SetCardInfo("Boros Signet", 314, Rarity.UNCOMMON, mage.cards.b.BorosSignet.class));
|
||||
cards.add(new SetCardInfo("Bountiful Landscape", 342, Rarity.COMMON, mage.cards.b.BountifulLandscape.class));
|
||||
cards.add(new SetCardInfo("Caldera Pyremaw", 33, Rarity.RARE, mage.cards.c.CalderaPyremaw.class));
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue