From fd9b055fd36c72b3ef7e47564a7a4d0cac1051b6 Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Thu, 8 Apr 2021 08:41:56 -0400 Subject: [PATCH] [C21] Implemented Guardian Augmenter --- .../src/mage/cards/g/GuardianAugmenter.java | 63 +++++++++++++++++++ .../src/mage/sets/Commander2021Edition.java | 1 + 2 files changed, 64 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/g/GuardianAugmenter.java diff --git a/Mage.Sets/src/mage/cards/g/GuardianAugmenter.java b/Mage.Sets/src/mage/cards/g/GuardianAugmenter.java new file mode 100644 index 0000000000..a64e1fc92c --- /dev/null +++ b/Mage.Sets/src/mage/cards/g/GuardianAugmenter.java @@ -0,0 +1,63 @@ +package mage.cards.g; + +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.FlashAbility; +import mage.abilities.keyword.HexproofAbility; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.SubType; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.CommanderPredicate; + +import java.util.UUID; + +/** + * @author TheElk801 + */ +public final class GuardianAugmenter extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("commander creatures"); + private static final FilterPermanent filter2 = new FilterPermanent("commanders"); + + static { + filter.add(CommanderPredicate.instance); + filter2.add(CommanderPredicate.instance); + } + + public GuardianAugmenter(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.CREATURE}, "{2}{G}"); + + this.subtype.add(SubType.TROLL); + this.subtype.add(SubType.WIZARD); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flash + this.addAbility(FlashAbility.getInstance()); + + // Commander creatures you control get +2/+2. + this.addAbility(new SimpleStaticAbility(new BoostControlledEffect( + 2, 2, Duration.WhileOnBattlefield, filter + ))); + + // Commanders you control have hexproof. + this.addAbility(new SimpleStaticAbility(new GainAbilityControlledEffect( + HexproofAbility.getInstance(), Duration.WhileOnBattlefield, filter2 + ))); + } + + private GuardianAugmenter(final GuardianAugmenter card) { + super(card); + } + + @Override + public GuardianAugmenter copy() { + return new GuardianAugmenter(this); + } +} diff --git a/Mage.Sets/src/mage/sets/Commander2021Edition.java b/Mage.Sets/src/mage/sets/Commander2021Edition.java index b160af00ab..7b10b302f8 100644 --- a/Mage.Sets/src/mage/sets/Commander2021Edition.java +++ b/Mage.Sets/src/mage/sets/Commander2021Edition.java @@ -47,6 +47,7 @@ public final class Commander2021Edition extends ExpansionSet { cards.add(new SetCardInfo("Feldon of the Third Path", 169, Rarity.MYTHIC, mage.cards.f.FeldonOfTheThirdPath.class)); cards.add(new SetCardInfo("Fiery Encore", 51, Rarity.RARE, mage.cards.f.FieryEncore.class)); cards.add(new SetCardInfo("Great Furnace", 292, Rarity.COMMON, mage.cards.g.GreatFurnace.class)); + cards.add(new SetCardInfo("Guardian Augmenter", 62, Rarity.RARE, mage.cards.g.GuardianAugmenter.class)); cards.add(new SetCardInfo("Hedron Archive", 244, Rarity.UNCOMMON, mage.cards.h.HedronArchive.class)); cards.add(new SetCardInfo("Hellkite Igniter", 171, Rarity.RARE, mage.cards.h.HellkiteIgniter.class)); cards.add(new SetCardInfo("Hellkite Tyrant", 172, Rarity.MYTHIC, mage.cards.h.HellkiteTyrant.class));