From ba976819fdc95670ba86432b656011bdb6af66ab Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Sat, 22 Jun 2019 12:31:28 -0400 Subject: [PATCH] Implemented Season of Growth --- .../src/mage/cards/s/SeasonOfGrowth.java | 49 +++++++++++++++++++ Mage.Sets/src/mage/sets/CoreSet2020.java | 1 + 2 files changed, 50 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/s/SeasonOfGrowth.java diff --git a/Mage.Sets/src/mage/cards/s/SeasonOfGrowth.java b/Mage.Sets/src/mage/cards/s/SeasonOfGrowth.java new file mode 100644 index 0000000000..d347018ab5 --- /dev/null +++ b/Mage.Sets/src/mage/cards/s/SeasonOfGrowth.java @@ -0,0 +1,49 @@ +package mage.cards.s; + +import mage.abilities.common.EntersBattlefieldControlledTriggeredAbility; +import mage.abilities.common.SpellCastControllerTriggeredAbility; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.keyword.ScryEffect; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.filter.FilterSpell; +import mage.filter.StaticFilters; +import mage.filter.predicate.other.TargetsPermanentPredicate; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class SeasonOfGrowth extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("a spell that targets a creature you control"); + + static { + filter.add(new TargetsPermanentPredicate(StaticFilters.FILTER_CONTROLLED_CREATURE)); + } + + public SeasonOfGrowth(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{G}"); + + // Whenever a creature enters the battlefield under your control, scry 1. + this.addAbility(new EntersBattlefieldControlledTriggeredAbility( + new ScryEffect(1), StaticFilters.FILTER_PERMANENT_CREATURE_A + )); + + // Whenever you cast a spell that targets a creature you control, draw a card. + this.addAbility(new SpellCastControllerTriggeredAbility( + new DrawCardSourceControllerEffect(1), filter, false + )); + } + + private SeasonOfGrowth(final SeasonOfGrowth card) { + super(card); + } + + @Override + public SeasonOfGrowth copy() { + return new SeasonOfGrowth(this); + } +} diff --git a/Mage.Sets/src/mage/sets/CoreSet2020.java b/Mage.Sets/src/mage/sets/CoreSet2020.java index b742fd95fd..6fc3ca51fc 100644 --- a/Mage.Sets/src/mage/sets/CoreSet2020.java +++ b/Mage.Sets/src/mage/sets/CoreSet2020.java @@ -145,6 +145,7 @@ public final class CoreSet2020 extends ExpansionSet { cards.add(new SetCardInfo("Scholar of the Ages", 74, Rarity.UNCOMMON, mage.cards.s.ScholarOfTheAges.class)); cards.add(new SetCardInfo("Scoured Barrens", 251, Rarity.COMMON, mage.cards.s.ScouredBarrens.class)); cards.add(new SetCardInfo("Scuttlemutt", 238, Rarity.UNCOMMON, mage.cards.s.Scuttlemutt.class)); + cards.add(new SetCardInfo("Season of Growth", 191, Rarity.UNCOMMON, mage.cards.s.SeasonOfGrowth.class)); cards.add(new SetCardInfo("Shared Summons", 193, Rarity.RARE, mage.cards.s.SharedSummons.class)); cards.add(new SetCardInfo("Shifting Ceratops", 194, Rarity.RARE, mage.cards.s.ShiftingCeratops.class)); cards.add(new SetCardInfo("Silverback Shaman", 195, Rarity.COMMON, mage.cards.s.SilverbackShaman.class));