13
0
geforkt von Mirrors/Velocity

Fixed disconnection reason display due to outdated client version (#1259)

Dieser Commit ist enthalten in:
Maxim Breitman 2024-02-29 22:41:05 +03:00 committet von GitHub
Ursprung d330236b09
Commit af09677f60
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: B5690EEEBB952194

Datei anzeigen

@ -118,6 +118,8 @@ public class HandshakeSessionHandler implements MinecraftSessionHandler {
private void handleLogin(HandshakePacket handshake, InitialInboundConnection ic) {
if (!ProtocolVersion.isSupported(handshake.getProtocolVersion())) {
// Bump connection into correct protocol state so that we can send the disconnect packet.
connection.setState(StateRegistry.LOGIN);
ic.disconnectQuietly(Component.translatable()
.key("multiplayer.disconnect.outdated_client")
.arguments(Component.text(ProtocolVersion.SUPPORTED_VERSION_STRING))