Esempio n. 1
0
        public void InteractionMessages(int interactionCountOneOne, int interactionCountOneTwo, int interactionCountTwoOne, int interactionCountTwoTwo,
                                        string interactionMessageOne, string interactionMessageTwo, string countMessageOne, string countMessageTwo)
        {
            Console.SetCursorPosition(interactionMessageOne.Length, TheCity.GetUpperBound(0) + 1);
            Console.Write($"{countMessageOne}{interactionCountOneTwo}");
            Console.SetCursorPosition(interactionMessageTwo.Length, TheCity.GetUpperBound(0) + 2);
            Console.Write($"{countMessageTwo}{interactionCountTwoTwo}");

            Thread.Sleep(100);

            InteractionMessages(interactionCountOneOne, interactionCountOneTwo, interactionMessageOne, countMessageOne.Length, 1);
            InteractionMessages(interactionCountTwoOne, interactionCountTwoTwo, interactionMessageTwo, countMessageTwo.Length, 2);
        }
Esempio n. 2
0
        public string DrawCity()
        {
            string str = "";

            for (int row = 0; row <= TheCity.GetUpperBound(0); row++)
            {
                for (int column = 0; column <= TheCity.GetUpperBound(1); column++)
                {
                    str += TheCity[row, column];
                }

                str += "\n";
            }

            return(str);
        }
Esempio n. 3
0
        void InteractionMessages(int countOne, int countTwo, string interactionMessage, int countMessageLength, int row)
        {
            for (int counter = 1; counter <= countOne; counter++)
            {
                Console.SetCursorPosition(0, TheCity.GetUpperBound(0) + row);
                Console.Write(interactionMessage);

                Console.SetCursorPosition(interactionMessage.Length + countMessageLength, TheCity.GetUpperBound(0) + row);
                Console.Write(countTwo + counter);

                Thread.Sleep(2000);

                Console.SetCursorPosition(0, TheCity.GetUpperBound(0) + row);
                Console.Write(new string(' ', interactionMessage.Length));
                Thread.Sleep(100);
            }
        }