Random PinBall

I just started playing around with the physics functions to see what they do. With what I learned so far, I put together this little program that simulates a pinball. There’s probably a lot of coding to get to an actual pinball game, but this is probably a good start. The pinball will get stuck every now and then, but I didn’t want to spend the time or write the code to stop it. Besides, it’s interesting to see if it will get stuck. If it does, just restart the program for another random layout. I added a lot of comments and tried to keep everything together for anyone else trying to learn the physics functions. I hope this helps someone else.


The program is at: http://gist.github.com/2943054

A nice demo Dave! Don’t think it would take much to bump it to a playable game.

I downloaded and ran, nice demo of the powerful box2d physics. Makes me want to make some cool physics games.