diff --git a/Mage.Sets/src/mage/cards/r/Reprobation.java b/Mage.Sets/src/mage/cards/r/Reprobation.java new file mode 100644 index 00000000000..d874a21eef5 --- /dev/null +++ b/Mage.Sets/src/mage/cards/r/Reprobation.java @@ -0,0 +1,76 @@ +package mage.cards.r; + +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BecomesCreatureAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.SubType; +import mage.game.permanent.token.TokenImpl; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +import java.util.UUID; + +/** + * @author JayDi85 + */ +public final class Reprobation extends CardImpl { + + public Reprobation(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}"); + + this.subtype.add(SubType.AURA); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.LoseAbility)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + + // Enchanted creature loses all abilities and is a Coward creature with base power and toughness 0/1. + // (It keeps all supertypes but loses all other types and creature types.) + this.addAbility(new SimpleStaticAbility(new BecomesCreatureAttachedEffect( + new ReprobationToken(), "Enchanted creature loses all abilities and is a Coward creature with base power and toughness 0/1" + + " (It keeps all supertypes but loses all other types and creature types.)", + Duration.WhileOnBattlefield, + BecomesCreatureAttachedEffect.LoseType.ABILITIES_SUBTYPE + ))); + } + + private Reprobation(final Reprobation card) { + super(card); + } + + @Override + public Reprobation copy() { + return new Reprobation(this); + } +} + +class ReprobationToken extends TokenImpl { + + ReprobationToken() { + super("", "loses all abilities and is a Coward creature with base power and toughness 0/1"); + cardType.add(CardType.CREATURE); + subtype.add(SubType.COWARD); + power = new MageInt(0); + toughness = new MageInt(1); + } + + private ReprobationToken(final ReprobationToken token) { + super(token); + } + + public ReprobationToken copy() { + return new ReprobationToken(this); + } + +} diff --git a/Mage.Sets/src/mage/sets/ModernHorizons.java b/Mage.Sets/src/mage/sets/ModernHorizons.java index 0f97e04621b..6ef31508ec4 100644 --- a/Mage.Sets/src/mage/sets/ModernHorizons.java +++ b/Mage.Sets/src/mage/sets/ModernHorizons.java @@ -185,6 +185,7 @@ public final class ModernHorizons extends ExpansionSet { cards.add(new SetCardInfo("Reckless Charge", 144, Rarity.COMMON, mage.cards.r.RecklessCharge.class)); cards.add(new SetCardInfo("Recruit the Worthy", 22, Rarity.COMMON, mage.cards.r.RecruitTheWorthy.class)); cards.add(new SetCardInfo("Regrowth", 175, Rarity.UNCOMMON, mage.cards.r.Regrowth.class)); + cards.add(new SetCardInfo("Reprobation", 23, Rarity.COMMON, mage.cards.r.Reprobation.class)); cards.add(new SetCardInfo("Return from Extinction", 104, Rarity.COMMON, mage.cards.r.ReturnFromExtinction.class)); cards.add(new SetCardInfo("Rhox Veteran", 24, Rarity.COMMON, mage.cards.r.RhoxVeteran.class)); cards.add(new SetCardInfo("Rime Tender", 176, Rarity.COMMON, mage.cards.r.RimeTender.class));