Class Keyframe.Builder<V>

java.lang.Object
dev.wyck.level.dimension.timeline.Keyframe.Builder<V>
Type Parameters:
V - the type of value stored in the keyframe
Enclosing interface:
Keyframe<V>

@AsOf("3.2.0") public static final class Keyframe.Builder<V> extends Object
Creates a new keyframe builder.
Since:
3.2.0
  • Constructor Details

    • Builder

      public Builder()
    • Builder

      public Builder(Keyframe<V> keyframe)
  • Method Details

    • ticks

      @AsOf("3.2.0") public Keyframe.Builder<V> ticks(int ticks)
      Sets the number of ticks this keyframe occurs at.
      Parameters:
      ticks - the number of ticks this keyframe occurs at
      Returns:
      this builder
      Since:
      3.2.0
    • value

      @AsOf("3.2.0") public Keyframe.Builder<V> value(V value)
      Sets the value stored in this keyframe.
      Parameters:
      value - the value stored in this keyframe
      Returns:
      this builder
      Since:
      3.2.0
    • build

      @AsOf("3.2.0") public Keyframe<V> build()
      Builds the keyframe.
      Returns:
      the built keyframe
      Since:
      3.2.0