diff --git a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java index b39c25164..72c4af1cd 100644 --- a/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java +++ b/Plugins/Nautilus.Game.Arcade/src/nautilus/game/arcade/game/games/survivalgames/SurvivalGames.java @@ -37,14 +37,14 @@ import org.bukkit.event.entity.ItemSpawnEvent; import org.bukkit.event.entity.EntityDamageEvent.DamageCause; import org.bukkit.event.entity.ProjectileHitEvent; import org.bukkit.event.hanging.HangingBreakEvent; +import org.bukkit.event.inventory.InventoryOpenEvent; import org.bukkit.event.inventory.PrepareItemCraftEvent; -import org.bukkit.event.player.PlayerChangedWorldEvent; import org.bukkit.event.player.PlayerCommandPreprocessEvent; import org.bukkit.event.player.PlayerInteractEvent; -import org.bukkit.event.player.PlayerJoinEvent; import org.bukkit.event.player.PlayerMoveEvent; import org.bukkit.event.player.PlayerQuitEvent; import org.bukkit.event.vehicle.VehicleCreateEvent; +import org.bukkit.inventory.BeaconInventory; import org.bukkit.inventory.FurnaceInventory; import org.bukkit.inventory.InventoryHolder; import org.bukkit.inventory.ItemStack; @@ -94,8 +94,6 @@ import nautilus.game.arcade.stats.SimultaneousSkeletonStatTracker; import nautilus.game.arcade.stats.WinWithoutWearingArmorStatTracker; import net.minecraft.server.v1_8_R3.EntityLargeFireball; import net.minecraft.server.v1_8_R3.PacketPlayOutScoreboardTeam; -import net.minecraft.server.v1_8_R3.PacketPlayOutWorldBorder; -import net.minecraft.server.v1_8_R3.PacketPlayOutWorldBorder.EnumWorldBorderAction; import net.minecraft.server.v1_8_R3.ScoreboardTeam; import net.minecraft.server.v1_8_R3.WorldServer; @@ -2018,6 +2016,15 @@ public abstract class SurvivalGames extends Game } } } + + @EventHandler + public void onInventoryOpen(InventoryOpenEvent event) + { + if(event.getInventory() instanceof BeaconInventory) + { + event.setCancelled(true); + } + } public int getSecondsSinceStart() {