public void EndGameGenerationTest()
        {
            Game     game  = new Game(new StartMenu());
            Robots   robot = new WorkingCreator().Create();
            GamePole pole  = new GamePole(game, robot);

            EndGame endGame = new EndGame(pole);

            Assert.AreEqual(endGame.pole, pole);
        }
        public void GameProcessGenerationTest()
        {
            Game        game        = new Game(new StartMenu());
            Robots      robot       = new WorkingCreator().Create();
            GamePole    pole        = new GamePole(game, robot);
            GameProcess gameProcess = new GameProcess(robot, pole);

            Assert.AreEqual(gameProcess.pole, pole);
            Assert.AreEqual(gameProcess.robot, robot);
            Assert.AreNotEqual(gameProcess.controller, null);
        }
Example #3
0
        public void GenerateNewGame()
        {
            Random rnd    = new Random();
            int    random = rnd.Next(10);

            if (random < 5)
            {
                Robot = new WorkingCreator().Create();
            }
            else if (random > 7)
            {
                Robot = new SmartCreator().Create();
            }
            else
            {
                Robot = new CyborgCreator().Create();
            }
            Console.WriteLine("Вам выпал робот: " + Robot.fullHero);
            //GamePole = new GamePole();
            GameHistory = new GameHistory();
            pole        = new GamePole(this, Robot);
        }
Example #4
0
 public void TestInitialize()
 {
     Robots Robot = new WorkingCreator().Create();
 }