예제 #1
0
        public void MainMenuAction(Day day, Player player, Booth lemonadeStand)
        {
            switch (mainMenuOutput)
            {
            case 1:
                // view inventory
                player.DisplayInventory();
                break;

            case 2:
                // purchase inventory
                player.DisplayInventory();
                player.AskForPurchase(player);
                break;

            case 3:
                // set recipe
                lemonadeStand.pitcher.recipe.SetRecipe(player.inventory);
                player.inventory.SetPricePerGlassSold();
                player.inventory.CheckRecipeIngredientsInventory(lemonadeStand.pitcher.recipe);
                lemonadeStand.OpenBooth();
                break;

            case 4:
                // print sales report
                DisplayMainMenu(day, player);
                break;

            case 5:
                //clear console
                Console.Clear();
                DisplayMainMenu(day, player);
                break;

            default:
                Console.WriteLine("\nPlease select from the available options!");
                DisplayMainMenu(day, player);
                break;
            }
        }