[PIP] Implement Megaton's Fate

This commit is contained in:
theelk801 2024-04-08 12:11:59 -04:00
parent b1ee6e587f
commit 8b7169c2a9
3 changed files with 50 additions and 0 deletions

View file

@ -0,0 +1,48 @@
package mage.cards.m;
import mage.abilities.Mode;
import mage.abilities.effects.common.CreateTokenEffect;
import mage.abilities.effects.common.DamageAllEffect;
import mage.abilities.effects.common.DestroyTargetEffect;
import mage.abilities.effects.common.counter.AddCountersPlayersEffect;
import mage.cards.CardImpl;
import mage.cards.CardSetInfo;
import mage.constants.CardType;
import mage.constants.TargetController;
import mage.counters.CounterType;
import mage.filter.StaticFilters;
import mage.game.permanent.token.TreasureToken;
import mage.target.common.TargetArtifactPermanent;
import java.util.UUID;
/**
* @author TheElk801
*/
public final class MegatonsFate extends CardImpl {
public MegatonsFate(UUID ownerId, CardSetInfo setInfo) {
super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{5}{R}");
// Choose one --
// * Disarm -- Destroy target artifact. Create four Treasure tokens.
this.getSpellAbility().addEffect(new DestroyTargetEffect());
this.getSpellAbility().addTarget(new TargetArtifactPermanent());
this.getSpellAbility().addEffect(new CreateTokenEffect(new TreasureToken(), 4));
this.getSpellAbility().withFirstModeFlavorWord("Disarm");
// * Detonate -- Megaton's Fate deals 8 damage to each creature. Each player gets four rad counters.
this.getSpellAbility().addMode(new Mode(new DamageAllEffect(8, StaticFilters.FILTER_PERMANENT_CREATURE))
.addEffect(new AddCountersPlayersEffect(CounterType.RAD.createInstance(4), TargetController.EACH_PLAYER))
.withFlavorWord("Detonate"));
}
private MegatonsFate(final MegatonsFate card) {
super(card);
}
@Override
public MegatonsFate copy() {
return new MegatonsFate(this);
}
}

View file

@ -178,6 +178,7 @@ public final class Fallout extends ExpansionSet {
cards.add(new SetCardInfo("Martial Coup", 167, Rarity.RARE, mage.cards.m.MartialCoup.class));
cards.add(new SetCardInfo("Masterwork of Ingenuity", 234, Rarity.RARE, mage.cards.m.MasterworkOfIngenuity.class));
cards.add(new SetCardInfo("Mechanized Production", 178, Rarity.MYTHIC, mage.cards.m.MechanizedProduction.class));
cards.add(new SetCardInfo("Megaton's Fate", 61, Rarity.RARE, mage.cards.m.MegatonsFate.class));
cards.add(new SetCardInfo("Memorial to Glory", 271, Rarity.UNCOMMON, mage.cards.m.MemorialToGlory.class));
cards.add(new SetCardInfo("Mind Stone", 235, Rarity.UNCOMMON, mage.cards.m.MindStone.class));
cards.add(new SetCardInfo("Mister Gutsy", 136, Rarity.RARE, mage.cards.m.MisterGutsy.class, NON_FULL_USE_VARIOUS));

View file

@ -170,6 +170,7 @@ public enum CounterType {
PRESSURE("pressure"),
PREY("prey"),
PUPA("pupa"),
RAD("rad"),
REACH("reach"),
REJECTION("rejection"),
REPAIR("repair"),