Exemplo n.º 1
0
    public void Upgrade()
    {
        if (Currencies.Gold < price)
        {
            return;
        }

        Currencies.AddGold(-price);
        GameObject lvlUp = Instantiate(nextLvl, transform.position, transform.rotation);

        Destroy(gameObject);
        Selector.Deselect();
    }
Exemplo n.º 2
0
 public void AddGold(int amount)
 {
     Currencies.AddGold(amount);
 }
Exemplo n.º 3
0
 public void Sell()
 {
     Currencies.AddGold(price);
     Destroy(gameObject);
     Selector.Deselect();
 }