Bouncy Ball tank
Bouncy Ball tank - 1.00
Ron Dippold (sizer99)
A simple bouncing balls demo to demonstrate Pygame sprites. It makes a 'fish tank' and fills it with random blocks, then drops a large number of random balls in it that bounce around off the walls, blocks, and each other. After they settle down enough they disappear and respawn. Balls are not perfectly elastic (they lose energy on bounces) and gravity and ball mass are taken into account for collisions.
I wrote this back in 2005 as my first Pygame program, and looking back, this is pretty naive, but I can still just watch it for quite a while. Basically I'm just uploading this as a simple code sample.
You can just go in and hack the settings in the config file at top.
Pygame.org account Comments
If you wish to leave a comment with your pygame.org account, please sign in first.