From 8818a12b6e30e349bfe9a7e384dcb9e91eec7514 Mon Sep 17 00:00:00 2001 From: jeffwadsworth Date: Mon, 13 Jul 2020 16:54:08 -0500 Subject: [PATCH] - Fixed #6834 --- .../common/TargetTappedPermanentAsYouCast.java | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/Mage/src/main/java/mage/target/common/TargetTappedPermanentAsYouCast.java b/Mage/src/main/java/mage/target/common/TargetTappedPermanentAsYouCast.java index 50f8d076f8..50e7540323 100644 --- a/Mage/src/main/java/mage/target/common/TargetTappedPermanentAsYouCast.java +++ b/Mage/src/main/java/mage/target/common/TargetTappedPermanentAsYouCast.java @@ -5,14 +5,14 @@ import mage.filter.FilterPermanent; import mage.game.Game; import mage.game.permanent.Permanent; import mage.target.TargetPermanent; + import java.util.Set; import java.util.UUID; import java.util.stream.Collectors; public class TargetTappedPermanentAsYouCast extends TargetPermanent { - public TargetTappedPermanentAsYouCast() { - } + public TargetTappedPermanentAsYouCast() {} public TargetTappedPermanentAsYouCast(FilterPermanent filter) { this.filter = filter; @@ -46,10 +46,17 @@ public class TargetTappedPermanentAsYouCast extends TargetPermanent { public boolean canTarget(UUID controllerId, UUID id, Ability source, Game game) { if (super.canTarget(controllerId, id, source, game)) { Permanent permanent = game.getPermanent(id); - return permanent != null - && permanent.isTapped(); + return permanent != null && permanent.isTapped(); } return false; } + // See ruling: https://www.mtgsalvation.com/forums/magic-fundamentals/magic-rulings/magic-rulings-archives/253345-dream-leash + @Override + public boolean stillLegalTarget(UUID id, Ability source, Game game) { + Permanent permanent = game.getPermanent(id); + return permanent != null + && getFilter().match(permanent, game) + && super.canTarget(id, game); // check everything but leave out the tapped requirement + } }