diff --git a/src/main/java/com/gmail/nossr50/skills/unarmed/DisarmEventHandler.java b/src/main/java/com/gmail/nossr50/skills/unarmed/DisarmEventHandler.java index c00c5a102..aa3343e47 100644 --- a/src/main/java/com/gmail/nossr50/skills/unarmed/DisarmEventHandler.java +++ b/src/main/java/com/gmail/nossr50/skills/unarmed/DisarmEventHandler.java @@ -19,8 +19,6 @@ public class DisarmEventHandler { this.manager = manager; this.defender = defender; this.inHand = defender.getItemInHand(); - - calculateSkillModifier(); } protected boolean isHoldingItem() { @@ -31,7 +29,7 @@ public class DisarmEventHandler { this.skillModifier = Misc.skillCheck(manager.getSkillLevel(), Unarmed.DISARM_MAX_BONUS_LEVEL); } - protected void sendAbilityMessage() { + private void sendAbilityMessage() { defender.sendMessage(LocaleLoader.getString("Skills.Disarmed")); } diff --git a/src/main/java/com/gmail/nossr50/skills/unarmed/UnarmedManager.java b/src/main/java/com/gmail/nossr50/skills/unarmed/UnarmedManager.java index 839afdb74..9357d2a6e 100644 --- a/src/main/java/com/gmail/nossr50/skills/unarmed/UnarmedManager.java +++ b/src/main/java/com/gmail/nossr50/skills/unarmed/UnarmedManager.java @@ -19,10 +19,7 @@ public class UnarmedManager extends SkillManager { * @param defender The defending player */ public void disarmCheck(Player defender) { - if (player == null) - return; - - if (!Permissions.disarm(player)) { + if (Misc.isNPC(player) || !Permissions.disarm(player)) { return; }