public override void LoadContent() { bodyA = BodyFactory.Instance.CreateRectangleBody(100, 25, 5); bodyB = BodyFactory.Instance.CreateRectangleBody(100, 25, 5); bodyA.Position = new Vector2(250, 300); bodyB.Position = new Vector2(350, 300); geomA = GeomFactory.Instance.CreateRectangleGeom(bodyA, 100, 25); geomB = GeomFactory.Instance.CreateRectangleGeom(bodyB, 100, 25); geomA.IgnoreCollisionWith(geomB); weldJoint = new WeldJoint(bodyA, bodyB, new Vector2(300, 300)); weldJoint.Broke += weldJoint_Broke; weldJoint.Breakpoint = 5.0f; PhysicsSimulator.Add(bodyA); PhysicsSimulator.Add(bodyB); PhysicsSimulator.Add(geomA); PhysicsSimulator.Add(geomB); PhysicsSimulator.Add(weldJoint); brush = new PolygonBrush(Vertices.CreateRectangle(100, 25), Color.White, Color.Black, 2.0f, 0.5f); brush.Load(ScreenManager.GraphicsDevice); bodyC = BodyFactory.Instance.CreatePolygonBody(Vertices.CreateGear(50, 20, .50f, 10), 10); bodyC.Position = new Vector2(500, 200); geomC = GeomFactory.Instance.CreatePolygonGeom(bodyC, Vertices.CreateGear(50, 20, .50f, 10), 1.5f); bodyD = BodyFactory.Instance.CreatePolygonBody(Vertices.CreateGear(50, 20, .50f, 10), 10); bodyD.Position = new Vector2(613, 200); geomD = GeomFactory.Instance.CreatePolygonGeom(bodyD, Vertices.CreateGear(50, 20, .50f, 10), 1.5f); geomC.CollisionGroup = 2; geomD.CollisionGroup = 3; geomC.FrictionCoefficient = 0f; geomD.FrictionCoefficient = 0f; PhysicsSimulator.Add(bodyC); PhysicsSimulator.Add(geomC); PhysicsSimulator.Add(bodyD); PhysicsSimulator.Add(geomD); gearBrushA = new PolygonBrush(Vertices.CreateGear(50, 20, .50f, 10), Color.White, Color.Black, 0.5f, 0.5f); gearBrushA.Load(ScreenManager.GraphicsDevice); gearBrushB = new PolygonBrush(Vertices.CreateGear(50, 20, .50f, 10), Color.White, Color.Black, 0.5f, 0.5f); gearBrushB.Load(ScreenManager.GraphicsDevice); revJointA = JointFactory.Instance.CreateFixedRevoluteJoint(bodyC, bodyC.Position); revJointB = JointFactory.Instance.CreateFixedRevoluteJoint(bodyD, bodyD.Position); PhysicsSimulator.Add(revJointA); PhysicsSimulator.Add(revJointB); table = new List<Table>(); table.Add(new Table(new Vector2(200, 450), 200, 50)); table[0].Load(PhysicsSimulator, ScreenManager.GraphicsDevice); base.LoadContent(); }