using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class Moneyplus : MonoBehaviour
{
private int money = 0;
public Text moneyText;
public static int rate = 1;
public GameObject ui, upgrade;
public System.Int32 GetMoney()
{
return money;
}
public void SetMoney(int value)
{
money = value;
}
public void UpgradeWindow()
{
ui.SetActive(false);
upgrade.SetActive(true);
}
public void Click() => SetMoney(GetMoney() + rate);
public void FixedUpdate() => moneyText.text = GetMoney().ToString() + "$";
}
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;
public class Moneyplus : MonoBehaviour
{
private int money = 0;
public Text moneyText;
public static int rate = 1;
public GameObject ui, upgrade;
public System.Int32 GetMoney()
{
return money;
}
public void SetMoney()
{
money = int;
}
public void UpgradeWindow()
{
ui.SetActive(false);
upgrade.SetActive(true);
}
public void Click() => SetMoney(GetMoney() + rate.ToInt);
public void FixedUpdate() => moneyText.text = GetMoney().ToString() + "$";
}