diff --git a/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java b/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java index 0b4fc155a0..7d382e014c 100644 --- a/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java +++ b/Mage.Server.Plugins/Mage.Player.Human/src/mage/player/human/HumanPlayer.java @@ -197,12 +197,14 @@ public class HumanPlayer extends PlayerImpl { } else { replacementEffectChoice.setChoiceByKey(response.getString()); } - int index = 0; - for (String key : rEffects.keySet()) { - if (replacementEffectChoice.getChoiceKey().equals(key)) { - return index; + if (replacementEffectChoice.getChoiceKey() != null) { + int index = 0; + for (String key : rEffects.keySet()) { + if (replacementEffectChoice.getChoiceKey().equals(key)) { + return index; + } + index++; } - index++; } } }