Record Class GoalDebugPayload
java.lang.Object
java.lang.Record
net.minecraft.network.protocol.common.custom.GoalDebugPayload
- All Implemented Interfaces:
- CustomPacketPayload
public record GoalDebugPayload(int entityId, BlockPos pos, List<GoalDebugPayload.DebugGoal> goals)
extends Record
implements CustomPacketPayload
- 
Nested Class SummaryNested Classes
- 
Field SummaryFieldsModifier and TypeFieldDescriptionprivate final intThe field for theentityIdrecord component.private final List<GoalDebugPayload.DebugGoal>The field for thegoalsrecord component.static final ResourceLocationprivate final BlockPosThe field for theposrecord component.
- 
Constructor SummaryConstructorsConstructorDescriptionGoalDebugPayload(int entityId, BlockPos pos, List<GoalDebugPayload.DebugGoal> goals) Creates an instance of aGoalDebugPayloadrecord class.GoalDebugPayload(FriendlyByteBuf p_300481_) 
- 
Method SummaryModifier and TypeMethodDescriptionintentityId()Returns the value of theentityIdrecord component.final booleanIndicates whether some other object is "equal to" this one.goals()Returns the value of thegoalsrecord component.final inthashCode()Returns a hash code value for this object.id()pos()Returns the value of theposrecord component.final StringtoString()Returns a string representation of this record class.voidwrite(FriendlyByteBuf p_297279_) 
- 
Field Details- 
entityIdprivate final int entityIdThe field for theentityIdrecord component.
- 
posThe field for theposrecord component.
- 
goalsThe field for thegoalsrecord component.
- 
ID
 
- 
- 
Constructor Details- 
GoalDebugPayload
- 
GoalDebugPayloadCreates an instance of aGoalDebugPayloadrecord class.- Parameters:
- entityId- the value for the- entityIdrecord component
- pos- the value for the- posrecord component
- goals- the value for the- goalsrecord component
 
 
- 
- 
Method Details- 
write- Specified by:
- writein interface- CustomPacketPayload
 
- 
id- Specified by:
- idin interface- CustomPacketPayload
 
- 
toStringReturns 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.
- 
hashCodepublic 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.
- 
equalsIndicates 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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='.
- 
entityIdpublic int entityId()Returns the value of theentityIdrecord component.- Returns:
- the value of the entityIdrecord component
 
- 
posReturns the value of theposrecord component.- Returns:
- the value of the posrecord component
 
- 
goalsReturns the value of thegoalsrecord component.- Returns:
- the value of the goalsrecord component
 
 
-