Exemplo n.º 1
0
        public int PurchaseItems(Player player, Inventory inventory, Day day)
        {
            UserInterface.DisplayCashOnHand(player);
            int moneySpentOnLemons = SellLemons(player, inventory);

            UserInterface.DisplayCashOnHand(player);
            int moneySpentOnIce = SellIce(player, inventory);

            UserInterface.DisplayCashOnHand(player);
            int moneySpentOnSugar = SellSugar(player, inventory);

            UserInterface.DisplayCashOnHand(player);
            int moneySpentOnCups = SellCups(player, inventory);

            UserInterface.DisplayCashOnHand(player);
            day.totalPurchase = moneySpentOnCups + moneySpentOnIce + moneySpentOnLemons + moneySpentOnSugar;
            return(day.totalPurchase);
        }