public override void Update(GameTime gt)
        {
            if (_upkey.Released())
            {
                MoveFocusUp();
            }
            else if (_downkey.Released())
            {
                MoveFocusDown();
            }
            else if (_leftkey.Released())
            {
                MoveFocusLeft();
            }
            else if (_rightkey.Released())
            {
                MoveFocusRight();
            }
            if (_selectkey.Released())
            {
                Release();
            }

            base.Update(gt);
        }
예제 #2
0
        public override void PostUpdate()
        {
            base.PostUpdate();

            if (_backkey.Released())
            {
                (new MenuState()).Show();
            }
        }
예제 #3
0
            public override void Update(GameTime gt)
            {
                base.Update(gt);

                AutoBody.Position = new Vector2(_rand.Next(40, EntityGame.Viewport.Width - 40), -30);

                if (MouseService.Cursor.Down())
                {
                    MouseBody.Position = new Vector2(MouseService.Cursor.Position.X, MouseService.Cursor.Position.Y);
                    FancySpawnerMouse.Emit(1);
                }
                if (_emitkey.Released())
                {
                    FancySpawnerAuto.AutoEmit = !FancySpawnerAuto.AutoEmit;
                }
            }
예제 #4
0
        public override void Update(GameTime gt)
        {
            base.Update(gt);

            _titleLabel.Text = _currentTest.Title;

            _descriptionLabel.Text = _currentTest.Description;

            if (_beginTest.Released() && !_currentTest.Active)
            {
                if (!_currentTest.Started)
                {
                    _currentTest.Begin();
                }
                _currentTest.Active = true;
            }
            else if (_beginTest.Released() && _currentTest.Active)
            {
                _currentTest.Active = false;
            }

            if (_resetTest.Released())
            {
                _currentTest.Reset();
                _currentTest.Initialize();
            }

            if (_nextTest.Released())
            {
                NextTest();
            }
            else if (_lastTest.Released())
            {
                LastTest();
            }
        }