// We only need a single particle system ParticleSystem ps; void setup() { // setup the environment size(400, 400); colorMode(RGB, 255, 255, 255, 100); smooth(); // To create our particle system we use two properties: // 1 -> How many particles should we start with // Vector3D -> What is the origin of the particle system ps = new ParticleSystem(1, new Vector3D(width / 2, height / 2, 0)); } void draw() { // clear the background background(0); // apply the simulation to the particles, and draw them to the screen ps.simulate(); // add a new particle ps.addParticle(); }