mirror of
https://github.com/songoda/FabledSkyBlock.git
synced 2024-11-26 04:06:00 +01:00
Fix players being able to illegally interact with a skyblock inventory
This commit is contained in:
parent
fac0997c97
commit
92846d2d75
@ -50,12 +50,12 @@ public class nInventoryUtil {
|
||||
}
|
||||
|
||||
if (inv != null && event.getInventory().equals(inv)) {
|
||||
event.setCancelled(true);
|
||||
|
||||
if (event.getCurrentItem() == null || event.getCurrentItem().getType() == Material.AIR) {
|
||||
return;
|
||||
}
|
||||
|
||||
event.setCancelled(true);
|
||||
|
||||
ClickEvent clickEvent = new ClickEvent(event.getClick(), event.getSlot(),
|
||||
event.getCurrentItem());
|
||||
handler.onClick(clickEvent);
|
||||
|
Loading…
Reference in New Issue
Block a user