BottomTip.cs 345 B

12345678910111213141516171819
  1. using UnityEngine;
  2. using UnityEngine.UI;
  3. using System.Collections;
  4. public class BottomTip : MonoBehaviour {
  5. public Text textUI;
  6. public Animator animator;
  7. public void Show(string txt, bool newOne=true)
  8. {
  9. textUI.text = txt;
  10. if(newOne)
  11. animator.Play("BottomTipShow", 0, 0);
  12. else
  13. animator.Play("BottomTipChange", 0, 0);
  14. }
  15. }