From 3e51a60d0d05423f7f7ac304fcbcb25fbee9c928 Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Tue, 30 Mar 2021 08:31:51 -0400 Subject: [PATCH] [STX] Implemented Illuminate History --- .../src/mage/cards/i/IlluminateHistory.java | 44 +++++++++++++++++++ .../mage/sets/StrixhavenSchoolOfMages.java | 1 + 2 files changed, 45 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/i/IlluminateHistory.java diff --git a/Mage.Sets/src/mage/cards/i/IlluminateHistory.java b/Mage.Sets/src/mage/cards/i/IlluminateHistory.java new file mode 100644 index 00000000000..073de314ddf --- /dev/null +++ b/Mage.Sets/src/mage/cards/i/IlluminateHistory.java @@ -0,0 +1,44 @@ +package mage.cards.i; + +import mage.abilities.condition.Condition; +import mage.abilities.condition.common.CardsInControllerGraveyardCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.discard.DiscardAndDrawThatManyEffect; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.SubType; +import mage.game.permanent.token.LoreholdToken; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class IlluminateHistory extends CardImpl { + + private static final Condition condition = new CardsInControllerGraveyardCondition(7); + + public IlluminateHistory(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.SORCERY}, "{2}{R}{R}"); + + this.subtype.add(SubType.LESSON); + + // Discard any number of cards, then draw that many cards. Then if there are seven or more cards in your graveyard, create a 3/2 red and white Spirit creature token. + this.getSpellAbility().addEffect(new DiscardAndDrawThatManyEffect(Integer.MAX_VALUE)); + this.getSpellAbility().addEffect(new ConditionalOneShotEffect( + new CreateTokenEffect(new LoreholdToken()), condition, "Then if there are seven or more " + + "cards in your graveyard, create a 3/2 red and white Spirit creature token" + )); + } + + private IlluminateHistory(final IlluminateHistory card) { + super(card); + } + + @Override + public IlluminateHistory copy() { + return new IlluminateHistory(this); + } +} diff --git a/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java b/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java index 67c2b859ea8..80bbfce65a2 100644 --- a/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java +++ b/Mage.Sets/src/mage/sets/StrixhavenSchoolOfMages.java @@ -49,6 +49,7 @@ public final class StrixhavenSchoolOfMages extends ExpansionSet { cards.add(new SetCardInfo("Go Blank", 72, Rarity.UNCOMMON, mage.cards.g.GoBlank.class)); cards.add(new SetCardInfo("Grinning Ignus", 104, Rarity.UNCOMMON, mage.cards.g.GrinningIgnus.class)); cards.add(new SetCardInfo("Heated Debate", 106, Rarity.COMMON, mage.cards.h.HeatedDebate.class)); + cards.add(new SetCardInfo("Illuminate History", 108, Rarity.RARE, mage.cards.i.IlluminateHistory.class)); cards.add(new SetCardInfo("Illustrious Historian", 109, Rarity.COMMON, mage.cards.i.IllustriousHistorian.class)); cards.add(new SetCardInfo("Introduction to Annihilation", 3, Rarity.COMMON, mage.cards.i.IntroductionToAnnihilation.class)); cards.add(new SetCardInfo("Introduction to Prophecy", 4, Rarity.COMMON, mage.cards.i.IntroductionToProphecy.class));