2D Physics

8 weeks Solo

December 2016

Physics programming


Project Brief

This is my first try in making a physics engine. I was developing it while in parallel working on a game - Oberon. Making stable stacking within the given timeframe that could work in the game proved to be too ambitious, but even though these physics didn't make it into the game, I'm still very proud of the result.

Project Result

Rigidbody Physics

I learned how to write real-time Rigidbody Physics: Different integration methods, how forces and impulses affect bodies. I learned about different stages of a physics step, moment of inertia, torque, and many other things.

Collision Detection

I wrote code for collision detection. The game needed only boxes, so I decided to focus only on those. My system supports point to edge and edge to edge collision detection.

Collision Resolution

I learned and implemented collision resolution for this physics framework along with friction and resting states. I was very close to making stacking work properly, but due to time constraints, I couldn't get it to desired quality for a game.