Class KnockbackTraceComponent

java.lang.Object
com.hypixel.hytale.builtin.npcknockbackdebug.KnockbackTraceComponent
All Implemented Interfaces:
Component<EntityStore>, Cloneable

public class KnockbackTraceComponent extends Object implements Component<EntityStore>
  • Constructor Details

    • KnockbackTraceComponent

      public KnockbackTraceComponent()
    • KnockbackTraceComponent

      public KnockbackTraceComponent(@Nonnull String direction, float y, float force, @Nonnull String preset, @Nonnull ChangeVelocityType velocityType, @Nonnull org.joml.Vector3dc commandVelocity, @Nonnull String velocityConfig, @Nonnull org.joml.Vector3dc startPosition)
  • Method Details

    • getComponentType

      @Nonnull public static ComponentType<EntityStore, KnockbackTraceComponent> getComponentType()
    • getDirection

      @Nonnull public String getDirection()
    • getY

      public float getY()
    • getForce

      public float getForce()
    • getPreset

      @Nonnull public String getPreset()
    • getVelocityType

      @Nonnull public ChangeVelocityType getVelocityType()
    • getCommandVelocity

      @Nonnull public org.joml.Vector3d getCommandVelocity()
    • getVelocityConfig

      @Nonnull public String getVelocityConfig()
    • getStartPosition

      @Nonnull public org.joml.Vector3d getStartPosition()
    • getPreviousPosition

      @Nonnull public org.joml.Vector3d getPreviousPosition()
    • getSamples

      @Nonnull public List<KnockbackTraceComponent.TickSample> getSamples()
    • getTickCount

      public int getTickCount()
    • getTotalDistance

      public double getTotalDistance()
    • getMaxY

      public double getMaxY()
    • hasMoved

      public boolean hasMoved()
    • addSample

      public void addSample(@Nonnull KnockbackTraceComponent.TickSample sample, @Nonnull org.joml.Vector3dc positionDelta, float dt, double movementThresholdSquared)
    • hasTimedOut

      public boolean hasTimedOut()
    • clone

      @Nonnull public Component<EntityStore> clone()
      Specified by:
      clone in interface Component<EntityStore>
      Returns:
      a clone instance of the original component instance.