diff --git a/Mage.Sets/src/mage/sets/magic2010/DivineVerdict.java b/Mage.Sets/src/mage/sets/magic2010/DivineVerdict.java new file mode 100644 index 0000000000..4f5554fbdb --- /dev/null +++ b/Mage.Sets/src/mage/sets/magic2010/DivineVerdict.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.magic2010; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Rarity; +import mage.abilities.effects.common.DestroyTargetEffect; +import mage.cards.CardImpl; +import mage.filter.common.FilterCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author North + */ +public class DivineVerdict extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("attacking or blocking creature"); + + static { + filter.setAttacking(true); + filter.setUseAttacking(true); + filter.setBlocking(true); + filter.setUseBlocking(true); + } + + public DivineVerdict(UUID ownerId) { + super(ownerId, 8, "Divine Verdict", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{3}{W}"); + this.expansionSetCode = "M10"; + + this.color.setWhite(true); + + this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); + this.getSpellAbility().addEffect(new DestroyTargetEffect()); + } + + public DivineVerdict(final DivineVerdict card) { + super(card); + } + + @Override + public DivineVerdict copy() { + return new DivineVerdict(this); + } +} diff --git a/Mage.Sets/src/mage/sets/magic2010/GorgonFlail.java b/Mage.Sets/src/mage/sets/magic2010/GorgonFlail.java new file mode 100644 index 0000000000..49c1111c3f --- /dev/null +++ b/Mage.Sets/src/mage/sets/magic2010/GorgonFlail.java @@ -0,0 +1,68 @@ +/* + * 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.magic2010; + +import java.util.UUID; +import mage.Constants.AttachmentType; +import mage.Constants.CardType; +import mage.Constants.Outcome; +import mage.Constants.Rarity; +import mage.Constants.Zone; +import mage.abilities.common.SimpleStaticAbility; +import mage.abilities.costs.mana.ManaCostsImpl; +import mage.abilities.effects.common.continious.BoostEquippedEffect; +import mage.abilities.effects.common.continious.GainAbilityAttachedEffect; +import mage.abilities.keyword.DeathtouchAbility; +import mage.abilities.keyword.EquipAbility; +import mage.cards.CardImpl; + +/** + * + * @author North + */ +public class GorgonFlail extends CardImpl { + + public GorgonFlail(UUID ownerId) { + super(ownerId, 211, "Gorgon Flail", Rarity.UNCOMMON, new CardType[]{CardType.ARTIFACT}, "{2}"); + this.expansionSetCode = "M10"; + this.subtype.add("Equipment"); + + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new BoostEquippedEffect(1, 1))); + this.addAbility(new SimpleStaticAbility(Zone.BATTLEFIELD, new GainAbilityAttachedEffect(DeathtouchAbility.getInstance(), AttachmentType.EQUIPMENT))); + this.addAbility(new EquipAbility(Outcome.BoostCreature, new ManaCostsImpl("{2}"))); + } + + public GorgonFlail(final GorgonFlail card) { + super(card); + } + + @Override + public GorgonFlail copy() { + return new GorgonFlail(this); + } +} diff --git a/Mage.Sets/src/mage/sets/magic2010/Righteousness.java b/Mage.Sets/src/mage/sets/magic2010/Righteousness.java new file mode 100644 index 0000000000..f82c531fc4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/magic2010/Righteousness.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.magic2010; + +import java.util.UUID; +import mage.Constants.Rarity; + +/** + * + * @author North + */ +public class Righteousness extends mage.sets.tenth.Righteousness { + + public Righteousness(UUID ownerId) { + super(ownerId); + this.cardNumber = 27; + this.expansionSetCode = "M10"; + this.rarity = Rarity.UNCOMMON; + } + + public Righteousness(final Righteousness card) { + super(card); + } + + @Override + public Righteousness copy() { + return new Righteousness(this); + } +} diff --git a/Mage.Sets/src/mage/sets/magic2010/TrumpetBlast.java b/Mage.Sets/src/mage/sets/magic2010/TrumpetBlast.java new file mode 100644 index 0000000000..dc456eb72a --- /dev/null +++ b/Mage.Sets/src/mage/sets/magic2010/TrumpetBlast.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010 BetaSteward_at_googlemail.com. All rights reserved. + * + * Redistribution and use in source and binary forms, with or without modification, are + * permitted provided that the following conditions are met: + * + * 1. Redistributions of source code must retain the above copyright notice, this list of + * conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright notice, this list + * of conditions and the following disclaimer in the documentation and/or other materials + * provided with the distribution. + * + * THIS SOFTWARE IS PROVIDED BY BetaSteward_at_googlemail.com ``AS IS'' AND ANY EXPRESS OR IMPLIED + * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND + * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL BetaSteward_at_googlemail.com OR + * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR + * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR + * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON + * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING + * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF + * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + * + * The views and conclusions contained in the software and documentation are those of the + * authors and should not be interpreted as representing official policies, either expressed + * or implied, of BetaSteward_at_googlemail.com. + */ +package mage.sets.magic2010; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Duration; +import mage.Constants.Rarity; +import mage.abilities.effects.common.continious.BoostAllEffect; +import mage.cards.CardImpl; +import mage.filter.common.FilterAttackingCreature; + +/** + * + * @author North + */ +public class TrumpetBlast extends CardImpl { + + private static final FilterAttackingCreature filter = new FilterAttackingCreature("Attacking creatures"); + + public TrumpetBlast(UUID ownerId) { + super(ownerId, 160, "Trumpet Blast", Rarity.COMMON, new CardType[]{CardType.INSTANT}, "{2}{R}"); + this.expansionSetCode = "M10"; + + this.color.setRed(true); + + this.getSpellAbility().addEffect(new BoostAllEffect(2, 0, Duration.EndOfTurn, filter, false)); + } + + public TrumpetBlast(final TrumpetBlast card) { + super(card); + } + + @Override + public TrumpetBlast copy() { + return new TrumpetBlast(this); + } +} diff --git a/Mage.Sets/src/mage/sets/magic2010/Windstorm.java b/Mage.Sets/src/mage/sets/magic2010/Windstorm.java new file mode 100644 index 0000000000..23c1cb4f61 --- /dev/null +++ b/Mage.Sets/src/mage/sets/magic2010/Windstorm.java @@ -0,0 +1,68 @@ +/* + * 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.magic2010; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Rarity; +import mage.abilities.dynamicvalue.common.ManacostVariableValue; +import mage.abilities.effects.common.DamageAllEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.CardImpl; +import mage.filter.common.FilterCreaturePermanent; + +/** + * + * @author North + */ +public class Windstorm extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("creature with flying"); + + static { + filter.getAbilities().add(FlyingAbility.getInstance()); + } + + public Windstorm(UUID ownerId) { + super(ownerId, 205, "Windstorm", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{X}{G}"); + this.expansionSetCode = "M10"; + + this.color.setGreen(true); + + this.getSpellAbility().addEffect(new DamageAllEffect(new ManacostVariableValue(), filter)); + } + + public Windstorm(final Windstorm card) { + super(card); + } + + @Override + public Windstorm copy() { + return new Windstorm(this); + } +} diff --git a/Mage.Sets/src/mage/sets/mirrodinbesieged/RallyTheForces.java b/Mage.Sets/src/mage/sets/mirrodinbesieged/RallyTheForces.java index becd78317f..293b52a090 100644 --- a/Mage.Sets/src/mage/sets/mirrodinbesieged/RallyTheForces.java +++ b/Mage.Sets/src/mage/sets/mirrodinbesieged/RallyTheForces.java @@ -38,7 +38,6 @@ import mage.abilities.effects.common.continious.GainAbilityAllEffect; import mage.abilities.keyword.FirstStrikeAbility; import mage.cards.CardImpl; import mage.filter.common.FilterAttackingCreature; -import mage.filter.common.FilterCreaturePermanent; /** * diff --git a/Mage.Sets/src/mage/sets/tenth/Righteousness.java b/Mage.Sets/src/mage/sets/tenth/Righteousness.java new file mode 100644 index 0000000000..af4af7af12 --- /dev/null +++ b/Mage.Sets/src/mage/sets/tenth/Righteousness.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.tenth; + +import java.util.UUID; +import mage.Constants.CardType; +import mage.Constants.Duration; +import mage.Constants.Rarity; +import mage.abilities.effects.common.continious.BoostTargetEffect; +import mage.cards.CardImpl; +import mage.filter.common.FilterCreaturePermanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author North + */ +public class Righteousness extends CardImpl { + + private static final FilterCreaturePermanent filter = new FilterCreaturePermanent("blocking creature"); + + static { + filter.setBlocking(true); + filter.setUseBlocking(true); + } + + public Righteousness(UUID ownerId) { + super(ownerId, 36, "Righteousness", Rarity.RARE, new CardType[]{CardType.INSTANT}, "{W}"); + this.expansionSetCode = "10E"; + + this.color.setWhite(true); + + this.getSpellAbility().addEffect(new BoostTargetEffect(7, 7, Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent(filter)); + } + + public Righteousness(final Righteousness card) { + super(card); + } + + @Override + public Righteousness copy() { + return new Righteousness(this); + } +} diff --git a/Mage/src/mage/filter/common/FilterCreaturePermanent.java b/Mage/src/mage/filter/common/FilterCreaturePermanent.java index 39fec82b21..fc9437eab6 100644 --- a/Mage/src/mage/filter/common/FilterCreaturePermanent.java +++ b/Mage/src/mage/filter/common/FilterCreaturePermanent.java @@ -44,8 +44,6 @@ public class FilterCreaturePermanent> exten protected boolean attacking; protected boolean useBlocking; protected boolean blocking; - protected boolean useTapped; - protected boolean tapped; public FilterCreaturePermanent() { this("creature"); @@ -75,15 +73,18 @@ public class FilterCreaturePermanent> exten if (!super.match(permanent)) return notFilter; - if (useAttacking && permanent.isAttacking() != attacking) - return notFilter; + if (useAttacking && permanent.isAttacking() != attacking) { + if (useBlocking) { + if ((permanent.getBlocking() > 0) != blocking) + return notFilter; + } else + return notFilter; + } + if (useBlocking && (permanent.getBlocking() > 0) != blocking) return notFilter; - if (useTapped && permanent.isTapped() != tapped) - return notFilter; - return !notFilter; } @@ -103,14 +104,6 @@ public class FilterCreaturePermanent> exten this.blocking = blocking; } - public void setUseTapped ( boolean useTapped ) { - this.useTapped = useTapped; - } - - public void setTapped ( boolean tapped ) { - this.tapped = tapped; - } - @Override public FilterCreaturePermanent copy() { if (this == defaultFilter)