diff --git a/Mage.Sets/src/mage/cards/s/SerratedArrows.java b/Mage.Sets/src/mage/cards/s/SerratedArrows.java index 51652b69586..8d2908238ba 100644 --- a/Mage.Sets/src/mage/cards/s/SerratedArrows.java +++ b/Mage.Sets/src/mage/cards/s/SerratedArrows.java @@ -39,7 +39,7 @@ public final class SerratedArrows extends CardImpl { effect = new ConditionalOneShotEffect(new SacrificeSourceEffect(), new SourceHasCounterCondition(CounterType.ARROWHEAD, 0, 0), "if there are no arrowhead counters on {this}, sacrifice it"); this.addAbility(new BeginningOfUpkeepTriggeredAbility(Zone.BATTLEFIELD, effect, TargetController.YOU, false, false)); - // {tap}, Remove an arrowhead counter from Serrated Arrows: Put a -1/-1 counter on target creature. + // {T}, Remove an arrowhead counter from Serrated Arrows: Put a -1/-1 counter on target creature. Ability ability = new SimpleActivatedAbility(Zone.BATTLEFIELD, new AddCountersTargetEffect(CounterType.M1M1.createInstance()), new TapSourceCost()); diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/facedown/PrimordialMistTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/facedown/PrimordialMistTest.java new file mode 100644 index 00000000000..4de081e34fe --- /dev/null +++ b/Mage.Tests/src/test/java/org/mage/test/cards/facedown/PrimordialMistTest.java @@ -0,0 +1,56 @@ +package org.mage.test.cards.facedown; + +import mage.constants.EmptyNames; +import mage.constants.PhaseStep; +import mage.constants.Zone; +import org.junit.Test; +import org.mage.test.serverside.base.CardTestPlayerBase; + +/** + * + * @author LevelX2 + */ +public class PrimordialMistTest extends CardTestPlayerBase { + + /** + * I have Brine Elemental played face down as a morph, an artifact which has + * been manifested and Kadena which has been turned face by Ixidron. I can't + * seem to activate Primordial Mist's second ability for any of these kinds + * of face down creatures: + */ + @Test + public void test_ExileAndCastMorphFaceDownCard() { + setStrictChooseMode(true); + + // At the beginning of your end step, you may manifest the top card of your library. + // Exile a face-down permanent you control face-up: You may play that card this turn + addCard(Zone.BATTLEFIELD, playerA, "Primordial Mist"); + // Morph {5}{U}{U} + // When Brine Elemental is turned face up, each opponent skips their next untap step. + addCard(Zone.HAND, playerA, "Brine Elemental"); // Creature {5}{U}{U} (5/4) + addCard(Zone.BATTLEFIELD, playerA, "Island", 9); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Brine Elemental"); + setChoice(playerA, "Yes"); // cast it face down as 2/2 creature + + waitStackResolved(1, PhaseStep.PRECOMBAT_MAIN, playerA); + + activateAbility(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Exile a face-down permanent you control"); + setChoice(playerA, EmptyNames.FACE_DOWN_CREATURE.toString()); + + castSpell(1, PhaseStep.POSTCOMBAT_MAIN, playerA, "Brine Elemental"); + setChoice(playerA, "No"); // cast it face down as 2/2 creature + + setChoice(playerA, "Yes"); + + setStopAt(1, PhaseStep.END_TURN); + execute(); + + assertAllCommandsUsed(); + + assertExileCount(playerA, 0); + + assertPowerToughness(playerA, "Brine Elemental", 5, 4); + + } +} diff --git a/Mage/src/main/java/mage/filter/predicate/other/FaceDownPredicate.java b/Mage/src/main/java/mage/filter/predicate/other/FaceDownPredicate.java index 9edc49598cb..47caf232580 100644 --- a/Mage/src/main/java/mage/filter/predicate/other/FaceDownPredicate.java +++ b/Mage/src/main/java/mage/filter/predicate/other/FaceDownPredicate.java @@ -1,10 +1,8 @@ package mage.filter.predicate.other; -import mage.abilities.keyword.MorphAbility; import mage.cards.Card; import mage.filter.predicate.Predicate; import mage.game.Game; -import mage.game.permanent.Permanent; /** * @author North @@ -14,15 +12,7 @@ public enum FaceDownPredicate implements Predicate { @Override public boolean apply(Card input, Game game) { - if (game.inCheckPlayableState()) { - // Check for cost reduction of possible face down spell to cast - if (input != null && !(input instanceof Permanent)) { - return input.getAbilities().containsClass(MorphAbility.class); - } - return false; - } else { - return input.isFaceDown(game); - } + return input.isFaceDown(game); } @Override diff --git a/Mage/src/main/java/mage/players/PlayerImpl.java b/Mage/src/main/java/mage/players/PlayerImpl.java index 37a2dba762d..b75a1c80356 100644 --- a/Mage/src/main/java/mage/players/PlayerImpl.java +++ b/Mage/src/main/java/mage/players/PlayerImpl.java @@ -3100,15 +3100,6 @@ public abstract class PlayerImpl implements Player, Serializable { } } - // ALTERNATIVE COST from source card (AlternativeCostSourceAbility) - for (Ability objectAbility : sourceObject.getAbilities()) { - if (objectAbility instanceof AlternativeCostSourceAbility) { - if (objectAbility.getCosts().canPay(copy, copy.getSourceId(), playerId, game)) { - return true; - } - } - } - // ALTERNATIVE COST FROM dynamic effects if (getCastSourceIdWithAlternateMana().contains(copy.getSourceId())) { ManaCosts alternateCosts = getCastSourceIdManaCosts().get(copy.getSourceId()); @@ -3128,7 +3119,9 @@ public abstract class PlayerImpl implements Player, Serializable { } // ALTERNATIVE COST from source card (any AlternativeSourceCosts) - return canPlayCardByAlternateCost(game.getCard(ability.getSourceId()), availableMana, copy, game); + if (AbilityType.SPELL.equals(ability.getAbilityType())) { + return canPlayCardByAlternateCost(game.getCard(ability.getSourceId()), availableMana, copy, game); + } } return false; }