mirror of
https://github.com/DieReicheErethons/Brewery.git
synced 2025-01-07 18:58:15 +01:00
Added MC Barrel Permission #222
This commit is contained in:
parent
44310e0e36
commit
e847672b81
@ -92,10 +92,13 @@ permissions:
|
|||||||
children:
|
children:
|
||||||
brewery.openbarrel.small: true
|
brewery.openbarrel.small: true
|
||||||
brewery.openbarrel.big: true
|
brewery.openbarrel.big: true
|
||||||
|
brewery.openbarrel.mc: true
|
||||||
brewery.openbarrel.small:
|
brewery.openbarrel.small:
|
||||||
description: Allow to open small Barrels
|
description: Allow to open small Barrels
|
||||||
brewery.openbarrel.big:
|
brewery.openbarrel.big:
|
||||||
description: Allow to open big Barrels
|
description: Allow to open big Barrels
|
||||||
|
brewery.openbarrel.mc:
|
||||||
|
description: Allow to open Minecraft Barrels
|
||||||
|
|
||||||
# -- Cauldron --
|
# -- Cauldron --
|
||||||
brewery.cauldron.time:
|
brewery.cauldron.time:
|
||||||
|
@ -51,6 +51,13 @@ public class PlayerListener implements Listener {
|
|||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
if (P.use1_14 && type == Material.BARREL) {
|
||||||
|
if (!player.hasPermission("brewery.openbarrel.mc")) {
|
||||||
|
event.setCancelled(true);
|
||||||
|
P.p.msg(player, P.p.languageReader.get("Error_NoPermissions"));
|
||||||
|
}
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
// Do not process Off Hand for Barrel interaction
|
// Do not process Off Hand for Barrel interaction
|
||||||
if (P.use1_9 && event.getHand() != EquipmentSlot.HAND) {
|
if (P.use1_9 && event.getHand() != EquipmentSlot.HAND) {
|
||||||
|
Loading…
Reference in New Issue
Block a user