mirror of
https://github.com/correl/mage.git
synced 2024-11-25 03:00:11 +00:00
Fixed Archfiend's Vessel not moving to exile (fixes #7622)
This commit is contained in:
parent
1f6332d658
commit
27c0f75302
2 changed files with 30 additions and 3 deletions
|
@ -113,7 +113,7 @@ class ArchfiendsVesselEffect extends OneShotEffect {
|
||||||
if (archfiendsVessel != null) {
|
if (archfiendsVessel != null) {
|
||||||
Player controller = game.getPlayer(source.getControllerId());
|
Player controller = game.getPlayer(source.getControllerId());
|
||||||
if (controller != null) {
|
if (controller != null) {
|
||||||
boolean moved = controller.moveCards(archfiendsVessel.getMainCard(), Zone.EXILED, source, game);
|
boolean moved = controller.moveCards(archfiendsVessel, Zone.EXILED, source, game);
|
||||||
if (moved) {
|
if (moved) {
|
||||||
Token token = new DemonToken();
|
Token token = new DemonToken();
|
||||||
token.putOntoBattlefield(1, game, source, controller.getId());
|
token.putOntoBattlefield(1, game, source, controller.getId());
|
||||||
|
@ -128,4 +128,4 @@ class ArchfiendsVesselEffect extends OneShotEffect {
|
||||||
public ArchfiendsVesselEffect copy() {
|
public ArchfiendsVesselEffect copy() {
|
||||||
return new ArchfiendsVesselEffect(this);
|
return new ArchfiendsVesselEffect(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,8 +26,9 @@ public class ArchfiendsVesselTest extends CardTestPlayerBase {
|
||||||
assertAllCommandsUsed();
|
assertAllCommandsUsed();
|
||||||
|
|
||||||
assertPermanentCount(playerA, "Demon", 1);
|
assertPermanentCount(playerA, "Demon", 1);
|
||||||
|
assertPermanentCount(playerA, archfiendsVessel, 0);
|
||||||
assertExileCount(playerA, archfiendsVessel, 1);
|
assertExileCount(playerA, archfiendsVessel, 1);
|
||||||
|
assertGraveyardCount(playerA, archfiendsVessel, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@ -48,7 +49,33 @@ public class ArchfiendsVesselTest extends CardTestPlayerBase {
|
||||||
assertAllCommandsUsed();
|
assertAllCommandsUsed();
|
||||||
|
|
||||||
assertPermanentCount(playerA, "Demon", 1);
|
assertPermanentCount(playerA, "Demon", 1);
|
||||||
|
assertPermanentCount(playerA, archfiendsVessel, 0);
|
||||||
assertExileCount(playerA, archfiendsVessel, 1);
|
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);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue