Interface MoveEntityPacketView

All Superinterfaces:
PacketView

public interface MoveEntityPacketView extends PacketView
Copy-on-write view shared by the three clientbound relative-movement packet shapes.
  • Method Details

    • entityId

      int entityId()
      Returns:
      native entity ID
    • hasPosition

      boolean hasPosition()
      Returns:
      whether this packet carries relative position
    • hasRotation

      boolean hasRotation()
      Returns:
      whether this packet carries rotation
    • deltaX

      double deltaX()
      Returns:
      relative X movement in blocks
    • deltaY

      double deltaY()
      Returns:
      relative Y movement in blocks
    • deltaZ

      double deltaZ()
      Returns:
      relative Z movement in blocks
    • yaw

      float yaw()
      Returns:
      yaw in degrees
    • pitch

      float pitch()
      Returns:
      pitch in degrees
    • onGround

      boolean onGround()
      Returns:
      whether the entity is on the ground
    • position

      void position(double x, double y, double z)
      Parameters:
      x - relative X movement in blocks
      y - relative Y movement in blocks
      z - relative Z movement in blocks
    • rotation

      void rotation(float yaw, float pitch)
      Parameters:
      yaw - yaw in degrees
      pitch - pitch in degrees
    • onGround

      void onGround(boolean onGround)
      Parameters:
      onGround - replacement on-ground flag