Package net.minecraft.server.network
Class ServerLoginPacketListenerImpl
java.lang.Object
net.minecraft.server.network.ServerLoginPacketListenerImpl
- All Implemented Interfaces:
PacketListener
,ServerCookiePacketListener
,ServerPacketListener
,ServerLoginPacketListener
,ServerboundPacketListener
,TickablePacketListener
public class ServerLoginPacketListenerImpl
extends Object
implements ServerLoginPacketListener, TickablePacketListener
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static enum
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate com.mojang.authlib.GameProfile
private final byte[]
(package private) final Connection
(package private) static final org.slf4j.Logger
private static final int
(package private) String
(package private) final MinecraftServer
private final String
private int
How long has player been trying to login into the server.private final boolean
private static final AtomicInteger
-
Constructor Summary
ConstructorsConstructorDescriptionServerLoginPacketListenerImpl
(MinecraftServer pServer, Connection pConnection, boolean pTransferred) -
Method Summary
Modifier and TypeMethodDescriptionvoid
disconnect
(Component pReason) void
fillListenerSpecificCrashDetails
(CrashReport pCrashReport, CrashReportCategory pCategory) private void
finishLoginAndWaitForClient
(com.mojang.authlib.GameProfile p_295520_) void
void
void
handleHello
(ServerboundHelloPacket pPacket) void
handleKey
(ServerboundKeyPacket pPacket) void
boolean
private boolean
isPlayerAlreadyInWorld
(com.mojang.authlib.GameProfile p_294314_) void
onDisconnect
(DisconnectionDetails pDetails) (package private) void
startClientVerification
(com.mojang.authlib.GameProfile p_295643_) void
tick()
private void
verifyLoginAndFinishConnectionSetup
(com.mojang.authlib.GameProfile p_294502_) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface net.minecraft.network.PacketListener
createDisconnectionInfo, fillCrashReport, shouldHandleMessage
Methods inherited from interface net.minecraft.network.ServerboundPacketListener
flow
Methods inherited from interface net.minecraft.network.protocol.login.ServerLoginPacketListener
protocol
Methods inherited from interface net.minecraft.network.protocol.game.ServerPacketListener
onPacketError
-
Field Details
-
UNIQUE_THREAD_ID
-
LOGGER
static final org.slf4j.Logger LOGGER -
MAX_TICKS_BEFORE_LOGIN
private static final int MAX_TICKS_BEFORE_LOGIN- See Also:
-
challenge
private final byte[] challenge -
server
-
connection
-
state
-
tick
private int tickHow long has player been trying to login into the server. -
requestedUsername
-
authenticatedProfile
@Nullable private com.mojang.authlib.GameProfile authenticatedProfile -
serverId
- See Also:
-
transferred
private final boolean transferred
-
-
Constructor Details
-
ServerLoginPacketListenerImpl
public ServerLoginPacketListenerImpl(MinecraftServer pServer, Connection pConnection, boolean pTransferred)
-
-
Method Details
-
tick
public void tick()- Specified by:
tick
in interfaceTickablePacketListener
-
isAcceptingMessages
public boolean isAcceptingMessages()- Specified by:
isAcceptingMessages
in interfacePacketListener
-
disconnect
-
isPlayerAlreadyInWorld
private boolean isPlayerAlreadyInWorld(com.mojang.authlib.GameProfile p_294314_) -
onDisconnect
- Specified by:
onDisconnect
in interfacePacketListener
-
getUserName
-
handleHello
- Specified by:
handleHello
in interfaceServerLoginPacketListener
-
startClientVerification
void startClientVerification(com.mojang.authlib.GameProfile p_295643_) -
verifyLoginAndFinishConnectionSetup
private void verifyLoginAndFinishConnectionSetup(com.mojang.authlib.GameProfile p_294502_) -
finishLoginAndWaitForClient
private void finishLoginAndWaitForClient(com.mojang.authlib.GameProfile p_295520_) -
handleKey
- Specified by:
handleKey
in interfaceServerLoginPacketListener
-
handleCustomQueryPacket
- Specified by:
handleCustomQueryPacket
in interfaceServerLoginPacketListener
-
handleLoginAcknowledgement
- Specified by:
handleLoginAcknowledgement
in interfaceServerLoginPacketListener
-
fillListenerSpecificCrashDetails
public void fillListenerSpecificCrashDetails(CrashReport pCrashReport, CrashReportCategory pCategory) - Specified by:
fillListenerSpecificCrashDetails
in interfacePacketListener
-
handleCookieResponse
- Specified by:
handleCookieResponse
in interfaceServerCookiePacketListener
-