Exemplo n.º 1
0
        public GameManager(
            IBoardPrinter boardPrinter,
            IBoardManager boardManager,
            IBoardGenerator boardGenerator,
            IActionParser actionParser,
            IScoreManager scoreManager,
            User.User user)
        {
            _boardPrinter   = boardPrinter;
            _boardManager   = boardManager;
            _boardGenerator = boardGenerator;
            _actionParser   = actionParser;
            _scoreManager   = scoreManager;
            _user           = user;

            _menuOptions = new StringBuilder()
                           .AppendLine("--------------------------")
                           .AppendLine("SELECT AN OPTION:")
                           .AppendLine("S X Y - Select a cell in the x,y position")
                           .AppendLine("F X Y - Flag a cell in the x,y position")
                           .AppendLine("E - Exit the game")
                           .AppendLine()
                           .ToString();
        }
Exemplo n.º 2
0
 public ActionService(IActionParser parser)
 {
     _parser = parser;
 }
Exemplo n.º 3
0
 public GameDataJsonFileReader(IActionParser parser, IList <string> interactionDirectories)
 {
     _parser = parser;
     _interactionDirectories = interactionDirectories;
 }
Exemplo n.º 4
0
 private Game GetGame(IAdventureRepository adventureRepo, IActionParser actionParser)
 {
     return(new Game(adventureRepo, actionParser));
 }
Exemplo n.º 5
0
 public Game(IAdventureRepository adventureRepository, IActionParser actionParser)
 {
     this.adventureRepository = adventureRepository;
     this.actionParser        = actionParser;
 }
Exemplo n.º 6
0
 public void SetUp()
 {
     _actionParser = new ActionParser();
 }