diff --git a/Mage.Sets/src/mage/cards/a/ArchfiendsVessel.java b/Mage.Sets/src/mage/cards/a/ArchfiendsVessel.java index e879c473eb..ba8e149d4e 100644 --- a/Mage.Sets/src/mage/cards/a/ArchfiendsVessel.java +++ b/Mage.Sets/src/mage/cards/a/ArchfiendsVessel.java @@ -113,7 +113,7 @@ class ArchfiendsVesselEffect extends OneShotEffect { if (archfiendsVessel != null) { Player controller = game.getPlayer(source.getControllerId()); if (controller != null) { - boolean moved = controller.moveCards(archfiendsVessel.getMainCard(), Zone.EXILED, source, game); + boolean moved = controller.moveCards(archfiendsVessel, Zone.EXILED, source, game); if (moved) { Token token = new DemonToken(); token.putOntoBattlefield(1, game, source, controller.getId()); @@ -128,4 +128,4 @@ class ArchfiendsVesselEffect extends OneShotEffect { public ArchfiendsVesselEffect copy() { return new ArchfiendsVesselEffect(this); } -} \ No newline at end of file +} diff --git a/Mage.Tests/src/test/java/org/mage/test/cards/single/m21/ArchfiendsVesselTest.java b/Mage.Tests/src/test/java/org/mage/test/cards/single/m21/ArchfiendsVesselTest.java index cb1f0923b0..d151dfd5f7 100644 --- a/Mage.Tests/src/test/java/org/mage/test/cards/single/m21/ArchfiendsVesselTest.java +++ b/Mage.Tests/src/test/java/org/mage/test/cards/single/m21/ArchfiendsVesselTest.java @@ -26,8 +26,9 @@ public class ArchfiendsVesselTest extends CardTestPlayerBase { assertAllCommandsUsed(); assertPermanentCount(playerA, "Demon", 1); + assertPermanentCount(playerA, archfiendsVessel, 0); assertExileCount(playerA, archfiendsVessel, 1); - + assertGraveyardCount(playerA, archfiendsVessel, 0); } @Test @@ -48,7 +49,33 @@ public class ArchfiendsVesselTest extends CardTestPlayerBase { assertAllCommandsUsed(); assertPermanentCount(playerA, "Demon", 1); + assertPermanentCount(playerA, archfiendsVessel, 0); assertExileCount(playerA, archfiendsVessel, 1); + assertGraveyardCount(playerA, archfiendsVessel, 0); + } + @Test + public void diesOnStack() { + // If Archfiend’s Vessel leaves the battlefield while its triggered ability is on the stack, + // you can’t exile it from the zone it’s put into, so you won’t create a Demon. + + addCard(Zone.GRAVEYARD, playerA, archfiendsVessel); + addCard(Zone.HAND, playerA, "Exhume"); + addCard(Zone.HAND, playerA, "Fatal Push"); + addCard(Zone.BATTLEFIELD, playerA, "Swamp", 3); + + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Exhume"); + addTarget(playerA, archfiendsVessel); + castSpell(1, PhaseStep.PRECOMBAT_MAIN, playerA, "Fatal Push"); + addTarget(playerA, archfiendsVessel); + setStrictChooseMode(true); + setStopAt(1, PhaseStep.POSTCOMBAT_MAIN); + execute(); + assertAllCommandsUsed(); + + assertPermanentCount(playerA, "Demon", 0); + assertPermanentCount(playerA, archfiendsVessel, 0); + assertExileCount(playerA, archfiendsVessel, 0); + assertGraveyardCount(playerA, archfiendsVessel, 1); } }