Hotfix inventory click.

This commit is contained in:
asofold 2012-10-30 20:30:44 +01:00
parent c146b8ca5d
commit cb03c04420

View File

@ -150,8 +150,14 @@ public class InventoryListener implements Listener {
final Player player = (Player) event.getWhoClicked();
// Illegal enchantments hotfixes
try{
if (Items.checkIllegalEnchantments(player, event.getCurrentItem())) event.setCancelled(true);
}
catch(final ArrayIndexOutOfBoundsException e){} // Hotfix
try{
if (Items.checkIllegalEnchantments(player, event.getCursor())) event.setCancelled(true);
}
catch(final ArrayIndexOutOfBoundsException e){} // Hotfix
// Fast inventory manipulation check.
if (fastClick.isEnabled(player)){