using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; public class EggNum : MonoBehaviour { public Text eggNumText; public static EggNum instance; // Start is called before the first frame update void Awake() { instance = this; } public void SetEggNumText(float start) { StartCoroutine(Tools.AnimateText(start, PlayerInfo.instance.Money, 0.5f,eggNumText)); } }