fix status kick

This commit is contained in:
creeper123123321 2022-03-24 20:04:44 -03:00
parent 9b67c1468e
commit 062ae5eb53
3 changed files with 3 additions and 2 deletions

View File

@ -44,6 +44,6 @@ public class StatusKicked implements ConnectionState {
@Override
public void start(@NotNull MinecraftHandler handler) {
ConnectionState.DefaultImpls.start(this, handler);
UtilKt.setAutoRead(handler.getData().getFrontChannel(), true);
}
}

View File

@ -68,7 +68,7 @@ class HandshakeState : ConnectionState {
val port = parsed.port ?: VIAaaSConfig.defaultBackendPort ?: virtualPort
val host = HostAndPort.fromParts(backAddress, port)
var frontOnline = parsed.online
val frontOnline = parsed.online
val addressFromWeb = VIAaaSConfig.hostName.any { parsed.serverAddress.equals(it, ignoreCase = true) }

View File

@ -73,6 +73,7 @@ class StatusState : ConnectionState {
}.toString()
send(handler.data.frontChannel, packet, flush = true)
handler.data.state = StatusKicked()
handler.data.state.start(handler)
}
override fun start(handler: MinecraftHandler) {