This is the main type for your game
상속: Microsoft.Xna.Framework.Game
예제 #1
0
 /// <summary>
 /// The main entry point for the application.
 /// </summary>
 static void Main(string[] args)
 {
     using (Game1 game = new Game1())
     {
         game.Run();
     }
 }
        /// This method is invoked when the application has loaded and is ready to run. In this 
        // method you should instantiate the window, load the UI into it and then make the window
        // visible.
        // You have 17 seconds to return from this method, or iOS will terminate your application.
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            gamer = new Game1();
            gamer.Run();

            return true;
        }
예제 #3
0
        // Constructor
        public GamePage()
        {
            InitializeComponent();

            _game = XamlGame<Game1>.Create("", this);

            // Sample code to localize the ApplicationBar
            //BuildLocalizedApplicationBar();
        }
예제 #4
0
        protected override void OnCreate(Bundle bundle)
        {
            base.OnCreate (bundle);

            // Create our OpenGL view, and display it
            Game1.Activity = this;
            var g = new Game1 ();
            SetContentView (g.Window);
            g.Run ();
        }
예제 #5
0
        protected override void OnCreate(Bundle bundle)
        {
            //base.OnCreate (bundle);
            //Microsoft.Xna.Framework.Game.Activity = this;
            //Game = new WindowsPuzzleVisualizer.Game1();
            //WindowsPuzzleVisualizer.Game1 game = new WindowsPuzzleVisualizer.Game1();
            //game.Run();

            base.OnCreate(bundle);
            Game1.Activity = this;
            var g = new Game1(Assets);
            SetContentView(g.Window);
            g.Run();
        }
예제 #6
0
        //
        // This method is invoked when the application has loaded and is ready to run. In this
        // method you should instantiate the window, load the UI into it and then make the window
        // visible.
        //
        // You have 17 seconds to return from this method, or iOS will terminate your application.
        //
        public override bool FinishedLaunching(UIApplication app, NSDictionary options)
        {
            // Fun begins..
            game = new Game1();
            game.Run();
            // create a new window instance based on the screen size
            /*window = new UIWindow (UIScreen.MainScreen.Bounds);

            // If you have defined a view, add it here:
            // window.AddSubview (navigationController.View);

            // make the window visible
            window.MakeKeyAndVisible ();*/

            return true;
        }
예제 #7
0
 static void Main()
 {
     using (var game = new Game1())
         game.Run();
 }