From 592362a258a1d4f2877aa44aaa9c39fe98bc460b Mon Sep 17 00:00:00 2001 From: Evan Kranzler Date: Thu, 21 Jun 2018 22:59:29 -0400 Subject: [PATCH] Implemented Tezzeret, Artifice Master --- .../mage/cards/t/TezzeretArtificeMaster.java | 58 +++++++++++++++++++ Mage.Sets/src/mage/sets/CoreSet2019.java | 1 + .../emblems/TezzeretArtificeMasterEmblem.java | 26 +++++++++ 3 files changed, 85 insertions(+) create mode 100644 Mage.Sets/src/mage/cards/t/TezzeretArtificeMaster.java create mode 100644 Mage/src/main/java/mage/game/command/emblems/TezzeretArtificeMasterEmblem.java diff --git a/Mage.Sets/src/mage/cards/t/TezzeretArtificeMaster.java b/Mage.Sets/src/mage/cards/t/TezzeretArtificeMaster.java new file mode 100644 index 0000000000..a1843d8453 --- /dev/null +++ b/Mage.Sets/src/mage/cards/t/TezzeretArtificeMaster.java @@ -0,0 +1,58 @@ +package mage.cards.t; + +import java.util.UUID; +import mage.abilities.LoyaltyAbility; +import mage.abilities.common.PlanswalkerEntersWithLoyalityCountersAbility; +import mage.abilities.condition.common.MetalcraftCondition; +import mage.abilities.decorator.ConditionalOneShotEffect; +import mage.abilities.effects.common.CreateTokenEffect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.GetEmblemEffect; +import mage.constants.SubType; +import mage.constants.SuperType; +import mage.cards.CardImpl; +import mage.cards.CardSetInfo; +import mage.constants.CardType; +import mage.game.command.emblems.TezzeretArtificeMasterEmblem; +import mage.game.permanent.token.ThopterColorlessToken; + +/** + * + * @author TheElk801 + */ +public final class TezzeretArtificeMaster extends CardImpl { + + public TezzeretArtificeMaster(UUID ownerId, CardSetInfo setInfo) { + super(ownerId, setInfo, new CardType[]{CardType.PLANESWALKER}, "{3}{U}{U}"); + + this.addSuperType(SuperType.LEGENDARY); + this.subtype.add(SubType.TEZZERET); + this.addAbility(new PlanswalkerEntersWithLoyalityCountersAbility(5)); + + // +1: Create a colorless Thopter artifact creature token with flying. + this.addAbility(new LoyaltyAbility(new CreateTokenEffect(new ThopterColorlessToken()), 1)); + + // 0: Draw a card. If you control three or more artifacts, draw two cards instead. + this.addAbility(new LoyaltyAbility(new ConditionalOneShotEffect( + new DrawCardSourceControllerEffect(2), + new DrawCardSourceControllerEffect(1), + MetalcraftCondition.instance, + "Draw a card. If you control three or " + + "more artifacts, draw two cards instead" + ), 0)); + + // −9: You get an emblem with "At the beginning of your end step, search your library for a permanent card, put it into the battlefield, then shuffle your library." + this.addAbility(new LoyaltyAbility( + new GetEmblemEffect(new TezzeretArtificeMasterEmblem()), -9 + )); + } + + public TezzeretArtificeMaster(final TezzeretArtificeMaster card) { + super(card); + } + + @Override + public TezzeretArtificeMaster copy() { + return new TezzeretArtificeMaster(this); + } +} diff --git a/Mage.Sets/src/mage/sets/CoreSet2019.java b/Mage.Sets/src/mage/sets/CoreSet2019.java index 1340bb9d75..312dcf0fdc 100644 --- a/Mage.Sets/src/mage/sets/CoreSet2019.java +++ b/Mage.Sets/src/mage/sets/CoreSet2019.java @@ -245,6 +245,7 @@ public final class CoreSet2019 extends ExpansionSet { cards.add(new SetCardInfo("Tattered Mummy", 295, Rarity.COMMON, mage.cards.t.TatteredMummy.class)); cards.add(new SetCardInfo("Tezzeret's Gatebreaker", 289, Rarity.RARE, mage.cards.t.TezzeretsGatebreaker.class)); cards.add(new SetCardInfo("Tezzeret's Strider", 290, Rarity.UNCOMMON, mage.cards.t.TezzeretsStrider.class)); + cards.add(new SetCardInfo("Tezzeret, Artifice Master", 79, Rarity.MYTHIC, mage.cards.t.TezzeretArtificeMaster.class)); cards.add(new SetCardInfo("Tezzeret, Cruel Machinist", 286, Rarity.MYTHIC, mage.cards.t.TezzeretCruelMachinist.class)); cards.add(new SetCardInfo("Thorn Lieutenant", 203, Rarity.RARE, mage.cards.t.ThornLieutenant.class)); cards.add(new SetCardInfo("Thornhide Wolves", 204, Rarity.COMMON, mage.cards.t.ThornhideWolves.class)); diff --git a/Mage/src/main/java/mage/game/command/emblems/TezzeretArtificeMasterEmblem.java b/Mage/src/main/java/mage/game/command/emblems/TezzeretArtificeMasterEmblem.java new file mode 100644 index 0000000000..24376c9a17 --- /dev/null +++ b/Mage/src/main/java/mage/game/command/emblems/TezzeretArtificeMasterEmblem.java @@ -0,0 +1,26 @@ +package mage.game.command.emblems; + +import mage.abilities.common.BeginningOfEndStepTriggeredAbility; +import mage.abilities.effects.common.search.SearchLibraryPutInPlayEffect; +import mage.constants.TargetController; +import mage.filter.common.FilterPermanentCard; +import mage.game.command.Emblem; +import mage.target.common.TargetCardInLibrary; + +/** + * + * @author spjspj + */ +public class TezzeretArtificeMasterEmblem extends Emblem { + + // −9: You get an emblem with "At the beginning of your end step, search your library for a permanent card, put it into the battlefield, then shuffle your library." + public TezzeretArtificeMasterEmblem() { + this.setName("Emblem Tezzeret"); + this.setExpansionSetCodeForImage("M19"); + this.getAbilities().add(new BeginningOfEndStepTriggeredAbility( + new SearchLibraryPutInPlayEffect( + new TargetCardInLibrary(new FilterPermanentCard()) + ), TargetController.YOU, false + )); + } +}