diff options
author | KHobbits <rob@khobbits.co.uk> | 2012-09-19 21:07:50 +0100 |
---|---|---|
committer | KHobbits <rob@khobbits.co.uk> | 2012-09-19 21:07:50 +0100 |
commit | 17a7548ef8cbc0a8b095ade930b420a68a474b5f (patch) | |
tree | 960faaa47e6b2ea7eb0cf8f73d327917c5acdfd9 /EssentialsAntiBuild/src/com/earth2me | |
parent | 019ecfead2b09512cad03121cbb10dfa3bb17d26 (diff) | |
download | Essentials-17a7548ef8cbc0a8b095ade930b420a68a474b5f.tar Essentials-17a7548ef8cbc0a8b095ade930b420a68a474b5f.tar.gz Essentials-17a7548ef8cbc0a8b095ade930b420a68a474b5f.tar.lz Essentials-17a7548ef8cbc0a8b095ade930b420a68a474b5f.tar.xz Essentials-17a7548ef8cbc0a8b095ade930b420a68a474b5f.zip |
ignoreCancelled events.
Diffstat (limited to 'EssentialsAntiBuild/src/com/earth2me')
-rw-r--r-- | EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java b/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java index 1fc57525d..f061beed4 100644 --- a/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java +++ b/EssentialsAntiBuild/src/com/earth2me/essentials/antibuild/EssentialsAntiBuildListener.java @@ -235,7 +235,7 @@ public class EssentialsAntiBuildListener implements Listener } } - @EventHandler(priority = EventPriority.LOW) + @EventHandler(priority = EventPriority.LOW, ignoreCancelled = true) public void onCraftItemEvent(final CraftItemEvent event) { HumanEntity entity = event.getWhoClicked(); @@ -256,14 +256,14 @@ public class EssentialsAntiBuildListener implements Listener } } - @EventHandler(priority = EventPriority.LOW) + @EventHandler(priority = EventPriority.LOW, ignoreCancelled = true) public void onPlayerPickupItem(PlayerPickupItemEvent event) { final User user = ess.getUser(event.getPlayer()); final ItemStack item = event.getItem().getItemStack(); - if (!metaPermCheck(user, "craft", item.getTypeId(), item.getData().getData())) + if (!metaPermCheck(user, "pickup", item.getTypeId(), item.getData().getData())) { event.setCancelled(true); event.getItem().setPickupDelay(50); @@ -271,7 +271,7 @@ public class EssentialsAntiBuildListener implements Listener } - @EventHandler(priority = EventPriority.LOW) + @EventHandler(priority = EventPriority.LOW, ignoreCancelled = true) public void onPlayerDropItem(PlayerDropItemEvent event) { |