Mirror von
https://github.com/GeyserMC/Geyser.git
synchronisiert 2024-12-26 16:12:46 +01:00
Update Nukkit Protocol Library to 1.14 (#117)
* Update nukkit protocolib to 1.14 * Fixes * Remove debug
Dieser Commit ist enthalten in:
Ursprung
cbbc485efa
Commit
1f7b8ba5d5
@ -66,8 +66,8 @@
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.nukkitx.protocol</groupId>
|
||||
<artifactId>bedrock-v388</artifactId>
|
||||
<version>2.4.2</version>
|
||||
<artifactId>bedrock-v389</artifactId>
|
||||
<version>2.4.4</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
@ -27,7 +27,7 @@ package org.geysermc.connector;
|
||||
|
||||
import com.nukkitx.protocol.bedrock.BedrockPacketCodec;
|
||||
import com.nukkitx.protocol.bedrock.BedrockServer;
|
||||
import com.nukkitx.protocol.bedrock.v388.Bedrock_v388;
|
||||
import com.nukkitx.protocol.bedrock.v389.Bedrock_v389;
|
||||
|
||||
import lombok.Getter;
|
||||
import org.fusesource.jansi.AnsiConsole;
|
||||
@ -67,8 +67,7 @@ import java.util.concurrent.TimeUnit;
|
||||
@Getter
|
||||
public class GeyserConnector implements Connector {
|
||||
|
||||
public static final BedrockPacketCodec BEDROCK_PACKET_CODEC = Bedrock_v388.V388_CODEC;
|
||||
public static final int BEDROCK_1_14_PROTOCOL_VERSION = 389;
|
||||
public static final BedrockPacketCodec BEDROCK_PACKET_CODEC = Bedrock_v389.V389_CODEC;
|
||||
|
||||
public static final String NAME = "Geyser";
|
||||
public static final String VERSION = "1.0-SNAPSHOT";
|
||||
|
@ -45,7 +45,7 @@ public class UpstreamPacketHandler extends LoggingPacketHandler {
|
||||
|
||||
@Override
|
||||
public boolean handle(LoginPacket loginPacket) {
|
||||
if (loginPacket.getProtocolVersion() != GeyserConnector.BEDROCK_1_14_PROTOCOL_VERSION) {
|
||||
if (loginPacket.getProtocolVersion() != GeyserConnector.BEDROCK_PACKET_CODEC.getProtocolVersion()) {
|
||||
session.getUpstream().disconnect("Unsupported Bedrock version. Are you running an outdated version?");
|
||||
return true;
|
||||
}
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren