Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-12-15 11:00:06 +01:00
Fix hex colours not being allowed in MOTD (#3755)
Dieser Commit ist enthalten in:
Ursprung
f32d7fb2d2
Commit
4b5b20d4cd
@ -60,7 +60,7 @@ index 0000000000000000000000000000000000000000..a2a409e635dde08f7c53e67164b967a0
|
||||
+}
|
||||
diff --git a/src/main/java/com/destroystokyo/paper/network/StandardPaperServerListPingEventImpl.java b/src/main/java/com/destroystokyo/paper/network/StandardPaperServerListPingEventImpl.java
|
||||
new file mode 100644
|
||||
index 0000000000000000000000000000000000000000..a85466bc7e0a8aa54b9eff14077fe6c992ae2902
|
||||
index 0000000000000000000000000000000000000000..d2a1e54de64896c74404e79ad721d044a9d52794
|
||||
--- /dev/null
|
||||
+++ b/src/main/java/com/destroystokyo/paper/network/StandardPaperServerListPingEventImpl.java
|
||||
@@ -0,0 +1,112 @@
|
||||
@ -71,11 +71,11 @@ index 0000000000000000000000000000000000000000..a85466bc7e0a8aa54b9eff14077fe6c9
|
||||
+import com.google.common.base.MoreObjects;
|
||||
+import com.google.common.base.Strings;
|
||||
+import com.mojang.authlib.GameProfile;
|
||||
+import net.minecraft.server.ChatComponentText;
|
||||
+import net.minecraft.server.MinecraftServer;
|
||||
+import net.minecraft.server.NetworkManager;
|
||||
+import net.minecraft.server.PacketStatusOutServerInfo;
|
||||
+import net.minecraft.server.ServerPing;
|
||||
+import org.bukkit.craftbukkit.util.CraftChatMessage;
|
||||
+
|
||||
+import java.util.List;
|
||||
+import java.util.UUID;
|
||||
@ -155,7 +155,7 @@ index 0000000000000000000000000000000000000000..a85466bc7e0a8aa54b9eff14077fe6c9
|
||||
+ ServerPing ping = new ServerPing();
|
||||
+
|
||||
+ // Description
|
||||
+ ping.setMOTD(new ChatComponentText(event.getMotd()));
|
||||
+ ping.setMOTD(CraftChatMessage.fromString(event.getMotd())[0]);
|
||||
+
|
||||
+ // Players
|
||||
+ if (!event.shouldHidePlayers()) {
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren