Beispiel #1
0
 public void BuyCup(Player player, Pitcher pitcher, Inventory inventory)
 {
     player.cash += player.GetPrice();
     pitcher.AdjustFull(-10);
     inventory.UseCup();
     dailyIncome += player.GetPrice();
     Console.WriteLine("You made ${0} and your pitcher is {1}% full.", player.GetPrice(), pitcher.GetFull());
     Console.WriteLine("Current money: ${0}. Current number of cups: {1}\n", player.GetCash(), inventory.GetCups());
 }
Beispiel #2
0
 public void BuyCup(Player player, Pitcher pitcher, Inventory inventory)
 {
     player.cash += player.GetPrice();
     pitcher.AdjustFull(-10);
     inventory.RemoveCup();
     cashMakeFromSale       += player.GetPrice();
     Console.ForegroundColor = ConsoleColor.DarkCyan;
     Console.WriteLine("Yay! A customer just bought a cup of lemonade");
     Console.ResetColor();
     Console.ForegroundColor = ConsoleColor.Yellow;
     Console.WriteLine("You made ${0} and your pitcher of lemonade is {1}% left.\n", player.GetPrice(), pitcher.GetFull());
     Console.ResetColor();
 }