Games from Nothing: Black & White Exercise #4 — Particles

ring

For our introduction to particle systems, I modified existing code of both the rings and particles. In my first attempt with the rings I altered the time taken for the rings to ‘expire’ or disappear from the screen. Then changed the color variables and set them to randomly increment and then put the final value modulo 255 to get a variable in range.  The rings are initialized whenever they a point is pressed on the screen. From there the rings spread out  and the colors pulse with each set of rings taking a different color.

ring1

The third picture shows the modifications I made to the particle system. Again I randomized the colors but also inverted gravity to create an upward stream. In addition, instead of a single stream, I added two more points the particles could come from on either side of the initial stream. This simple alteration along with movement creates a feeling of greater volume akin to a smoke effect from a fire.

Particle

Author: Silas Osborne