Time for action — adding intervals to a particle system

We will now see that there are also some parameters that don't affect the appearance of the particles, and only affect the way they are emitted.

  1. Remove the added parameters of the point emitter and only keep the emission_rate, direction, and velocity:
    emitter Point
    {
    emission_rate 30
    direction 1 0 0
    velocity 20
    
  2. Then add the parameters that define how long a particle should be emitted and how long to wait before starting over:
    duration 1
    repeat_delay 1
    }
    
  3. Compile and run the application. You should see a stream of white particles, which is briefly interrupted each time the emitter stops emitting.

What just happened?

We added the parameter duration, which defines how long the emitter will emit particles ...

Get Ogre 3D 1.7 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.