Dieser Commit ist enthalten in:
Ursprung
c9aab07344
Commit
0c6cfba029
@ -84,6 +84,7 @@ public class FightSystem extends JavaPlugin {
|
|||||||
new PersonalKitCreator();
|
new PersonalKitCreator();
|
||||||
new ArrowStopper();
|
new ArrowStopper();
|
||||||
new ArrowPickup();
|
new ArrowPickup();
|
||||||
|
new BlockFadeListener();
|
||||||
|
|
||||||
new EnterHandler();
|
new EnterHandler();
|
||||||
new TechHider();
|
new TechHider();
|
||||||
|
@ -0,0 +1,24 @@
|
|||||||
|
package de.steamwar.fightsystem.listener;
|
||||||
|
|
||||||
|
import de.steamwar.fightsystem.ArenaMode;
|
||||||
|
import de.steamwar.fightsystem.states.FightState;
|
||||||
|
import de.steamwar.fightsystem.states.StateDependentListener;
|
||||||
|
import org.bukkit.Material;
|
||||||
|
import org.bukkit.event.EventHandler;
|
||||||
|
import org.bukkit.event.Listener;
|
||||||
|
import org.bukkit.event.block.BlockFadeEvent;
|
||||||
|
|
||||||
|
public class BlockFadeListener implements Listener {
|
||||||
|
|
||||||
|
public BlockFadeListener() {
|
||||||
|
new StateDependentListener(ArenaMode.Check, FightState.All, this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@EventHandler
|
||||||
|
public void onBlockFade(BlockFadeEvent event) {
|
||||||
|
if (event.getBlock().getType() == Material.SNOW_BLOCK || event.getBlock().getType() == Material.SNOW || event.getBlock().getType() == Material.ICE) {
|
||||||
|
event.setCancelled(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
In neuem Issue referenzieren
Einen Benutzer sperren