diff --git a/Plugins/Mineplex.MapParser/src/mineplex/mapparser/GameType.java b/Plugins/Mineplex.MapParser/src/mineplex/mapparser/GameType.java index 7e627f491..7fe8dd6f8 100644 --- a/Plugins/Mineplex.MapParser/src/mineplex/mapparser/GameType.java +++ b/Plugins/Mineplex.MapParser/src/mineplex/mapparser/GameType.java @@ -30,6 +30,7 @@ public enum GameType Halloween("Halloween Horror"), HideSeek("Block Hunt"), Horse("Horseback"), + Lobbers("Bomb Lobbers"), SurvivalGames("Survival Games"), SurvivalGamesTeams("Survival Games Teams"), Micro("Micro Battle"), diff --git a/Plugins/Mineplex.MapParser/src/mineplex/mapparser/MapParser.java b/Plugins/Mineplex.MapParser/src/mineplex/mapparser/MapParser.java index 8e9b39b59..622e7516c 100644 --- a/Plugins/Mineplex.MapParser/src/mineplex/mapparser/MapParser.java +++ b/Plugins/Mineplex.MapParser/src/mineplex/mapparser/MapParser.java @@ -38,6 +38,7 @@ import org.bukkit.event.player.PlayerMoveEvent; import org.bukkit.event.player.PlayerQuitEvent; import org.bukkit.plugin.Plugin; import org.bukkit.plugin.java.JavaPlugin; +import org.bukkit.util.Vector; import mineplex.core.common.util.C; import mineplex.core.common.util.Callback; @@ -720,6 +721,7 @@ public class MapParser extends JavaPlugin implements Listener return blocks; } + long lastUse = 0; @EventHandler(priority = EventPriority.LOWEST) public void leaptest(PlayerInteractEvent event) { @@ -730,6 +732,18 @@ public class MapParser extends JavaPlugin implements Listener if (event.getPlayer().getItemInHand().getType() != Material.FEATHER) return; - event.getPlayer().setVelocity(event.getPlayer().getLocation().getDirection().multiply(1.2)); + if (System.currentTimeMillis() - lastUse < 800) + { + Bukkit.broadcastMessage("Cooldown"); + return; + } + + + lastUse = System.currentTimeMillis(); + + Vector vel = event.getPlayer().getLocation().getDirection().multiply(1.2); + vel.add(new Vector(0,0.6,0)); + + event.getPlayer().setVelocity(vel); } }