disabled ice forming

This commit is contained in:
Cheese 2015-07-02 10:09:39 +10:00
parent 607a94f985
commit 1e26ebe0bd
2 changed files with 16 additions and 2 deletions

View File

@ -24,6 +24,7 @@ import org.bukkit.event.Listener;
import org.bukkit.event.block.Action; import org.bukkit.event.block.Action;
import org.bukkit.event.block.BlockBurnEvent; import org.bukkit.event.block.BlockBurnEvent;
import org.bukkit.event.block.BlockFadeEvent; import org.bukkit.event.block.BlockFadeEvent;
import org.bukkit.event.block.BlockFormEvent;
import org.bukkit.event.block.BlockSpreadEvent; import org.bukkit.event.block.BlockSpreadEvent;
import org.bukkit.event.block.LeavesDecayEvent; import org.bukkit.event.block.LeavesDecayEvent;
import org.bukkit.event.entity.EntitySpawnEvent; import org.bukkit.event.entity.EntitySpawnEvent;
@ -277,6 +278,12 @@ public class MapParser extends JavaPlugin implements Listener
event.setCancelled(true); event.setCancelled(true);
} }
@EventHandler
public void DisableIceForm(BlockFormEvent event)
{
event.setCancelled(true);
}
@EventHandler @EventHandler
public void Updates(PlayerMoveEvent event) public void Updates(PlayerMoveEvent event)
{ {

View File

@ -40,6 +40,7 @@ import org.bukkit.inventory.ItemStack;
import org.bukkit.metadata.FixedMetadataValue; import org.bukkit.metadata.FixedMetadataValue;
import org.bukkit.util.Vector; import org.bukkit.util.Vector;
import mineplex.core.common.Rank;
import mineplex.core.common.util.C; import mineplex.core.common.util.C;
import mineplex.core.common.util.F; import mineplex.core.common.util.F;
import mineplex.core.common.util.MapUtil; import mineplex.core.common.util.MapUtil;
@ -1796,10 +1797,16 @@ public class Bridge extends TeamGame implements OreObsfucation
@EventHandler @EventHandler
public void debug(PlayerCommandPreprocessEvent event) public void debug(PlayerCommandPreprocessEvent event)
{ {
if (event.getPlayer().isOp() && event.getMessage().contains("/oretoggle")) if (Manager.GetClients().hasRank(event.getPlayer(), Rank.ADMIN) && event.getMessage().contains("/oretoggle"))
_ore.ToggleVisibility(); _ore.ToggleVisibility();
if (event.getPlayer().isOp() && event.getMessage().contains("/bridge")) if (Manager.GetClients().hasRank(event.getPlayer(), Rank.ADMIN) && event.getMessage().contains("/bridge"))
_bridgeTime = 30000; _bridgeTime = 30000;
} }
@EventHandler
public void disableIceForm(BlockFormEvent event)
{
event.setCancelled(true);
}
} }