summaryrefslogtreecommitdiffstats
path: root/nms-patches/PlayerConnection.patch
diff options
context:
space:
mode:
authorThinkofdeath <thinkofdeath@spigotmc.org>2014-12-15 11:07:32 +0100
committerThinkofdeath <thinkofdeath@spigotmc.org>2014-12-15 11:07:32 +0100
commitf6bfbb9851366ff22035cb3e8b5690bed449d739 (patch)
treebf7b7a32a36f9cb7c43c447d5919b1bbb48ba338 /nms-patches/PlayerConnection.patch
parent07c2162118ad34d16e85679b293b702f87aa6934 (diff)
parentb9c3e3e8f0df87a9eeb41e5a56872892ad75c3a2 (diff)
downloadcraftbukkit-f6bfbb9851366ff22035cb3e8b5690bed449d739.tar
craftbukkit-f6bfbb9851366ff22035cb3e8b5690bed449d739.tar.gz
craftbukkit-f6bfbb9851366ff22035cb3e8b5690bed449d739.tar.lz
craftbukkit-f6bfbb9851366ff22035cb3e8b5690bed449d739.tar.xz
craftbukkit-f6bfbb9851366ff22035cb3e8b5690bed449d739.zip
Merge pull request #58 in SPIGOT/craftbukkit from ~DMCK2B/craftbukkit:bugfix/fixNoOPCheckOnCommandBlocks to master
* commit 'b9c3e3e8f0df87a9eeb41e5a56872892ad75c3a2': Swap out always-OP vanilla system for Bukkit OP checking in command blocks
Diffstat (limited to 'nms-patches/PlayerConnection.patch')
-rw-r--r--nms-patches/PlayerConnection.patch12
1 files changed, 9 insertions, 3 deletions
diff --git a/nms-patches/PlayerConnection.patch b/nms-patches/PlayerConnection.patch
index 841ff572..19d548ef 100644
--- a/nms-patches/PlayerConnection.patch
+++ b/nms-patches/PlayerConnection.patch
@@ -1,5 +1,5 @@
---- ../work/decompile-8eb82bde//net/minecraft/server/PlayerConnection.java 2014-12-09 12:20:29.531617451 +0000
-+++ src/main/java/net/minecraft/server/PlayerConnection.java 2014-12-09 12:20:21.823617622 +0000
+--- ../work/decompile-8eb82bde//net/minecraft/server/PlayerConnection.java Mon Dec 15 10:02:18 2014
++++ src/main/java/net/minecraft/server/PlayerConnection.java Mon Dec 15 10:02:18 2014
@@ -16,6 +16,48 @@
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
@@ -1420,7 +1420,7 @@
return;
} finally {
packetdataserializer.release();
-@@ -946,6 +1896,7 @@
+@@ -946,11 +1896,12 @@
}
} catch (Exception exception2) {
PlayerConnection.c.error("Couldn\'t select trade", exception2);
@@ -1428,6 +1428,12 @@
}
} else if ("MC|AdvCdm".equals(packetplayincustompayload.a())) {
if (!this.minecraftServer.getEnableCommandBlock()) {
+ this.player.sendMessage(new ChatMessage("advMode.notEnabled", new Object[0]));
+- } else if (this.player.a(2, "") && this.player.abilities.canInstantlyBuild) {
++ } else if (this.player.getBukkitEntity().isOp() && this.player.abilities.canInstantlyBuild) { // CraftBukkit - Change to Bukkit OP versus Vanilla OP
+ packetdataserializer = packetplayincustompayload.b();
+
+ try {
@@ -986,6 +1937,7 @@
}
} catch (Exception exception3) {