DirectX Particle Explosion

At long last, I have written a useful Windows 95 demo that uses DirectX! I need to note that the particle explosion is based on some old DOS 32-bit code by Tom Hammersley. The particle system in my demo is based directly (no pun intended) on his code with only slight modifications. However, all of the DirectX Windows code was written by me, but I just want to give credit where credit is due.

What Does it Do?

This demo uses some simple physics to simulate an explosion with a particle system. It looks pretty awesome considering the small amount of code used for the particle system. You can press the spacebar to keep making new explosions which makes this a fun demo to play with.

In order to run this demo you need DirectX 5 which many of you probably have already if you play PC games much. If you don't have it, you can get it here, but be warned that it's a 3.5MB download. My first version of this demo assumed that the video card would organize its memory contiguously, and it worked fine on my video card, but several other people have had problems with it. I changed the code so that it now only copies the double buffer into the video buffer one line at a time so that it would work (theoretically) on everybody's video card. Let me know if it doesn't work for you. Just remember that you need DirectX 5 for it to work at all.

Particle explosion screenshot

Anyway, you may download the demo below. It includes a README file with some detailed information about the demo, an executable file, and the full source code! The code is well commented, and it uses the DirectDraw and DirectInput components of DirectX. Enjoy!

If you have any questions or comments about this demo e-mail me.

Back to Main Page