From 74397dbaed5ad97d174b92c64cecd675b67d75b7 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Wed, 15 Jul 2015 08:04:36 +0300 Subject: [PATCH 1/6] Fix PermanentsTargetOpponentControlsCount --- .../common/PermanentsTargetOpponentControlsCount.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java index f1f7ef9b874..20ac6b22b9a 100644 --- a/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java +++ b/Mage/src/mage/abilities/dynamicvalue/common/PermanentsTargetOpponentControlsCount.java @@ -26,7 +26,7 @@ public class PermanentsTargetOpponentControlsCount implements DynamicValue { } public PermanentsTargetOpponentControlsCount(FilterPermanent filter, Integer multiplier) { - this.filter = filter; + this.filter = filter.copy(); this.multiplier = multiplier; } From 650ba2cba7f4e6a77be48ad7eb3db541ef09af90 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Wed, 15 Jul 2015 08:04:58 +0300 Subject: [PATCH 2/6] Implement cards: Aurora Griffin, Escape Routes, Honorable Scout, and Phyrexian Bloodstock --- .../mage/sets/planeshift/AuroraGriffin.java | 75 +++++++++++++++++ .../mage/sets/planeshift/EscapeRoutes.java | 78 ++++++++++++++++++ .../mage/sets/planeshift/HonorableScout.java | 80 +++++++++++++++++++ .../sets/planeshift/PhyrexianBloodstock.java | 76 ++++++++++++++++++ 4 files changed, 309 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/HonorableScout.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java diff --git a/Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java b/Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java new file mode 100644 index 00000000000..251546109d7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/AuroraGriffin.java @@ -0,0 +1,75 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; + +/** + * + * @author LoneFox + */ +public class AuroraGriffin extends CardImpl { + + public AuroraGriffin(UUID ownerId) { + super(ownerId, 2, "Aurora Griffin", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Griffin"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // {W}: Target permanent becomes white until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(ObjectColor.WHITE, + Duration.EndOfTurn), new ManaCostsImpl("{W}")); + ability.addTarget(new TargetPermanent()); + this.addAbility(ability); + } + + public AuroraGriffin(final AuroraGriffin card) { + super(card); + } + + @Override + public AuroraGriffin copy() { + return new AuroraGriffin(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java b/Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java new file mode 100644 index 00000000000..e39db8fd8e7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/EscapeRoutes.java @@ -0,0 +1,78 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.ReturnToHandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class EscapeRoutes extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white or black creature you control"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.WHITE), new ColorPredicate(ObjectColor.BLACK))); + filter.add(new ControllerPredicate(TargetController.YOU)); + } + + public EscapeRoutes(UUID ownerId) { + super(ownerId, 25, "Escape Routes", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}"); + this.expansionSetCode = "PLS"; + + // {2}{U}: Return target white or black creature you control to its owner's hand. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new ReturnToHandTargetEffect(), new ManaCostsImpl("{2}{U}")); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public EscapeRoutes(final EscapeRoutes card) { + super(card); + } + + @Override + public EscapeRoutes copy() { + return new EscapeRoutes(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/HonorableScout.java b/Mage.Sets/src/mage/sets/planeshift/HonorableScout.java new file mode 100644 index 00000000000..97d924c4c29 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/HonorableScout.java @@ -0,0 +1,80 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsTargetOpponentControlsCount; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetOpponent; + +/** + * + * @author LoneFox + */ +public class HonorableScout extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("black and/or red creature"); + + static { + filter.add(Predicates.or(new ColorPredicate(ObjectColor.BLACK), new ColorPredicate(ObjectColor.RED))); + } + + public HonorableScout(UUID ownerId) { + super(ownerId, 8, "Honorable Scout", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{W}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Human"); + this.subtype.add("Soldier"); + this.subtype.add("Scout"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // When Honorable Scout enters the battlefield, you gain 2 life for each black and/or red creature target opponent controls. + Ability ability = new EntersBattlefieldTriggeredAbility(new GainLifeEffect(new PermanentsTargetOpponentControlsCount(filter, 2))); + ability.addTarget(new TargetOpponent()); + this.addAbility(ability); + } + + public HonorableScout(final HonorableScout card) { + super(card); + } + + @Override + public HonorableScout copy() { + return new HonorableScout(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java b/Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java new file mode 100644 index 00000000000..71027519ae0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/PhyrexianBloodstock.java @@ -0,0 +1,76 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.LeavesBattlefieldTriggeredAbility; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class PhyrexianBloodstock extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("white creature"); + + static { + filter.add(new ColorPredicate(ObjectColor.WHITE)); + } + + public PhyrexianBloodstock(UUID ownerId) { + super(ownerId, 50, "Phyrexian Bloodstock", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{B}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Zombie"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // When Phyrexian Bloodstock leaves the battlefield, destroy target white creature. It can't be regenerated. + Ability ability = new LeavesBattlefieldTriggeredAbility(new DestroyTargetEffect(true), false); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public PhyrexianBloodstock(final PhyrexianBloodstock card) { + super(card); + } + + @Override + public PhyrexianBloodstock copy() { + return new PhyrexianBloodstock(this); + } +} From a53f9a3735a32dec7e547c5d0f6362f2fecaf7c8 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Wed, 15 Jul 2015 11:02:55 +0300 Subject: [PATCH 3/6] Implement cards: Exotic Disease, Mire Kavu, Pygmy Kavu, and Quirion Explorer --- .../mage/sets/planeshift/ExoticDisease.java | 69 +++++++++++++++++ .../src/mage/sets/planeshift/MireKavu.java | 72 ++++++++++++++++++ .../src/mage/sets/planeshift/PygmyKavu.java | 76 +++++++++++++++++++ .../mage/sets/planeshift/QuirionExplorer.java | 64 ++++++++++++++++ 4 files changed, 281 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/MireKavu.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java diff --git a/Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java b/Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java new file mode 100644 index 00000000000..3b453b32b4d --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/ExoticDisease.java @@ -0,0 +1,69 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.abilities.effects.common.LoseLifeTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.target.TargetPlayer; + +/** + * + * @author LoneFox + */ +public class ExoticDisease extends CardImpl { + + public ExoticDisease(UUID ownerId) { + super(ownerId, 43, "Exotic Disease", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{4}{B}"); + this.expansionSetCode = "PLS"; + + // Domain - Target player loses X life and you gain X life, where X is the number of basic land types among lands you control. + DomainValue dv = new DomainValue(); + Effect effect = new LoseLifeTargetEffect(dv); + effect.setText("Domain - Target player loses X life"); + this.getSpellAbility().addEffect(effect); + effect = new GainLifeEffect(dv); + effect.setText("and you gain X life, where X is the number of basic land types among lands you control"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetPlayer()); + } + + public ExoticDisease(final ExoticDisease card) { + super(card); + } + + @Override + public ExoticDisease copy() { + return new ExoticDisease(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/MireKavu.java b/Mage.Sets/src/mage/sets/planeshift/MireKavu.java new file mode 100644 index 00000000000..4833b72e1f8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/MireKavu.java @@ -0,0 +1,72 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.common.continuous.BoostSourceWhileControlsEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.FilterPermanent; +import mage.filter.predicate.mageobject.SubtypePredicate; + +/** + * + * @author LoneFox + */ +public class MireKavu extends CardImpl { + + private static final FilterPermanent filter = new FilterPermanent("Swamp"); + + static { + filter.add(new SubtypePredicate("Swamp")); + } + + public MireKavu(UUID ownerId) { + super(ownerId, 67, "Mire Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{R}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(3); + this.toughness = new MageInt(2); + + // Mire Kavu gets +1/+1 as long as you control a Swamp. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostSourceWhileControlsEffect(filter, 1, 1))); + } + + public MireKavu(final MireKavu card) { + super(card); + } + + @Override + public MireKavu copy() { + return new MireKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java b/Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java new file mode 100644 index 00000000000..4cba0900000 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/PygmyKavu.java @@ -0,0 +1,76 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.common.EntersBattlefieldTriggeredAbility; +import mage.abilities.dynamicvalue.common.PermanentsOnBattlefieldCount; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.permanent.ControllerPredicate; + +/** + * + * @author LoneFox + */ +public class PygmyKavu extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("black creature your opponents control"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLACK)); + filter.add(new ControllerPredicate(TargetController.OPPONENT)); + } + + public PygmyKavu(UUID ownerId) { + super(ownerId, 88, "Pygmy Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{3}{G}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // When Pygmy Kavu enters the battlefield, draw a card for each black creature your opponents control. + this.addAbility(new EntersBattlefieldTriggeredAbility(new DrawCardSourceControllerEffect(new PermanentsOnBattlefieldCount(filter)))); + } + + public PygmyKavu(final PygmyKavu card) { + super(card); + } + + @Override + public PygmyKavu copy() { + return new PygmyKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java b/Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java new file mode 100644 index 00000000000..bccab7725ad --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/QuirionExplorer.java @@ -0,0 +1,64 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.mana.AnyColorOpponentLandsProduceManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class QuirionExplorer extends CardImpl { + + public QuirionExplorer(UUID ownerId) { + super(ownerId, 90, "Quirion Explorer", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{1}{G}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Elf"); + this.subtype.add("Druid"); + this.subtype.add("Scout"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {T}: Add to your mana pool one mana of any color that a land an opponent controls could produce. + this.addAbility(new AnyColorOpponentLandsProduceManaAbility()); + } + + public QuirionExplorer(final QuirionExplorer card) { + super(card); + } + + @Override + public QuirionExplorer copy() { + return new QuirionExplorer(this); + } +} From 0a5c152db24711e3f382d7334c9a1fa6e91362a4 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Thu, 16 Jul 2015 08:57:14 +0300 Subject: [PATCH 4/6] Implement cards: Death Bomb, Ertai's Trickery, Shriek of Death, and Skyshroud Blessing --- .../src/mage/sets/planeshift/DeathBomb.java | 76 ++++++++++++++++ .../mage/sets/planeshift/ErtaisTrickery.java | 91 +++++++++++++++++++ .../mage/sets/planeshift/ShriekOfDread.java | 62 +++++++++++++ .../sets/planeshift/SkyshroudBlessing.java | 65 +++++++++++++ 4 files changed, 294 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/planeshift/DeathBomb.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java diff --git a/Mage.Sets/src/mage/sets/planeshift/DeathBomb.java b/Mage.Sets/src/mage/sets/planeshift/DeathBomb.java new file mode 100644 index 00000000000..8266d993c30 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/DeathBomb.java @@ -0,0 +1,76 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.costs.common.SacrificeTargetCost; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.abilities.effects.common.LoseLifeTargetControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.filter.common.FilterControlledCreaturePermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetControlledCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class DeathBomb extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("nonblack creature"); + static { + filter.add(Predicates.not(new ColorPredicate(ObjectColor.BLACK))); + } + + public DeathBomb(UUID ownerId) { + super(ownerId, 41, "Death Bomb", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{B}"); + this.expansionSetCode = "PLS"; + + // As an additional cost to cast Death Bomb, sacrifice a creature. + this.getSpellAbility().addCost(new SacrificeTargetCost(new TargetControlledCreaturePermanent(1,1, new FilterControlledCreaturePermanent("a creature"), true))); + // Destroy target nonblack creature. It can't be regenerated. Its controller loses 2 life. + this.getSpellAbility().addEffect(new DestroyTargetEffect(true)); + this.getSpellAbility().addEffect(new LoseLifeTargetControllerEffect(2)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); + } + + public DeathBomb(final DeathBomb card) { + super(card); + } + + @Override + public DeathBomb copy() { + return new DeathBomb(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java b/Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java new file mode 100644 index 00000000000..7018891526b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/ErtaisTrickery.java @@ -0,0 +1,91 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.condition.common.KickedCondition; +import mage.abilities.effects.common.CounterTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.stack.Spell; +import mage.target.TargetSpell; + +/** + * + * @author LoneFox + */ +public class ErtaisTrickery extends CardImpl { + + public ErtaisTrickery(UUID ownerId) { + super(ownerId, 24, "Ertai's Trickery", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{U}"); + this.expansionSetCode = "PLS"; + + // Counter target spell if it was kicked. + this.getSpellAbility().addEffect(new ErtaisTrickeryEffect()); + this.getSpellAbility().addTarget(new TargetSpell()); + } + + public ErtaisTrickery(final ErtaisTrickery card) { + super(card); + } + + @Override + public ErtaisTrickery copy() { + return new ErtaisTrickery(this); + } +} + +class ErtaisTrickeryEffect extends CounterTargetEffect { + + public ErtaisTrickeryEffect() { + super(); + staticText = "Counter target spell if it was kicked."; + } + + public ErtaisTrickeryEffect(final CounterTargetEffect effect) { + super(effect); + } + + @Override + public ErtaisTrickeryEffect copy() { + return new ErtaisTrickeryEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Spell targetSpell = game.getStack().getSpell(source.getFirstTarget()); + if(targetSpell != null && KickedCondition.getInstance().apply(game, targetSpell.getSpellAbility())) { + return super.apply(game, source); + } + return false; + } + +} diff --git a/Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java b/Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java new file mode 100644 index 00000000000..769e10d3d32 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/ShriekOfDread.java @@ -0,0 +1,62 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; +import mage.abilities.keyword.FearAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class ShriekOfDread extends CardImpl { + + public ShriekOfDread(UUID ownerId) { + super(ownerId, 53, "Shriek of Dread", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{1}{B}"); + this.expansionSetCode = "PLS"; + + // Target creature gains fear until end of turn. + this.getSpellAbility().addEffect(new GainAbilityTargetEffect(FearAbility.getInstance(), Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + } + + public ShriekOfDread(final ShriekOfDread card) { + super(card); + } + + @Override + public ShriekOfDread copy() { + return new ShriekOfDread(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java b/Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java new file mode 100644 index 00000000000..decb8652a7b --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SkyshroudBlessing.java @@ -0,0 +1,65 @@ +/* + * 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.planeshift; + +import java.util.UUID; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.continuous.GainAbilityAllEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.filter.common.FilterLandPermanent; + +/** + * + * @author LoneFox + */ +public class SkyshroudBlessing extends CardImpl { + + public SkyshroudBlessing(UUID ownerId) { + super(ownerId, 92, "Skyshroud Blessing", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{G}"); + this.expansionSetCode = "PLS"; + + // Lands gain shroud until end of turn. + this.getSpellAbility().addEffect(new GainAbilityAllEffect(ShroudAbility.getInstance(), + Duration.EndOfTurn, new FilterLandPermanent("all lands"))); + // Draw a card. + this.getSpellAbility().addEffect(new DrawCardSourceControllerEffect(1)); + } + + public SkyshroudBlessing(final SkyshroudBlessing card) { + super(card); + } + + @Override + public SkyshroudBlessing copy() { + return new SkyshroudBlessing(this); + } +} From 3149cd810fa0cc253d79d8b4ffa9e50961dac9dd Mon Sep 17 00:00:00 2001 From: LoneFox Date: Thu, 16 Jul 2015 09:30:02 +0300 Subject: [PATCH 5/6] Implement cards: Kavu Recluse, Reef Shaman, Sea Snidd, and Slimy Kavu --- .../src/mage/sets/apocalypse/ReefShaman.java | 72 +++++++++++++++++++ .../src/mage/sets/invasion/SlimyKavu.java | 70 ++++++++++++++++++ .../src/mage/sets/planeshift/KavuRecluse.java | 70 ++++++++++++++++++ .../src/mage/sets/planeshift/SeaSnidd.java | 71 ++++++++++++++++++ 4 files changed, 283 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java create mode 100644 Mage.Sets/src/mage/sets/invasion/SlimyKavu.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java create mode 100644 Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java diff --git a/Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java b/Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java new file mode 100644 index 00000000000..a66ce005308 --- /dev/null +++ b/Mage.Sets/src/mage/sets/apocalypse/ReefShaman.java @@ -0,0 +1,72 @@ +/* + * 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.apocalypse; + +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.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class ReefShaman extends CardImpl { + + public ReefShaman(UUID ownerId) { + super(ownerId, 29, "Reef Shaman", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{U}"); + this.expansionSetCode = "APC"; + this.subtype.add("Merfolk"); + this.subtype.add("Shaman"); + this.power = new MageInt(0); + this.toughness = new MageInt(2); + + // {T}: Target land becomes the basic land type of your choice until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public ReefShaman(final ReefShaman card) { + super(card); + } + + @Override + public ReefShaman copy() { + return new ReefShaman(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/SlimyKavu.java b/Mage.Sets/src/mage/sets/invasion/SlimyKavu.java new file mode 100644 index 00000000000..2f32f766387 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/SlimyKavu.java @@ -0,0 +1,70 @@ +/* + * 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.invasion; + +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.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class SlimyKavu extends CardImpl { + + public SlimyKavu(UUID ownerId) { + super(ownerId, 170, "Slimy Kavu", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Kavu"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {T}: Target land becomes a Swamp until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, "Swamp"), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public SlimyKavu(final SlimyKavu card) { + super(card); + } + + @Override + public SlimyKavu copy() { + return new SlimyKavu(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java b/Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java new file mode 100644 index 00000000000..b90364edac5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/KavuRecluse.java @@ -0,0 +1,70 @@ +/* + * 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.planeshift; + +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.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class KavuRecluse extends CardImpl { + + public KavuRecluse(UUID ownerId) { + super(ownerId, 64, "Kavu Recluse", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{R}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Kavu"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // {T}: Target land becomes a Forest until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn, "Forest"), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public KavuRecluse(final KavuRecluse card) { + super(card); + } + + @Override + public KavuRecluse copy() { + return new KavuRecluse(this); + } +} diff --git a/Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java b/Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java new file mode 100644 index 00000000000..f6eb16aabcc --- /dev/null +++ b/Mage.Sets/src/mage/sets/planeshift/SeaSnidd.java @@ -0,0 +1,71 @@ +/* + * 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.planeshift; + +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.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BecomesBasicLandTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetLandPermanent; + +/** + * + * @author LoneFox + */ +public class SeaSnidd extends CardImpl { + + public SeaSnidd(UUID ownerId) { + super(ownerId, 31, "Sea Snidd", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{U}"); + this.expansionSetCode = "PLS"; + this.subtype.add("Beast"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {T}: Target land becomes the basic land type of your choice until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesBasicLandTargetEffect(Duration.EndOfTurn), new TapSourceCost()); + ability.addTarget(new TargetLandPermanent()); + this.addAbility(ability); + } + + public SeaSnidd(final SeaSnidd card) { + super(card); + } + + @Override + public SeaSnidd copy() { + return new SeaSnidd(this); + } +} From 30ae59cc18fa96d5f46cb7096b9c4bbc83849743 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Thu, 16 Jul 2015 21:09:46 +0300 Subject: [PATCH 6/6] Implement cards: Metathran Transport, Pyre Zombie, Wandering Stream, and Wings of Hope --- .../sets/invasion/MetathranTransport.java | 87 +++++++++++++++++++ .../src/mage/sets/invasion/PyreZombie.java | 79 +++++++++++++++++ .../mage/sets/invasion/WanderingStream.java | 63 ++++++++++++++ .../src/mage/sets/invasion/WingsOfHope.java | 82 +++++++++++++++++ 4 files changed, 311 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/invasion/MetathranTransport.java create mode 100644 Mage.Sets/src/mage/sets/invasion/PyreZombie.java create mode 100644 Mage.Sets/src/mage/sets/invasion/WanderingStream.java create mode 100644 Mage.Sets/src/mage/sets/invasion/WingsOfHope.java diff --git a/Mage.Sets/src/mage/sets/invasion/MetathranTransport.java b/Mage.Sets/src/mage/sets/invasion/MetathranTransport.java new file mode 100644 index 00000000000..e650e7f25aa --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/MetathranTransport.java @@ -0,0 +1,87 @@ +/* + * 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.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.common.SimpleEvasionAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.combat.CantBeBlockedByCreaturesSourceEffect; +import mage.abilities.effects.common.continuous.BecomesColorTargetEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class MetathranTransport extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("blue creatures"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLUE)); + } + + public MetathranTransport(UUID ownerId) { + super(ownerId, 62, "Metathran Transport", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{U}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Metathran"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + // Metathran Transport can't be blocked by blue creatures. + this.addAbility(new SimpleEvasionAbility(new CantBeBlockedByCreaturesSourceEffect(filter, Duration.WhileOnBattlefield))); + // {U}: Target creature becomes blue until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BecomesColorTargetEffect(ObjectColor.BLUE, + Duration.EndOfTurn), new ManaCostsImpl("{U}")); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public MetathranTransport(final MetathranTransport card) { + super(card); + } + + @Override + public MetathranTransport copy() { + return new MetathranTransport(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/PyreZombie.java b/Mage.Sets/src/mage/sets/invasion/PyreZombie.java new file mode 100644 index 00000000000..b9a1ace8379 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/PyreZombie.java @@ -0,0 +1,79 @@ +/* + * 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.invasion; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.abilities.effects.common.ReturnToHandSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class PyreZombie extends CardImpl { + + public PyreZombie(UUID ownerId) { + super(ownerId, 261, "Pyre Zombie", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{1}{B}{R}"); + this.expansionSetCode = "INV"; + this.subtype.add("Zombie"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // At the beginning of your upkeep, if Pyre Zombie is in your graveyard, you may pay {1}{B}{B}. If you do, return Pyre Zombie to your hand. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.GRAVEYARD, + new DoIfCostPaid(new ReturnToHandSourceEffect(), new ManaCostsImpl("{1}{B}{B}")), + TargetController.YOU, false)); + // {1}{R}{R}, Sacrifice Pyre Zombie: Pyre Zombie deals 2 damage to target creature or player. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DamageTargetEffect(2), new ManaCostsImpl("{1}{R}{R}")); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public PyreZombie(final PyreZombie card) { + super(card); + } + + @Override + public PyreZombie copy() { + return new PyreZombie(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/WanderingStream.java b/Mage.Sets/src/mage/sets/invasion/WanderingStream.java new file mode 100644 index 00000000000..e2808415610 --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/WanderingStream.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.invasion; + +import java.util.UUID; +import mage.abilities.dynamicvalue.MultipliedValue; +import mage.abilities.dynamicvalue.common.DomainValue; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.GainLifeEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class WanderingStream extends CardImpl { + + public WanderingStream(UUID ownerId) { + super(ownerId, 224, "Wandering Stream", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{G}"); + this.expansionSetCode = "INV"; + + // Domain - You gain 2 life for each basic land type among lands you control. + Effect effect = new GainLifeEffect(new MultipliedValue(new DomainValue(), 2)); + effect.setText("Domain - You gain 2 life for each basic land type among lands you control"); + this.getSpellAbility().addEffect(effect); + } + + public WanderingStream(final WanderingStream card) { + super(card); + } + + @Override + public WanderingStream copy() { + return new WanderingStream(this); + } +} diff --git a/Mage.Sets/src/mage/sets/invasion/WingsOfHope.java b/Mage.Sets/src/mage/sets/invasion/WingsOfHope.java new file mode 100644 index 00000000000..5475eba52ef --- /dev/null +++ b/Mage.Sets/src/mage/sets/invasion/WingsOfHope.java @@ -0,0 +1,82 @@ +/* + * 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.invasion; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.AttachEffect; +import mage.abilities.effects.common.continuous.BoostEnchantedEffect; +import mage.abilities.effects.common.continuous.GainAbilityAttachedEffect; +import mage.abilities.keyword.EnchantAbility; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.constants.AttachmentType; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetPermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class WingsOfHope extends CardImpl { + + public WingsOfHope(UUID ownerId) { + super(ownerId, 289, "Wings of Hope", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{W}{U}"); + this.expansionSetCode = "INV"; + this.subtype.add("Aura"); + + // Enchant creature + TargetPermanent auraTarget = new TargetCreaturePermanent(); + this.getSpellAbility().addTarget(auraTarget); + this.getSpellAbility().addEffect(new AttachEffect(Outcome.BoostCreature)); + Ability ability = new EnchantAbility(auraTarget.getTargetName()); + this.addAbility(ability); + // Enchanted creature gets +1/+3 and has flying. + ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEnchantedEffect(1, 3, Duration.WhileOnBattlefield)); + Effect effect = new GainAbilityAttachedEffect(FlyingAbility.getInstance(), AttachmentType.AURA); + effect.setText("and has flying"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public WingsOfHope(final WingsOfHope card) { + super(card); + } + + @Override + public WingsOfHope copy() { + return new WingsOfHope(this); + } +}