Пример #1
0
        // Здесь можно изучить одно из заклинаний
        private void Libriary(Player player)
        {
            HelloPlayer(player);
            PrintForShops();
            for (int i = 0; i < Program.Spells.Count; i++)
            {
                WriteCharacteristics(Program.Spells[i].GetCharacteristics(true, RealCosts["spell"]));
                switch (Console.ReadKey(true).Key)
                {
                case ConsoleKey.Y:
                    if (player.LearnSpell(Program.Spells[i], RealCosts["spell"]))
                    {
                        Console.WriteLine("Вы изучили {0}", Program.Spells[i].Name);
                    }
                    return;

                case ConsoleKey.Escape:
                    return;
                }
                Console.Clear();
            }
        }