Pinball Box2D Prototype

This has been due for quite a while now - another reason I should never consider "project management."

But in my defense:
We won the World-Cup. So spent a lot of days being "high"
IPL going on (ah c'mon.. cheerleaders)
Guess who saw 3 seasons of Clone Wars? Muhaha \m/

Ok so I wanted to learn how to use a "Physics Engine" in a game. I narrowed down to Box2D.
I wanted to make something new, so I thought how about a Pinball game! Well.. apparently people have already tried that.. so.. boo hoo.

I actually ran into some trouble, expected - considering this was the first time I used it. I didn't how to rig up the "Flipper" system. Then I came across this post. So that was the moment of "Boo hoo" i told above, people already "Been there, coded that"

The Game: (Requires Flash Player.. duh)
[Its 1 MB, wait till it loads]

Link

Instructions:
Use LEFT and RIGHT Arrow Keys
P to Pause
SPACE or CLICK in the first screen

Known Bugs:
Flipper collision fails sometimes, probably due to drop in frame rates (Box2D requires constant time step)

Things to keep in mind:
When using b2RevoluteJointDef, do NOT set mass to zero and enable limit and motor.
Velocity and Position Iterations have little effect, they didn't seem to fix the flipper issue.

Note: It's doesn't work with with Flash Player 11

4 comments:

  1. Nice job man, looks great! Fun to play, too! :)

    ReplyDelete
  2. @JW & @Nitwick:
    Thanks guys :)

    ReplyDelete
  3. ROBLOX is powered by an ever growing membership base of more than 300,000 creator players who generate an infinite variety of highly immersive experiences.

    These experiences range from 3D multi-player games and contests, to interactive adventures where players can take on new identities exploring what it's like to be a dinosaur, a miner working a mine or an astronaut out in space.

    ReplyDelete