diff options
author | Thinkofdeath <thinkofdeath@spigotmc.org> | 2014-12-11 20:05:48 +0000 |
---|---|---|
committer | Thinkofdeath <thinkofdeath@spigotmc.org> | 2014-12-11 20:05:48 +0000 |
commit | b13fd35165a71762111e239c1b3a7501dc457c86 (patch) | |
tree | c0676349b93d87ba1d65266f7bd184cf23bd7e2a /nms-patches/PlayerSelector.patch | |
parent | 84699b36a81800a052ed1fc7433c55dcedfd02ca (diff) | |
download | craftbukkit-b13fd35165a71762111e239c1b3a7501dc457c86.tar craftbukkit-b13fd35165a71762111e239c1b3a7501dc457c86.tar.gz craftbukkit-b13fd35165a71762111e239c1b3a7501dc457c86.tar.lz craftbukkit-b13fd35165a71762111e239c1b3a7501dc457c86.tar.xz craftbukkit-b13fd35165a71762111e239c1b3a7501dc457c86.zip |
Re-enable selectors for players and the console using vanilla commands
Diffstat (limited to 'nms-patches/PlayerSelector.patch')
-rw-r--r-- | nms-patches/PlayerSelector.patch | 18 |
1 files changed, 3 insertions, 15 deletions
diff --git a/nms-patches/PlayerSelector.patch b/nms-patches/PlayerSelector.patch index a31e8db6..c0b028ba 100644 --- a/nms-patches/PlayerSelector.patch +++ b/nms-patches/PlayerSelector.patch @@ -1,18 +1,6 @@ ---- ../work/decompile-8eb82bde//net/minecraft/server/PlayerSelector.java 2014-12-02 20:23:52.649621319 +0000 -+++ src/main/java/net/minecraft/server/PlayerSelector.java 2014-12-02 20:22:46.409622789 +0000 -@@ -52,6 +52,11 @@ - } - - public static List getPlayers(ICommandListener icommandlistener, String s, Class oclass) { -+ // CraftBukkit start - disable playerselections for ICommandListeners other than command blocks -+ if (!(icommandlistener instanceof CommandBlockListenerAbstract)) { -+ return com.google.common.collect.ImmutableList.of(); -+ } -+ // CraftBukkit end - Matcher matcher = PlayerSelector.a.matcher(s); - - if (matcher.matches() && icommandlistener.a(1, "@")) { -@@ -97,7 +102,7 @@ +--- ../work/decompile-8eb82bde/net/minecraft/server/PlayerSelector.java 2014-12-11 20:04:51.273619960 +0000 ++++ src/main/java/net/minecraft/server/PlayerSelector.java 2014-12-11 20:03:19.893620952 +0000 +@@ -97,7 +97,7 @@ if (h(map)) { arraylist.add(icommandlistener.getWorld()); } else { |