-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Don't print component in resource pack rejection message (#8085)
- Loading branch information
Showing
1 changed file
with
19 additions
and
0 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
patches/server/0913-Don-t-print-component-in-resource-pack-rejection-mes.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 | ||
From: pop4959 <pop4959@gmail.com> | ||
Date: Sat, 2 Jul 2022 11:56:26 -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 0b7923f67d27549f41c0d398d1b99737f0c8a746..3faf67d100e49836eb9b408e88c296e615ca33f8 100644 | ||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java | ||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java | ||
@@ -1960,7 +1960,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(new TranslatableComponent("multiplayer.requiredTexturePrompt.disconnect"), org.bukkit.event.player.PlayerKickEvent.Cause.RESOURCE_PACK_REJECTION); // Paper - add cause | ||
} | ||
// Paper start |