Game development
Prototype a firework particle effect
A firework effect can be built from a burst of particles with different directions and shared gravity. Each particle stores position, velocity, lifetime and color; the renderer uses the remaining lifetime to fade it.
Start with a fixed particle count and reuse storage between bursts. Limit brightness and offer reduced effects so a celebratory moment does not make the playfield difficult to read.
Use a seeded random generator while debugging. A repeatable burst makes it easier to compare an optimization or track an out-of-bounds particle. Compare a simple burst with a gravity-driven burst and explain what each one communicates.