mirror of
https://github.com/correl/mage.git
synced 2025-03-17 01:06:26 -09:00
Implemented Righteous War
This commit is contained in:
parent
53f77ac9cd
commit
1b5c1cdb61
2 changed files with 90 additions and 0 deletions
89
Mage.Sets/src/mage/cards/r/RighteousWar.java
Normal file
89
Mage.Sets/src/mage/cards/r/RighteousWar.java
Normal file
|
@ -0,0 +1,89 @@
|
||||||
|
/*
|
||||||
|
* 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.cards.r;
|
||||||
|
|
||||||
|
import java.util.UUID;
|
||||||
|
import mage.ObjectColor;
|
||||||
|
import mage.abilities.common.SimpleStaticAbility;
|
||||||
|
import mage.abilities.effects.common.continuous.GainAbilityControlledEffect;
|
||||||
|
import mage.abilities.keyword.ProtectionAbility;
|
||||||
|
import mage.cards.CardImpl;
|
||||||
|
import mage.cards.CardSetInfo;
|
||||||
|
import mage.constants.CardType;
|
||||||
|
import mage.constants.Duration;
|
||||||
|
import mage.constants.Zone;
|
||||||
|
import mage.filter.common.FilterCreaturePermanent;
|
||||||
|
import mage.filter.predicate.mageobject.ColorPredicate;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @author TheElk801
|
||||||
|
*/
|
||||||
|
public class RighteousWar extends CardImpl {
|
||||||
|
|
||||||
|
private static final FilterCreaturePermanent whiteFilter = new FilterCreaturePermanent("white creatures you control");
|
||||||
|
private static final FilterCreaturePermanent blackFilter = new FilterCreaturePermanent("black creatures you control");
|
||||||
|
|
||||||
|
static {
|
||||||
|
whiteFilter.add(new ColorPredicate(ObjectColor.WHITE));
|
||||||
|
blackFilter.add(new ColorPredicate(ObjectColor.BLACK));
|
||||||
|
}
|
||||||
|
|
||||||
|
public RighteousWar(UUID ownerId, CardSetInfo setInfo) {
|
||||||
|
super(ownerId, setInfo, new CardType[]{CardType.ENCHANTMENT}, "{1}{W}{B}");
|
||||||
|
|
||||||
|
// White creatures you control have protection from black.
|
||||||
|
this.addAbility(new SimpleStaticAbility(
|
||||||
|
Zone.BATTLEFIELD,
|
||||||
|
new GainAbilityControlledEffect(
|
||||||
|
ProtectionAbility.from(ObjectColor.BLACK),
|
||||||
|
Duration.WhileOnBattlefield,
|
||||||
|
whiteFilter
|
||||||
|
)
|
||||||
|
));
|
||||||
|
|
||||||
|
// Black creatures you control have protection from white.
|
||||||
|
this.addAbility(new SimpleStaticAbility(
|
||||||
|
Zone.BATTLEFIELD,
|
||||||
|
new GainAbilityControlledEffect(
|
||||||
|
ProtectionAbility.from(ObjectColor.WHITE),
|
||||||
|
Duration.WhileOnBattlefield,
|
||||||
|
blackFilter
|
||||||
|
)
|
||||||
|
));
|
||||||
|
}
|
||||||
|
|
||||||
|
public RighteousWar(final RighteousWar card) {
|
||||||
|
super(card);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public RighteousWar copy() {
|
||||||
|
return new RighteousWar(this);
|
||||||
|
}
|
||||||
|
}
|
|
@ -147,6 +147,7 @@ public class Visions extends ExpansionSet {
|
||||||
cards.add(new SetCardInfo("Resistance Fighter", 118, Rarity.COMMON, mage.cards.r.ResistanceFighter.class));
|
cards.add(new SetCardInfo("Resistance Fighter", 118, Rarity.COMMON, mage.cards.r.ResistanceFighter.class));
|
||||||
cards.add(new SetCardInfo("Retribution of the Meek", 119, Rarity.RARE, mage.cards.r.RetributionOfTheMeek.class));
|
cards.add(new SetCardInfo("Retribution of the Meek", 119, Rarity.RARE, mage.cards.r.RetributionOfTheMeek.class));
|
||||||
cards.add(new SetCardInfo("Righteous Aura", 120, Rarity.COMMON, mage.cards.r.RighteousAura.class));
|
cards.add(new SetCardInfo("Righteous Aura", 120, Rarity.COMMON, mage.cards.r.RighteousAura.class));
|
||||||
|
cards.add(new SetCardInfo("Righteous War", 134, Rarity.RARE, mage.cards.r.RighteousWar.class));
|
||||||
cards.add(new SetCardInfo("River Boa", 68, Rarity.COMMON, mage.cards.r.RiverBoa.class));
|
cards.add(new SetCardInfo("River Boa", 68, Rarity.COMMON, mage.cards.r.RiverBoa.class));
|
||||||
cards.add(new SetCardInfo("Rock Slide", 92, Rarity.COMMON, mage.cards.r.RockSlide.class));
|
cards.add(new SetCardInfo("Rock Slide", 92, Rarity.COMMON, mage.cards.r.RockSlide.class));
|
||||||
cards.add(new SetCardInfo("Rowen", 69, Rarity.RARE, mage.cards.r.Rowen.class));
|
cards.add(new SetCardInfo("Rowen", 69, Rarity.RARE, mage.cards.r.Rowen.class));
|
||||||
|
|
Loading…
Add table
Reference in a new issue