diff --git a/Mage/src/mage/abilities/effects/ContinuousEffects.java b/Mage/src/mage/abilities/effects/ContinuousEffects.java index 6d56c1bb45f..b145ff4fbee 100644 --- a/Mage/src/mage/abilities/effects/ContinuousEffects.java +++ b/Mage/src/mage/abilities/effects/ContinuousEffects.java @@ -263,19 +263,39 @@ public class ContinuousEffects implements Serializable { } public boolean asThough(UUID objectId, AsThoughEffectType type, Game game) { - for (AsThoughEffect entry: asThoughEffects) { - AsThoughEffect effect = entry; + List asThoughEffectsList = getApplicableAsThoughEffects(game); + + for (AsThoughEffect effect: asThoughEffectsList) { if (effect.getAsThoughEffectType() == type) { - if (effect.getDuration() != Duration.OneUse || !effect.isUsed()) { - if (effect.applies(objectId, asThoughEffects.getAbility(entry.getId()), game)) { - return true; - } + if (effect.applies(objectId, asThoughEffects.getAbility(effect.getId()), game)) { + return true; } } } return false; } + /** + * Filters out asThough effects that are not active. + * + * @param game + * @return + */ + private List getApplicableAsThoughEffects(Game game) { + List asThoughEffectsList = new ArrayList(); + + for (AsThoughEffect effect: asThoughEffects) { + Ability ability = asThoughEffects.getAbility(effect.getId()); + if (!(ability instanceof StaticAbility) || ability.isInUseableZone(game, false)) { + if (effect.getDuration() != Duration.OneUse || !effect.isUsed()) { + asThoughEffectsList.add(effect); + } + } + } + + return asThoughEffectsList; + } + /** * Inspects all {@link Permanent permanent's} {@link Ability abilities} on the battlefield * for {@link CostModificationEffect cost modification effects} and applies them if necessary.