@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void onBlockBurn(BlockBurnEvent event) { ZoneManager manager = m_plugin.getZoneManager(); if (manager.zoneExists(event.getBlock().getLocation())) { event.setCancelled(true); } }
@EventHandler(ignoreCancelled = true) public void onBlockBurn(BlockBurnEvent event) { Block block = event.getBlock(); if (LotteryManager.isSignRegistered(block) || !checkBlockBroken(block)) { event.setCancelled(true); return; } }
@Override public void onBlockBurn(BlockBurnEvent event) { if (event.isCancelled()) return; /* Call listeners */ List<Listener> ll = event_handlers.get(event.getType()); if (ll != null) { for (Listener l : ll) { ((BlockListener) l).onBlockBurn(event); } } }
@SuppressWarnings("deprecation") @EventHandler(priority = EventPriority.LOW) public void onBlockBurn(BlockBurnEvent event) { Map map = Rixor.getRotation().getSlot().getMap(); BlockState newState = event.getBlock().getState(); newState.setData(new MaterialData(Material.AIR, (byte) 0)); BlockChangeEvent change = new BlockChangeEvent(event, map, null, event.getBlock().getState(), newState); Rixor.callEvent(change); }
/* (non-Javadoc) * @see org.bukkit.event.block.BlockListener#onBlockBurn(org.bukkit.event.block.BlockBurnEvent) */ @EventHandler(priority = EventPriority.LOWEST) public void onBlockBurn(final BlockBurnEvent event) { if (!event.isCancelled() && (event.getBlock() != null) && BlockBurn.handleBlockBurn(event.getBlock())) { event.setCancelled(true); WXLogger.prettyLog( Level.FINE, false, "Cancelled BlockBurnEvent on " + event.getBlock().getWorld().getName()); } }
@EventHandler(priority = EventPriority.HIGH) public void onBlockBurnEvent(BlockBurnEvent event) { if (event.isCancelled()) { return; } Block block = event.getBlock(); Set<Snitch> snitches = snitchManager.findSnitches(block.getWorld(), block.getLocation()); for (Snitch snitch : snitches) { if (snitch.getGroup() != null) { continue; } plugin.getJaLogger().logSnitchBlockBurn(snitch, block); } }
@EventHandler(priority = EventPriority.HIGH) public void onBlockBurn(BlockBurnEvent event) { if (!TotalFreedomMod.allowFireSpread) { event.setCancelled(true); return; } }
@EventHandler(priority = EventPriority.HIGHEST, ignoreCancelled = true) public void onBlockBurn(final BlockBurnEvent event) { final ProtectHolder settings = prot.getSettings(); if (settings.getData().getPrevent().isFirespread()) { event.setCancelled(true); } }
/** * Called when a block is destroyed from burning * * @param event Relevant event details */ @Override public void onBlockBurn(BlockBurnEvent event) { if (event.isCancelled()) { return; } ConfigurationManager cfg = plugin.getGlobalConfiguration(); WorldConfiguration wcfg = cfg.get(event.getBlock().getWorld()); if (wcfg.disableFireSpread) { event.setCancelled(true); return; } if (wcfg.fireSpreadDisableToggle) { event.setCancelled(true); return; } if (wcfg.disableFireSpreadBlocks.size() > 0) { Block block = event.getBlock(); if (wcfg.disableFireSpreadBlocks.contains(block.getTypeId())) { event.setCancelled(true); return; } } if (wcfg.useRegions) { Block block = event.getBlock(); Vector pt = toVector(block); RegionManager mgr = plugin.getGlobalRegionManager().get(block.getWorld()); ApplicableRegionSet set = mgr.getApplicableRegions(pt); if (!set.allows(DefaultFlag.FIRE_SPREAD)) { event.setCancelled(true); return; } } }
@EventHandler public void BlockBurnEvent(BlockBurnEvent event) { if (!arena.getRegion().isInside(event.getBlock().getLocation()) || arena.getEditMode()) return; if (arena.getArena().isInside(event.getBlock().getLocation()) && arena.isRunning()) return; event.setCancelled(true); }
/* * Called when a block is destroyed from burning. */ @EventHandler(priority = EventPriority.HIGH, ignoreCancelled = true) public void onBlockBurn(BlockBurnEvent event) { ConfigurationManager cfg = plugin.getGlobalStateManager(); WorldConfiguration wcfg = cfg.get(event.getBlock().getWorld()); if (cfg.activityHaltToggle) { event.setCancelled(true); return; } if (wcfg.disableFireSpread) { event.setCancelled(true); return; } if (wcfg.fireSpreadDisableToggle) { Block block = event.getBlock(); event.setCancelled(true); checkAndDestroyAround( block.getWorld(), block.getX(), block.getY(), block.getZ(), BlockID.FIRE); return; } if (wcfg.disableFireSpreadBlocks.size() > 0) { Block block = event.getBlock(); if (wcfg.disableFireSpreadBlocks.contains(block.getTypeId())) { event.setCancelled(true); checkAndDestroyAround( block.getWorld(), block.getX(), block.getY(), block.getZ(), BlockID.FIRE); return; } } if (wcfg.isChestProtected(event.getBlock())) { event.setCancelled(true); return; } if (wcfg.useRegions) { Block block = event.getBlock(); int x = block.getX(); int y = block.getY(); int z = block.getZ(); Vector pt = toVector(block); RegionManager mgr = plugin.getGlobalRegionManager().get(block.getWorld()); ApplicableRegionSet set = mgr.getApplicableRegions(pt); if (!set.allows(DefaultFlag.FIRE_SPREAD)) { checkAndDestroyAround(block.getWorld(), x, y, z, BlockID.FIRE); event.setCancelled(true); return; } } }
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true) public void onBlockBurn(BlockBurnEvent event) { addToCheck(event.getBlock(), event.getBlock().getState()); }
@HawkEvent(dataType = DataType.BLOCK_BURN) public void onBlockBurn(BlockBurnEvent event) { DataManager.addEntry(new BlockEntry("Environment", DataType.BLOCK_BURN, event.getBlock())); }
@EventHandler(priority = EventPriority.MONITOR) public void onBlockBurn(BlockBurnEvent event) { if (!event.isCancelled() && isLogging(event.getBlock().getWorld(), Logging.FIRE)) consumer.queueBlockBreak("Fire", event.getBlock().getState()); }
@EventHandler public void onBlockBurn_Appliance(final BlockBurnEvent event) { if (MadeToBreak.appliances.contains(event.getBlock().getTypeId())) { plugin.l.remove(event.getBlock().getLocation()); } }
@Override public void onBlockBurn(BlockBurnEvent event) { manager.burnBlock(event.getBlock()); }