Exemple #1
0
        /// <summary>
        /// The setup menu was clicked, perform the button's action.
        /// </summary>
        /// <param name="button">the button pressed</param>
        private static void PerformSetupMenuAction(int button)
        {
            switch (button)
            {
            case SETUP_MENU_EASY_BUTTON:
            {
                GameController.SetDifficulty(AIOption.Easy);
                break;
            }

            case SETUP_MENU_MEDIUM_BUTTON:
            {
                GameController.SetDifficulty(AIOption.Medium);
                break;
            }

            case SETUP_MENU_HARD_BUTTON:
            {
                GameController.SetDifficulty(AIOption.Hard);
                break;
            }
            }
            // Always end state - handles exit button as well
            GameController.EndCurrentState();
        }
Exemple #2
0
        /// <summary>
        /// The setup menu was clicked, perform the button's action.
        /// </summary>
        /// <param name="button">the button pressed</param>
        private static void PerformSetupMenuAction(int button)
        {
            switch (button)
            {
            //Easy difficulty button deleted. No AI for Easy. Reimplement if Easy Code is made.
//            case SETUP_MENU_EASY_BUTTON:
//                GameController.SetDifficulty(AIOption.Easy);
//                break;
            case SETUP_MENU_MEDIUM_BUTTON:
                GameController.SetDifficulty(AIOption.Medium);
                break;

            case SETUP_MENU_HARD_BUTTON:
                GameController.SetDifficulty(AIOption.Hard);
                break;
            }
            //Always end state - handles exit button as well
            GameController.EndCurrentState();
        }