[BRO] Implement Powerstone Fracture

This commit is contained in:
Evan Kranzler 2022-11-01 20:10:47 -04:00
parent 5cd61acf8a
commit 9b789c6d7d
2 changed files with 48 additions and 0 deletions

View file

@ -0,0 +1,47 @@
package mage.cards.p;
import mage.abilities.costs.common.SacrificeTargetCost;
import mage.abilities.effects.common.DestroyTargetEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.filter.common.FilterControlledPermanent;
import mage.filter.predicate.Predicates;
import mage.target.common.TargetCreatureOrPlaneswalker;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class PowerstoneFracture extends CardImpl {
private static final FilterControlledPermanent filter = new FilterControlledPermanent("artifact or creature");
static {
filter.add(Predicates.or(
CardType.ARTIFACT.getPredicate(),
CardType.CREATURE.getPredicate()
));
}
public PowerstoneFracture(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{1}{B}");
// As an additional cost to cast this spell, sacrifice an artifact or creature.
this.getSpellAbility().addCost(new SacrificeTargetCost(filter));
// Destroy target creature or planeswalker.
this.getSpellAbility().addEffect(new DestroyTargetEffect());
this.getSpellAbility().addTarget(new TargetCreatureOrPlaneswalker());
}
private PowerstoneFracture(final PowerstoneFracture card) {
super(card);
}
@Override
public PowerstoneFracture copy() {
return new PowerstoneFracture(this);
}
}

View file

@ -83,6 +83,7 @@ public final class TheBrothersWar extends ExpansionSet {
cards.add(new SetCardInfo("Phyrexian Dragon Engine", "163a", Rarity.RARE, mage.cards.p.PhyrexianDragonEngine.class));
cards.add(new SetCardInfo("Phyrexian Fleshgorger", 121, Rarity.MYTHIC, mage.cards.p.PhyrexianFleshgorger.class));
cards.add(new SetCardInfo("Plains", 278, Rarity.LAND, mage.cards.basiclands.Plains.class, FULL_ART_BFZ_VARIOUS));
cards.add(new SetCardInfo("Powerstone Fracture", 112, Rarity.COMMON, mage.cards.p.PowerstoneFracture.class));
cards.add(new SetCardInfo("Queen Kayla bin-Kroog", 218, Rarity.RARE, mage.cards.q.QueenKaylaBinKroog.class));
cards.add(new SetCardInfo("Reconstructed Thopter", 242, Rarity.UNCOMMON, mage.cards.r.ReconstructedThopter.class));
cards.add(new SetCardInfo("Recruitment Officer", 23, Rarity.UNCOMMON, mage.cards.r.RecruitmentOfficer.class));