Example #1
0
 public DXGamePlatform(XGame.XGame game, Control control) : base(game)
 {
     if (control == null)
     {
         throw new ArgumentNullException("control");
     }
     this.MainWindow   = new DXGameWindow(this, control);
     this.ActiveWindow = this.MainWindow;
     this.allGameWindows.Add(this.MainWindow);
     this.DeviceManager = new DXGameDeviceManager(this);
 }
Example #2
0
 public XGamePlatform(XGame game)
 {
     if (game == null)
     {
         throw new ArgumentNullException("game");
     }
     this.Game           = game;
     this.gameThread     = new Thread(this.RenderLoopCallback);
     this.allGameWindows = new List <XGameWindow>();
     this.InitCallback   = game.InitializeBeforeRun;
     this.RunCallback    = game.Tick;
     this.ExitCallback   = game.CleanUpAfterRun;
     this.IsRunning      = false;
 }