diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/uhc/UHC.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/uhc/UHC.java index 4e6eb86f5..85a62be1d 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/uhc/UHC.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/uhc/UHC.java @@ -43,7 +43,6 @@ import org.bukkit.event.player.PlayerPickupItemEvent; import org.bukkit.event.player.PlayerPortalEvent; import org.bukkit.event.player.PlayerQuitEvent; import org.bukkit.event.player.PlayerTeleportEvent.TeleportCause; -import org.bukkit.event.world.ChunkLoadEvent; import org.bukkit.event.world.ChunkUnloadEvent; import org.bukkit.inventory.CraftingInventory; import org.bukkit.inventory.ItemStack; @@ -83,10 +82,8 @@ import mineplex.serverdata.Utility; import nautilus.game.arcade.ArcadeManager; import nautilus.game.arcade.GameType; import nautilus.game.arcade.events.GameStateChangeEvent; -import nautilus.game.arcade.game.Game; import nautilus.game.arcade.game.GameTeam; import nautilus.game.arcade.game.TeamGame; -import nautilus.game.arcade.game.Game.GameState; import nautilus.game.arcade.kit.Kit; public class UHC extends TeamGame @@ -231,6 +228,23 @@ public class UHC extends TeamGame } } + @EventHandler + public void onDamage(CustomDamageEvent event) + { + if (!IsLive()) + return; + + if (UtilTime.elapsed(getGameLiveTime(), 20000)) + return; + + if (!(event.GetDamageeEntity() instanceof Player)) + return; + + event.SetCancelled("Spawn Invincibility"); + event.GetDamageeEntity().setFireTicks(0); + + } + @EventHandler public void onSecond(UpdateEvent event) {