Fixed some derpy fire handling.

This commit is contained in:
Wizjany 2011-05-16 16:27:17 -04:00
parent 33e0750959
commit f3ec873ac2

View File

@ -316,7 +316,8 @@ public void onBlockIgnite(BlockIgniteEvent event) {
} }
} }
if (wcfg.highFreqFlags && isFireSpread && set.allows(DefaultFlag.FIRE_SPREAD)) { if (wcfg.highFreqFlags && isFireSpread
&& !set.allows(DefaultFlag.FIRE_SPREAD)) {
event.setCancelled(true); event.setCancelled(true);
return; return;
} }
@ -363,6 +364,19 @@ public void onBlockBurn(BlockBurnEvent event) {
return; 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;
}
}
} }
/** /**