public override void Update(GameTime gameTime) { TouchCollection tc; base.Update(gameTime); _game.UpdateAll(gameTime); // Has the user touched the screen? tc = TouchPanel.GetState(); if (tc.Count == 1 && tc[0].State == TouchLocationState.Pressed) { // Enter HighScores mode _game.SetGameMode <Mode_HighScores>(); } }
public override void Update(GameTime gameTime) { TouchCollection tc; base.Update(gameTime); _game.UpdateAll(gameTime); // Assuming we're not still entering the player's name... if (!GameHelper.KeyboardInputIsVisible) { // Has the user touched the screen? tc = TouchPanel.GetState(); if (tc.Count == 1 && tc[0].State == TouchLocationState.Pressed) { // Return back to Game mode _game.SetGameMode <Mode_Game>(); // Reset the game _game.CurrentGameModeHandler.Reset(); } } }