Class ClientboundHelloPacket
java.lang.Object
net.minecraft.network.protocol.login.ClientboundHelloPacket
- All Implemented Interfaces:
Packet<ClientLoginPacketListener>
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final byte[]private final byte[]private final Stringprivate final booleanstatic final StreamCodec<FriendlyByteBuf, ClientboundHelloPacket> -
Constructor Summary
ConstructorsModifierConstructorDescriptionClientboundHelloPacket(String serverId, byte[] publicKey, byte[] challenge, boolean shouldAuthenticate) private -
Method Summary
Modifier and TypeMethodDescriptionbyte[]voidhandle(ClientLoginPacketListener listener) booleantype()private voidwrite(FriendlyByteBuf output) Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Packet
isSkippable, isTerminal
-
Field Details
-
STREAM_CODEC
-
serverId
-
publicKey
private final byte[] publicKey -
challenge
private final byte[] challenge -
shouldAuthenticate
private final boolean shouldAuthenticate
-
-
Constructor Details
-
ClientboundHelloPacket
public ClientboundHelloPacket(String serverId, byte[] publicKey, byte[] challenge, boolean shouldAuthenticate) -
ClientboundHelloPacket
-
-
Method Details
-
write
-
type
- Specified by:
typein interfacePacket<ClientLoginPacketListener>
-
handle
- Specified by:
handlein interfacePacket<ClientLoginPacketListener>
-
getServerId
-
getPublicKey
- Throws:
CryptException
-
getChallenge
public byte[] getChallenge() -
shouldAuthenticate
public boolean shouldAuthenticate()
-