Class ParticleMovementConfiguration

java.lang.Object
technology.sola.engine.physics.component.particle.ParticleConfiguration
technology.sola.engine.physics.component.particle.ParticleMovementConfiguration

@NullMarked public class ParticleMovementConfiguration extends ParticleConfiguration
ParticleMovementConfiguration contains configuration for the movement properties of emitted Particles.
  • Method Details

    • minSpeed

      public float minSpeed()
      Returns:
      the minimum speed for newly emitted Particles
    • maxSpeed

      public float maxSpeed()
      Returns:
      the maximum speed for newly emitted Particles
    • setSpeedBounds

      public ParticleMovementConfiguration setSpeedBounds(float minSpeed, float maxSpeed)
      Updates the minimum and maximum speed values for newly emitted Particles.
      Parameters:
      minSpeed - the minimum speed for new particles
      maxSpeed - the maximum speed for new particles
      Returns:
      this
    • setSpeed

      public ParticleMovementConfiguration setSpeed(float speed)
      Sets the speed for newly emitted Particles.
      Parameters:
      speed - the speed for new particles
      Returns:
      this
    • inheritedVelocityPercentage

      public float inheritedVelocityPercentage()
      Returns:
      the percentage of the owning Entity's velocity to inherit from
    • setInheritedVelocityPercentage

      public ParticleMovementConfiguration setInheritedVelocityPercentage(float inheritedVelocityPercentage)
      Updates the percentage of velocity inheritance from the owning Entity.
      Parameters:
      inheritedVelocityPercentage - new percentage of velocity inheritance from the owning Entity
      Returns:
      this
    • noise

      public @Nullable ParticleNoise noise()
      Returns:
      the ParticleNoise configuration for this emitter, or null if no noise is applied
    • setNoise

      public ParticleMovementConfiguration setNoise(@Nullable ParticleNoise noise)
      Sets the ParticleNoise configuration for this emitter.
      Parameters:
      noise - the new ParticleNoise configuration, or null to disable noise
      Returns:
      this