private static RepoFilesChoice CreateRepositoryFilesAndGetUserChoice(string message)
        {
            var repo   = SaveRepository.GetDefaultRepository();
            var files  = ShowSavedGamesAndReturnAsList(repo);
            var choice = UserInteraction.GetNumberFromUser(
                message, "Option not found. Please try again", 0, files.Count);

            return(new RepoFilesChoice(repo, files, choice));
        }
        private IMoveResult SaveGame(IMoveResult moveResult, int currentPlayer)
        {
            Console.WriteLine("Under what name save the game?");
            string file           = UserInteraction.ReadNotEmptyStringFromUser();
            var    saveRepository = SaveRepository.GetDefaultRepository();

            bool isEnded = moveResult.IsCheckMate(TeamColor.Black) || moveResult.IsCheckMate(TeamColor.White);
            var  state   = new ChessGameState(moveResult, isEnded, _players,
                                              _players[currentPlayer].TeamColor, PlayerMode.TwoPlayers, 0);

            saveRepository.Save(file + ".bin", state);
            Console.WriteLine("Game saved.");
            return(new StoppedMoveResult());
        }
        private IMoveResult SaveGame(IMoveResult moveResult)
        {
            Console.WriteLine("Under what name save the game?");
            string file           = UserInteraction.ReadNotEmptyStringFromUser();
            var    saveRepository = SaveRepository.GetDefaultRepository();

            bool isEnded = moveResult.IsCheckMate(TeamColor.Black) || moveResult.IsCheckMate(TeamColor.White);
            var  state   = new ChessGameState(moveResult, isEnded, new [] { _player },
                                              _computer.MyTeamColor, PlayerMode.SinglePlayer, _difficulty);

            saveRepository.Save(file + ".bin", state);
            Console.WriteLine("Game saved.");
            return(new StoppedMoveResult());
        }