3
0
Mirror von https://github.com/GeyserMC/Geyser.git synchronisiert 2024-11-19 14:30:17 +01:00

Cap render distance at 96 (#3530)

Signed-off-by: Joshua Castle <26531652+Kas-tle@users.noreply.github.com>
Co-authored-by: onebeastchris <github@onechris.mozmail.com>
Dieser Commit ist enthalten in:
Kas-tle 2024-03-08 19:51:32 -08:00 committet von GitHub
Ursprung 92ce0fc6c7
Commit 527eab0b58
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: B5690EEEBB952194

Datei anzeigen

@ -1464,6 +1464,11 @@ public class GeyserSession implements GeyserConnection, GeyserCommandSource {
}
public void setServerRenderDistance(int renderDistance) {
// +1 is for Fabric and Spigot
// Without the client misses loading some chunks per https://github.com/GeyserMC/Geyser/issues/3490
// Fog still appears essentially normally
// Ensure render distance is not above 96 as sending a larger value at any point crashes mobile clients and 96 is the max of any bedrock platform
renderDistance = Math.min(renderDistance, 96);
this.serverRenderDistance = renderDistance;
ChunkRadiusUpdatedPacket chunkRadiusUpdatedPacket = new ChunkRadiusUpdatedPacket();