public class PlayerMoveC2SPacket extends Object implements Packet<ServerPlayPacketListener>
Modifier and Type | Class and Description |
---|---|
static class |
PlayerMoveC2SPacket.Both |
static class |
PlayerMoveC2SPacket.LookOnly |
static class |
PlayerMoveC2SPacket.PositionOnly |
Modifier and Type | Field and Description |
---|---|
protected boolean |
changeLook |
protected boolean |
changePosition |
protected boolean |
onGround |
protected float |
pitch |
protected double |
x |
protected double |
y |
protected float |
yaw |
protected double |
z |
Constructor and Description |
---|
PlayerMoveC2SPacket() |
PlayerMoveC2SPacket(boolean onGround) |
Modifier and Type | Method and Description |
---|---|
void |
apply(ServerPlayPacketListener serverPlayPacketListener) |
float |
getPitch(float currentPitch) |
double |
getX(double currentX) |
double |
getY(double currentY) |
float |
getYaw(float currentYaw) |
double |
getZ(double currentZ) |
boolean |
isOnGround() |
void |
read(PacketByteBuf buf) |
void |
write(PacketByteBuf buf) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
isWritingErrorSkippable
protected double x
protected double y
protected double z
protected float yaw
protected float pitch
protected boolean onGround
protected boolean changePosition
protected boolean changeLook
public PlayerMoveC2SPacket()
@Environment(value=CLIENT) public PlayerMoveC2SPacket(boolean onGround)
public void apply(ServerPlayPacketListener serverPlayPacketListener)
apply
in interface Packet<ServerPlayPacketListener>
public void read(PacketByteBuf buf) throws IOException
read
in interface Packet<ServerPlayPacketListener>
IOException
public void write(PacketByteBuf buf) throws IOException
write
in interface Packet<ServerPlayPacketListener>
IOException
public double getX(double currentX)
public double getY(double currentY)
public double getZ(double currentZ)
public float getYaw(float currentYaw)
public float getPitch(float currentPitch)
public boolean isOnGround()