summaryrefslogtreecommitdiffstats
path: root/src/main/java/net/minecraft/server
diff options
context:
space:
mode:
authorAnimosity <nullcline@gmail.com>2011-01-05 10:47:57 +0800
committerDinner Bone <dinnerbone@dinnerbone.com>2011-01-05 18:56:59 +0800
commit4792d55a08c9cb05a29a75219bdac996bdbee0e5 (patch)
tree8b677b3e4d272f7191d9f5c5af5e1cfb6e8cd141 /src/main/java/net/minecraft/server
parent8e66e52958886ce82b05603f984a452e7b1459d3 (diff)
downloadcraftbukkit-4792d55a08c9cb05a29a75219bdac996bdbee0e5.tar
craftbukkit-4792d55a08c9cb05a29a75219bdac996bdbee0e5.tar.gz
craftbukkit-4792d55a08c9cb05a29a75219bdac996bdbee0e5.tar.lz
craftbukkit-4792d55a08c9cb05a29a75219bdac996bdbee0e5.tar.xz
craftbukkit-4792d55a08c9cb05a29a75219bdac996bdbee0e5.zip
Actually allow cancellation of player chat events
Diffstat (limited to 'src/main/java/net/minecraft/server')
-rw-r--r--src/main/java/net/minecraft/server/NetServerHandler.java1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/main/java/net/minecraft/server/NetServerHandler.java b/src/main/java/net/minecraft/server/NetServerHandler.java
index 7cfe5ff5..2fd1c49f 100644
--- a/src/main/java/net/minecraft/server/NetServerHandler.java
+++ b/src/main/java/net/minecraft/server/NetServerHandler.java
@@ -419,6 +419,7 @@ implements ICommandListener {
PlayerChatEvent event = new PlayerChatEvent(Type.PLAYER_CHAT, player, s);
server.getPluginManager().callEvent(event);
s = (new StringBuilder()).append("<").append(event.getPlayer().getName()).append("> ").append(event.getMessage()).toString();
+ if (event.isCancelled()) return;
// CraftBukkit stop
a.info(s);