Game series: Crush the Castle

Real world catapult prototype using Box2D – Cleaner code

We got it. After the first catapult prototype and the “slippery wheels” sequel, this is a version with realistic movement and a lot cleaner code. To add realistic movement I defined friction and restitution, making useless the CreateFixture2 function and widely using the more appropriate CreateFixture one. This way I have full control on fixtures, […]

Real world catapult prototype using Box2D

This is an early attempt to simulate a real world catapult using Box2D. Raw and uncommented code, but a lot of useful information about compound objects, revolute joints and motors. This is what you’ll get: Click with the mouse to shoot the ball.