* Master of Diversion - Fixed NPE because of using wrong id (Fixes #284).

This commit is contained in:
LevelX2 2013-07-16 08:27:48 +02:00
parent 6a23e957e0
commit 489a727f5c

View file

@ -73,7 +73,7 @@ public class MasterOfDiversion extends CardImpl<MasterOfDiversion> {
if (ability.getAbilityType().equals(AbilityType.TRIGGERED)) {
ability.getTargets().clear();
FilterCreaturePermanent filter = new FilterCreaturePermanent("creature defending player controls");
UUID defenderId = game.getCombat().getDefendingPlayer(ability.getControllerId());
UUID defenderId = game.getCombat().getDefendingPlayer(ability.getSourceId());
filter.add(new ControllerIdPredicate(defenderId));
TargetCreaturePermanent target = new TargetCreaturePermanent(filter);
target.setRequired(true);