Package net.minecraft.server.network
Class ServerLoginNetworkHandler
java.lang.Object
net.minecraft.server.network.ServerLoginNetworkHandler
- All Implemented Interfaces:
PacketListener,ServerLoginPacketListener
public class ServerLoginNetworkHandler extends Object implements ServerLoginPacketListener
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classServerLoginNetworkHandler.State -
Field Summary
Fields Modifier and Type Field Description private static AtomicIntegerauthenticatorThreadIdClientConnectionconnectionprivate static LoggerLOGGERprivate intloginTicksprivate byte[]nonceprivate ServerPlayerEntityplayerprivate com.mojang.authlib.GameProfileprofileprivate static RandomRANDOMprivate SecretKeysecretKeyprivate MinecraftServerserverprivate StringserverIdprivate ServerLoginNetworkHandler.Statestate -
Constructor Summary
Constructors Constructor Description ServerLoginNetworkHandler(MinecraftServer server, ClientConnection connection) -
Method Summary
Modifier and Type Method Description voidacceptPlayer()voiddisconnect(Text reason)ClientConnectiongetConnection()StringgetConnectionInfo()voidonDisconnected(Text reason)voidonHello(LoginHelloC2SPacket packet)voidonKey(LoginKeyC2SPacket packet)voidonQueryResponse(LoginQueryResponseC2SPacket packet)voidtick()protected com.mojang.authlib.GameProfiletoOfflineProfile(com.mojang.authlib.GameProfile profile)
-
Field Details
-
authenticatorThreadId
-
LOGGER
-
RANDOM
-
nonce
private final byte[] nonce -
server
-
connection
-
state
-
loginTicks
private int loginTicks -
profile
private com.mojang.authlib.GameProfile profile -
serverId
- See Also:
- Constant Field Values
-
secretKey
-
player
-
-
Constructor Details
-
ServerLoginNetworkHandler
-
-
Method Details
-
tick
public void tick() -
getConnection
- Specified by:
getConnectionin interfacePacketListener
-
disconnect
-
acceptPlayer
public void acceptPlayer() -
onDisconnected
- Specified by:
onDisconnectedin interfacePacketListener
-
getConnectionInfo
-
onHello
- Specified by:
onHelloin interfaceServerLoginPacketListener
-
onKey
- Specified by:
onKeyin interfaceServerLoginPacketListener
-
onQueryResponse
- Specified by:
onQueryResponsein interfaceServerLoginPacketListener
-
toOfflineProfile
protected com.mojang.authlib.GameProfile toOfflineProfile(com.mojang.authlib.GameProfile profile)
-