mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-27 07:20:00 +08:00
21ac7dc988
Upstream has released updates that appear to apply and compile correctly. This update has not been tested by PaperMC and as with ANY update, please do your own testing CraftBukkit Changes: 1e8c432cd #816: Prevent duplicate slash removal for console / block commands
25 lines
1.2 KiB
Diff
25 lines
1.2 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Shane Freeder <theboyetronic@gmail.com>
|
|
Date: Mon, 26 Apr 2021 01:27:08 +0100
|
|
Subject: [PATCH] Send empty commands if tab completion is disabled
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/commands/CommandDispatcher.java b/src/main/java/net/minecraft/commands/CommandDispatcher.java
|
|
index 47dc8450fff5583d70c969c0b92b96a665a02305..7e30ec9a08d919d2ae9218ee0a11f77719129f07 100644
|
|
--- a/src/main/java/net/minecraft/commands/CommandDispatcher.java
|
|
+++ b/src/main/java/net/minecraft/commands/CommandDispatcher.java
|
|
@@ -327,7 +327,12 @@ public class CommandDispatcher {
|
|
}
|
|
|
|
public void a(EntityPlayer entityplayer) {
|
|
- if ( org.spigotmc.SpigotConfig.tabComplete < 0 ) return; // Spigot
|
|
+ // Paper start - Send empty commands if tab completion is disabled
|
|
+ if ( org.spigotmc.SpigotConfig.tabComplete < 0 ) { //return; // Spigot
|
|
+ entityplayer.playerConnection.sendPacket(new PacketPlayOutCommands(new RootCommandNode<>()));
|
|
+ return;
|
|
+ }
|
|
+ // Paper end
|
|
// CraftBukkit start
|
|
// Register Vanilla commands into builtRoot as before
|
|
// Paper start - Async command map building
|