Record Class ClientboundTrackedWaypointPacket
java.lang.Object
java.lang.Record
net.minecraft.network.protocol.game.ClientboundTrackedWaypointPacket
- All Implemented Interfaces:
Packet<ClientGamePacketListener>
public record ClientboundTrackedWaypointPacket(ClientboundTrackedWaypointPacket.Operation operation, TrackedWaypoint waypoint)
extends Record
implements Packet<ClientGamePacketListener>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) static enum -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ClientboundTrackedWaypointPacket.OperationThe field for theoperationrecord component.private final TrackedWaypointThe field for thewaypointrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionClientboundTrackedWaypointPacket(ClientboundTrackedWaypointPacket.Operation operation, TrackedWaypoint waypoint) Creates an instance of aClientboundTrackedWaypointPacketrecord class. -
Method Summary
Modifier and TypeMethodDescriptionaddWaypointAzimuth(UUID pUuid, Waypoint.Icon pIcon, float pAngle) addWaypointChunk(UUID pUuid, Waypoint.Icon pIcon, ChunkPos pChunkPos) addWaypointPosition(UUID pUuid, Waypoint.Icon pIcon, Vec3i pPosition) voidapply(TrackedWaypointManager pWaypointManager) final booleanIndicates whether some other object is "equal to" this one.voidhandle(ClientGamePacketListener pHandler) Passes this Packet on to the PacketListener for processing.final inthashCode()Returns a hash code value for this object.Returns the value of theoperationrecord component.removeWaypoint(UUID pUuid) final StringtoString()Returns a string representation of this record class.type()updateWaypointAzimuth(UUID pUuid, Waypoint.Icon pIcon, float pAngle) updateWaypointChunk(UUID pUuid, Waypoint.Icon pIcon, ChunkPos pChunkPos) updateWaypointPosition(UUID pUuid, Waypoint.Icon pIcon, Vec3i pPosition) waypoint()Returns the value of thewaypointrecord component.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.minecraft.network.protocol.Packet
isSkippable, isTerminal
-
Field Details
-
operation
The field for theoperationrecord component. -
waypoint
The field for thewaypointrecord component. -
STREAM_CODEC
public static final StreamCodec<RegistryFriendlyByteBuf,ClientboundTrackedWaypointPacket> STREAM_CODEC
-
-
Constructor Details
-
ClientboundTrackedWaypointPacket
public ClientboundTrackedWaypointPacket(ClientboundTrackedWaypointPacket.Operation operation, TrackedWaypoint waypoint) Creates an instance of aClientboundTrackedWaypointPacketrecord class.- Parameters:
operation- the value for theoperationrecord componentwaypoint- the value for thewaypointrecord component
-
-
Method Details
-
removeWaypoint
-
addWaypointPosition
public static ClientboundTrackedWaypointPacket addWaypointPosition(UUID pUuid, Waypoint.Icon pIcon, Vec3i pPosition) -
updateWaypointPosition
public static ClientboundTrackedWaypointPacket updateWaypointPosition(UUID pUuid, Waypoint.Icon pIcon, Vec3i pPosition) -
addWaypointChunk
public static ClientboundTrackedWaypointPacket addWaypointChunk(UUID pUuid, Waypoint.Icon pIcon, ChunkPos pChunkPos) -
updateWaypointChunk
public static ClientboundTrackedWaypointPacket updateWaypointChunk(UUID pUuid, Waypoint.Icon pIcon, ChunkPos pChunkPos) -
addWaypointAzimuth
public static ClientboundTrackedWaypointPacket addWaypointAzimuth(UUID pUuid, Waypoint.Icon pIcon, float pAngle) -
updateWaypointAzimuth
public static ClientboundTrackedWaypointPacket updateWaypointAzimuth(UUID pUuid, Waypoint.Icon pIcon, float pAngle) -
type
- Specified by:
typein interfacePacket<ClientGamePacketListener>
-
handle
Passes this Packet on to the PacketListener for processing.- Specified by:
handlein interfacePacket<ClientGamePacketListener>
-
apply
-
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). -
operation
Returns the value of theoperationrecord component.- Returns:
- the value of the
operationrecord component
-
waypoint
Returns the value of thewaypointrecord component.- Returns:
- the value of the
waypointrecord component
-