Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-12-26 00:00:41 +01:00
Dieser Commit ist enthalten in:
Ursprung
46bde0c019
Commit
7613bdbafe
@ -28,6 +28,8 @@ package org.geysermc.geyser.network;
|
||||
import io.netty.buffer.Unpooled;
|
||||
import org.cloudburstmc.protocol.bedrock.BedrockDisconnectReasons;
|
||||
import org.cloudburstmc.protocol.bedrock.codec.BedrockCodec;
|
||||
import org.cloudburstmc.protocol.bedrock.codec.compat.BedrockCompat;
|
||||
import org.cloudburstmc.protocol.bedrock.codec.v622.Bedrock_v622;
|
||||
import org.cloudburstmc.protocol.bedrock.data.ExperimentData;
|
||||
import org.cloudburstmc.protocol.bedrock.data.PacketCompressionAlgorithm;
|
||||
import org.cloudburstmc.protocol.bedrock.data.ResourcePackType;
|
||||
@ -108,6 +110,10 @@ public class UpstreamPacketHandler extends LoggingPacketHandler {
|
||||
session.disconnect(disconnectMessage);
|
||||
return false;
|
||||
} else if (protocolVersion < GameProtocol.DEFAULT_BEDROCK_CODEC.getProtocolVersion()) {
|
||||
if (protocolVersion < Bedrock_v622.CODEC.getProtocolVersion()) {
|
||||
// https://github.com/GeyserMC/Geyser/issues/4378
|
||||
session.getUpstream().getSession().setCodec(BedrockCompat.CODEC_LEGACY);
|
||||
}
|
||||
session.disconnect(GeyserLocale.getLocaleStringLog("geyser.network.outdated.client", supportedVersions));
|
||||
return false;
|
||||
} else {
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren