heiheiheiWindow.cs 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. using UnityEngine;
  2. using System.Collections;
  3. public class heiheiheiWindow : UIWindowBase
  4. {
  5. //UI的初始化请放在这里
  6. public override void OnInit()
  7. {
  8. }
  9. //请在这里写UI的更新逻辑,当该UI监听的事件触发时,该函数会被调用
  10. public override void OnRefresh()
  11. {
  12. }
  13. //UI的进入动画
  14. public override IEnumerator EnterAnim(UIAnimCallBack l_animComplete, UICallBack l_callBack, params object[] objs)
  15. {
  16. AnimSystem.UguiAlpha(gameObject, null, 1, callBack:(object[] obj)=>
  17. {
  18. StartCoroutine(base.EnterAnim(l_animComplete, l_callBack, objs));
  19. });
  20. yield return new WaitForEndOfFrame();
  21. }
  22. //UI的退出动画
  23. public override IEnumerator ExitAnim(UIAnimCallBack l_animComplete, UICallBack l_callBack, params object[] objs)
  24. {
  25. AnimSystem.UguiAlpha(gameObject , null, 0, callBack:(object[] obj) =>
  26. {
  27. StartCoroutine(base.ExitAnim(l_animComplete, l_callBack, objs));
  28. });
  29. yield return new WaitForEndOfFrame();
  30. }
  31. }