mirror of
https://github.com/amalthea-mc/ShopChest.git
synced 2024-11-22 18:32:24 +00:00
Don't allow WorldGuard access when sneaking
Sneaking doesn't open a shop chest anymore.
This commit is contained in:
parent
3678738048
commit
1e02539aab
@ -52,10 +52,6 @@ public class WorldGuardListener implements Listener {
|
|||||||
if (shop.getVendor().getUniqueId().equals(player.getUniqueId()) && shop.getShopType() != Shop.ShopType.ADMIN) {
|
if (shop.getVendor().getUniqueId().equals(player.getUniqueId()) && shop.getShopType() != Shop.ShopType.ADMIN) {
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!shop.getVendor().getUniqueId().equals(player.getUniqueId()) && player.isSneaking()) {
|
|
||||||
return player.hasPermission(Permissions.OPEN_OTHER);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ClickType.getPlayerClickType(player) != null) {
|
if (ClickType.getPlayerClickType(player) != null) {
|
||||||
|
Loading…
Reference in New Issue
Block a user