using System.Collections; using System.Collections.Generic; using UnityEngine; using DG.Tweening; using UnityEngine.UI; public class ToolTip : MonoBehaviour { Text text; private void OnEnable() { text = GetComponent(); //WaitClose(); Invoke("Close", 4); } void WaitClose() { text.DOColor(new Color(text.color.r, text.color.g, text.color.b, 0), 4); } void Close() { gameObject.SetActive(false); } }