So I've written this little animation/simulation thing with Pygame for Python with a bouncing ball and breaking boxes. The ball follows the law of reflection when it hits surfaces, meaning that the angle at which it hits a surface will be the same as the angle at which it bounces away. When the ball bounces off a box the box disappears.
I put the code here on GitHub and a video here on Youtube.
No comments:
Post a Comment