diff --git a/mcMMO/com/gmail/nossr50/mcMMO.java b/mcMMO/com/gmail/nossr50/mcMMO.java index aff0ff5e2..5e5f1fba0 100644 --- a/mcMMO/com/gmail/nossr50/mcMMO.java +++ b/mcMMO/com/gmail/nossr50/mcMMO.java @@ -81,7 +81,7 @@ public class mcMMO extends JavaPlugin { pm.registerEvent(Event.Type.PLAYER_QUIT, playerListener, Priority.Normal, this); pm.registerEvent(Event.Type.BLOCK_DAMAGED, blockListener, Priority.Normal, this); pm.registerEvent(Event.Type.PLAYER_CHAT, playerListener, Priority.Monitor, this); - pm.registerEvent(Event.Type.PLAYER_COMMAND_PREPROCESS, playerListener, Priority.Normal, this); + pm.registerEvent(Event.Type.PLAYER_COMMAND_PREPROCESS, playerListener, Priority.High, this); pm.registerEvent(Event.Type.ENTITY_DEATH, entityListener, Priority.Normal, this); pm.registerEvent(Event.Type.BLOCK_FLOW, blockListener, Priority.Normal, this); pm.registerEvent(Event.Type.BLOCK_PLACED, blockListener, Priority.Normal, this); @@ -106,6 +106,20 @@ public class mcMMO extends JavaPlugin { } } } + public boolean isPartyChatToggled(Player player){ + if(mcConfig.getInstance().isPartyToggled(player.getName())){ + return true; + } else { + return false; + } + } + public boolean isAdminChatToggled(Player player){ + if(mcConfig.getInstance().isAdminToggled(player.getName())){ + return true; + } else { + return false; + } + } public Permissions getPermissions() { return permissions; diff --git a/mcMMO/com/gmail/nossr50/mcPlayerListener.java b/mcMMO/com/gmail/nossr50/mcPlayerListener.java index 2a6bc1c8c..b9d48cb7b 100644 --- a/mcMMO/com/gmail/nossr50/mcPlayerListener.java +++ b/mcMMO/com/gmail/nossr50/mcPlayerListener.java @@ -113,7 +113,7 @@ public class mcPlayerListener extends PlayerListener { mcm.getInstance().repairCheck(player, is, block); } } - public void onPlayerCommandPreprocess(PlayerChatEvent event) { + public void onPlayerCommandPreproccesss(PlayerChatEvent event){ Player player = event.getPlayer(); String[] split = event.getMessage().split(" "); String playerName = player.getName(); diff --git a/mcMMO/com/gmail/nossr50/mcm.java b/mcMMO/com/gmail/nossr50/mcm.java index ddd301bac..1b6aa8791 100644 --- a/mcMMO/com/gmail/nossr50/mcm.java +++ b/mcMMO/com/gmail/nossr50/mcm.java @@ -110,7 +110,7 @@ public class mcm { for(Player x : plugin.getServer().getOnlinePlayers()){ if(x != null && damaged != null){ CraftPlayer cp = (CraftPlayer)x; - if(x.getEntityId() != damaged.getEntityId()) + if(cp != null && x != null && damaged != null && x.getEntityId() != damaged.getEntityId()) cp.getHandle().a.b(new Packet38EntityStatus(damaged.getEntityId(), (byte)2)); } } diff --git a/mcMMO/plugin.yml b/mcMMO/plugin.yml index 665357d7d..389df2fb7 100644 --- a/mcMMO/plugin.yml +++ b/mcMMO/plugin.yml @@ -1,3 +1,3 @@ name: mcMMO main: com.gmail.nossr50.mcMMO -version: 0.8.5 \ No newline at end of file +version: 0.8.6 \ No newline at end of file