From f653ddb9211f2e8e53ea552370c1b9fe31959774 Mon Sep 17 00:00:00 2001 From: Zzooouhh Date: Thu, 2 Nov 2017 07:05:33 +0100 Subject: [PATCH] Another fix for #4090 --- .../RedirectDamageFromSourceToTargetEffect.java | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Mage/src/main/java/mage/abilities/effects/common/RedirectDamageFromSourceToTargetEffect.java b/Mage/src/main/java/mage/abilities/effects/common/RedirectDamageFromSourceToTargetEffect.java index 9a1e32f7e0..bff0d3ccee 100644 --- a/Mage/src/main/java/mage/abilities/effects/common/RedirectDamageFromSourceToTargetEffect.java +++ b/Mage/src/main/java/mage/abilities/effects/common/RedirectDamageFromSourceToTargetEffect.java @@ -10,6 +10,7 @@ import mage.abilities.effects.RedirectionEffect; import mage.constants.Duration; import mage.game.Game; import mage.game.events.GameEvent; +import mage.game.permanent.Permanent; /** * @@ -33,9 +34,14 @@ public class RedirectDamageFromSourceToTargetEffect extends RedirectionEffect { @Override public boolean applies(GameEvent event, Ability source, Game game) { - if (event.getTargetId().equals(source.getSourceId())) { - this.redirectTarget = source.getTargets().get(0); - return true; + Permanent permanent = game.getBattlefield().getPermanent(source.getSourceId()); + if (permanent != null) { + if (event.getTargetId().equals(source.getSourceId())) { + if (getTargetPointer().getFirst(game, source) != null) { + this.redirectTarget = source.getTargets().get(0); + return true; + } + } } return false; }