From 9d0650ed601df789c129eb06160627d117922941 Mon Sep 17 00:00:00 2001 From: pop4959 Date: Sat, 2 Jul 2022 02:19:53 -0700 Subject: [PATCH] Don't print component in resource pack rejection message (#8084) --- ...onent-in-resource-pack-rejection-mes.patch | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 patches/server/0919-Don-t-print-component-in-resource-pack-rejection-mes.patch diff --git a/patches/server/0919-Don-t-print-component-in-resource-pack-rejection-mes.patch b/patches/server/0919-Don-t-print-component-in-resource-pack-rejection-mes.patch new file mode 100644 index 000000000..0441fd544 --- /dev/null +++ b/patches/server/0919-Don-t-print-component-in-resource-pack-rejection-mes.patch @@ -0,0 +1,19 @@ +From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 +From: pop4959 +Date: Fri, 1 Jul 2022 22:00:06 -0700 +Subject: [PATCH] Don't print component in resource pack rejection message + + +diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +index 630a762b71861bfe21c47a11d4fe05e1a3b7d339..3486b3eed20b25525569154cb1457a9270a943f9 100644 +--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java ++++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java +@@ -1979,7 +1979,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Ser + public void handleResourcePackResponse(ServerboundResourcePackPacket packet) { + PacketUtils.ensureRunningOnSameThread(packet, this, this.player.getLevel()); + if (packet.getAction() == ServerboundResourcePackPacket.Action.DECLINED && this.server.isResourcePackRequired()) { +- ServerGamePacketListenerImpl.LOGGER.info("Disconnecting {} due to resource pack rejection", this.player.getName()); ++ ServerGamePacketListenerImpl.LOGGER.info("Disconnecting {} due to resource pack rejection", this.player.getGameProfile().getName()); // Paper - Don't print component in resource pack rejection message + this.disconnect(Component.translatable("multiplayer.requiredTexturePrompt.disconnect"), org.bukkit.event.player.PlayerKickEvent.Cause.RESOURCE_PACK_REJECTION); // Paper - add cause + } + // Paper start