Exemplo n.º 1
0
        //Action takes user input to perform an action.
        public static void Action()
        {
            Console.WriteLine("Please choose your action: \n--------------------------");
            Console.WriteLine("1: Move " +
                              "\n2: Shoot" +
                              "\n3: Note" +
                              "\n4: Trace" +
                              "\n5: Cheat" +
                              "\n--------------------------");
            string ActionInput = Console.ReadLine();

            Console.WriteLine();
            switch (ActionInput)
            {
            case "1":
                MoveMenu();
                GameState = Map.Move(size);
                break;

            case "2":
                ShootMenu();
                GameState = Map.Shoot(size);
                break;

            case "3":
                Map.Note(size);
                Console.WriteLine("enter any charater to get back in action");
                Console.ReadLine();
                Update();
                break;

            case "4":
                Map.Trace(size);
                Console.WriteLine("enter any charater to get back in action");
                Console.ReadLine();
                Update();
                break;

            case "5":
                Map.Cheat(size);
                Console.WriteLine("enter any charater to get back in action");
                Console.ReadLine();
                Update();
                break;

            default:
                Console.Clear();
                Update();
                break;
            }
        }