Class MovementStates

java.lang.Object
com.hypixel.hytale.protocol.MovementStates

public class MovementStates extends Object
  • Field Details

    • NULLABLE_BIT_FIELD_SIZE

      public static final int NULLABLE_BIT_FIELD_SIZE
      See Also:
    • FIXED_BLOCK_SIZE

      public static final int FIXED_BLOCK_SIZE
      See Also:
    • VARIABLE_FIELD_COUNT

      public static final int VARIABLE_FIELD_COUNT
      See Also:
    • VARIABLE_BLOCK_START

      public static final int VARIABLE_BLOCK_START
      See Also:
    • MAX_SIZE

      public static final int MAX_SIZE
      See Also:
    • idle

      public boolean idle
    • horizontalIdle

      public boolean horizontalIdle
    • jumping

      public boolean jumping
    • flying

      public boolean flying
    • walking

      public boolean walking
    • running

      public boolean running
    • sprinting

      public boolean sprinting
    • crouching

      public boolean crouching
    • forcedCrouching

      public boolean forcedCrouching
    • falling

      public boolean falling
    • fallingFar

      public boolean fallingFar
    • climbing

      public boolean climbing
    • inFluid

      public boolean inFluid
    • swimming

      public boolean swimming
    • swimJumping

      public boolean swimJumping
    • onGround

      public boolean onGround
    • mantling

      public boolean mantling
    • sliding

      public boolean sliding
    • mounting

      public boolean mounting
    • rolling

      public boolean rolling
    • sitting

      public boolean sitting
    • gliding

      public boolean gliding
    • sleeping

      public boolean sleeping
    • extraJumpsUsed

      public byte extraJumpsUsed
  • Constructor Details

    • MovementStates

      public MovementStates()
    • MovementStates

      public MovementStates(boolean idle, boolean horizontalIdle, boolean jumping, boolean flying, boolean walking, boolean running, boolean sprinting, boolean crouching, boolean forcedCrouching, boolean falling, boolean fallingFar, boolean climbing, boolean inFluid, boolean swimming, boolean swimJumping, boolean onGround, boolean mantling, boolean sliding, boolean mounting, boolean rolling, boolean sitting, boolean gliding, boolean sleeping, byte extraJumpsUsed)
    • MovementStates

      public MovementStates(@Nonnull MovementStates other)
  • Method Details

    • requireBounds

      public static void requireBounds(MemorySegment mem, int offset)
      Checks that the fixed block fits. The per-field getters read without their own bound check, so call this once before reading fields out of an untrusted segment.
    • getIdle

      public static boolean getIdle(MemorySegment mem)
    • getIdle

      public static boolean getIdle(MemorySegment mem, int offset)
    • getHorizontalIdle

      public static boolean getHorizontalIdle(MemorySegment mem)
    • getHorizontalIdle

      public static boolean getHorizontalIdle(MemorySegment mem, int offset)
    • getJumping

      public static boolean getJumping(MemorySegment mem)
    • getJumping

      public static boolean getJumping(MemorySegment mem, int offset)
    • getFlying

      public static boolean getFlying(MemorySegment mem)
    • getFlying

      public static boolean getFlying(MemorySegment mem, int offset)
    • getWalking

      public static boolean getWalking(MemorySegment mem)
    • getWalking

      public static boolean getWalking(MemorySegment mem, int offset)
    • getRunning

      public static boolean getRunning(MemorySegment mem)
    • getRunning

      public static boolean getRunning(MemorySegment mem, int offset)
    • getSprinting

      public static boolean getSprinting(MemorySegment mem)
    • getSprinting

      public static boolean getSprinting(MemorySegment mem, int offset)
    • getCrouching

      public static boolean getCrouching(MemorySegment mem)
    • getCrouching

      public static boolean getCrouching(MemorySegment mem, int offset)
    • getForcedCrouching

      public static boolean getForcedCrouching(MemorySegment mem)
    • getForcedCrouching

      public static boolean getForcedCrouching(MemorySegment mem, int offset)
    • getFalling

      public static boolean getFalling(MemorySegment mem)
    • getFalling

      public static boolean getFalling(MemorySegment mem, int offset)
    • getFallingFar

      public static boolean getFallingFar(MemorySegment mem)
    • getFallingFar

      public static boolean getFallingFar(MemorySegment mem, int offset)
    • getClimbing

      public static boolean getClimbing(MemorySegment mem)
    • getClimbing

      public static boolean getClimbing(MemorySegment mem, int offset)
    • getInFluid

      public static boolean getInFluid(MemorySegment mem)
    • getInFluid

      public static boolean getInFluid(MemorySegment mem, int offset)
    • getSwimming

      public static boolean getSwimming(MemorySegment mem)
    • getSwimming

      public static boolean getSwimming(MemorySegment mem, int offset)
    • getSwimJumping

      public static boolean getSwimJumping(MemorySegment mem)
    • getSwimJumping

      public static boolean getSwimJumping(MemorySegment mem, int offset)
    • getOnGround

      public static boolean getOnGround(MemorySegment mem)
    • getOnGround

      public static boolean getOnGround(MemorySegment mem, int offset)
    • getMantling

      public static boolean getMantling(MemorySegment mem)
    • getMantling

      public static boolean getMantling(MemorySegment mem, int offset)
    • getSliding

      public static boolean getSliding(MemorySegment mem)
    • getSliding

      public static boolean getSliding(MemorySegment mem, int offset)
    • getMounting

      public static boolean getMounting(MemorySegment mem)
    • getMounting

      public static boolean getMounting(MemorySegment mem, int offset)
    • getRolling

      public static boolean getRolling(MemorySegment mem)
    • getRolling

      public static boolean getRolling(MemorySegment mem, int offset)
    • getSitting

      public static boolean getSitting(MemorySegment mem)
    • getSitting

      public static boolean getSitting(MemorySegment mem, int offset)
    • getGliding

      public static boolean getGliding(MemorySegment mem)
    • getGliding

      public static boolean getGliding(MemorySegment mem, int offset)
    • getSleeping

      public static boolean getSleeping(MemorySegment mem)
    • getSleeping

      public static boolean getSleeping(MemorySegment mem, int offset)
    • getExtraJumpsUsed

      public static byte getExtraJumpsUsed(MemorySegment mem)
    • getExtraJumpsUsed

      public static byte getExtraJumpsUsed(MemorySegment mem, int offset)
    • toObject

      public static MovementStates toObject(MemorySegment mem)
    • toObject

      public static MovementStates toObject(MemorySegment mem, int offset)
    • toObject

      public static MovementStates toObject(MemorySegment mem, int offset, @Nullable ReadCursor cursor)
      Decodes one MovementStates and reports the end of its encoding through the cursor. The variable block is decoded in field order against a running position, and each offset slot must name that position, so the fields decoded are the bytes walked.
    • serialize

      public int serialize(@Nonnull MemorySegment mem, int offset)
    • computeSize

      public int computeSize()
    • clone

      public MovementStates clone()
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object