mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-27 01:05:38 +00:00
smartn't @ZeroEpoch1969
Signed-off-by: Robinson Gallego <robinson.leal7@gmail.com>
This commit is contained in:
parent
ca868a290d
commit
561854f2f0
@ -54,11 +54,14 @@ public class InteractBlocker extends FreedomService
|
|||||||
@EventHandler(priority = EventPriority.HIGH)
|
@EventHandler(priority = EventPriority.HIGH)
|
||||||
public void onRightClickBell(PlayerInteractEvent event)
|
public void onRightClickBell(PlayerInteractEvent event)
|
||||||
{
|
{
|
||||||
if (event.getClickedBlock().getType().equals(Material.BELL))
|
if (event.getClickedBlock() != null)
|
||||||
{
|
{
|
||||||
if (!ConfigEntry.ALLOW_BELLS.getBoolean())
|
if (event.getClickedBlock().getType().equals(Material.BELL))
|
||||||
{
|
{
|
||||||
event.setCancelled(true);
|
if (!ConfigEntry.ALLOW_BELLS.getBoolean())
|
||||||
|
{
|
||||||
|
event.setCancelled(true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user