Interface Ticks


public interface Ticks
Standard game tick utilities.
Since:
4.0.0
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final long
    A single tick duration, in milliseconds.
    static final int
    The number of ticks that occur in one second.
  • Method Summary

    Static Methods
    Modifier and Type
    Method
    Description
    static @NotNull Duration
    duration(long ticks)
    Converts ticks into a Duration.
  • Field Details

    • TICKS_PER_SECOND

      static final int TICKS_PER_SECOND
      The number of ticks that occur in one second.
      Since:
      4.0.0
      See Also:
    • SINGLE_TICK_DURATION_MS

      static final long SINGLE_TICK_DURATION_MS
      A single tick duration, in milliseconds.
      Since:
      4.0.0
      See Also:
  • Method Details

    • duration

      @NotNull static @NotNull Duration duration(long ticks)
      Converts ticks into a Duration.
      Parameters:
      ticks - the number of ticks
      Returns:
      a duration
      Since:
      4.0.0