Пример #1
0
 public void BuyFuel()
 {
     if (currentMoney >= fuelCost)
     {
         SoundManager.PlaySound(SoundManager.Sound.Buy);
         currentMoney   -= fuelCost;
         moneyText.text  = currentMoney.ToString();
         fuelCost        = fuelCost * 5;
         fuelUpText.text = "$ " + fuelCost.ToString();
         fuelManager.UpgradeFuel();
     }
     else
     {
         StartCoroutine(MoneyWarning(warning2Text));
     }
 }