Fixed changes made to PlayerCommandPreprocess events having no effect. Fixes BUKKIT-376

This commit is contained in:
EvilSeph 2012-02-25 16:53:54 -05:00
parent d6c6b18ba9
commit 5901a74565

View File

@ -781,7 +781,7 @@ public class NetServerHandler extends NetHandler implements ICommandListener {
} }
try { try {
if (this.server.dispatchCommand(player, s.substring(1))) { if (this.server.dispatchCommand(player, event.getMessage().substring(1))) {
return; return;
} }
} catch (CommandException ex) { } catch (CommandException ex) {
@ -791,7 +791,7 @@ public class NetServerHandler extends NetHandler implements ICommandListener {
} }
// CraftBukkit end // CraftBukkit end
/* CraftBukkit start - No longer neaded as we have already handled it in server.dispatchCommand above. /* // CraftBukkit start - No longer needed as we have already handled it in server.dispatchCommand above.
if (s.toLowerCase().startsWith("/me ")) { if (s.toLowerCase().startsWith("/me ")) {
s = "* " + this.player.name + " " + s.substring(s.indexOf(" ")).trim(); s = "* " + this.player.name + " " + s.substring(s.indexOf(" ")).trim();
logger.info(s); logger.info(s);