2021-09-11 17:27:48 +00:00
|
|
|
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
2022-08-01 14:01:20 +00:00
|
|
|
From: Nassim Jahnke <nassim@njahnke.dev>
|
2021-09-11 17:27:48 +00:00
|
|
|
Date: Sat, 11 Sep 2021 11:56:51 +0200
|
|
|
|
Subject: [PATCH] Dont send unnecessary sign update
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
2022-11-05 18:50:16 +00:00
|
|
|
index 399372cdb9d4ed2fc7bbe7d52742be7271e6744f..c91768eb4f238eb59a3e451dc8c3d299f9712b30 100644
|
2021-09-11 17:27:48 +00:00
|
|
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
|
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
2022-11-05 18:50:16 +00:00
|
|
|
@@ -3342,6 +3342,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
2021-09-11 17:27:48 +00:00
|
|
|
|
|
|
|
if (!tileentitysign.isEditable() || !this.player.getUUID().equals(tileentitysign.getPlayerWhoMayEdit())) {
|
|
|
|
ServerGamePacketListenerImpl.LOGGER.warn("Player {} just tried to change non-editable sign", this.player.getName().getString());
|
|
|
|
+ if (this.player.distanceToSqr(blockposition.getX(), blockposition.getY(), blockposition.getZ()) < 32 * 32) // Paper
|
|
|
|
this.send(tileentity.getUpdatePacket()); // CraftBukkit
|
|
|
|
return;
|
|
|
|
}
|