Exemple #1
0
        protected override void LoadContent()
        {
            // TODO: use this.Content to load your game content here

            spriteBatch = new SpriteBatch(GraphicsDevice);
            HUD.LoadContent(Content);
            _manageScreens = new ManageScreens(Content, graphics);
            _manageScreens.LoadNewScreen(new ScreenStart(_manageScreens), "");
        }
        public override void Update(GameTime gameTime)
        {
            Camera.Update(Vector2.Zero);
            ObjectAnimated.Update(gameTime);

            if (_canPressStart)
            {
                ObjectAnimated.Play("StartScreen");

                if (ManageInput.playerStart)
                {
                    ManageScreens.LoadNewScreen(new ScreenLoad(ManageScreens), "Fading");
                }
            }
        }
Exemple #3
0
        protected override void Update(GameTime gameTime)
        {
            if (Keyboard.GetState().IsKeyDown(Keys.Escape))
            {
                Exit();
            }

            if (RestartGame)
            {
                RestartGame = false;
                _manageScreens.LoadNewScreen(new ScreenStart(_manageScreens), "Fading");
            }

            // TODO: Add your update logic here
            _manageScreens.Update(gameTime);
            HUD.Update(gameTime);
            ManageInput.Update(gameTime);
            base.Update(gameTime);
        }
Exemple #4
0
        public override void Update(GameTime gameTime)
        {
            Camera.Update(Vector2.Zero);
            ObjectAnimated.Update(gameTime);

            if (_timer <= 0)
            {
                _canPressStart = true;
            }


            if (_canPressStart)
            {
                if (ManageInput.playerStart)
                {
                    ManageScreens.LoadNewScreen(new ScreenWorld(ManageScreens, true), "Fading");
                }
            }
            _timer--;
        }