diff --git a/Mage.Sets/src/mage/cards/d/DraconicDestiny.java b/Mage.Sets/src/mage/cards/d/DraconicDestiny.java new file mode 100644 index 0000000000..3e4779880b --- /dev/null +++ b/Mage.Sets/src/mage/cards/d/DraconicDestiny.java @@ -0,0 +1,64 @@ +package mage.cards.d; + +import mage.abilities.Ability; +import mage.abilities.common.DiesAttachedTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.abilities.effects.common.continuous.AddCardSubtypeAttachedEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.abilities.keyword.HasteAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.*; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +import java.util.UUID; + +/** + * @author PurpleCrowbar + */ +public final class DraconicDestiny extends CardImpl { + + public DraconicDestiny(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{R}{R}"); + this.subtype.add(SubType.AURA); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget); + this.addAbility(ability); + + // Enchanted creature gets +1/+1 and has flying, haste, and "{1}: This creature gets +1/+0 until end of turn." It's a Dragon in addition to its other types. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 1, Duration.WhileOnBattlefield)); + ability.addEffect(new GainAbilityAttachedEffect(FlyingAbility.getInstance(), AttachmentType.AURA).setText("and has flying")); + ability.addEffect(new GainAbilityAttachedEffect(HasteAbility.getInstance(), AttachmentType.AURA).setText(", haste")); + ability.addEffect(new GainAbilityAttachedEffect(new SimpleActivatedAbility( + new BoostSourceEffect(1, 0, Duration.EndOfTurn), new GenericManaCost(1) + ), AttachmentType.AURA).setText(", and \"{1}: This creature gets +1/+0 until end of turn.\"")); + ability.addEffect(new AddCardSubtypeAttachedEffect(SubType.DRAGON, Duration.WhileOnBattlefield, AttachmentType.AURA) + .setText("It's a Dragon in addition to its other types")); + this.addAbility(ability); + + // When enchanted creature dies, return Draconic Destiny to its owner's hand. + this.addAbility(new DiesAttachedTriggeredAbility(new ReturnToHandSourceEffect(false, true), "enchanted creature")); + } + + private DraconicDestiny(final DraconicDestiny card) { + super(card); + } + + @Override + public DraconicDestiny copy() { + return new DraconicDestiny(this); + } +} diff --git a/Mage.Sets/src/mage/sets/TheBrothersWar.java b/Mage.Sets/src/mage/sets/TheBrothersWar.java index 96bb8e7169..61b197a81e 100644 --- a/Mage.Sets/src/mage/sets/TheBrothersWar.java +++ b/Mage.Sets/src/mage/sets/TheBrothersWar.java @@ -53,6 +53,8 @@ public final class TheBrothersWar extends ExpansionSet { cards.add(new SetCardInfo("Disciples of Gix", 90, Rarity.UNCOMMON, mage.cards.d.DisciplesOfGix.class)); cards.add(new SetCardInfo("Disenchant", 6, Rarity.COMMON, mage.cards.d.Disenchant.class)); cards.add(new SetCardInfo("Disfigure", 91, Rarity.COMMON, mage.cards.d.Disfigure.class)); + cards.add(new SetCardInfo("Draconic Destiny", 130, Rarity.MYTHIC, mage.cards.d.DraconicDestiny.class, NON_FULL_USE_VARIOUS)); + cards.add(new SetCardInfo("Draconic Destiny", 336, Rarity.MYTHIC, mage.cards.d.DraconicDestiny.class, NON_FULL_USE_VARIOUS)); cards.add(new SetCardInfo("Drafna, Founder of Lat-Nam", 47, Rarity.RARE, mage.cards.d.DrafnaFounderOfLatNam.class)); cards.add(new SetCardInfo("Epic Confrontation", 176, Rarity.COMMON, mage.cards.e.EpicConfrontation.class)); cards.add(new SetCardInfo("Evangel of Synthesis", 209, Rarity.UNCOMMON, mage.cards.e.EvangelOfSynthesis.class));