示例#1
0
        private void Functions()
        {
            _gridService = new GridService
            {
                Rows = rows,
                Cols = cols
            };

            SwitchCellState();

            //If the player didn't win, stop the game
            if (_gridService.DidThePlayerWin(_countAlive, _countTries))
            {
                StartGame.Content   = "Start game";
                LoadContent.Content = "Reload game";
                //StartGame.IsEnabled = false;

                _timer.Stop();
                _isGameLoaded = false;
                _countTries   = 0;
                _countAlive   = 0;
            }
            _countAlive = 0;
        }