GamePage.xaml.cs 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. using System;
  2. using System.Collections.Generic;
  3. using System.IO;
  4. using System.Linq;
  5. using System.Runtime.InteropServices.WindowsRuntime;
  6. using Windows.Foundation;
  7. using Windows.Foundation.Collections;
  8. using Windows.UI.Xaml;
  9. using Windows.UI.Xaml.Controls;
  10. using Windows.UI.Xaml.Controls.Primitives;
  11. using Windows.UI.Xaml.Data;
  12. using Windows.UI.Xaml.Input;
  13. using Windows.UI.Xaml.Media;
  14. using Windows.UI.Xaml.Navigation;
  15. // The Blank Page item template is documented at http://go.microsoft.com/fwlink/?LinkId=402352&clcid=0x409
  16. namespace GameStateManagementSample
  17. {
  18. /// <summary>
  19. /// An empty page that can be used on its own or navigated to within a Frame.
  20. /// </summary>
  21. public sealed partial class GamePage : Page
  22. {
  23. readonly GameStateManagementGame _game;
  24. public GamePage()
  25. {
  26. this.InitializeComponent();
  27. // Create the game.
  28. var launchArguments = string.Empty;
  29. _game = MonoGame.Framework.XamlGame<GameStateManagementGame>.Create(launchArguments, Window.Current.CoreWindow, swapChainPanel);
  30. }
  31. }
  32. }