From 9c0e73dfdb4b15581a5e9d4a6b5b1e76e23d329d Mon Sep 17 00:00:00 2001 From: fireshoes Date: Fri, 1 Jul 2016 15:00:18 -0500 Subject: [PATCH] Fixed Warriors' Lesson to only trigger on combat damage instead of all damage.[EMN] Added a few more cards. --- .../eldritchmoon/DecimatorOfTheProvinces.java | 88 +++++++++++ .../eldritchmoon/DistendedMindbender.java | 144 ++++++++++++++++++ .../mage/sets/eldritchmoon/PeaceOfMind.java | 52 +++++++ .../src/mage/sets/eldritchmoon/PreyUpon.java | 52 +++++++ .../sets/eldritchmoon/TreeOfPerdition.java | 123 +++++++++++++++ .../mage/sets/eldritchmoon/WailingGhoul.java | 63 ++++++++ .../mage/sets/eldritchmoon/WretchedGryff.java | 73 +++++++++ .../src/mage/sets/theros/WarriorsLesson.java | 4 +- Utils/mtg-cards-data.txt | 1 + 9 files changed, 598 insertions(+), 2 deletions(-) create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/DecimatorOfTheProvinces.java create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/DistendedMindbender.java create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/PeaceOfMind.java create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/PreyUpon.java create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/TreeOfPerdition.java create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/WailingGhoul.java create mode 100644 Mage.Sets/src/mage/sets/eldritchmoon/WretchedGryff.java diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/DecimatorOfTheProvinces.java b/Mage.Sets/src/mage/sets/eldritchmoon/DecimatorOfTheProvinces.java new file mode 100644 index 00000000000..8b5a67fbffa --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/DecimatorOfTheProvinces.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.CastSourceTriggeredAbility; +import mage.abilities.effects.common.continuous.BoostControlledEffect; +import mage.abilities.effects.common.continuous.GainAbilityControlledEffect; +import mage.abilities.keyword.EmergeAbility; +import mage.abilities.keyword.HasteAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author fireshoes + */ +public class DecimatorOfTheProvinces extends CardImpl { + + public DecimatorOfTheProvinces(UUID ownerId) { + super(ownerId, 2, "Decimator of the Provinces", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{10}"); + this.expansionSetCode = "EMN"; + this.subtype.add("Eldrazi"); + this.subtype.add("Boar"); + this.power = new MageInt(7); + this.toughness = new MageInt(7); + + // Emerge {6}{G}{G}{G} + this.addAbility(new EmergeAbility(this, new ManaCostsImpl<>("{6}{G}{G}{G}"))); + + // When you cast Decimator of the Provinces, creatures you control get +2/+2 and gain trample until end of turn. + Effect effect = new BoostControlledEffect(2, 2, Duration.EndOfTurn); + effect.setText("creatures you control get +2/+2"); + Ability ability = new CastSourceTriggeredAbility(effect); + effect = new GainAbilityControlledEffect(TrampleAbility.getInstance(), Duration.EndOfTurn, new FilterCreaturePermanent()); + effect.setText("and gain trample until end of turn"); + ability.addEffect(effect); + this.addAbility(ability); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + + // Haste + this.addAbility(HasteAbility.getInstance()); + } + + public DecimatorOfTheProvinces(final DecimatorOfTheProvinces card) { + super(card); + } + + @Override + public DecimatorOfTheProvinces copy() { + return new DecimatorOfTheProvinces(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/DistendedMindbender.java b/Mage.Sets/src/mage/sets/eldritchmoon/DistendedMindbender.java new file mode 100644 index 00000000000..1b94f55d8bf --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/DistendedMindbender.java @@ -0,0 +1,144 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.List; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.CastSourceTriggeredAbility; +import mage.abilities.keyword.EmergeAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.Filter; +import mage.filter.FilterCard; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.filter.predicate.mageobject.ConvertedManaCostPredicate; +import mage.game.Game; +import mage.players.Player; +import mage.target.TargetCard; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class DistendedMindbender extends CardImpl { + + public DistendedMindbender(UUID ownerId) { + super(ownerId, 3, "Distended Mindbender", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{8}"); + this.expansionSetCode = "EMN"; + this.subtype.add("Eldrazi"); + this.subtype.add("Insect"); + this.power = new MageInt(5); + this.toughness = new MageInt(5); + + // Emerge {5}{B}{B} + this.addAbility(new EmergeAbility(this, new ManaCostsImpl<>("{5}{B}{B}"))); + + // When controller cast Distended Mindbender, target opponent reveals his or her hand. You choose from it a nonland card with converted mana cost 3 or less + // and a card with converted mana cost 4 or greater. That player discards those cards. + Ability ability = new CastSourceTriggeredAbility(new DistendedMindbenderEffect()); + ability.addTarget(new TargetOpponent()); + this.addAbility(ability); + } + + public DistendedMindbender(final DistendedMindbender card) { + super(card); + } + + @Override + public DistendedMindbender copy() { + return new DistendedMindbender(this); + } +} + +class DistendedMindbenderEffect extends OneShotEffect { + + private static final FilterCard filterFourOrGreater = new FilterCard("a card from it with converted mana cost 4 or greater"); + private static final FilterCard filterThreeOrLess = new FilterCard("a nonland card from it with converted mana cost 3 or less"); + + static { + filterFourOrGreater.add(new ConvertedManaCostPredicate(Filter.ComparisonType.GreaterThan, 3)); + filterThreeOrLess.add(new ConvertedManaCostPredicate(Filter.ComparisonType.LessThan, 4)); + filterThreeOrLess.add(Predicates.not(new CardTypePredicate(CardType.LAND))); + } + + public DistendedMindbenderEffect() { + super(Outcome.Discard); + this.staticText = "target opponent reveals his or her hand. You choose from it a nonland card with converted mana cost 3 or less and a card with " + + "converted mana cost 4 or greater. That player discards those cards."; + } + + public DistendedMindbenderEffect(final DistendedMindbenderEffect effect) { + super(effect); + } + + @Override + public DistendedMindbenderEffect copy() { + return new DistendedMindbenderEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player opponent = game.getPlayer(source.getFirstTarget()); + Player controller = game.getPlayer(source.getControllerId()); + if (opponent != null && controller != null) { + opponent.revealCards("Distended Mindbender", opponent.getHand(), game); + TargetCard targetThreeOrLess = new TargetCard(1, Zone.HAND, filterThreeOrLess); + TargetCard targetFourOrGreater = new TargetCard(1, Zone.HAND, filterFourOrGreater); + if (controller.choose(Outcome.Benefit, opponent.getHand(), targetThreeOrLess, game)) { + List targets = targetThreeOrLess.getTargets(); + for (UUID targetId : targets) { + Card card = opponent.getHand().get(targetId, game); + if (card != null) { + opponent.discard(card, source, game); + } + } + } + if (controller.choose(Outcome.Benefit, opponent.getHand(), targetFourOrGreater, game)) { + List targets = targetFourOrGreater.getTargets(); + for (UUID targetId : targets) { + Card card = opponent.getHand().get(targetId, game); + if (card != null) { + opponent.discard(card, source, game); + } + } + } + return true; + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/PeaceOfMind.java b/Mage.Sets/src/mage/sets/eldritchmoon/PeaceOfMind.java new file mode 100644 index 00000000000..d4fbd576a05 --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/PeaceOfMind.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class PeaceOfMind extends mage.sets.ninthedition.PeaceOfMind { + + public PeaceOfMind(UUID ownerId) { + super(ownerId); + this.cardNumber = 36; + this.expansionSetCode = "EMN"; + } + + public PeaceOfMind(final PeaceOfMind card) { + super(card); + } + + @Override + public PeaceOfMind copy() { + return new PeaceOfMind(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/PreyUpon.java b/Mage.Sets/src/mage/sets/eldritchmoon/PreyUpon.java new file mode 100644 index 00000000000..caf215f140d --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/PreyUpon.java @@ -0,0 +1,52 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.UUID; + +/** + * + * @author fireshoes + */ +public class PreyUpon extends mage.sets.innistrad.PreyUpon { + + public PreyUpon(UUID ownerId) { + super(ownerId); + this.cardNumber = 166; + this.expansionSetCode = "EMN"; + } + + public PreyUpon(final PreyUpon card) { + super(card); + } + + @Override + public PreyUpon copy() { + return new PreyUpon(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/TreeOfPerdition.java b/Mage.Sets/src/mage/sets/eldritchmoon/TreeOfPerdition.java new file mode 100644 index 00000000000..a6bd9ae4923 --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/TreeOfPerdition.java @@ -0,0 +1,123 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continuous.SetPowerToughnessSourceEffect; +import mage.abilities.keyword.DefenderAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.SubLayer; +import mage.constants.Zone; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.players.Player; +import mage.target.common.TargetOpponent; + +/** + * + * @author fireshoes + */ +public class TreeOfPerdition extends CardImpl { + + public TreeOfPerdition(UUID ownerId) { + super(ownerId, 109, "Tree of Perdition", Rarity.MYTHIC, new CardType[]{CardType.CREATURE}, "{3}{B}"); + this.expansionSetCode = "EMN"; + this.subtype.add("Plant"); + this.power = new MageInt(0); + this.toughness = new MageInt(13); + + // Defender + this.addAbility(DefenderAbility.getInstance()); + + // {tap}: Exchange target opponent's life total with Tree of Perdition's toughness. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TreeOfPerditionEffect(), new TapSourceCost()); + ability.addTarget(new TargetOpponent()); + this.addAbility(ability); + } + + public TreeOfPerdition(final TreeOfPerdition card) { + super(card); + } + + @Override + public TreeOfPerdition copy() { + return new TreeOfPerdition(this); + } +} + +class TreeOfPerditionEffect extends OneShotEffect { + + public TreeOfPerditionEffect() { + super(Outcome.Neutral); + staticText = "Exchange target opponent's life total with Tree of Perdition's toughness"; + } + + public TreeOfPerditionEffect(final TreeOfPerditionEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Player opponent = game.getPlayer(source.getFirstTarget()); + if (opponent != null && opponent.isLifeTotalCanChange()) { + Permanent perm = game.getPermanent(source.getSourceId()); + if (perm != null) { + int amount = perm.getToughness().getValue(); + int life = opponent.getLife(); + if (life == amount) { + return false; + } + if (life < amount && !opponent.isCanGainLife()) { + return false; + } + if (life > amount && !opponent.isCanLoseLife()) { + return false; + } + opponent.setLife(amount, game); + game.addEffect(new SetPowerToughnessSourceEffect(Integer.MIN_VALUE, life, Duration.WhileOnBattlefield, SubLayer.SetPT_7b), source); + return true; + } + } + return false; + } + + @Override + public TreeOfPerditionEffect copy() { + return new TreeOfPerditionEffect(this); + } + +} diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/WailingGhoul.java b/Mage.Sets/src/mage/sets/eldritchmoon/WailingGhoul.java new file mode 100644 index 00000000000..b6ab7103613 --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/WailingGhoul.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.effects.common.PutTopCardOfLibraryIntoGraveControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class WailingGhoul extends CardImpl { + + public WailingGhoul(UUID ownerId) { + super(ownerId, 112, "Wailing Ghoul", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{B}"); + this.expansionSetCode = "EMN"; + this.subtype.add("Zombie"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // When Wailing Ghoul enters the battlefield, put the top two cards of your library into your graveyard. + this.addAbility(new EntersBattlefieldTriggeredAbility(new PutTopCardOfLibraryIntoGraveControllerEffect(2))); + } + + public WailingGhoul(final WailingGhoul card) { + super(card); + } + + @Override + public WailingGhoul copy() { + return new WailingGhoul(this); + } +} diff --git a/Mage.Sets/src/mage/sets/eldritchmoon/WretchedGryff.java b/Mage.Sets/src/mage/sets/eldritchmoon/WretchedGryff.java new file mode 100644 index 00000000000..be1ff151082 --- /dev/null +++ b/Mage.Sets/src/mage/sets/eldritchmoon/WretchedGryff.java @@ -0,0 +1,73 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.eldritchmoon; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.CastSourceTriggeredAbility; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.keyword.EmergeAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author fireshoes + */ +public class WretchedGryff extends CardImpl { + + public WretchedGryff(UUID ownerId) { + super(ownerId, 12, "Wretched Gryff", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{7}"); + this.expansionSetCode = "EMN"; + this.subtype.add("Eldrazi"); + this.subtype.add("Hippogriff"); + this.power = new MageInt(3); + this.toughness = new MageInt(4); + + // Emerge {5}{U} + this.addAbility(new EmergeAbility(this, new ManaCostsImpl<>("{5}{U}"))); + + // When you cast Wretched Gryff, draw a card. + this.addAbility(new CastSourceTriggeredAbility(new DrawCardSourceControllerEffect(1))); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + } + + public WretchedGryff(final WretchedGryff card) { + super(card); + } + + @Override + public WretchedGryff copy() { + return new WretchedGryff(this); + } +} diff --git a/Mage.Sets/src/mage/sets/theros/WarriorsLesson.java b/Mage.Sets/src/mage/sets/theros/WarriorsLesson.java index 1102c8c40ab..6a131b3924e 100644 --- a/Mage.Sets/src/mage/sets/theros/WarriorsLesson.java +++ b/Mage.Sets/src/mage/sets/theros/WarriorsLesson.java @@ -29,7 +29,7 @@ package mage.sets.theros; import java.util.UUID; import mage.abilities.Ability; -import mage.abilities.common.DealsDamageToAPlayerTriggeredAbility; +import mage.abilities.common.DealsCombatDamageToAPlayerTriggeredAbility; import mage.abilities.effects.Effect; import mage.abilities.effects.common.DrawCardSourceControllerEffect; import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; @@ -51,7 +51,7 @@ public class WarriorsLesson extends CardImpl { // Until end of turn, up to two target creatures you control each gain "Whenever this creature deals combat damage to a player, draw a card." - Ability ability = new DealsDamageToAPlayerTriggeredAbility(new DrawCardSourceControllerEffect(1),false); + Ability ability = new DealsCombatDamageToAPlayerTriggeredAbility(new DrawCardSourceControllerEffect(1),false); Effect effect = new GainAbilityTargetEffect(ability, Duration.EndOfTurn); effect.setText("Until end of turn, up to two target creatures you control each gain \"Whenever this creature deals combat damage to a player, draw a card.\""); this.getSpellAbility().addEffect(effect); diff --git a/Utils/mtg-cards-data.txt b/Utils/mtg-cards-data.txt index 22e3ceab78a..7ca1eef071a 100644 --- a/Utils/mtg-cards-data.txt +++ b/Utils/mtg-cards-data.txt @@ -57336,6 +57336,7 @@ Midnight Scavengers|Eldritch Moon|96|C|{4}{B}|Creature - Human Rogue|3|3|When Mi Murder|Eldritch Moon|97|U|{1}{B}{B}|Instant|||Destroy target creature.| Noosegraf Mob|Eldritch Moon|98|R|{4}{B}{B}|Creature - Zombie|0|0|Noosegraf Mob enters the battlefield with five +1/+1 counters on it.$Whenever a player casts a spell, remove a +1/+1 counter from Noosegraf Mob. If you do, put a 2/2 black Zombie creature token onto the battlefield.| Stromkirk Condemned|Eldritch Moon|106|R|{B}{B}|Creature - Vampire Horror|2|2|Discard a card: Vampires you control get +1/+1 until end of turn. Activate this ability only once each turn.| +Tree of Perdition|Eldritch Moon|109|M|{3}{B}|Creature - Plant|0|13|Defender${tap}: Exchange target opponent's life total with Tree of Perdition's toughness.| Voldaren Pariah|Eldritch Moon|111|R|{3}{B}{B}|Creature - Vampire Horror|3|3|Flying$Sacrifice three other creatures: Transform Voldaren Pariah.$Madness {B}{B}{B} (If you discard this card, discard it into exile. When you do, cast it for its madness cost or put it into your graveyard.)| Abolisher of Bloodlines|Eldritch Moon|111|R||Creature - Eldrazi Vampire|6|5|Flying$When this creature transforms into Abolisher of Bloodlines, target opponent sacrifices three creatures.| Wailing Ghoul|Eldritch Moon|112|C|{1}{B}|Creature - Zombie|1|3|When Wailing Ghoul enters the battlefield, put the top two cards of your library into your graveyard.|