Exemple #1
0
        public override int Play(out Team Winner)
        {
            bool firstPlayer = true;

            Winner = Game.Teams.OrderByDescending(t => t.Score).Take(1).Single();
            Game.SetActiveTeam(Winner);

            CurrentQuiz = new Quiz();

            for (int stage = 0; stage < 2; stage++)
            {
                firstPlayer = stage == 0;

                Game.RequestIn($"{(firstPlayer ? "Первому" : "Второму")} игроку приготовиться к запуску таймера!");
                foreach (var answer in CurrentQuiz)
                {
                    Game.RequestOut($"[{answer.Index}] {answer.Text}");
                }

                //Game.StartTimer();
                Game.InstantSignaling();
                Game.Blackboard();

                for (int index = 0; index < 5; index++)
                {
                    Answer answer = requestAnswer();
                    answer.IsLeft = firstPlayer;
                    CurrentQuiz.AddAnswer(answer);
                    Game.Open(answer);
                    Score += answer.Score;
                    Game.SetRoundScore();
                }

                if (firstPlayer)
                {
                    Game.RequestIn($"Нажмите Enter чтобы закрыть табло и повозите второго игрока!");
                    Game.ShowTitle();
                }
            }

            return(0);
        }