From 01cc741e3361decc9b5c8e16dbf4660bc2f2eda8 Mon Sep 17 00:00:00 2001 From: alisolarflare Date: Thu, 22 Dec 2016 05:16:04 -0500 Subject: [PATCH] Added Debug Messages --- .../components/hotfix/hotfixes/CreativeKillLoop.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/buttondevteam/alipresents/components/hotfix/hotfixes/CreativeKillLoop.java b/src/buttondevteam/alipresents/components/hotfix/hotfixes/CreativeKillLoop.java index cd7e045..b83c626 100644 --- a/src/buttondevteam/alipresents/components/hotfix/hotfixes/CreativeKillLoop.java +++ b/src/buttondevteam/alipresents/components/hotfix/hotfixes/CreativeKillLoop.java @@ -16,8 +16,13 @@ public class CreativeKillLoop extends BukkitRunnable implements Listener { @Override public void run() { + plugin.getServer().broadcastMessage("CreativeLoop"); for (Player player : plugin.getServer().getOnlinePlayers()){ - if(player.getGameMode() != GameMode.SURVIVAL && player.getWorld().getName() == "World" && player.isOp() == false){ + player.sendMessage("Player: " + player.getName()); + player.sendMessage("World: " + player.getWorld()); + player.sendMessage("Gamemode : " + player.getGameMode().toString()); + player.sendMessage("IsOP: " + player.isOp()); + if(player.getGameMode() != GameMode.SURVIVAL && player.getWorld().getName().equalsIgnoreCase("world") && player.isOp() == false){ player.sendMessage("[Hotfix] Every Gamemode other than survival is disabled in the new world!"); player.setGameMode(GameMode.SURVIVAL); }