Exemple #1
0
        public GameBoardDrawerTest()
        {
            shootCheckerMock = new Mock <IShootChecker>();
            shootCheckerMock
            .Setup(x => x.CheckShot(It.IsAny <Point>(), It.IsAny <IList <GeneratedShip> >(), It.IsAny <IList <Point> >()))
            .Returns(ShootResult.WrongShoot);

            target = new GameBoardDrawer(shootCheckerMock.Object);
        }
Exemple #2
0
        private void DrawGameBoard()
        {
            GameBoardDrawer gameBoardDrawer = new GameBoardDrawer()
            {
                GridToBeDrawnOn = GameBoardGrid,
                ImageCards      = _imageCards,
                CardDeck        = CardDeck,
                NumberOfColumns = 5
            };

            gameBoardDrawer.Draw();
            gameBoardDrawer.SetEventOnCardClicked(GetClickedCard);
        }