Paper/Spigot-Server-Patches/0461-Broadcast-join-message-to-console.patch

24 Zeilen
1.2 KiB
Diff

From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
2020-04-17 01:18:51 +02:00
From: AvrooVulcan <avrovulcan.programming@gmail.com>
Date: Fri, 17 Apr 2020 00:15:23 +0100
Subject: [PATCH] Broadcast join message to console
diff --git a/src/main/java/net/minecraft/server/PlayerList.java b/src/main/java/net/minecraft/server/PlayerList.java
index db049d529c4ed9157a1136695e5cd14429fd442f..3e63eeca4f22fa4e607adf0e5845df1498ffcef5 100644
2020-04-17 01:18:51 +02:00
--- a/src/main/java/net/minecraft/server/PlayerList.java
+++ b/src/main/java/net/minecraft/server/PlayerList.java
@@ -211,9 +211,9 @@ public abstract class PlayerList {
2020-04-17 01:18:51 +02:00
joinMessage = playerJoinEvent.getJoinMessage();
if (joinMessage != null && joinMessage.length() > 0) {
- for (IChatBaseComponent line : org.bukkit.craftbukkit.util.CraftChatMessage.fromString(joinMessage)) {
- server.getPlayerList().sendAll(new PacketPlayOutChat(line, ChatMessageType.SYSTEM, SystemUtils.b));
2020-04-17 01:18:51 +02:00
- }
+ // Paper start - Removed sendAll for loop and broadcasted to console also
+ server.getPlayerList().sendMessage(CraftChatMessage.fromString(joinMessage));
+ // Paper end
}
// CraftBukkit end