mirror of
https://github.com/correl/mage.git
synced 2024-11-28 19:19:55 +00:00
[J22] Implement Coalborn Entity
This commit is contained in:
parent
dd9a07592a
commit
23bd6f6919
3 changed files with 64 additions and 1 deletions
58
Mage.Sets/src/mage/cards/c/CoalbornEntity.java
Normal file
58
Mage.Sets/src/mage/cards/c/CoalbornEntity.java
Normal file
|
@ -0,0 +1,58 @@
|
||||||
|
package mage.cards.c;
|
||||||
|
|
||||||
|
import mage.MageInt;
|
||||||
|
import mage.abilities.Ability;
|
||||||
|
import mage.abilities.common.SimpleActivatedAbility;
|
||||||
|
import mage.abilities.costs.mana.ManaCostsImpl;
|
||||||
|
import mage.abilities.effects.common.DamageTargetEffect;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.SubType;
|
||||||
|
import mage.filter.common.FilterPermanentOrPlayer;
|
||||||
|
import mage.filter.predicate.Predicates;
|
||||||
|
import mage.filter.predicate.permanent.TokenPredicate;
|
||||||
|
import mage.target.common.TargetPermanentOrPlayer;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public final class CoalbornEntity extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterPermanentOrPlayer filter
|
||||||
|
= new FilterPermanentOrPlayer("creature token, player, or planeswalker");
|
||||||
|
|
||||||
|
static {
|
||||||
|
filter.getPermanentFilter().add(Predicates.or(
|
||||||
|
CardType.PLANESWALKER.getPredicate(),
|
||||||
|
Predicates.and(
|
||||||
|
CardType.CREATURE.getPredicate(),
|
||||||
|
TokenPredicate.TRUE
|
||||||
|
)
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
public CoalbornEntity(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{4}{R}");
|
||||||
|
|
||||||
|
this.subtype.add(SubType.ELEMENTAL);
|
||||||
|
this.power = new MageInt(4);
|
||||||
|
this.toughness = new MageInt(4);
|
||||||
|
|
||||||
|
// {2}{R}: Coalborn Entity deals 1 damage to target creature token, player, or planeswalker.
|
||||||
|
Ability ability = new SimpleActivatedAbility(new DamageTargetEffect(1), new ManaCostsImpl<>("{2}{R}"));
|
||||||
|
ability.addTarget(new TargetPermanentOrPlayer(filter));
|
||||||
|
this.addAbility(ability);
|
||||||
|
}
|
||||||
|
|
||||||
|
private CoalbornEntity(final CoalbornEntity card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public CoalbornEntity copy() {
|
||||||
|
return new CoalbornEntity(this);
|
||||||
|
}
|
||||||
|
}
|
|
@ -29,6 +29,7 @@ public final class Jumpstart2022 extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Blood Artist", 117, Rarity.UNCOMMON, mage.cards.b.BloodArtist.class));
|
cards.add(new SetCardInfo("Blood Artist", 117, Rarity.UNCOMMON, mage.cards.b.BloodArtist.class));
|
||||||
cards.add(new SetCardInfo("Burglar Rat", 384, Rarity.COMMON, mage.cards.b.BurglarRat.class));
|
cards.add(new SetCardInfo("Burglar Rat", 384, Rarity.COMMON, mage.cards.b.BurglarRat.class));
|
||||||
cards.add(new SetCardInfo("Chittering Rats", 387, Rarity.COMMON, mage.cards.c.ChitteringRats.class));
|
cards.add(new SetCardInfo("Chittering Rats", 387, Rarity.COMMON, mage.cards.c.ChitteringRats.class));
|
||||||
|
cards.add(new SetCardInfo("Coalborn Entity", 32, Rarity.UNCOMMON, mage.cards.c.CoalbornEntity.class));
|
||||||
cards.add(new SetCardInfo("Coldsteel Heart", 94, Rarity.UNCOMMON, mage.cards.c.ColdsteelHeart.class));
|
cards.add(new SetCardInfo("Coldsteel Heart", 94, Rarity.UNCOMMON, mage.cards.c.ColdsteelHeart.class));
|
||||||
cards.add(new SetCardInfo("Conductor of Cacophony", 20, Rarity.UNCOMMON, mage.cards.c.ConductorOfCacophony.class));
|
cards.add(new SetCardInfo("Conductor of Cacophony", 20, Rarity.UNCOMMON, mage.cards.c.ConductorOfCacophony.class));
|
||||||
cards.add(new SetCardInfo("Crypt Rats", 392, Rarity.UNCOMMON, mage.cards.c.CryptRats.class));
|
cards.add(new SetCardInfo("Crypt Rats", 392, Rarity.UNCOMMON, mage.cards.c.CryptRats.class));
|
||||||
|
|
|
@ -23,13 +23,17 @@ public class TargetPermanentOrPlayer extends TargetImpl {
|
||||||
protected FilterPermanentOrPlayer filter;
|
protected FilterPermanentOrPlayer filter;
|
||||||
|
|
||||||
public TargetPermanentOrPlayer() {
|
public TargetPermanentOrPlayer() {
|
||||||
this(1, 1);
|
this(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
public TargetPermanentOrPlayer(int numTargets) {
|
public TargetPermanentOrPlayer(int numTargets) {
|
||||||
this(numTargets, numTargets);
|
this(numTargets, numTargets);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public TargetPermanentOrPlayer(FilterPermanentOrPlayer filter) {
|
||||||
|
this(1, 1, filter, false);
|
||||||
|
}
|
||||||
|
|
||||||
public TargetPermanentOrPlayer(int minNumTargets, int maxNumTargets) {
|
public TargetPermanentOrPlayer(int minNumTargets, int maxNumTargets) {
|
||||||
this(minNumTargets, maxNumTargets, false);
|
this(minNumTargets, maxNumTargets, false);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue