mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-19 01:17:42 +01:00
Updated Upstream (Paper)
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@bf5852a Fix NPE for PlayerPostRespawnEvent#getRespawnedLocation (#11268) PaperMC/Paper@fb53074 Apply optimise collision checking in move packet handling patch PaperMC/Paper@81bfda8 [ci skip] Specify rebase location in CONTRIBUTING (#11255) PaperMC/Paper@9571983 Fix scanForLegacyEnderDragon world config (#11262) PaperMC/Paper@ec55c11 Fix indestructable light blocks (#11275) PaperMC/Paper@1b8ab11 Add Configuration for vertical Despawn Ranges (#10440) PaperMC/Paper@534ab86 [ci-skip] Revert "Add Configuration for vertical Despawn Ranges (#10440)" (#11278) PaperMC/Paper@e619744 Allow skipping of world symlink validation (#11250) PaperMC/Paper@78216fe Re-implement portalCreateRadius world config (#11267) PaperMC/Paper@4829fbf Handle custom registry elements properly (#11230)
This commit is contained in:
@@ -5,10 +5,10 @@ Subject: [PATCH] PlayerBookTooLargeEvent
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
index f71219cc6805c214a130643144c02332d0df5750..e327b9400bf29b6712e6d559f174cd31238db515 100644
|
||||
index 1121011d188db81be723e12fa734c3659d993176..1662892485ec26e191dd21c14b8e8aae87afac41 100644
|
||||
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
||||
@@ -1153,6 +1153,10 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
|
||||
@@ -1187,6 +1187,10 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
|
||||
int maxBookPageSize = io.papermc.paper.configuration.GlobalConfiguration.get().itemValidation.bookSize.pageMax;
|
||||
double multiplier = Math.clamp(io.papermc.paper.configuration.GlobalConfiguration.get().itemValidation.bookSize.totalMultiplier, 0.3D, 1D);
|
||||
long byteAllowed = maxBookPageSize;
|
||||
@@ -19,7 +19,7 @@ index f71219cc6805c214a130643144c02332d0df5750..e327b9400bf29b6712e6d559f174cd31
|
||||
for (String testString : pageList) {
|
||||
int byteLength = testString.getBytes(java.nio.charset.StandardCharsets.UTF_8).length;
|
||||
byteTotal += byteLength;
|
||||
@@ -1174,7 +1178,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
|
||||
@@ -1208,7 +1212,8 @@ public class ServerGamePacketListenerImpl extends ServerCommonPacketListenerImpl
|
||||
}
|
||||
|
||||
if (byteTotal > byteAllowed) {
|
||||
|
||||
Reference in New Issue
Block a user