Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- @EventHandler
- public void onMovePlayer(PlayerMoveEvent e){
- Player p = e.getPlayer();
- if(p.getLocation().getBlock().getRelative(0, -1, 0).getType() == Material.STAINED_CLAY){
- p.getLocation().getBlock().getRelative(0, -1, 0).setType(Material.AIR);
- }
- if(p.getLocation().getBlock().getType() == Material.WATER || p.getLocation().getBlock().getType() == Material.STATIONARY_WATER){
- Bukkit.runTaskLater(Plugin, new Runnable(){
- public void run(){
- p.setGameMode(GameMode.SPECTATOR);
- }
- },20);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment