Update to Minecraft 1.12-pre5

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2017-05-19 21:00:13 +10:00
parent 5284eb89a3
commit 530fe41851
47 changed files with 222 additions and 283 deletions

View File

@@ -98,7 +98,7 @@
+
thread.setDaemon(true);
thread.start();
DedicatedServer.LOGGER.info("Starting minecraft server version 1.12-pre2");
DedicatedServer.LOGGER.info("Starting minecraft server version 1.12-pre5");
@@ -79,7 +126,7 @@
}
@@ -172,14 +172,14 @@
while (!this.serverCommandQueue.isEmpty()) {
ServerCommand servercommand = (ServerCommand) this.serverCommandQueue.remove(0);
- this.getCommandHandler().b(servercommand.source, servercommand.command);
- this.getCommandHandler().a(servercommand.source, servercommand.command);
+ // CraftBukkit start - ServerCommand for preprocessing
+ ServerCommandEvent event = new ServerCommandEvent(console, servercommand.command);
+ server.getPluginManager().callEvent(event);
+ if (event.isCancelled()) continue;
+ servercommand = new ServerCommand(event.getCommand(), servercommand.source);
+
+ // this.getCommandHandler().b(servercommand.source, servercommand.command); // Called in dispatchServerCommand
+ // this.getCommandHandler().a(servercommand.source, servercommand.command); // Called in dispatchServerCommand
+ server.dispatchServerCommand(console, servercommand);
+ // CraftBukkit end
}
@@ -215,7 +215,7 @@
- public String executeRemoteCommand(String s) {
- this.remoteControlCommandListener.clearMessages();
- this.b.b(this.remoteControlCommandListener, s);
- this.b.a(this.remoteControlCommandListener, s);
- return this.remoteControlCommandListener.getMessages();
+ return result.toString();
+ // CraftBukkit end