示例#1
0
        protected override void Initialize()
        {
            _graphics.PreferredBackBufferHeight = (int)WindowSize.Y;
            _graphics.PreferredBackBufferWidth  = (int)WindowSize.X;
            _graphics.ApplyChanges();

            _spriteBatch = new SpriteBatch(GraphicsDevice);

            SpaceBackground.Initialize();

            NewGame();

            base.Initialize();
        }
示例#2
0
        protected override void Initialize()
        {
            // set up display size
            _graphics.PreferredBackBufferHeight = (int)WindowSize.Y;
            _graphics.PreferredBackBufferWidth  = (int)WindowSize.X;
            _graphics.ApplyChanges();

            _spriteBatch = new SpriteBatch(GraphicsDevice);

            TimeRemaining = GameDuration;

            SpaceBackground.Initialize();
            ConnectionManager.Initialize();
            GameModel.Initialize(this);
            SyncManager.Start();

            _gui.Initialize();

            GameOver = false;

            base.Initialize();
        }