Package net.minecraft.entity.player
Record Class PlayerPosition
java.lang.Object
java.lang.Record
net.minecraft.entity.player.PlayerPosition
- Record Components:
position-deltaMovement-yaw-pitch-
public record PlayerPosition(Vec3d position, Vec3d deltaMovement, float yaw, float pitch)
extends Record
- Mappings:
Namespace Name named net/minecraft/entity/player/PlayerPositionintermediary net/minecraft/class_10182official bysnamed positionintermediary comp_3148official bnamed deltaMovementintermediary comp_3149official cnamed yawintermediary comp_3150official dnamed pitchintermediary comp_3151official e
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Vec3dThe field for thedeltaMovementrecord component.static final PacketCodec<PacketByteBuf, PlayerPosition> private final floatThe field for thepitchrecord component.private final Vec3dThe field for thepositionrecord component.private final floatThe field for theyawrecord component. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic PlayerPositionapply(PlayerPosition currentPos, PlayerPosition newPos, Set<PositionFlag> flags) Returns the value of thedeltaMovementrecord component.final booleanIndicates whether some other object is "equal to" this one.static PlayerPositionfromEntity(Entity entity) static PlayerPositionfromTeleportTarget(TeleportTarget teleportTarget) final inthashCode()Returns a hash code value for this object.floatpitch()Returns the value of thepitchrecord component.position()Returns the value of thepositionrecord component.private static doubleresolve(double delta, double value, Set<PositionFlag> flags, PositionFlag deltaFlag) final StringtoString()Returns a string representation of this record class.floatyaw()Returns the value of theyawrecord component.
-
Field Details
-
position
The field for thepositionrecord component. -
deltaMovement
The field for thedeltaMovementrecord component. -
yaw
private final float yawThe field for theyawrecord component. -
pitch
private final float pitchThe field for thepitchrecord component. -
PACKET_CODEC
- Mappings:
Namespace Name Mixin selector named PACKET_CODECLnet/minecraft/entity/player/PlayerPosition;PACKET_CODEC:Lnet/minecraft/network/codec/PacketCodec;intermediary field_54565Lnet/minecraft/class_10182;field_54565:Lnet/minecraft/class_9139;official aLbys;a:Lze;
-
-
Constructor Details
-
PlayerPosition
-
-
Method Details
-
fromEntity
- Mappings:
Namespace Name Mixin selector named fromEntityLnet/minecraft/entity/player/PlayerPosition;fromEntity(Lnet/minecraft/entity/Entity;)Lnet/minecraft/entity/player/PlayerPosition;intermediary method_63638Lnet/minecraft/class_10182;method_63638(Lnet/minecraft/class_1297;)Lnet/minecraft/class_10182;official aLbys;a(Lbxe;)Lbys;
-
fromTeleportTarget
- Mappings:
Namespace Name Mixin selector named fromTeleportTargetLnet/minecraft/entity/player/PlayerPosition;fromTeleportTarget(Lnet/minecraft/world/TeleportTarget;)Lnet/minecraft/entity/player/PlayerPosition;intermediary method_63640Lnet/minecraft/class_10182;method_63640(Lnet/minecraft/class_5454;)Lnet/minecraft/class_10182;official aLbys;a(Leza;)Lbys;
-
apply
public static PlayerPosition apply(PlayerPosition currentPos, PlayerPosition newPos, Set<PositionFlag> flags) - Mappings:
Namespace Name Mixin selector named applyLnet/minecraft/entity/player/PlayerPosition;apply(Lnet/minecraft/entity/player/PlayerPosition;Lnet/minecraft/entity/player/PlayerPosition;Ljava/util/Set;)Lnet/minecraft/entity/player/PlayerPosition;intermediary method_63639Lnet/minecraft/class_10182;method_63639(Lnet/minecraft/class_10182;Lnet/minecraft/class_10182;Ljava/util/Set;)Lnet/minecraft/class_10182;official aLbys;a(Lbys;Lbys;Ljava/util/Set;)Lbys;
-
resolve
private static double resolve(double delta, double value, Set<PositionFlag> flags, PositionFlag deltaFlag) - Mappings:
Namespace Name Mixin selector named resolveLnet/minecraft/entity/player/PlayerPosition;resolve(DDLjava/util/Set;Lnet/minecraft/network/packet/s2c/play/PositionFlag;)Dintermediary method_63636Lnet/minecraft/class_10182;method_63636(DDLjava/util/Set;Lnet/minecraft/class_2709;)Dofficial aLbys;a(DDLjava/util/Set;Lbyt;)D
-
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. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
position
Returns the value of thepositionrecord component.- Returns:
- the value of the
positionrecord component
-
deltaMovement
Returns the value of thedeltaMovementrecord component.- Returns:
- the value of the
deltaMovementrecord component
-
yaw
public float yaw()Returns the value of theyawrecord component.- Returns:
- the value of the
yawrecord component
-
pitch
public float pitch()Returns the value of thepitchrecord component.- Returns:
- the value of the
pitchrecord component
-