* Wave of Vitriol - Fixed that Stranglehold's effect still was applyed even if it was already moved to graveyard (fixes #3966).

This commit is contained in:
LevelX2 2017-09-11 14:19:05 +02:00
parent 849262a7f1
commit eff3e7899a

View file

@ -27,6 +27,7 @@
*/
package mage.cards.w;
import java.util.*;
import mage.abilities.Ability;
import mage.abilities.effects.OneShotEffect;
import mage.cards.CardImpl;
@ -47,8 +48,6 @@ import mage.game.permanent.Permanent;
import mage.players.Player;
import mage.target.common.TargetCardInLibrary;
import java.util.*;
/**
*
* @author LevelX2
@ -121,12 +120,11 @@ class WaveOfVitriolEffect extends OneShotEffect {
}
}
}
game.getState().handleSimultaneousEvent(game);
game.applyEffects();
Cards toBattlefield = new CardsImpl();
Set<Player> playersToShuffle = new LinkedHashSet<>();
for (Map.Entry<Player, Integer> entry : sacrificedLands.entrySet()) {
if (entry.getKey().chooseUse(Outcome.PutLandInPlay, "Search your library for up to " + entry.getValue() + " basic lands?", source, game)) {
TargetCardInLibrary target = new TargetCardInLibrary(0, entry.getValue(), StaticFilters.FILTER_BASIC_LAND_CARD);
if (entry.getKey().searchLibrary(target, game)) {
if (!target.getTargets().isEmpty()) {