mirror of
https://github.com/TotalFreedomMC/TF-EssentialsX.git
synced 2025-08-05 03:53:41 +00:00
attempt to fix Essentials overriding Skulls (#2356) @kennyrkun
This commit is contained in:
parent
7948e764d4
commit
dd41b10522
1 changed files with 1 additions and 0 deletions
|
@ -728,6 +728,7 @@ public class EssentialsPlayerListener implements Listener {
|
||||||
} else if (clickedInventory != null && clickedInventory.getType() == InventoryType.PLAYER) {
|
} else if (clickedInventory != null && clickedInventory.getType() == InventoryType.PLAYER) {
|
||||||
if (ess.getSettings().isDirectHatAllowed() && event.getClick() == ClickType.LEFT && event.getSlot() == 39
|
if (ess.getSettings().isDirectHatAllowed() && event.getClick() == ClickType.LEFT && event.getSlot() == 39
|
||||||
&& event.getCursor().getType() != Material.AIR && event.getCursor().getType().getMaxDurability() == 0
|
&& event.getCursor().getType() != Material.AIR && event.getCursor().getType().getMaxDurability() == 0
|
||||||
|
&& !MaterialUtil.isSkull(event.getCursor().getType())
|
||||||
&& ess.getUser(event.getWhoClicked()).isAuthorized("essentials.hat")) {
|
&& ess.getUser(event.getWhoClicked()).isAuthorized("essentials.hat")) {
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
final PlayerInventory inv = (PlayerInventory) clickedInventory;
|
final PlayerInventory inv = (PlayerInventory) clickedInventory;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue