AIsOfCatan.HumanAgent.BeforeDiceRoll C# (CSharp) Метод

BeforeDiceRoll() публичный Метод

public BeforeDiceRoll ( IGameState state, IGameActions actions ) : void
state IGameState
actions IGameActions
Результат void
        public void BeforeDiceRoll(IGameState state, IGameActions actions)
        {
            hasPlayedDevCard = false;
            if (!state.GetOwnDevelopmentCards().Any(dc => dc != DevelopmentCard.VictoryPoint))
                return; //No cards to play
            Console.WriteLine("Do you want to use a Development Card before roling the dice? Y/N");
            var r = Console.ReadLine() ?? "";
            if (!r.ToLower().StartsWith("y")) return;
            PlayDevelopmentCard(state, actions);
        }