private void UpdateBankBalance() { int bankBalance = GamerPrefs.GetOkane(); bankBalance += okane; GamerPrefs.SetOkane(bankBalance); }
public void AddMoney() { int money = GamerPrefs.GetOkane(); money += 1; GamerPrefs.SetOkane(money); this.money.text = GamerPrefs.GetOkane().ToString(); }
public void UpgradeShield() { if (!(shieldDuration >= Shield_Duration_Cap)) { if (balance >= shildDurationUpgrCost) { balance -= shildDurationUpgrCost; shieldDuration += 2; GamerPrefs.SetShieldDuration(shieldDuration); GamerPrefs.SetOkane(balance); HandleOkaneBalance(); HandleShield(); } } }
public void UpgradeMaxLife() { if (!(maxLife >= Max_Life_Cap)) { if (balance >= maxLifeUpgrCost) { balance -= maxLifeUpgrCost; maxLife += 1; GamerPrefs.SetMaxLife(maxLife); GamerPrefs.SetOkane(balance); HandleOkaneBalance(); HandleMaxLife(); } } }
public void UpgradeTimeSlow() { if (!(timeSlow >= Time_Slow_Cap)) { if (balance >= timeSlowUpgrCost) { balance -= timeSlowUpgrCost; timeSlow += 2; GamerPrefs.SetSlowTimeDuration(timeSlow); GamerPrefs.SetOkane(balance); HandleOkaneBalance(); HandleTimeSlow(); } } }