Class LookAtS2CPacket
java.lang.Object
net.minecraft.network.packet.s2c.play.LookAtS2CPacket
- All Implemented Interfaces:
Packet<ClientPlayPacketListener>
public class LookAtS2CPacket extends Object implements Packet<ClientPlayPacketListener>
-
Field Summary
Fields Modifier and Type Field Description private intentityIdprivate booleanlookAtEntityprivate EntityAnchorArgumentType.EntityAnchorselfAnchorprivate EntityAnchorArgumentType.EntityAnchortargetAnchorprivate doubletargetXprivate doubletargetYprivate doubletargetZ -
Constructor Summary
Constructors Constructor Description LookAtS2CPacket()LookAtS2CPacket(EntityAnchorArgumentType.EntityAnchor entityAnchor, double targetX, double targetY, double targetZ)LookAtS2CPacket(EntityAnchorArgumentType.EntityAnchor selfAnchor, Entity entity, EntityAnchorArgumentType.EntityAnchor targetAnchor) -
Method Summary
Modifier and Type Method Description voidapply(ClientPlayPacketListener clientPlayPacketListener)EntityAnchorArgumentType.EntityAnchorgetSelfAnchor()Vec3dgetTargetPosition(World world)voidread(PacketByteBuf buf)voidwrite(PacketByteBuf buf)Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.minecraft.network.Packet
isWritingErrorSkippable
-
Field Details
-
targetX
private double targetX -
targetY
private double targetY -
targetZ
private double targetZ -
entityId
private int entityId -
selfAnchor
-
targetAnchor
-
lookAtEntity
private boolean lookAtEntity
-
-
Constructor Details
-
LookAtS2CPacket
public LookAtS2CPacket() -
LookAtS2CPacket
public LookAtS2CPacket(EntityAnchorArgumentType.EntityAnchor entityAnchor, double targetX, double targetY, double targetZ) -
LookAtS2CPacket
public LookAtS2CPacket(EntityAnchorArgumentType.EntityAnchor selfAnchor, Entity entity, EntityAnchorArgumentType.EntityAnchor targetAnchor)
-
-
Method Details
-
read
- Specified by:
readin interfacePacket<ClientPlayPacketListener>- Throws:
IOException
-
write
- Specified by:
writein interfacePacket<ClientPlayPacketListener>- Throws:
IOException
-
apply
- Specified by:
applyin interfacePacket<ClientPlayPacketListener>
-
getSelfAnchor
-
getTargetPosition
-