Add 'use' flag to cakes

This commit is contained in:
unknown 2012-08-10 22:33:55 +02:00
parent 684214ff6a
commit e60b20b37b

View File

@ -667,7 +667,8 @@ private void handleBlockRightClick(PlayerInteractEvent event) {
if (type == BlockID.CAKE_BLOCK) {
if (!plugin.getGlobalRegionManager().hasBypass(player, world)
&& !set.canBuild(localPlayer)) {
&& !set.canBuild(localPlayer)
&& !set.allows(DefaultFlag.USE, localPlayer)) {
player.sendMessage(ChatColor.DARK_RED + "You're not invited to this tea party!");
event.setUseInteractedBlock(Result.DENY);
event.setCancelled(true);