Record Class StructuresDebugPayload
java.lang.Object
java.lang.Record
net.minecraft.network.protocol.common.custom.StructuresDebugPayload
- All Implemented Interfaces:
CustomPacketPayload
public record StructuresDebugPayload(ResourceKey<Level> dimension, BoundingBox mainBB, List<StructuresDebugPayload.PieceInfo> pieces)
extends Record
implements CustomPacketPayload
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface net.minecraft.network.protocol.common.custom.CustomPacketPayload
CustomPacketPayload.FallbackProvider<B extends FriendlyByteBuf>, CustomPacketPayload.Type<T extends CustomPacketPayload>, CustomPacketPayload.TypeAndCodec<B extends FriendlyByteBuf,T extends CustomPacketPayload> -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ResourceKey<Level> The field for thedimensionrecord component.private final BoundingBoxThe field for themainBBrecord component.private final List<StructuresDebugPayload.PieceInfo> The field for thepiecesrecord component.static final StreamCodec<FriendlyByteBuf, StructuresDebugPayload> static final CustomPacketPayload.Type<StructuresDebugPayload> -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateStructuresDebugPayload(FriendlyByteBuf p_294983_) StructuresDebugPayload(ResourceKey<Level> dimension, BoundingBox mainBB, List<StructuresDebugPayload.PieceInfo> pieces) Creates an instance of aStructuresDebugPayloadrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedimensionrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.mainBB()Returns the value of themainBBrecord component.pieces()Returns the value of thepiecesrecord component.(package private) static BoundingBoxreadBoundingBox(FriendlyByteBuf p_294387_) final StringtoString()Returns a string representation of this record class.type()private voidwrite(FriendlyByteBuf p_295318_) (package private) static voidwriteBoundingBox(FriendlyByteBuf p_296195_, BoundingBox p_294095_)
-
Field Details
-
dimension
The field for thedimensionrecord component. -
mainBB
The field for themainBBrecord component. -
pieces
The field for thepiecesrecord component. -
STREAM_CODEC
-
TYPE
-
-
Constructor Details
-
StructuresDebugPayload
-
StructuresDebugPayload
public StructuresDebugPayload(ResourceKey<Level> dimension, BoundingBox mainBB, List<StructuresDebugPayload.PieceInfo> pieces) Creates an instance of aStructuresDebugPayloadrecord class.- Parameters:
dimension- the value for thedimensionrecord componentmainBB- the value for themainBBrecord componentpieces- the value for thepiecesrecord component
-
-
Method Details
-
write
-
type
- Specified by:
typein interfaceCustomPacketPayload
-
readBoundingBox
-
writeBoundingBox
-
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). -
dimension
Returns the value of thedimensionrecord component.- Returns:
- the value of the
dimensionrecord component
-
mainBB
Returns the value of themainBBrecord component.- Returns:
- the value of the
mainBBrecord component
-
pieces
Returns the value of thepiecesrecord component.- Returns:
- the value of the
piecesrecord component
-