Interface BoltParticleOptions.SpawnFunction

Enclosing class:
BoltParticleOptions

public static interface BoltParticleOptions.SpawnFunction
A bolt's spawn function defines its spawn behavior (handled by the renderer). A spawn function generates a lower and upper bound on a spawn delay (via getSpawnDelayBounds()), for which an intermediate value is chosen randomly from a uniform distribution (getSpawnDelay()). Spawn functions can also be defined as 'consecutive,' in which cases the Bolt Renderer will always begin rendering a new bolt instance when one expires.
  • Field Details

  • Method Details

    • delay

      static BoltParticleOptions.SpawnFunction delay(float delay)
      Spawn bolts with a specified constant delay.
    • noise

      static BoltParticleOptions.SpawnFunction noise(float delay, float noise)
      Spawns bolts with a specified delay and specified noise value, which will be randomly applied at either end of the delay bounds.
    • getSpawnDelayBounds

      org.apache.commons.lang3.tuple.Pair<Float,Float> getSpawnDelayBounds(Random rand)
    • getSpawnDelay

      default float getSpawnDelay(Random rand)
    • isConsecutive

      default boolean isConsecutive()