Inheritance: 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();
     }
 }
示例#2
0
        public void Run()
        {
            this.Show();
            this.Activate();

            mGameData = new Game1();
            mGameData.Initialize();


            while (this.IsDisposed == false && Created)
            {

                if (Form.ActiveForm != this)
                {
                    System.Threading.Thread.Sleep(500);
                    Application.DoEvents();
                    continue;
                }

                FrameUpdate();

                mGameData.Update();

                if (!Created)
                    break;


                Draw();

                Application.DoEvents();



            }

        }