Пример #1
0
        public void Execute()
        {
            if (!UnityEngine.Input.GetKeyDown(KeyCode.Escape))
            {
                return;
            }

            if (!_gameInfo.hasCurrentState)
            {
                _gameInfo.ReplaceCurrentState(global::GameState.Menu);
                return;
            }

            _gameInfo.ReplaceCurrentState(_gameInfo.currentState.Value == global::GameState.Gameplay
                ? global::GameState.Menu
                : global::GameState.Gameplay);
        }
Пример #2
0
 public void Initialize()
 {
     _gameInfo.ReplaceCurrentState(global::GameState.Menu);
 }
 protected override void Execute(List <GameInfoEntity> entities)
 {
     _gameInfo.ReplaceCurrentState(global::GameState.Menu);
 }