diff --git a/src/engine/net/client/handlers/AttackCmdMsgHandler.java b/src/engine/net/client/handlers/AttackCmdMsgHandler.java index c4c4952a..3c137631 100644 --- a/src/engine/net/client/handlers/AttackCmdMsgHandler.java +++ b/src/engine/net/client/handlers/AttackCmdMsgHandler.java @@ -63,6 +63,10 @@ public class AttackCmdMsgHandler extends AbstractClientMsgHandler { return true; //cannot attack other things } + if(target == null) { + playerCharacter.setCombatTarget(target); + return true; // cannot attack a null target + } //set sources target playerCharacter.setCombatTarget(target);