protected override void Update(GameTime gameTime) { KeyboardHandler.Update(); if (KeyboardHandler.CurrentState.IsKeyDown(Keys.Escape)) Exit(); if (KeyboardHandler.Pressed.Contains(Keys.G)) Gravity = (Gravity != Vector2.Zero) ? Vector2.Zero : NormalGravity; if (KeyboardHandler.Pressed.Contains(Keys.R)) world = new World(); world.Update(gameTime); base.Update(gameTime); }
protected override void Initialize() { world = new World(); base.Initialize(); }