Ejemplo n.º 1
0
        public static void DisplayCategories(ScoreCard scoreCard, List <int> diceCup)
        {
            Console.Write("Categories:\n");
            foreach (var category in scoreCard.CategoryScoreCard)
            {
                if (category.IsUsed)
                {
                    Console.ForegroundColor = ConsoleColor.Red;
                    Console.WriteLine(category.ToString());
                    Console.ResetColor();
                }
                else
                {
                    Console.WriteLine(
                        $"{category.CategoryKey}) {category.CategoryName}: {ScoreCalculator.CalculateScore(diceCup, category.CategoryKey)}");
                }
            }

            Console.Write("\n");
        }