示例#1
0
        public virtual void GameLogic()
        {
            Console.WriteLine("Press ENTER TO START");
            Console.ReadLine();
            for (int i = 0; i < daysToPlay; i++)
            {
                ResetDailyValues();
                currentDayNo = i + 1;

                newDay.CreateDayWeather();
                newDay.GenerateCustomers(newDay.dayWeather);
                DisplayDayInventoryScreen();

                myStore.SellCups(player1);
                Console.Clear();
                DisplayDayInventoryScreen();

                myStore.SellLemons(player1);
                Console.Clear();
                DisplayDayInventoryScreen();

                myStore.SellSugar(player1);
                Console.Clear();
                DisplayDayInventoryScreen();

                myStore.SellIce(player1);
                Console.Clear();
                DisplayDayInventoryScreen();

                player1.CreateRecipe(myStore);
                Console.Clear();
                DisplayDayInventoryScreen();

                player1.SetCupPrice();
                Console.Clear();
                DisplayDayInventoryScreen();

                newDay.SellLemonade(player1);
                Console.WriteLine($"Total {newDay.customersDidBuy} customers bought your lemonade today");
                newDay.CalculateProfit(player1);
                DisplayDailyStats();
                Console.ReadLine();
            }
        }