public override void LoadContent() { _agent = new Agent(new Vector2(ScreenManager.ScreenCenter.X, 100)); _agent.Load(ScreenManager.GraphicsDevice, PhysicsSimulator); LoadObstacles(); base.LoadContent(); }
public override void LoadContent() { _agent = new Agent(ScreenManager.ScreenCenter - new Vector2(200, 0)); _agent.CollisionCategory = CollisionCategory.Cat5; _agent.CollidesWith = CollisionCategory.All & ~CollisionCategory.Cat4; //collide with all but Cat4 (black) _agent.Load(ScreenManager.GraphicsDevice, PhysicsSimulator); _agent.Body.LinearDragCoefficient = .001f; LoadSpiders(); base.LoadContent(); }
public override void LoadContent() { _agent = new Agent(ScreenManager.ScreenCenter); _agent.CollisionCategory = CollisionCategory.Cat5; _agent.CollidesWith = CollisionCategory.All & ~CollisionCategory.Cat4; //collide with all but Cat4 (black) _agent.Load(ScreenManager.GraphicsDevice, PhysicsSimulator); LoadCircles(); base.LoadContent(); }
public override void LoadContent() { _rectangleTexture = DrawingHelper.CreateRectangleTexture(ScreenManager.GraphicsDevice, 32, 32, 2, 0, 0, Color.White, Color.Black); _rectangleBody = BodyFactory.Instance.CreateRectangleBody(32, 32, 1f); //template _rectangleGeom = GeomFactory.Instance.CreateRectangleGeom(_rectangleBody, 32, 32); //template _rectangleGeom.FrictionCoefficient = .4f; _rectangleGeom.RestitutionCoefficient = 0f; //create the pyramid near the bottom of the screen. _pyramid = new Pyramid(_rectangleBody, _rectangleGeom, 32f / 3f, 32f / 3f, 32, 32, _pyramidBaseBodyCount, new Vector2(ScreenManager.ScreenCenter.X - _pyramidBaseBodyCount * .5f * (32 + 32 / 3), ScreenManager.ScreenHeight - 60)); _pyramid.Load(PhysicsSimulator); _agent = new Agent(ScreenManager.ScreenCenter - new Vector2(320, 200)); _agent.Load(ScreenManager.GraphicsDevice, PhysicsSimulator); base.LoadContent(); }