Record Class CustomPayloadS2CPacket
java.lang.Object
java.lang.Record
net.minecraft.network.packet.s2c.common.CustomPayloadS2CPacket
- Record Components:
payload-
- All Implemented Interfaces:
Packet<ClientCommonPacketListener>
public record CustomPayloadS2CPacket(CustomPayload payload)
extends Record
implements Packet<ClientCommonPacketListener>
- Mappings:
Namespace Name official ywintermediary net/minecraft/class_2658named net/minecraft/network/packet/s2c/common/CustomPayloadS2CPacketofficial cintermediary comp_1646named payload
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final PacketCodec<PacketByteBuf, CustomPayloadS2CPacket> private static final intprivate final CustomPayloadThe field for thepayloadrecord component.static final PacketCodec<RegistryByteBuf, CustomPayloadS2CPacket> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidapply(ClientCommonPacketListener clientCommonPacketListener) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.payload()Returns the value of thepayloadrecord component.final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.network.packet.Packet
isWritingErrorSkippable, transitionsNetworkState
-
Field Details
-
payload
The field for thepayloadrecord component. -
MAX_PAYLOAD_SIZE
private static final int MAX_PAYLOAD_SIZE- See Also:
- Mappings:
Namespace Name Mixin selector official dLyw;d:Iintermediary field_33326Lnet/minecraft/class_2658;field_33326:Inamed MAX_PAYLOAD_SIZELnet/minecraft/network/packet/s2c/common/CustomPayloadS2CPacket;MAX_PAYLOAD_SIZE:I
-
PLAY_CODEC
- Mappings:
Namespace Name Mixin selector official aLyw;a:Lyg;intermediary field_48620Lnet/minecraft/class_2658;field_48620:Lnet/minecraft/class_9139;named PLAY_CODECLnet/minecraft/network/packet/s2c/common/CustomPayloadS2CPacket;PLAY_CODEC:Lnet/minecraft/network/codec/PacketCodec;
-
CONFIGURATION_CODEC
- Mappings:
Namespace Name Mixin selector official bLyw;b:Lyg;intermediary field_48621Lnet/minecraft/class_2658;field_48621:Lnet/minecraft/class_9139;named CONFIGURATION_CODECLnet/minecraft/network/packet/s2c/common/CustomPayloadS2CPacket;CONFIGURATION_CODEC:Lnet/minecraft/network/codec/PacketCodec;
-
-
Constructor Details
-
CustomPayloadS2CPacket
-
-
Method Details
-
getPacketId
- Specified by:
getPacketIdin interfacePacket<ClientCommonPacketListener>- Mappings:
Namespace Name Mixin selector official aLyp;a()Lyr;intermediary method_55846Lnet/minecraft/class_2596;method_55846()Lnet/minecraft/class_9145;named getPacketIdLnet/minecraft/network/packet/Packet;getPacketId()Lnet/minecraft/network/packet/PacketType;
-
apply
- Specified by:
applyin interfacePacket<ClientCommonPacketListener>- Mappings:
Namespace Name Mixin selector official aLyw;a(Lyv;)Vintermediary method_53024Lnet/minecraft/class_2658;method_53024(Lnet/minecraft/class_8705;)Vnamed applyLnet/minecraft/network/packet/s2c/common/CustomPayloadS2CPacket;apply(Lnet/minecraft/network/listener/ClientCommonPacketListener;)V
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
payload
Returns the value of thepayloadrecord component.- Returns:
- the value of the
payloadrecord component
-