Record Class ServerboundSetGameRulePacket
java.lang.Object
java.lang.Record
net.minecraft.network.protocol.game.ServerboundSetGameRulePacket
- All Implemented Interfaces:
Packet<ServerGamePacketListener>
public record ServerboundSetGameRulePacket(List<ServerboundSetGameRulePacket.Entry> entries)
extends Record
implements Packet<ServerGamePacketListener>
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final List<ServerboundSetGameRulePacket.Entry> The field for theentriesrecord component.static final StreamCodec<io.netty.buffer.ByteBuf, ServerboundSetGameRulePacket> -
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance of aServerboundSetGameRulePacketrecord class. -
Method Summary
Modifier and TypeMethodDescriptionentries()Returns the value of theentriesrecord component.final booleanIndicates whether some other object is "equal to" this one.voidhandle(ServerGamePacketListener listener) final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.type()Methods inherited from interface Packet
isSkippable, isTerminal
-
Field Details
-
entries
The field for theentriesrecord component. -
STREAM_CODEC
-
-
Constructor Details
-
ServerboundSetGameRulePacket
Creates an instance of aServerboundSetGameRulePacketrecord class.- Parameters:
entries- the value for theentriesrecord component
-
-
Method Details
-
type
- Specified by:
typein interfacePacket<ServerGamePacketListener>
-
handle
- Specified by:
handlein interfacePacket<ServerGamePacketListener>
-
toString
-
hashCode
-
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). -
entries
Returns the value of theentriesrecord component.- Returns:
- the value of the
entriesrecord component
-