diff --git a/Mage.Sets/src/mage/sets/alarareborn/BantSureblade.java b/Mage.Sets/src/mage/sets/alarareborn/BantSureblade.java index 1f7bffd622e..b4f34c66ba2 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/BantSureblade.java +++ b/Mage.Sets/src/mage/sets/alarareborn/BantSureblade.java @@ -74,11 +74,11 @@ public class BantSureblade extends CardImpl { Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new BoostSourceEffect(1,1, Duration.WhileOnBattlefield), new ControlsPermanentCondition(filter), - "As long as you control another multicolored permanent, Bant Sureblade gets +1/+1 and has first strike")); + "As long as you control another multicolored permanent, {this} gets +1/+1")); Ability ability2 = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new GainAbilitySourceEffect(FirstStrikeAbility.getInstance()), new ControlsPermanentCondition(filter), - null)); + "As long as you control another multicolored permanent, {this} has first strike")); this.addAbility(ability); this.addAbility(ability2); } diff --git a/Mage.Sets/src/mage/sets/alarareborn/ClovenCasting.java b/Mage.Sets/src/mage/sets/alarareborn/ClovenCasting.java new file mode 100644 index 00000000000..4f7ffc8b6e9 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alarareborn/ClovenCasting.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.alarareborn; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.common.SpellCastTriggeredAbility; +import mage.abilities.costs.mana.GenericManaCost; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.DoIfCostPaid; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Outcome; +import mage.constants.Rarity; +import mage.filter.FilterSpell; +import mage.filter.predicate.Predicates; +import mage.filter.predicate.mageobject.CardTypePredicate; +import mage.filter.predicate.mageobject.MulticoloredPredicate; +import mage.game.Game; +import mage.game.stack.Spell; +import mage.players.Player; + +/** + * + * @author jeffwadsworth + */ +public class ClovenCasting extends CardImpl { + + private static final FilterSpell filter = new FilterSpell("a multicolored instant or sorcery spell"); + + static { + filter.add(Predicates.or( + new CardTypePredicate(CardType.INSTANT), + new CardTypePredicate(CardType.SORCERY))); + filter.add(new MulticoloredPredicate()); + } + + public ClovenCasting(UUID ownerId) { + super(ownerId, 86, "Cloven Casting", Rarity.RARE, new CardType[]{CardType.ENCHANTMENT}, "{5}{U}{R}"); + this.expansionSetCode = "ARB"; + + this.color.setRed(true); + this.color.setBlue(true); + + // Whenever you cast a multicolored instant or sorcery spell, you may pay {1}. If you do, copy that spell. You may choose new targets for the copy. + this.addAbility(new SpellCastTriggeredAbility(new DoIfCostPaid(new ClovenCastingEffect(), new GenericManaCost(1)), filter, true, true)); + + } + + public ClovenCasting(final ClovenCasting card) { + super(card); + } + + @Override + public ClovenCasting copy() { + return new ClovenCasting(this); + } +} + +class ClovenCastingEffect extends OneShotEffect { + + public ClovenCastingEffect() { + super(Outcome.Copy); + staticText = "copy that spell. You may choose new targets for the copy"; + } + + public ClovenCastingEffect(final ClovenCastingEffect effect) { + super(effect); + } + + @Override + public boolean apply(Game game, Ability source) { + Spell spell = game.getStack().getSpell(targetPointer.getFirst(game, source)); + if (spell != null) { + Spell copy = spell.copySpell(); + copy.setControllerId(source.getControllerId()); + copy.setCopiedSpell(true); + game.getStack().push(copy); + copy.chooseNewTargets(game, source.getControllerId()); + Player player = game.getPlayer(source.getControllerId()); + String activateMessage = copy.getActivatedMessage(game); + if (activateMessage.startsWith(" casts ")) { + activateMessage = activateMessage.substring(6); + } + game.informPlayers(player.getName() + " copies " + activateMessage); + return true; + } + return false; + } + + @Override + public ClovenCastingEffect copy() { + return new ClovenCastingEffect(this); + } +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/alarareborn/EsperStormblade.java b/Mage.Sets/src/mage/sets/alarareborn/EsperStormblade.java index ed7dbe2909a..8ae48669916 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/EsperStormblade.java +++ b/Mage.Sets/src/mage/sets/alarareborn/EsperStormblade.java @@ -74,11 +74,11 @@ public class EsperStormblade extends CardImpl { Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new BoostSourceEffect(1,1, Duration.WhileOnBattlefield), new ControlsPermanentCondition(filter), - "As long as you control another multicolored permanent, Esper Stormblade gets +1/+1 and has flying")); + "As long as you control another multicolored permanent, {this} gets +1/+1")); Ability ability2 = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new GainAbilitySourceEffect(FlyingAbility.getInstance()), new ControlsPermanentCondition(filter), - null)); + "As long as you control another multicolored permanent, {this} has flying")); this.addAbility(ability); this.addAbility(ability2); } diff --git a/Mage.Sets/src/mage/sets/alarareborn/GrixisGrimblade.java b/Mage.Sets/src/mage/sets/alarareborn/GrixisGrimblade.java index 1f970736914..272024c9de4 100644 --- a/Mage.Sets/src/mage/sets/alarareborn/GrixisGrimblade.java +++ b/Mage.Sets/src/mage/sets/alarareborn/GrixisGrimblade.java @@ -74,11 +74,11 @@ public class GrixisGrimblade extends CardImpl { Ability ability = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new BoostSourceEffect(1,1, Duration.WhileOnBattlefield), new ControlsPermanentCondition(filter), - "As long as you control another multicolored permanent, Grixis Grimblade gets +1/+1 and has deathtouch")); + "As long as you control another multicolored permanent, {this} gets +1/+1")); Ability ability2 = new SimpleStaticAbility(Zone.BATTLEFIELD, new ConditionalContinousEffect( new GainAbilitySourceEffect(DeathtouchAbility.getInstance()), new ControlsPermanentCondition(filter), - null)); + "As long as you control another multicolored permanent, {this} has deathtouch")); this.addAbility(ability); this.addAbility(ability2); diff --git a/Mage.Sets/src/mage/sets/alarareborn/IntimidationBolt.java b/Mage.Sets/src/mage/sets/alarareborn/IntimidationBolt.java new file mode 100644 index 00000000000..f340bb4cbf4 --- /dev/null +++ b/Mage.Sets/src/mage/sets/alarareborn/IntimidationBolt.java @@ -0,0 +1,101 @@ +/* + * 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.alarareborn; + +import java.util.UUID; +import mage.abilities.Ability; +import mage.abilities.effects.RestrictionEffect; +import mage.abilities.effects.common.DamageTargetEffect; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +import mage.constants.Rarity; +import mage.game.Game; +import mage.game.permanent.Permanent; +import mage.target.common.TargetCreaturePermanent; + +/** + * + * @author jeffwadsworth + */ +public class IntimidationBolt extends CardImpl { + + public IntimidationBolt(UUID ownerId) { + super(ownerId, 99, "Intimidation Bolt", Rarity.UNCOMMON, new CardType[]{CardType.INSTANT}, "{1}{R}{W}"); + this.expansionSetCode = "ARB"; + + this.color.setRed(true); + this.color.setWhite(true); + + // Intimidation Bolt deals 3 damage to target creature. Other creatures can't attack this turn. + this.getSpellAbility().addEffect(new DamageTargetEffect(3)); + this.getSpellAbility().addEffect(new IntimidationEffect(Duration.EndOfTurn)); + this.getSpellAbility().addTarget(new TargetCreaturePermanent()); + + } + + public IntimidationBolt(final IntimidationBolt card) { + super(card); + } + + @Override + public IntimidationBolt copy() { + return new IntimidationBolt(this); + } +} + +class IntimidationEffect extends RestrictionEffect { + + public IntimidationEffect(Duration duration) { + super(duration); + staticText = "Other creatures can't attack this turn"; + } + + public IntimidationEffect(final IntimidationEffect effect) { + super(effect); + } + + @Override + public boolean applies(Permanent permanent, Ability source, Game game) { + if (!permanent.getId().equals(source.getFirstTarget())) { + return true; + } + return false; + } + + @Override + public boolean canAttack(Game game) { + return false; + } + + @Override + public IntimidationEffect copy() { + return new IntimidationEffect(this); + } + +} \ No newline at end of file diff --git a/Mage.Sets/src/mage/sets/alarareborn/SpellboundDragon.java b/Mage.Sets/src/mage/sets/alarareborn/SpellboundDragon.java new file mode 100644 index 00000000000..5ca50ccb98f --- /dev/null +++ b/Mage.Sets/src/mage/sets/alarareborn/SpellboundDragon.java @@ -0,0 +1,115 @@ +/* + * 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.alarareborn; + +import java.util.UUID; +import mage.MageInt; +import mage.abilities.Ability; +import mage.abilities.common.AttacksTriggeredAbility; +import mage.abilities.effects.OneShotEffect; +import mage.abilities.effects.common.continious.BoostSourceEffect; +import mage.abilities.keyword.FlyingAbility; +import mage.cards.Card; +import mage.cards.CardImpl; +import mage.constants.CardType; +import mage.constants.Duration; +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.TargetDiscard; + +/** + * + * @author jeffwadsworth + */ +public class SpellboundDragon extends CardImpl { + + public SpellboundDragon(UUID ownerId) { + super(ownerId, 90, "Spellbound Dragon", Rarity.RARE, new CardType[]{CardType.CREATURE}, "{3}{U}{R}"); + this.expansionSetCode = "ARB"; + this.subtype.add("Dragon"); + + this.color.setRed(true); + this.color.setBlue(true); + this.power = new MageInt(3); + this.toughness = new MageInt(5); + + // Flying + this.addAbility(FlyingAbility.getInstance()); + + // Whenever Spellbound Dragon attacks, draw a card, then discard a card. Spellbound Dragon gets +X/+0 until end of turn, where X is the discarded card's converted mana cost. + this.addAbility(new AttacksTriggeredAbility(new SpellboundDragonEffect(), false)); + + } + + public SpellboundDragon(final SpellboundDragon card) { + super(card); + } + + @Override + public SpellboundDragon copy() { + return new SpellboundDragon(this); + } +} + +class SpellboundDragonEffect extends OneShotEffect { + + public SpellboundDragonEffect() { + super(Outcome.BoostCreature); + staticText = "draw a card, then discard a card. Spellbound Dragon gets +X/+0 until end of turn, where X is the discarded card's converted mana cost"; + } + + public SpellboundDragonEffect(final SpellboundDragonEffect effect) { + super(effect); + } + + @Override + public SpellboundDragonEffect copy() { + return new SpellboundDragonEffect(this); + } + + @Override + public boolean apply(Game game, Ability source) { + Player you = game.getPlayer(source.getControllerId()); + Permanent dragon = game.getPermanent(source.getSourceId()); + you.drawCards(1, game); + TargetDiscard target = new TargetDiscard(you.getId()); + you.choose(Outcome.Discard, target, source.getSourceId(), game); + Card card = you.getHand().get(target.getFirstTarget(), game); + if (card != null && you.discard(card, source, game)) { + int cmc = card.getManaCost().convertedManaCost(); + if (dragon != null) { + game.addEffect(new BoostSourceEffect(cmc, 0, Duration.EndOfTurn), source); + return true; + } + } + return false; + } +} \ No newline at end of file