Class KeyframeAnimation.StateCollection.State

java.lang.Object
dev.kosmx.playerAnim.core.data.KeyframeAnimation.StateCollection.State
Enclosing class:
KeyframeAnimation.StateCollection

public static final class KeyframeAnimation.StateCollection.State extends Object
  • Field Details

    • defaultValue

      public final float defaultValue
    • threshold

      public final float threshold
    • name

      public final String name
  • Constructor Details

  • Method Details

    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • lockAndVerify

      public void lockAndVerify(int maxLength)
      Locks the object, throws exception if contains invalid data
      Parameters:
      maxLength - length of animation
    • setEnabled

      public void setEnabled(boolean newValue)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • length

      public int length()
    • findAtTick

      public int findAtTick(int tick)
      Find the last keyframe's number before the tick
      Parameters:
      tick - tick
      Returns:
      given keyframe
    • addKeyFrame

      public boolean addKeyFrame(int tick, float value, Ease ease, int rotate, boolean degrees)
      Add a new keyframe to the emote
      Parameters:
      tick - where
      value - what value
      ease - with what easing
      rotate - 360 degrees turn
      degrees - is the value in degrees (or radians if false)
      Returns:
      is the keyframe valid
    • addKeyFrame

      public boolean addKeyFrame(int tick, float value, Ease ease, int rotate, boolean degrees, Float easingArg)
      Add a new keyframe to the emote
      Parameters:
      tick - where
      value - what value
      ease - with what easing
      rotate - 360 degrees turn
      degrees - is the value in degrees (or radians if false)
      easingArg - self-explanatory
      Returns:
      is the keyframe valid
    • addKeyFrame

      public boolean addKeyFrame(int tick, float value, Ease ease)
      Add a new keyframe to the emote
      Parameters:
      tick - where
      value - what value
      ease - with what easing
      Returns:
      is the keyframe valid
    • addKeyFrame

      public boolean addKeyFrame(int tick, float value, Ease ease, Float easingArg)
      Add a new keyframe to the emote
      Parameters:
      tick - where
      value - what value
      ease - with what easing
      easingArg - self-explanatory
      Returns:
      is the keyframe valid
    • replace

      public void replace(KeyframeAnimation.KeyFrame keyFrame, int pos)
    • replaceEase

      public void replaceEase(int pos, Ease ease)
    • copy