mirror of
https://github.com/GeyserMC/Geyser.git
synced 2025-12-19 14:59:27 +00:00
Update protocol to resolve more client crashes on 1.21.130, re-enable commands, bump version
This commit is contained in:
@@ -119,10 +119,6 @@ public class UpstreamPacketHandler extends LoggingPacketHandler {
|
||||
|
||||
private boolean setCorrectCodec(int protocolVersion) {
|
||||
BedrockCodec packetCodec = GameProtocol.getBedrockCodec(protocolVersion);
|
||||
// temp fix allowing 1.21.130 preview to join
|
||||
if (protocolVersion == 897) {
|
||||
packetCodec = GameProtocol.getBedrockCodec(898);
|
||||
}
|
||||
if (packetCodec == null) {
|
||||
// None of our Bedrock codecs support this client version, so we can simply compare it to our default protocol.
|
||||
String supportedVersions = GameProtocol.getAllSupportedBedrockVersions();
|
||||
|
||||
@@ -43,7 +43,6 @@ import org.geysermc.geyser.GeyserImpl;
|
||||
import org.geysermc.geyser.api.event.java.ServerDefineCommandsEvent;
|
||||
import org.geysermc.geyser.api.util.PlatformType;
|
||||
import org.geysermc.geyser.command.CommandRegistry;
|
||||
import org.geysermc.geyser.network.GameProtocol;
|
||||
import org.geysermc.geyser.registry.BlockRegistries;
|
||||
import org.geysermc.geyser.registry.Registries;
|
||||
import org.geysermc.geyser.session.GeyserSession;
|
||||
@@ -124,7 +123,7 @@ public class JavaCommandsTranslator extends PacketTranslator<ClientboundCommands
|
||||
@Override
|
||||
public void translate(GeyserSession session, ClientboundCommandsPacket packet) {
|
||||
// Don't send command suggestions if they are disabled
|
||||
if (GameProtocol.is1_21_130orHigher(session.protocolVersion()) || !session.getGeyser().config().gameplay().commandSuggestions()) {
|
||||
if (!session.getGeyser().config().gameplay().commandSuggestions()) {
|
||||
session.getGeyser().getLogger().debug("Not sending translated command suggestions as they are disabled.");
|
||||
|
||||
// Send a mostly empty packet so Bedrock doesn't override /help with its own, built-in help command.
|
||||
|
||||
Reference in New Issue
Block a user