(my apologies for the artifacting in the video capture)

I've got a fun little Java program (and animation API) here that displays a sunset followed by Fireworks (sorry the video quality is pretty bad). I'd love to see what kind of creative firework code you guys can come up with for the 4th. The source and compiled binaries are available here.

You can write some new classes to extend AnimObject (or either of the two example classes I provided - SimpleFirework and SimpleSparklingFirework). You should probably only have to modify the worldTick method in FireworksWorld.java to add your new effects, but you're also welcome to write your own class that extends either FireworksWorld or AnimationWorld and a new main class to go along with it.

If anyone comes up with a couple cool ones and posts them here, I'll happily turn it all into an applet (or a Java WebStart app), and host it on SFGP for everyone to play with.


Happy Fourth.
Very cool, Elfprince; thanks for sharing! It looks to me as if it picks a few fixed points along the horizon as the firework launching points; is that accurate?
Yes, though it would be easy to change that. I figured it was semi realistic to limit the number of places being launched from.
  
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.

» Go to Registration page
Page 1 of 1
» All times are UTC - 5 Hours
 
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum

 

Advertisement