More destruction
Published September 02, 2007
When I left you last time, I was busy trying to tidy up some temporary test code I was using in my particle system so I could extend it to do some fancier stuff. The truth is though, that I'm finding it hard to cleanup the last few bits of the particle system framework. I've still not found a clean way to handle new particle initialisation (e.g. so you can set an initial position, velocity, colour, energy, etc) in a flexible way, and, I need to think some more about how to safely delete game objects from inside the game update loop. To avoid having to deal with any of that, I decided to work on the explosions a little more.
I swapped the basic spherical particle sprite (for some grass of all things!) to give the fire more texture. I added some particle rotation, to give the flame bursts a rolling effect. And I added some black smoke around the bottom. On my Dad's advice, I also added some lift, so the flame plume rises into a red afterburn which I quite like. Finally, I put in a quick-and-dirty physics force model.
Here's a wee moovie of the lastest explosions - this time a slightly larger and more destructive one. As usual, click the picture for the moovie.
Cheers!