Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-23 14:50:08 +01:00
37 Zeilen
1.8 KiB
Diff
37 Zeilen
1.8 KiB
Diff
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||
|
From: kashike <kashike@vq.lc>
|
||
|
Date: Fri, 9 Jun 2017 07:24:34 -0700
|
||
|
Subject: [PATCH] Add configuration option to prevent player names from being
|
||
|
suggested
|
||
|
|
||
|
|
||
|
diff --git a/src/main/java/com/destroystokyo/paper/PaperConfig.java b/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
||
|
index 4e2f243faa209925dcb7c3ef89df3ed875c5ff78..48319aaf1c525c6fb7bdee5c2f570a0d056d4eae 100644
|
||
|
--- a/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
||
|
+++ b/src/main/java/com/destroystokyo/paper/PaperConfig.java
|
||
|
@@ -268,4 +268,9 @@ public class PaperConfig {
|
||
|
flyingKickPlayerMessage = getString("messages.kick.flying-player", flyingKickPlayerMessage);
|
||
|
flyingKickVehicleMessage = getString("messages.kick.flying-vehicle", flyingKickVehicleMessage);
|
||
|
}
|
||
|
+
|
||
|
+ public static boolean suggestPlayersWhenNullTabCompletions = true;
|
||
|
+ private static void suggestPlayersWhenNull() {
|
||
|
+ suggestPlayersWhenNullTabCompletions = getBoolean("settings.suggest-player-names-when-null-tab-completions", suggestPlayersWhenNullTabCompletions);
|
||
|
+ }
|
||
|
}
|
||
|
diff --git a/src/main/java/org/bukkit/craftbukkit/CraftServer.java b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||
|
index 539577a0378754cbe0942a79140f6d137eb825ed..0ed8e95d464cf17dc0355056775a9a375a4e7a86 100644
|
||
|
--- a/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||
|
+++ b/src/main/java/org/bukkit/craftbukkit/CraftServer.java
|
||
|
@@ -2301,5 +2301,10 @@ public final class CraftServer implements Server {
|
||
|
commandMap.registerServerAliases();
|
||
|
return true;
|
||
|
}
|
||
|
+
|
||
|
+ @Override
|
||
|
+ public boolean suggestPlayerNamesWhenNullTabCompletions() {
|
||
|
+ return com.destroystokyo.paper.PaperConfig.suggestPlayersWhenNullTabCompletions;
|
||
|
+ }
|
||
|
// Paper end
|
||
|
}
|