This commit is contained in:
Jeff Wadsworth 2022-03-31 14:43:18 -05:00
parent 6ca93d1936
commit cf931cb0b1

View file

@ -1,4 +1,3 @@
package mage.cards.l; package mage.cards.l;
import java.util.ArrayList; import java.util.ArrayList;
@ -17,6 +16,7 @@ import mage.constants.Outcome;
import mage.constants.SuperType; import mage.constants.SuperType;
import mage.filter.FilterPermanent; import mage.filter.FilterPermanent;
import mage.filter.StaticFilters; import mage.filter.StaticFilters;
import mage.filter.predicate.permanent.ControllerIdPredicate;
import mage.game.Game; import mage.game.Game;
import mage.game.permanent.Permanent; import mage.game.permanent.Permanent;
import mage.players.Player; import mage.players.Player;
@ -82,7 +82,9 @@ class LilianaOfTheVeilEffect extends OneShotEffect {
Player targetPlayer = game.getPlayer(source.getFirstTarget()); Player targetPlayer = game.getPlayer(source.getFirstTarget());
if (player != null && targetPlayer != null) { if (player != null && targetPlayer != null) {
int count = game.getBattlefield().countAll(new FilterPermanent(), targetPlayer.getId(), game); int count = game.getBattlefield().countAll(new FilterPermanent(), targetPlayer.getId(), game);
TargetPermanent target = new TargetPermanent(0, count, new FilterPermanent("permanents to put in the first pile"), true); FilterPermanent filter = new FilterPermanent("permanents to put in the first pile");
filter.add(new ControllerIdPredicate(targetPlayer.getId()));
TargetPermanent target = new TargetPermanent(0, count, filter, true);
List<Permanent> pile1 = new ArrayList<>(); List<Permanent> pile1 = new ArrayList<>();
target.setRequired(false); target.setRequired(false);
if (player.choose(Outcome.Neutral, target, source, game)) { if (player.choose(Outcome.Neutral, target, source, game)) {