From 86432eb426ca64980ee230dffe0705c46e77c2b4 Mon Sep 17 00:00:00 2001 From: RoboMWM Date: Sun, 23 Oct 2016 22:38:31 -0700 Subject: [PATCH] Don't handle item pickups when Items_As_Unarmed is set to true If `unarmed.Items_As_Unarmed` is set to true in config, then there's no need to be manually handling item pickups. --- src/main/java/com/gmail/nossr50/listeners/PlayerListener.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/gmail/nossr50/listeners/PlayerListener.java b/src/main/java/com/gmail/nossr50/listeners/PlayerListener.java index 4bb145eb1..8f67f7914 100644 --- a/src/main/java/com/gmail/nossr50/listeners/PlayerListener.java +++ b/src/main/java/com/gmail/nossr50/listeners/PlayerListener.java @@ -332,7 +332,7 @@ public class PlayerListener implements Listener { } } - if ((mcMMOPlayer.isUsingUnarmed() && ItemUtils.isSharable(dropStack)) || mcMMOPlayer.getAbilityMode(AbilityType.BERSERK)) { + if ((mcMMOPlayer.isUsingUnarmed() && ItemUtils.isSharable(dropStack) && !Config.getInstance().getUnarmedItemsAsUnarmed()) || mcMMOPlayer.getAbilityMode(AbilityType.BERSERK)) { boolean pickupSuccess = Unarmed.handleItemPickup(player.getInventory(), drop); boolean cancel = Config.getInstance().getUnarmedItemPickupDisabled() || pickupSuccess; event.setCancelled(cancel);