From ad4a75d94b9bd333987ee8a927aefb573c4714ae Mon Sep 17 00:00:00 2001 From: LoneFox Date: Sun, 11 Oct 2015 11:33:59 +0300 Subject: [PATCH 1/6] Implement cards: Armor Thrull, Dwarven Armorer, Dwarven Lieutenant, and Elven Lyre --- .../mage/sets/fallenempires/ArmorThrull1.java | 52 +++++++ .../mage/sets/fallenempires/ArmorThrull2.java | 52 +++++++ .../mage/sets/fallenempires/ArmorThrull3.java | 52 +++++++ .../mage/sets/fallenempires/ArmorThrull4.java | 52 +++++++ .../sets/fallenempires/DwarvenArmorer.java | 128 ++++++++++++++++++ .../sets/fallenempires/DwarvenLieutenant.java | 79 +++++++++++ .../mage/sets/fallenempires/ElvenLyre.java | 54 ++++++++ .../sets/masterseditionii/ArmorThrull.java | 72 ++++++++++ .../mage/sets/masterseditionii/ElvenLyre.java | 71 ++++++++++ Mage/src/mage/counters/CounterType.java | 6 + 10 files changed, 618 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ArmorThrull1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ArmorThrull2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ArmorThrull3.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ArmorThrull4.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/DwarvenArmorer.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/DwarvenLieutenant.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ElvenLyre.java create mode 100644 Mage.Sets/src/mage/sets/masterseditionii/ArmorThrull.java create mode 100644 Mage.Sets/src/mage/sets/masterseditionii/ElvenLyre.java diff --git a/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull1.java b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull1.java new file mode 100644 index 0000000000..e543304cf0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull1.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ArmorThrull1 extends mage.sets.masterseditionii.ArmorThrull { + + public ArmorThrull1(UUID ownerId) { + super(ownerId); + this.cardNumber = 1; + this.expansionSetCode = "FEM"; + } + + public ArmorThrull1(final ArmorThrull1 card) { + super(card); + } + + @Override + public ArmorThrull1 copy() { + return new ArmorThrull1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull2.java b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull2.java new file mode 100644 index 0000000000..c39b457788 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull2.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ArmorThrull2 extends mage.sets.masterseditionii.ArmorThrull { + + public ArmorThrull2(UUID ownerId) { + super(ownerId); + this.cardNumber = 2; + this.expansionSetCode = "FEM"; + } + + public ArmorThrull2(final ArmorThrull2 card) { + super(card); + } + + @Override + public ArmorThrull2 copy() { + return new ArmorThrull2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull3.java b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull3.java new file mode 100644 index 0000000000..2a16cd7b3f --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull3.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ArmorThrull3 extends mage.sets.masterseditionii.ArmorThrull { + + public ArmorThrull3(UUID ownerId) { + super(ownerId); + this.cardNumber = 3; + this.expansionSetCode = "FEM"; + } + + public ArmorThrull3(final ArmorThrull3 card) { + super(card); + } + + @Override + public ArmorThrull3 copy() { + return new ArmorThrull3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull4.java b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull4.java new file mode 100644 index 0000000000..97d46f8898 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ArmorThrull4.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ArmorThrull4 extends mage.sets.masterseditionii.ArmorThrull { + + public ArmorThrull4(UUID ownerId) { + super(ownerId); + this.cardNumber = 4; + this.expansionSetCode = "FEM"; + } + + public ArmorThrull4(final ArmorThrull4 card) { + super(card); + } + + @Override + public ArmorThrull4 copy() { + return new ArmorThrull4(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/DwarvenArmorer.java b/Mage.Sets/src/mage/sets/fallenempires/DwarvenArmorer.java new file mode 100644 index 0000000000..b98704b1ec --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/DwarvenArmorer.java @@ -0,0 +1,128 @@ +/* + * 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.fallenempires; + +import java.util.HashSet; +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.DiscardCardCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.cards.CardImpl; +import mage.choices.Choice; +import mage.choices.ChoiceImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.Counter; +import mage.counters.CounterType; +import mage.game.Game; +import mage.players.Player; +import mage.target.common.TargetCreaturePermanent; +import mage.target.targetpointer.FixedTarget; + +/** + * + * @author LoneFox + */ +public class DwarvenArmorer extends CardImpl { + + public DwarvenArmorer(UUID ownerId) { + super(ownerId, 104, "Dwarven Armorer", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{R}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Dwarf"); + this.power = new MageInt(0); + this.toughness = new MageInt(2); + + // {R}, {tap}, Discard a card: Put a +0/+1 counter or a +1/+0 counter on target creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DwarvenArmorerEffect(), new ManaCostsImpl("{R}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new DiscardCardCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public DwarvenArmorer(final DwarvenArmorer card) { + super(card); + } + + @Override + public DwarvenArmorer copy() { + return new DwarvenArmorer(this); + } +} + +class DwarvenArmorerEffect extends OneShotEffect { + + private static final HashSet choices = new HashSet<>(); + + static { + choices.add("+0/+1"); + choices.add("+1/+0"); + } + + public DwarvenArmorerEffect() { + super(Outcome.Benefit); + staticText = "Put a +0/+1 counter or a +1/+0 counter on target creature."; + } + + public DwarvenArmorerEffect(final DwarvenArmorerEffect effect) { + super(effect); + } + + @java.lang.Override + public DwarvenArmorerEffect copy() { + return new DwarvenArmorerEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Player controller = game.getPlayer(source.getControllerId()); + if(controller != null) { + Choice choice = new ChoiceImpl(true); + choice.setMessage("Choose type of counter to add"); + choice.setChoices(choices); + while(!controller.choose(outcome, choice, game)) { + if(controller.canRespond()) { + return false; + } + } + Counter counter = choice.getChoice().equals("+0/+1") ? CounterType.P0P1.createInstance() : CounterType.P1P0.createInstance(); + Effect effect = new AddCountersTargetEffect(counter); + effect.setTargetPointer(new FixedTarget(this.getTargetPointer().getFirst(game, source))); + return effect.apply(game, source); + } + return false; + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/DwarvenLieutenant.java b/Mage.Sets/src/mage/sets/fallenempires/DwarvenLieutenant.java new file mode 100644 index 0000000000..2cc864b9fc --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/DwarvenLieutenant.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.fallenempires; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +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.SubtypePredicate; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class DwarvenLieutenant extends CardImpl { + + static FilterCreaturePermanent filter = new FilterCreaturePermanent("Dwarf creature"); + + static { + filter.add(new SubtypePredicate("Dwarf")); + } + + public DwarvenLieutenant(UUID ownerId) { + super(ownerId, 106, "Dwarven Lieutenant", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{R}{R}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Dwarf"); + this.subtype.add("Soldier"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {1}{R}: Target Dwarf creature gets +1/+0 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(1, 0, Duration.EndOfTurn), new ManaCostsImpl("{1}{R}")); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public DwarvenLieutenant(final DwarvenLieutenant card) { + super(card); + } + + @Override + public DwarvenLieutenant copy() { + return new DwarvenLieutenant(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ElvenLyre.java b/Mage.Sets/src/mage/sets/fallenempires/ElvenLyre.java new file mode 100644 index 0000000000..8657136f09 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ElvenLyre.java @@ -0,0 +1,54 @@ +/* + * 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.fallenempires; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class ElvenLyre extends mage.sets.masterseditionii.ElvenLyre { + + public ElvenLyre(UUID ownerId) { + super(ownerId); + this.cardNumber = 172; + this.expansionSetCode = "FEM"; + this.rarity = Rarity.RARE; + } + + public ElvenLyre(final ElvenLyre card) { + super(card); + } + + @Override + public ElvenLyre copy() { + return new ElvenLyre(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/ArmorThrull.java b/Mage.Sets/src/mage/sets/masterseditionii/ArmorThrull.java new file mode 100644 index 0000000000..dbd058685b --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/ArmorThrull.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.masterseditionii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.counter.AddCountersTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class ArmorThrull extends CardImpl { + + public ArmorThrull(UUID ownerId) { + super(ownerId, 77, "Armor Thrull", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{B}"); + this.expansionSetCode = "ME2"; + this.subtype.add("Thrull"); + this.power = new MageInt(1); + this.toughness = new MageInt(3); + + // {T}, Sacrifice Armor Thrull: Put a +1/+2 counter on target creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.P1P2.createInstance()), new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + } + + public ArmorThrull(final ArmorThrull card) { + super(card); + } + + @Override + public ArmorThrull copy() { + return new ArmorThrull(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/ElvenLyre.java b/Mage.Sets/src/mage/sets/masterseditionii/ElvenLyre.java new file mode 100644 index 0000000000..5fd78b1f65 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/ElvenLyre.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.masterseditionii; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class ElvenLyre extends CardImpl { + + public ElvenLyre(UUID ownerId) { + super(ownerId, 208, "Elven Lyre", Rarity.COMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "ME2"; + + // {1}, {tap}, Sacrifice Elven Lyre: Target creature gets +2/+2 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(2, 2, Duration.EndOfTurn), new ManaCostsImpl("{1}")); + ability.addCost(new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + ability.addTarget(new TargetCreaturePermanent()); + this.addAbility(ability); + + } + + public ElvenLyre(final ElvenLyre card) { + super(card); + } + + @Override + public ElvenLyre copy() { + return new ElvenLyre(this); + } +} diff --git a/Mage/src/mage/counters/CounterType.java b/Mage/src/mage/counters/CounterType.java index eaf7bde19e..da70425325 100644 --- a/Mage/src/mage/counters/CounterType.java +++ b/Mage/src/mage/counters/CounterType.java @@ -75,8 +75,10 @@ public enum CounterType { M2M2(new BoostCounter(-2, -2).name), MINING("mining"), MUSTER("muster"), + P0P1(new BoostCounter(0, 1).name), P1P0(new BoostCounter(1, 0).name), P1P1(new BoostCounter(1, 1).name), + P1P2(new BoostCounter(1, 2).name), P2P2(new BoostCounter(2, 2).name), PAGE("page"), PAIN("pain"), @@ -134,10 +136,14 @@ public enum CounterType { */ public Counter createInstance(int amount) { switch (this) { + case P0P1: + return new BoostCounter(0, 1, amount); case P1P0: return new BoostCounter(1, 0, amount); case P1P1: return new BoostCounter(1, 1, amount); + case P1P2: + return new BoostCounter(1, 2, amount); case P2P2: return new BoostCounter(2, 2, amount); case M1M1: From d9da74868ee6fcd37afb5c9af5e92cdf92e45c22 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Sun, 11 Oct 2015 12:28:24 +0300 Subject: [PATCH 2/6] Fix Bloodied Ghost's tooltip text --- Mage.Sets/src/mage/sets/eventide/BloodiedGhost.java | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/Mage.Sets/src/mage/sets/eventide/BloodiedGhost.java b/Mage.Sets/src/mage/sets/eventide/BloodiedGhost.java index 2d046b50df..dd8ae7ec4b 100644 --- a/Mage.Sets/src/mage/sets/eventide/BloodiedGhost.java +++ b/Mage.Sets/src/mage/sets/eventide/BloodiedGhost.java @@ -29,13 +29,13 @@ package mage.sets.eventide; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Rarity; import mage.MageInt; import mage.abilities.common.EntersBattlefieldAbility; import mage.abilities.effects.common.counter.AddCountersSourceEffect; import mage.abilities.keyword.FlyingAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.counters.CounterType; /** @@ -48,12 +48,15 @@ public class BloodiedGhost extends CardImpl { super(ownerId, 83, "Bloodied Ghost", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{1}{W/B}{W/B}"); this.expansionSetCode = "EVE"; this.subtype.add("Spirit"); - - this.power = new MageInt(3); this.toughness = new MageInt(3); + + // Flying this.addAbility(FlyingAbility.getInstance()); - this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.M1M1.createInstance()), "Bloodied Ghost gets a -1/-1 counter")); + + // Bloodied Ghost enters the battlefield with a -1/-1 counter on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.M1M1.createInstance()), + "with a -1/-1 counter on it.")); } public BloodiedGhost (final BloodiedGhost card) { From f7e92ee885fe1e80dbb1c1c5a4f4ea52154ba9d5 Mon Sep 17 00:00:00 2001 From: LoneFox Date: Mon, 12 Oct 2015 19:18:58 +0300 Subject: [PATCH 3/6] Add RemoveAllCountersSourceEffect and use it for Witherscale Wurm. Implement cards: Homarid and Tidal Influence TODO: The tooltip text of Tidal Infuence's first ability is wrong. The idea is copied from Feast of Blood, which also has the same problem. --- .../src/mage/sets/fallenempires/Homarid1.java | 120 +++++++++++++ .../src/mage/sets/fallenempires/Homarid2.java | 51 ++++++ .../src/mage/sets/fallenempires/Homarid3.java | 51 ++++++ .../src/mage/sets/fallenempires/Homarid4.java | 51 ++++++ .../sets/fallenempires/TidalInfluence.java | 167 ++++++++++++++++++ .../mage/sets/shadowmoor/WitherscaleWurm.java | 37 +--- .../common/RemoveAllCountersSourceEffect.java | 73 ++++++++ Mage/src/mage/counters/CounterType.java | 1 + 8 files changed, 516 insertions(+), 35 deletions(-) create mode 100644 Mage.Sets/src/mage/sets/fallenempires/Homarid1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/Homarid2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/Homarid3.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/Homarid4.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/TidalInfluence.java create mode 100644 Mage/src/mage/abilities/effects/common/RemoveAllCountersSourceEffect.java diff --git a/Mage.Sets/src/mage/sets/fallenempires/Homarid1.java b/Mage.Sets/src/mage/sets/fallenempires/Homarid1.java new file mode 100644 index 0000000000..a69771b105 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/Homarid1.java @@ -0,0 +1,120 @@ +/* + * 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.fallenempires; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.SourceHasCounterCondition; +import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.RemoveAllCountersSourceEffect; +import mage.abilities.effects.common.continuous.BoostSourceEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author LoneFox + */ +public class Homarid1 extends CardImpl { + + public Homarid1(UUID ownerId) { + super(ownerId, 38, "Homarid", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Homarid"); + this.power = new MageInt(2); + this.toughness = new MageInt(2); + + // Homarid enters the battlefield with a tide counter on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIDE.createInstance()), + "with a tide counter on it.")); + // At the beginning of your upkeep, put a tide counter on Homarid. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.TIDE.createInstance()), + TargetController.YOU, false)); + // As long as there is exactly one tide counter on Homarid, it gets -1/-1. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( + new BoostSourceEffect(-1, -1, Duration.WhileOnBattlefield), new SourceHasCounterCondition(CounterType.TIDE, 1, 1), + "As long as there is exactly one tide counter on {this}, it gets -1/-1."))); + // As long as there are exactly three tide counters on Homarid, it gets +1/+1. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( + new BoostSourceEffect(1, 1, Duration.WhileOnBattlefield), new SourceHasCounterCondition(CounterType.TIDE, 3, 3), + "As long as there are exactly three tide counter on {this}, it gets +1/+1."))); + // Whenever there are four tide counters on Homarid, remove all tide counters from it. + this.addAbility(new HomaridTriggeredAbility(new RemoveAllCountersSourceEffect(CounterType.TIDE))); + } + + public Homarid1(final Homarid1 card) { + super(card); + } + + @Override + public Homarid1 copy() { + return new Homarid1(this); + } +} + +class HomaridTriggeredAbility extends StateTriggeredAbility { + + public HomaridTriggeredAbility(Effect effect) { + super(Zone.BATTLEFIELD, effect); + } + + public HomaridTriggeredAbility(final HomaridTriggeredAbility ability) { + super(ability); + } + + @Override + public HomaridTriggeredAbility copy() { + return new HomaridTriggeredAbility(this); + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return new CountersCount(CounterType.TIDE).calculate(game, this, null) == 4; + } + + @Override + public String getRule() { + return "Whenever there are four tide counters on {this}, " + super.getRule(); + } + +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/Homarid2.java b/Mage.Sets/src/mage/sets/fallenempires/Homarid2.java new file mode 100644 index 0000000000..51d33e80bb --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/Homarid2.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class Homarid2 extends Homarid1 { + + public Homarid2(UUID ownerId) { + super(ownerId); + this.cardNumber = 39; + } + + public Homarid2(final Homarid2 card) { + super(card); + } + + @Override + public Homarid2 copy() { + return new Homarid2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/Homarid3.java b/Mage.Sets/src/mage/sets/fallenempires/Homarid3.java new file mode 100644 index 0000000000..f42970458e --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/Homarid3.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class Homarid3 extends Homarid1 { + + public Homarid3(UUID ownerId) { + super(ownerId); + this.cardNumber = 40; + } + + public Homarid3(final Homarid3 card) { + super(card); + } + + @Override + public Homarid3 copy() { + return new Homarid3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/Homarid4.java b/Mage.Sets/src/mage/sets/fallenempires/Homarid4.java new file mode 100644 index 0000000000..4ae2066c64 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/Homarid4.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class Homarid4 extends Homarid1 { + + public Homarid4(UUID ownerId) { + super(ownerId); + this.cardNumber = 41; + } + + public Homarid4(final Homarid4 card) { + super(card); + } + + @Override + public Homarid4 copy() { + return new Homarid4(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/TidalInfluence.java b/Mage.Sets/src/mage/sets/fallenempires/TidalInfluence.java new file mode 100644 index 0000000000..5de52d6b93 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/TidalInfluence.java @@ -0,0 +1,167 @@ +/* + * 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.fallenempires; + +import java.util.UUID; +import mage.ObjectColor; +import mage.abilities.Ability; +import mage.abilities.StateTriggeredAbility; +import mage.abilities.common.BeginningOfUpkeepTriggeredAbility; +import mage.abilities.common.EntersBattlefieldAbility; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.condition.common.SourceHasCounterCondition; +import mage.abilities.costs.CostImpl; +import mage.abilities.decorator.ConditionalContinuousEffect; +import mage.abilities.dynamicvalue.common.CountersCount; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.RemoveAllCountersSourceEffect; +import mage.abilities.effects.common.continuous.BoostAllEffect; +import mage.abilities.effects.common.counter.AddCountersSourceEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; +import mage.counters.CounterType; +import mage.filter.FilterPermanent; +import mage.filter.common.FilterCreaturePermanent; +import mage.filter.predicate.mageobject.ColorPredicate; +import mage.filter.predicate.mageobject.NamePredicate; +import mage.game.Game; +import mage.game.events.GameEvent; + +/** + * + * @author LoneFox + */ +public class TidalInfluence extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("blue creatures"); + + static { + filter.add(new ColorPredicate(ObjectColor.BLUE)); + } + + public TidalInfluence(UUID ownerId) { + super(ownerId, 57, "Tidal Influence", Rarity.UNCOMMON, new CardType[]{CardType.ENCHANTMENT}, "{2}{U}"); + this.expansionSetCode = "FEM"; + + // Cast Tidal Influence only if no permanents named Tidal Influence are on the battlefield. + this.getSpellAbility().addCost(new TidalInfluenceCost()); + // Tidal Influence enters the battlefield with a tide counter on it. + this.addAbility(new EntersBattlefieldAbility(new AddCountersSourceEffect(CounterType.TIDE.createInstance()), + "with a tide counter on it.")); + // At the beginning of your upkeep, put a tide counter on Tidal Influence. + this.addAbility(new BeginningOfUpkeepTriggeredAbility(new AddCountersSourceEffect(CounterType.TIDE.createInstance()), + TargetController.YOU, false)); + // As long as there is exactly one tide counter on Tidal Influence, all blue creatures get -2/-0. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( + new BoostAllEffect(-2, -0, Duration.WhileOnBattlefield, filter, false), + new SourceHasCounterCondition(CounterType.TIDE, 1, 1), + "As long as there is exactly one tide counter on {this}, all blue creatures get -2/-0."))); + // As long as there are exactly three tide counters on Tidal Influence, all blue creatures get +2/+0. + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinuousEffect( + new BoostAllEffect(2, -0, Duration.WhileOnBattlefield, filter, false), + new SourceHasCounterCondition(CounterType.TIDE, 3, 3), + "As long as there are exactly three tide counter on {this}, all blue creatures get +2/-0."))); + // Whenever there are four tide counters on Tidal Influence, remove all tide counters from it. + this.addAbility(new TidalInfluenceTriggeredAbility(new RemoveAllCountersSourceEffect(CounterType.TIDE))); + } + + public TidalInfluence(final TidalInfluence card) { + super(card); + } + + @Override + public TidalInfluence copy() { + return new TidalInfluence(this); + } +} + + +class TidalInfluenceCost extends CostImpl { + + private static final FilterPermanent filter = new FilterPermanent(); + + static { + filter.add(new NamePredicate("Tidal Influence")); + } + + public TidalInfluenceCost() { + this.text = "Cast Tidal Influence only if no permanents named Tidal Influence are on the battlefield"; + } + + public TidalInfluenceCost(final TidalInfluenceCost cost) { + super(cost); + } + + @Override + public boolean canPay(Ability ability, UUID sourceId, UUID controllerId, Game game) { + return !game.getBattlefield().contains(filter, 1, game); + } + + @Override + public boolean pay(Ability ability, Game game, UUID sourceId, UUID controllerId, boolean noMana) { + this.paid = true; + return paid; + } + + @Override + public TidalInfluenceCost copy() { + return new TidalInfluenceCost(this); + } +} + + +class TidalInfluenceTriggeredAbility extends StateTriggeredAbility { + + public TidalInfluenceTriggeredAbility(Effect effect) { + super(Zone.BATTLEFIELD, effect); + } + + public TidalInfluenceTriggeredAbility(final TidalInfluenceTriggeredAbility ability) { + super(ability); + } + + @Override + public TidalInfluenceTriggeredAbility copy() { + return new TidalInfluenceTriggeredAbility(this); + } + + @Override + public boolean checkTrigger(GameEvent event, Game game) { + return new CountersCount(CounterType.TIDE).calculate(game, this, null) == 4; + } + + @Override + public String getRule() { + return "Whenever there are four tide counters on {this}, " + super.getRule(); + } + +} diff --git a/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java b/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java index bc3e1f3d06..9f8ba6c97d 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/WitherscaleWurm.java @@ -29,21 +29,17 @@ package mage.sets.shadowmoor; import java.util.UUID; import mage.MageInt; -import mage.abilities.Ability; import mage.abilities.common.BlocksOrBecomesBlockedByCreatureTriggeredAbility; import mage.abilities.common.DealsDamageToOpponentTriggeredAbility; import mage.abilities.effects.Effect; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.RemoveAllCountersSourceEffect; import mage.abilities.effects.common.continuous.GainAbilityTargetEffect; import mage.abilities.keyword.WitherAbility; import mage.cards.CardImpl; import mage.constants.CardType; import mage.constants.Duration; -import mage.constants.Outcome; import mage.constants.Rarity; import mage.counters.CounterType; -import mage.game.Game; -import mage.game.permanent.Permanent; /** * @@ -65,7 +61,7 @@ public class WitherscaleWurm extends CardImpl { this.addAbility(new BlocksOrBecomesBlockedByCreatureTriggeredAbility(effect, false)); // Whenever Witherscale Wurm deals damage to an opponent, remove all -1/-1 counters from it. - this.addAbility(new DealsDamageToOpponentTriggeredAbility(new WitherscaleWurmEffect(), false)); + this.addAbility(new DealsDamageToOpponentTriggeredAbility(new RemoveAllCountersSourceEffect(CounterType.M1M1), false)); } @@ -78,32 +74,3 @@ public class WitherscaleWurm extends CardImpl { return new WitherscaleWurm(this); } } - -class WitherscaleWurmEffect extends OneShotEffect { - - public WitherscaleWurmEffect() { - super(Outcome.Benefit); - staticText = "remove all -1/-1 counters from it"; - } - - public WitherscaleWurmEffect(WitherscaleWurmEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent witherscaleWurm = game.getPermanent(source.getSourceId()); - if (witherscaleWurm != null - && witherscaleWurm.getCounters().containsKey(CounterType.M1M1)) { - int M1M1Counters = witherscaleWurm.getCounters().getCount(CounterType.M1M1); - witherscaleWurm.getCounters().removeCounter(CounterType.M1M1, M1M1Counters); - return true; - } - return false; - } - - @Override - public WitherscaleWurmEffect copy() { - return new WitherscaleWurmEffect(this); - } -} diff --git a/Mage/src/mage/abilities/effects/common/RemoveAllCountersSourceEffect.java b/Mage/src/mage/abilities/effects/common/RemoveAllCountersSourceEffect.java new file mode 100644 index 0000000000..abc70475f4 --- /dev/null +++ b/Mage/src/mage/abilities/effects/common/RemoveAllCountersSourceEffect.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.abilities.effects.common; + +import mage.abilities.Ability; +import mage.abilities.effects.OneShotEffect; +import mage.constants.Outcome; +import mage.counters.CounterType; +import mage.game.Game; +import mage.game.permanent.Permanent; + +/** + * + * @author LoneFox + */ +public class RemoveAllCountersSourceEffect extends OneShotEffect { + + private final CounterType counterType; + + public RemoveAllCountersSourceEffect(CounterType counterType) { + super(Outcome.Neutral); + this.counterType = counterType; + staticText = "remove all " + counterType.getName() + " counters from it."; + } + + public RemoveAllCountersSourceEffect(final RemoveAllCountersSourceEffect effect) { + super(effect); + this.counterType = effect.counterType; + } + + @Override + public RemoveAllCountersSourceEffect copy() { + return new RemoveAllCountersSourceEffect(this); + } + + @java.lang.Override + public boolean apply(Game game, Ability source) { + Permanent sourcePermanent = game.getPermanent(source.getSourceId()); + if(sourcePermanent != null) { + int count = sourcePermanent.getCounters().getCount(counterType); + sourcePermanent.getCounters().removeCounter(counterType, count); + return true; + } + return false; + } +} + diff --git a/Mage/src/mage/counters/CounterType.java b/Mage/src/mage/counters/CounterType.java index da70425325..f753763875 100644 --- a/Mage/src/mage/counters/CounterType.java +++ b/Mage/src/mage/counters/CounterType.java @@ -96,6 +96,7 @@ public enum CounterType { STRIFE("strife"), STUDY("study"), THEFT("theft"), + TIDE("tide"), TIME("time"), TOWER("tower"), VELOCITY("velocity"), From 41f7b6871b71c49cb64f7428f923669289be30ef Mon Sep 17 00:00:00 2001 From: LoneFox Date: Mon, 12 Oct 2015 20:47:43 +0300 Subject: [PATCH 4/6] Implement cards: Deep Spawn, Homarid Shaman, Homarid Warrior, and Vodalian Mage --- .../mage/sets/fallenempires/DeepSpawn.java | 88 +++++++++++++++++++ .../sets/fallenempires/HomaridShaman.java | 79 +++++++++++++++++ .../sets/fallenempires/HomaridWarrior1.java | 78 ++++++++++++++++ .../sets/fallenempires/HomaridWarrior2.java | 51 +++++++++++ .../sets/fallenempires/HomaridWarrior3.java | 51 +++++++++++ .../sets/fallenempires/VodalianMage1.java | 73 +++++++++++++++ .../sets/fallenempires/VodalianMage2.java | 51 +++++++++++ .../sets/fallenempires/VodalianMage3.java | 51 +++++++++++ .../sets/fifthedition/HomaridWarrior.java | 52 +++++++++++ .../mage/sets/masterseditionii/DeepSpawn.java | 54 ++++++++++++ 10 files changed, 628 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/fallenempires/DeepSpawn.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/HomaridShaman.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior3.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/VodalianMage1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/VodalianMage2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/VodalianMage3.java create mode 100644 Mage.Sets/src/mage/sets/fifthedition/HomaridWarrior.java create mode 100644 Mage.Sets/src/mage/sets/masterseditionii/DeepSpawn.java diff --git a/Mage.Sets/src/mage/sets/fallenempires/DeepSpawn.java b/Mage.Sets/src/mage/sets/fallenempires/DeepSpawn.java new file mode 100644 index 0000000000..129e152a1c --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/DeepSpawn.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.fallenempires; + +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.PutTopCardOfYourLibraryToGraveyardCost; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DontUntapInControllersNextUntapStepSourceEffect; +import mage.abilities.effects.common.SacrificeSourceUnlessPaysEffect; +import mage.abilities.effects.common.TapSourceEffect; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.abilities.keyword.TrampleAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.TargetController; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class DeepSpawn extends CardImpl { + + public DeepSpawn(UUID ownerId) { + super(ownerId, 34, "Deep Spawn", Rarity.UNCOMMON, new CardType[]{CardType.CREATURE}, "{5}{U}{U}{U}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Homarid"); + this.power = new MageInt(6); + this.toughness = new MageInt(6); + + // Trample + this.addAbility(TrampleAbility.getInstance()); + // At the beginning of your upkeep, sacrifice Deep Spawn unless you put the top two cards of your library into your graveyard. + Effect effect = new SacrificeSourceUnlessPaysEffect(new PutTopCardOfYourLibraryToGraveyardCost(2)); + effect.setText("sacrifice {this} unless you put the top two cards of your library into your graveyard"); + this.addAbility(new BeginningOfUpkeepTriggeredAbility(effect, TargetController.YOU, false)); + // {U}: Deep Spawn gains shroud until end of turn and doesn't untap during your next untap step. Tap Deep Spawn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect( + ShroudAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{U}")); + effect = new DontUntapInControllersNextUntapStepSourceEffect(); + effect.setText("and doesn't untap during your next untap step"); + ability.addEffect(effect); + ability.addEffect(new TapSourceEffect()); + this.addAbility(ability); + } + + public DeepSpawn(final DeepSpawn card) { + super(card); + } + + @Override + public DeepSpawn copy() { + return new DeepSpawn(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/HomaridShaman.java b/Mage.Sets/src/mage/sets/fallenempires/HomaridShaman.java new file mode 100644 index 0000000000..e092c8daa7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/HomaridShaman.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.fallenempires; + +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.TapTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +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 HomaridShaman extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("green creature"); + + static { + filter.add(new ColorPredicate(ObjectColor.GREEN)); + } + + public HomaridShaman(UUID ownerId) { + super(ownerId, 42, "Homarid Shaman", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{2}{U}{U}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Homarid"); + this.subtype.add("Shaman"); + this.power = new MageInt(2); + this.toughness = new MageInt(1); + + // {U}: Tap target green creature. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new TapTargetEffect(), new ManaCostsImpl("{U}")); + ability.addTarget(new TargetCreaturePermanent(filter)); + this.addAbility(ability); + } + + public HomaridShaman(final HomaridShaman card) { + super(card); + } + + @Override + public HomaridShaman copy() { + return new HomaridShaman(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior1.java b/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior1.java new file mode 100644 index 0000000000..2411486926 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior1.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.fallenempires; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DontUntapInControllersNextUntapStepSourceEffect; +import mage.abilities.effects.common.TapSourceEffect; +import mage.abilities.effects.common.continuous.GainAbilitySourceEffect; +import mage.abilities.keyword.ShroudAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class HomaridWarrior1 extends CardImpl { + + public HomaridWarrior1(UUID ownerId) { + super(ownerId, 44, "Homarid Warrior", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{4}{U}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Homarid"); + this.subtype.add("Warrior"); + this.power = new MageInt(3); + this.toughness = new MageInt(3); + + // {U}: Homarid Warrior gains shroud until end of turn and doesn't untap during your next untap step. Tap Homarid Warrior. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new GainAbilitySourceEffect( + ShroudAbility.getInstance(), Duration.EndOfTurn), new ManaCostsImpl("{U}")); + Effect effect = new DontUntapInControllersNextUntapStepSourceEffect(); + effect.setText("and doesn't untap during your next untap step"); + ability.addEffect(effect); + ability.addEffect(new TapSourceEffect()); + this.addAbility(ability); + } + + public HomaridWarrior1(final HomaridWarrior1 card) { + super(card); + } + + @Override + public HomaridWarrior1 copy() { + return new HomaridWarrior1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior2.java b/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior2.java new file mode 100644 index 0000000000..f927b68c66 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior2.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class HomaridWarrior2 extends HomaridWarrior1 { + + public HomaridWarrior2(UUID ownerId) { + super(ownerId); + this.cardNumber = 45; + } + + public HomaridWarrior2(final HomaridWarrior2 card) { + super(card); + } + + @Override + public HomaridWarrior2 copy() { + return new HomaridWarrior2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior3.java b/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior3.java new file mode 100644 index 0000000000..92ba080f52 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/HomaridWarrior3.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class HomaridWarrior3 extends HomaridWarrior1 { + + public HomaridWarrior3(UUID ownerId) { + super(ownerId); + this.cardNumber = 46; + } + + public HomaridWarrior3(final HomaridWarrior3 card) { + super(card); + } + + @Override + public HomaridWarrior3 copy() { + return new HomaridWarrior3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/VodalianMage1.java b/Mage.Sets/src/mage/sets/fallenempires/VodalianMage1.java new file mode 100644 index 0000000000..ec3c12ddde --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/VodalianMage1.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.fallenempires; + +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.CounterUnlessPaysEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.TargetSpell; + +/** + * + * @author LoneFox + */ +public class VodalianMage1 extends CardImpl { + + public VodalianMage1(UUID ownerId) { + super(ownerId, 59, "Vodalian Mage", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{U}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Merfolk"); + this.subtype.add("Wizard"); + this.power = new MageInt(1); + this.toughness = new MageInt(1); + + // {U}, {tap}: Counter target spell unless its controller pays {1}. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new CounterUnlessPaysEffect(new ManaCostsImpl("{1}")), + new ManaCostsImpl("{U}")); + ability.addCost(new TapSourceCost()); + ability.addTarget(new TargetSpell()); + this.addAbility(ability); + } + + public VodalianMage1(final VodalianMage1 card) { + super(card); + } + + @Override + public VodalianMage1 copy() { + return new VodalianMage1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/VodalianMage2.java b/Mage.Sets/src/mage/sets/fallenempires/VodalianMage2.java new file mode 100644 index 0000000000..c1d98f2207 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/VodalianMage2.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class VodalianMage2 extends VodalianMage1 { + + public VodalianMage2(UUID ownerId) { + super(ownerId); + this.cardNumber = 60; + } + + public VodalianMage2(final VodalianMage2 card) { + super(card); + } + + @Override + public VodalianMage2 copy() { + return new VodalianMage2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/VodalianMage3.java b/Mage.Sets/src/mage/sets/fallenempires/VodalianMage3.java new file mode 100644 index 0000000000..c7d1789e17 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/VodalianMage3.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class VodalianMage3 extends VodalianMage1 { + + public VodalianMage3(UUID ownerId) { + super(ownerId); + this.cardNumber = 61; + } + + public VodalianMage3(final VodalianMage3 card) { + super(card); + } + + @Override + public VodalianMage3 copy() { + return new VodalianMage3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fifthedition/HomaridWarrior.java b/Mage.Sets/src/mage/sets/fifthedition/HomaridWarrior.java new file mode 100644 index 0000000000..a5498872d0 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fifthedition/HomaridWarrior.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.fifthedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class HomaridWarrior extends mage.sets.fallenempires.HomaridWarrior1 { + + public HomaridWarrior(UUID ownerId) { + super(ownerId); + this.cardNumber = 92; + this.expansionSetCode = "5ED"; + } + + public HomaridWarrior(final HomaridWarrior card) { + super(card); + } + + @Override + public HomaridWarrior copy() { + return new HomaridWarrior(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/DeepSpawn.java b/Mage.Sets/src/mage/sets/masterseditionii/DeepSpawn.java new file mode 100644 index 0000000000..f990a1afa1 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/DeepSpawn.java @@ -0,0 +1,54 @@ +/* + * 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.masterseditionii; + +import java.util.UUID; +import mage.constants.Rarity; + +/** + * + * @author LoneFox + */ +public class DeepSpawn extends mage.sets.fallenempires.DeepSpawn { + + public DeepSpawn(UUID ownerId) { + super(ownerId); + this.cardNumber = 45; + this.expansionSetCode = "ME2"; + this.rarity = Rarity.RARE; + } + + public DeepSpawn(final DeepSpawn card) { + super(card); + } + + @Override + public DeepSpawn copy() { + return new DeepSpawn(this); + } +} From 05aba24b9a84b67a4215cc13024aeda4595c9faf Mon Sep 17 00:00:00 2001 From: LoneFox Date: Mon, 12 Oct 2015 21:42:42 +0300 Subject: [PATCH 5/6] Implement cards: Basal Thrull, Combat Medic, Elven Fortress, and Ring of Renewal --- .../mage/sets/fallenempires/BasalThrull1.java | 70 ++++++++++++++++++ .../mage/sets/fallenempires/BasalThrull2.java | 51 +++++++++++++ .../mage/sets/fallenempires/BasalThrull3.java | 51 +++++++++++++ .../mage/sets/fallenempires/BasalThrull4.java | 51 +++++++++++++ .../mage/sets/fallenempires/CombatMedic1.java | 52 ++++++++++++++ .../mage/sets/fallenempires/CombatMedic2.java | 52 ++++++++++++++ .../mage/sets/fallenempires/CombatMedic3.java | 52 ++++++++++++++ .../mage/sets/fallenempires/CombatMedic4.java | 52 ++++++++++++++ .../sets/fallenempires/ElvenFortress1.java | 67 +++++++++++++++++ .../sets/fallenempires/ElvenFortress2.java | 51 +++++++++++++ .../sets/fallenempires/ElvenFortress3.java | 51 +++++++++++++ .../sets/fallenempires/ElvenFortress4.java | 51 +++++++++++++ .../sets/fallenempires/RingOfRenewal.java | 52 ++++++++++++++ .../mage/sets/mastersedition/BasalThrull.java | 52 ++++++++++++++ .../sets/masterseditionii/CombatMedic.java | 72 +++++++++++++++++++ .../sets/masterseditioniv/RingOfRenewal.java | 70 ++++++++++++++++++ 16 files changed, 897 insertions(+) create mode 100644 Mage.Sets/src/mage/sets/fallenempires/BasalThrull1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/BasalThrull2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/BasalThrull3.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/BasalThrull4.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/CombatMedic1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/CombatMedic2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/CombatMedic3.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/CombatMedic4.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ElvenFortress1.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ElvenFortress2.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ElvenFortress3.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/ElvenFortress4.java create mode 100644 Mage.Sets/src/mage/sets/fallenempires/RingOfRenewal.java create mode 100644 Mage.Sets/src/mage/sets/mastersedition/BasalThrull.java create mode 100644 Mage.Sets/src/mage/sets/masterseditionii/CombatMedic.java create mode 100644 Mage.Sets/src/mage/sets/masterseditioniv/RingOfRenewal.java diff --git a/Mage.Sets/src/mage/sets/fallenempires/BasalThrull1.java b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull1.java new file mode 100644 index 0000000000..efef91c76a --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull1.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.fallenempires; + +import java.util.UUID; +import mage.MageInt; +import mage.Mana; +import mage.abilities.Ability; +import mage.abilities.costs.common.SacrificeSourceCost; +import mage.abilities.costs.common.TapSourceCost; +import mage.abilities.effects.common.BasicManaEffect; +import mage.abilities.mana.SimpleManaAbility; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class BasalThrull1 extends CardImpl { + + public BasalThrull1(UUID ownerId) { + super(ownerId, 5, "Basal Thrull", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{B}{B}"); + this.expansionSetCode = "FEM"; + this.subtype.add("Thrull"); + this.power = new MageInt(1); + this.toughness = new MageInt(2); + + // {T}, Sacrifice Basal Thrull: Add {B}{B} to your mana pool. + Ability ability = new SimpleManaAbility(Zone.BATTLEFIELD, new BasicManaEffect(new Mana(0, 0, 0, 0, 2, 0, 0)), new TapSourceCost()); + ability.addCost(new SacrificeSourceCost()); + this.addAbility(ability); + } + + public BasalThrull1(final BasalThrull1 card) { + super(card); + } + + @Override + public BasalThrull1 copy() { + return new BasalThrull1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/BasalThrull2.java b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull2.java new file mode 100644 index 0000000000..93ab2baea7 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull2.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class BasalThrull2 extends BasalThrull1 { + + public BasalThrull2(UUID ownerId) { + super(ownerId); + this.cardNumber = 6; + } + + public BasalThrull2(final BasalThrull2 card) { + super(card); + } + + @Override + public BasalThrull2 copy() { + return new BasalThrull2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/BasalThrull3.java b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull3.java new file mode 100644 index 0000000000..27a36274d8 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull3.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class BasalThrull3 extends BasalThrull1 { + + public BasalThrull3(UUID ownerId) { + super(ownerId); + this.cardNumber = 7; + } + + public BasalThrull3(final BasalThrull3 card) { + super(card); + } + + @Override + public BasalThrull3 copy() { + return new BasalThrull3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/BasalThrull4.java b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull4.java new file mode 100644 index 0000000000..d2441b5dc5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/BasalThrull4.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class BasalThrull4 extends BasalThrull1 { + + public BasalThrull4(UUID ownerId) { + super(ownerId); + this.cardNumber = 8; + } + + public BasalThrull4(final BasalThrull4 card) { + super(card); + } + + @Override + public BasalThrull4 copy() { + return new BasalThrull4(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/CombatMedic1.java b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic1.java new file mode 100644 index 0000000000..c564b342fa --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic1.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class CombatMedic1 extends mage.sets.masterseditionii.CombatMedic { + + public CombatMedic1(UUID ownerId) { + super(ownerId); + this.cardNumber = 133; + this.expansionSetCode = "FEM"; + } + + public CombatMedic1(final CombatMedic1 card) { + super(card); + } + + @Override + public CombatMedic1 copy() { + return new CombatMedic1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/CombatMedic2.java b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic2.java new file mode 100644 index 0000000000..9234cc1951 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic2.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class CombatMedic2 extends mage.sets.masterseditionii.CombatMedic { + + public CombatMedic2(UUID ownerId) { + super(ownerId); + this.cardNumber = 134; + this.expansionSetCode = "FEM"; + } + + public CombatMedic2(final CombatMedic2 card) { + super(card); + } + + @Override + public CombatMedic2 copy() { + return new CombatMedic2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/CombatMedic3.java b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic3.java new file mode 100644 index 0000000000..d6efe570e6 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic3.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class CombatMedic3 extends mage.sets.masterseditionii.CombatMedic { + + public CombatMedic3(UUID ownerId) { + super(ownerId); + this.cardNumber = 135; + this.expansionSetCode = "FEM"; + } + + public CombatMedic3(final CombatMedic3 card) { + super(card); + } + + @Override + public CombatMedic3 copy() { + return new CombatMedic3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/CombatMedic4.java b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic4.java new file mode 100644 index 0000000000..33028ae3b5 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/CombatMedic4.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class CombatMedic4 extends mage.sets.masterseditionii.CombatMedic { + + public CombatMedic4(UUID ownerId) { + super(ownerId); + this.cardNumber = 136; + this.expansionSetCode = "FEM"; + } + + public CombatMedic4(final CombatMedic4 card) { + super(card); + } + + @Override + public CombatMedic4 copy() { + return new CombatMedic4(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress1.java b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress1.java new file mode 100644 index 0000000000..2e5618016c --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress1.java @@ -0,0 +1,67 @@ +/* + * 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.fallenempires; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continuous.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.filter.common.FilterBlockingCreature; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author LoneFox + */ +public class ElvenFortress1 extends CardImpl { + + public ElvenFortress1(UUID ownerId) { + super(ownerId, 67, "Elven Fortress", Rarity.COMMON, new CardType[]{CardType.ENCHANTMENT}, "{G}"); + this.expansionSetCode = "FEM"; + + // {1}{G}: Target blocking creature gets +0/+1 until end of turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new BoostTargetEffect(0, 1, Duration.EndOfTurn), new ManaCostsImpl("{1}{G}")); + ability.addTarget(new TargetCreaturePermanent(new FilterBlockingCreature())); + this.addAbility(ability); + } + + public ElvenFortress1(final ElvenFortress1 card) { + super(card); + } + + @Override + public ElvenFortress1 copy() { + return new ElvenFortress1(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress2.java b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress2.java new file mode 100644 index 0000000000..c454d76e92 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress2.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ElvenFortress2 extends ElvenFortress1 { + + public ElvenFortress2(UUID ownerId) { + super(ownerId); + this.cardNumber = 68; + } + + public ElvenFortress2(final ElvenFortress2 card) { + super(card); + } + + @Override + public ElvenFortress2 copy() { + return new ElvenFortress2(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress3.java b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress3.java new file mode 100644 index 0000000000..2af6a0b26a --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress3.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ElvenFortress3 extends ElvenFortress1 { + + public ElvenFortress3(UUID ownerId) { + super(ownerId); + this.cardNumber = 69; + } + + public ElvenFortress3(final ElvenFortress3 card) { + super(card); + } + + @Override + public ElvenFortress3 copy() { + return new ElvenFortress3(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress4.java b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress4.java new file mode 100644 index 0000000000..70e5a5e6ac --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/ElvenFortress4.java @@ -0,0 +1,51 @@ +/* + * 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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class ElvenFortress4 extends ElvenFortress1 { + + public ElvenFortress4(UUID ownerId) { + super(ownerId); + this.cardNumber = 70; + } + + public ElvenFortress4(final ElvenFortress4 card) { + super(card); + } + + @Override + public ElvenFortress4 copy() { + return new ElvenFortress4(this); + } +} diff --git a/Mage.Sets/src/mage/sets/fallenempires/RingOfRenewal.java b/Mage.Sets/src/mage/sets/fallenempires/RingOfRenewal.java new file mode 100644 index 0000000000..4d9b13c818 --- /dev/null +++ b/Mage.Sets/src/mage/sets/fallenempires/RingOfRenewal.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.fallenempires; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class RingOfRenewal extends mage.sets.masterseditioniv.RingOfRenewal { + + public RingOfRenewal(UUID ownerId) { + super(ownerId); + this.cardNumber = 174; + this.expansionSetCode = "FEM"; + } + + public RingOfRenewal(final RingOfRenewal card) { + super(card); + } + + @Override + public RingOfRenewal copy() { + return new RingOfRenewal(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mastersedition/BasalThrull.java b/Mage.Sets/src/mage/sets/mastersedition/BasalThrull.java new file mode 100644 index 0000000000..a2cc39602c --- /dev/null +++ b/Mage.Sets/src/mage/sets/mastersedition/BasalThrull.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.mastersedition; + +import java.util.UUID; + +/** + * + * @author LoneFox + */ +public class BasalThrull extends mage.sets.fallenempires.BasalThrull1 { + + public BasalThrull(UUID ownerId) { + super(ownerId); + this.cardNumber = 59; + this.expansionSetCode = "MED"; + } + + public BasalThrull(final BasalThrull card) { + super(card); + } + + @Override + public BasalThrull copy() { + return new BasalThrull(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditionii/CombatMedic.java b/Mage.Sets/src/mage/sets/masterseditionii/CombatMedic.java new file mode 100644 index 0000000000..6708aa9d2c --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditionii/CombatMedic.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.masterseditionii; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.SimpleActivatedAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.PreventDamageToTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.constants.Zone; +import mage.target.common.TargetCreatureOrPlayer; + +/** + * + * @author LoneFox + */ +public class CombatMedic extends CardImpl { + + public CombatMedic(UUID ownerId) { + super(ownerId, 9, "Combat Medic", Rarity.COMMON, new CardType[]{CardType.CREATURE}, "{2}{W}"); + this.expansionSetCode = "ME2"; + this.subtype.add("Human"); + this.subtype.add("Cleric"); + this.subtype.add("Soldier"); + this.power = new MageInt(0); + this.toughness = new MageInt(2); + + // {1}{W}: Prevent the next 1 damage that would be dealt to target creature or player this turn. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new PreventDamageToTargetEffect(Duration.EndOfTurn, 1), new ManaCostsImpl("{1}{W}")); + ability.addTarget(new TargetCreatureOrPlayer()); + this.addAbility(ability); + } + + public CombatMedic(final CombatMedic card) { + super(card); + } + + @Override + public CombatMedic copy() { + return new CombatMedic(this); + } +} diff --git a/Mage.Sets/src/mage/sets/masterseditioniv/RingOfRenewal.java b/Mage.Sets/src/mage/sets/masterseditioniv/RingOfRenewal.java new file mode 100644 index 0000000000..61ac07d129 --- /dev/null +++ b/Mage.Sets/src/mage/sets/masterseditioniv/RingOfRenewal.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.masterseditioniv; + +import java.util.UUID; +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.Effect; +import mage.abilities.effects.common.DrawCardSourceControllerEffect; +import mage.abilities.effects.common.discard.DiscardControllerEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; + +/** + * + * @author LoneFox + */ +public class RingOfRenewal extends CardImpl { + + public RingOfRenewal(UUID ownerId) { + super(ownerId, 224, "Ring of Renewal", Rarity.RARE, new CardType[]{CardType.ARTIFACT}, "{5}"); + this.expansionSetCode = "ME4"; + + // {5}, {tap}: Discard a card at random, then draw two cards. + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DiscardControllerEffect(1, true), new ManaCostsImpl("{5}")); + ability.addCost(new TapSourceCost()); + Effect effect = new DrawCardSourceControllerEffect(2); + effect.setText(", then draw two cards"); + ability.addEffect(effect); + this.addAbility(ability); + } + + public RingOfRenewal(final RingOfRenewal card) { + super(card); + } + + @Override + public RingOfRenewal copy() { + return new RingOfRenewal(this); + } +} From 0d634ebf09990fb31ce01b3cf8d064dd67224a5f Mon Sep 17 00:00:00 2001 From: LoneFox Date: Mon, 12 Oct 2015 22:19:13 +0300 Subject: [PATCH 6/6] Kill a few DamageTargetControllerEffect implementations --- .../riseoftheeldrazi/GrotagSiegeRunner.java | 47 +++------------- .../sets/scarsofmirrodin/MeltTerrain.java | 52 +++--------------- .../mage/sets/shadowmoor/PoisonTheWell.java | 45 +++------------ .../sets/shadowmoor/SmashToSmithereens.java | 51 +++-------------- .../src/mage/sets/tenthedition/Cryoclasm.java | 55 +++---------------- .../src/mage/sets/theros/PeakEruption.java | 53 +++--------------- 6 files changed, 47 insertions(+), 256 deletions(-) diff --git a/Mage.Sets/src/mage/sets/riseoftheeldrazi/GrotagSiegeRunner.java b/Mage.Sets/src/mage/sets/riseoftheeldrazi/GrotagSiegeRunner.java index 4c8578d609..e3407fb0de 100644 --- a/Mage.Sets/src/mage/sets/riseoftheeldrazi/GrotagSiegeRunner.java +++ b/Mage.Sets/src/mage/sets/riseoftheeldrazi/GrotagSiegeRunner.java @@ -28,24 +28,21 @@ package mage.sets.riseoftheeldrazi; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; import mage.MageInt; import mage.abilities.Ability; import mage.abilities.common.SimpleActivatedAbility; import mage.abilities.costs.common.SacrificeSourceCost; import mage.abilities.costs.mana.ManaCostsImpl; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.abilities.keyword.DefenderAbility; import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Rarity; +import mage.constants.Zone; import mage.filter.common.FilterCreaturePermanent; import mage.filter.predicate.mageobject.AbilityPredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; import mage.target.common.TargetCreaturePermanent; /** @@ -70,10 +67,12 @@ public class GrotagSiegeRunner extends CardImpl { this.toughness = new MageInt(1); // {R}, Sacrifice Grotag Siege-Runner: Destroy target creature with defender. Grotag Siege-Runner deals 2 damage to that creature's controller. - SimpleActivatedAbility ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl("{R}")); + Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new DestroyTargetEffect(), new ManaCostsImpl("{R}")); ability.addCost(new SacrificeSourceCost()); + Effect effect = new DamageTargetControllerEffect(2); + effect.setText("{this} deals 2 damage to that creature's controller"); + ability.addEffect(effect); ability.addTarget(new TargetCreaturePermanent(filter)); - ability.addEffect(new GrotageSiegeRunnerEffect()); this.addAbility(ability); } @@ -86,31 +85,3 @@ public class GrotagSiegeRunner extends CardImpl { return new GrotagSiegeRunner(this); } } - -class GrotageSiegeRunnerEffect extends OneShotEffect { - - public GrotageSiegeRunnerEffect() { - super(Outcome.Damage); - this.staticText = "{this} deals 2 damage to that creature's controller"; - } - - public GrotageSiegeRunnerEffect(final GrotageSiegeRunnerEffect effect) { - super(effect); - } - - @Override - public GrotageSiegeRunnerEffect copy() { - return new GrotageSiegeRunnerEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = (Permanent) game.getLastKnownInformation(source.getFirstTarget(), Zone.BATTLEFIELD); - if (permanent != null) { - Player controller = game.getPlayer(permanent.getControllerId()); - controller.damage(2, source.getSourceId(), game, false, true); - return true; - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/scarsofmirrodin/MeltTerrain.java b/Mage.Sets/src/mage/sets/scarsofmirrodin/MeltTerrain.java index 8c95d5de0b..0524d95acd 100644 --- a/Mage.Sets/src/mage/sets/scarsofmirrodin/MeltTerrain.java +++ b/Mage.Sets/src/mage/sets/scarsofmirrodin/MeltTerrain.java @@ -29,18 +29,12 @@ package mage.sets.scarsofmirrodin; import java.util.UUID; - -import mage.constants.CardType; -import mage.constants.Rarity; -import mage.constants.Zone; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; -import mage.constants.Outcome; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.target.common.TargetLandPermanent; /** @@ -53,8 +47,11 @@ public class MeltTerrain extends CardImpl { super(ownerId, 97, "Melt Terrain", Rarity.COMMON, new CardType[]{CardType.SORCERY}, "{2}{R}{R}"); this.expansionSetCode = "SOM"; + // Destroy target land. Melt Terrain deals 2 damage to that land's controller. this.getSpellAbility().addEffect(new DestroyTargetEffect()); - this.getSpellAbility().addEffect(new MeltTerrainEffect()); + Effect effect = new DamageTargetControllerEffect(2); + effect.setText("{this} deals 2 damage to that land's controller"); + this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetLandPermanent()); } @@ -66,37 +63,4 @@ public class MeltTerrain extends CardImpl { public MeltTerrain copy() { return new MeltTerrain(this); } - } - -class MeltTerrainEffect extends OneShotEffect { - MeltTerrainEffect() { - super(Outcome.Damage); - staticText = "{this} deals 2 damage to that land's controller"; - } - - MeltTerrainEffect(final MeltTerrainEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent p = game.getBattlefield().getPermanent(source.getFirstTarget()); - if (p == null) { - p = (Permanent) game.getLastKnownInformation(source.getFirstTarget(), Zone.BATTLEFIELD); - } - if (p != null) { - Player player = game.getPlayer(p.getControllerId()); - if (player != null) { - player.damage(2, source.getSourceId(), game, false, true); - } - } - return false; - } - - @Override - public MeltTerrainEffect copy() { - return new MeltTerrainEffect(this); - } - -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/shadowmoor/PoisonTheWell.java b/Mage.Sets/src/mage/sets/shadowmoor/PoisonTheWell.java index cb515b6669..1b8d897cfe 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/PoisonTheWell.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/PoisonTheWell.java @@ -28,15 +28,12 @@ package mage.sets.shadowmoor; import java.util.UUID; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; +import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; import mage.target.common.TargetLandPermanent; /** @@ -50,7 +47,10 @@ public class PoisonTheWell extends CardImpl { this.expansionSetCode = "SHM"; // Destroy target land. Poison the Well deals 2 damage to that land's controller. - this.getSpellAbility().addEffect(new PoisonTheWellEffect()); + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + Effect effect = new DamageTargetControllerEffect(2); + effect.setText("{this} deals 2 damage to that land's controller"); + this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetLandPermanent()); } @@ -63,34 +63,3 @@ public class PoisonTheWell extends CardImpl { return new PoisonTheWell(this); } } - -class PoisonTheWellEffect extends OneShotEffect { - - public PoisonTheWellEffect() { - super(Outcome.DestroyPermanent); - this.staticText = "Destroy target land. {this} deals 2 damage to that land's controller"; - } - - public PoisonTheWellEffect(final PoisonTheWellEffect effect) { - super(effect); - } - - @Override - public PoisonTheWellEffect copy() { - return new PoisonTheWellEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent targetedLand = game.getPermanent(source.getFirstTarget()); - if (targetedLand != null) { - targetedLand.destroy(source.getSourceId(), game, true); - Player controller = game.getPlayer(targetedLand.getControllerId()); - if (controller != null) { - controller.damage(2, source.getSourceId(), game, false, true); - } - return true; - } - return false; - } -} diff --git a/Mage.Sets/src/mage/sets/shadowmoor/SmashToSmithereens.java b/Mage.Sets/src/mage/sets/shadowmoor/SmashToSmithereens.java index 98ff75dc2b..113b83d9f7 100644 --- a/Mage.Sets/src/mage/sets/shadowmoor/SmashToSmithereens.java +++ b/Mage.Sets/src/mage/sets/shadowmoor/SmashToSmithereens.java @@ -28,17 +28,12 @@ package mage.sets.shadowmoor; import java.util.UUID; -import mage.constants.CardType; -import mage.constants.Outcome; -import mage.constants.Rarity; -import mage.constants.Zone; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; +import mage.constants.CardType; +import mage.constants.Rarity; import mage.target.common.TargetArtifactPermanent; /** @@ -52,9 +47,11 @@ public class SmashToSmithereens extends CardImpl { this.expansionSetCode = "SHM"; // Destroy target artifact. Smash to Smithereens deals 3 damage to that artifact's controller. - this.getSpellAbility().addTarget(new TargetArtifactPermanent()); this.getSpellAbility().addEffect(new DestroyTargetEffect()); - this.getSpellAbility().addEffect(new SmashToSmithereensEffect()); + Effect effect = new DamageTargetControllerEffect(3); + effect.setText("{this} deals 3 damage to that artifact's controller"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetArtifactPermanent()); } public SmashToSmithereens(final SmashToSmithereens card) { @@ -66,35 +63,3 @@ public class SmashToSmithereens extends CardImpl { return new SmashToSmithereens(this); } } - -class SmashToSmithereensEffect extends OneShotEffect { - - SmashToSmithereensEffect() { - super(Outcome.Damage); - staticText = "{this} deals 3 damage to that artifact's controller"; - } - - SmashToSmithereensEffect(final SmashToSmithereensEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getBattlefield().getPermanent(source.getFirstTarget()); - if (permanent == null) { - permanent = (Permanent) game.getLastKnownInformation(source.getFirstTarget(), Zone.BATTLEFIELD); - } - if (permanent != null) { - Player player = game.getPlayer(permanent.getControllerId()); - if (player != null) { - player.damage(3, source.getSourceId(), game, false, true); - } - } - return false; - } - - @Override - public SmashToSmithereensEffect copy() { - return new SmashToSmithereensEffect(this); - } -} diff --git a/Mage.Sets/src/mage/sets/tenthedition/Cryoclasm.java b/Mage.Sets/src/mage/sets/tenthedition/Cryoclasm.java index f76c044baa..c9c1cff99b 100644 --- a/Mage.Sets/src/mage/sets/tenthedition/Cryoclasm.java +++ b/Mage.Sets/src/mage/sets/tenthedition/Cryoclasm.java @@ -28,23 +28,15 @@ package mage.sets.tenthedition; import java.util.UUID; - -import mage.MageObject; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; -import mage.abilities.effects.common.DamageTargetEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterLandPermanent; import mage.filter.predicate.Predicates; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; import mage.target.common.TargetLandPermanent; /** @@ -54,20 +46,20 @@ import mage.target.common.TargetLandPermanent; public class Cryoclasm extends CardImpl { private static final FilterLandPermanent filter = new FilterLandPermanent("Plains or Island"); + static { - filter.add(Predicates.or( - new SubtypePredicate("Plains"), - new SubtypePredicate("Island"))); + filter.add(Predicates.or(new SubtypePredicate("Plains"), new SubtypePredicate("Island"))); } public Cryoclasm(UUID ownerId) { super(ownerId, 195, "Cryoclasm", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{R}"); this.expansionSetCode = "10E"; - // Destroy target Plains or Island. Cryoclasm deals 3 damage to that land's controller. this.getSpellAbility().addEffect(new DestroyTargetEffect()); - this.getSpellAbility().addEffect(new CryoclasmEffect()); + Effect effect = new DamageTargetControllerEffect(3); + effect.setText("{this} deals 3 damage to that land's controller"); + this.getSpellAbility().addEffect(effect); this.getSpellAbility().addTarget(new TargetLandPermanent(filter)); } @@ -81,36 +73,3 @@ public class Cryoclasm extends CardImpl { return new Cryoclasm(this); } } - -class CryoclasmEffect extends OneShotEffect { - - public CryoclasmEffect() { - super(Outcome.Damage); - this.staticText = "{this} deals 3 damage to that land's controller"; - } - - public CryoclasmEffect(final CryoclasmEffect effect) { - super(effect); - } - - @Override - public CryoclasmEffect copy() { - return new CryoclasmEffect(this); - } - - @Override - public boolean apply(Game game, Ability source) { - UUID targetId = getTargetPointer().getFirst(game, source); - if (targetId != null) { - Permanent permanent = game.getPermanentOrLKIBattlefield(targetId); - if (permanent != null) { - Player controller = game.getPlayer(permanent.getControllerId()); - if (controller != null) { - controller.damage(3, source.getSourceId(), game, false, false); - return true; - } - } - } - return false; - } -} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/theros/PeakEruption.java b/Mage.Sets/src/mage/sets/theros/PeakEruption.java index 4aa27c573a..0b8e9796eb 100644 --- a/Mage.Sets/src/mage/sets/theros/PeakEruption.java +++ b/Mage.Sets/src/mage/sets/theros/PeakEruption.java @@ -28,19 +28,14 @@ package mage.sets.theros; import java.util.UUID; -import mage.abilities.Ability; -import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.Effect; +import mage.abilities.effects.common.DamageTargetControllerEffect; import mage.abilities.effects.common.DestroyTargetEffect; import mage.cards.CardImpl; import mage.constants.CardType; -import mage.constants.Outcome; import mage.constants.Rarity; -import mage.constants.Zone; import mage.filter.common.FilterLandPermanent; import mage.filter.predicate.mageobject.SubtypePredicate; -import mage.game.Game; -import mage.game.permanent.Permanent; -import mage.players.Player; import mage.target.common.TargetLandPermanent; /** @@ -50,20 +45,21 @@ import mage.target.common.TargetLandPermanent; public class PeakEruption extends CardImpl { private static final FilterLandPermanent filter = new FilterLandPermanent("Mountain"); + static{ filter.add(new SubtypePredicate(("Mountain"))); } - - + public PeakEruption(UUID ownerId) { super(ownerId, 132, "Peak Eruption", Rarity.UNCOMMON, new CardType[]{CardType.SORCERY}, "{2}{R}"); this.expansionSetCode = "THS"; - // Destroy target Mountain. Peak Eruption deals 3 damage to that land's controller. - this.getSpellAbility().addTarget(new TargetLandPermanent(filter)); this.getSpellAbility().addEffect(new DestroyTargetEffect()); - this.getSpellAbility().addEffect(new PeakEruptionEffect()); + Effect effect = new DamageTargetControllerEffect(3); + effect.setText("{this} deals 3 damage to that land's controller"); + this.getSpellAbility().addEffect(effect); + this.getSpellAbility().addTarget(new TargetLandPermanent(filter)); } public PeakEruption(final PeakEruption card) { @@ -75,36 +71,3 @@ public class PeakEruption extends CardImpl { return new PeakEruption(this); } } - - -class PeakEruptionEffect extends OneShotEffect { - - PeakEruptionEffect() { - super(Outcome.Damage); - staticText = "{this} deals 3 damage to that land's controller"; - } - - PeakEruptionEffect(final PeakEruptionEffect effect) { - super(effect); - } - - @Override - public boolean apply(Game game, Ability source) { - Permanent permanent = game.getBattlefield().getPermanent(source.getFirstTarget()); - if (permanent == null) { - permanent = (Permanent) game.getLastKnownInformation(source.getFirstTarget(), Zone.BATTLEFIELD); - } - if (permanent != null) { - Player player = game.getPlayer(permanent.getControllerId()); - if (player != null) { - player.damage(3, source.getSourceId(), game, false, true); - } - } - return false; - } - - @Override - public PeakEruptionEffect copy() { - return new PeakEruptionEffect(this); - } -}