void HideTop() { MenuTPs.duration = tpsDuration[1]; MenuTAs.duration = tasDuration[1]; MenuTPs.PlayReverse(); MenuTAs.PlayReverse(); MenuTPs.onFinished.Clear(); EventDelegate.Add(MenuTPs.onFinished, OnHideComplete); }
void ShowTop() { MenuTPs.duration = tpsDuration[0]; MenuTAs.duration = tasDuration[0]; MenuTPs.PlayForward(); MenuTAs.PlayForward(); MenuTPs.onFinished.Clear(); EventDelegate.Add(MenuTPs.onFinished, OnShowComplete); }
public override void Hide() { if (isShow) { OnHideStart(); isShow = false; MenuTPs.duration = tpsDuration[1]; MenuTAs.duration = tasDuration[1]; MenuTPs.PlayReverse(); MenuTAs.PlayReverse(); MenuTPs.onFinished.Clear(); EventDelegate.Add(MenuTPs.onFinished, OnHideComplete); EventDelegate.Execute(onHide); } }
public override void Show() { Debug.Log("Show" + gameObject.name); if (!isShow) { OnShowStart(); isShow = true; MenuTPs.duration = tpsDuration[0]; MenuTAs.duration = tasDuration[0]; MenuTPs.PlayForward(); MenuTAs.PlayForward(); MenuTPs.onFinished.Clear(); EventDelegate.Add(MenuTPs.onFinished, OnShowComplete); if (!gameObject.activeSelf) { NGUITools.SetActive(gameObject, true); } EventDelegate.Execute(onShow); } }
public override void Show() { Debug.Log("Show" + gameObject.name); if (!isShow) { current = GameController.Instance.currentMode; Debug.Log("Show" + GameController.Instance.currentMode.ToString()); GameController.Instance.ChangeStateTo(GameMode.Menu); OnShowStart(); isShow = true; MenuTPs.duration = tpsDuration[0]; MenuTAs.duration = tasDuration[0]; MenuTPs.PlayForward(); MenuTAs.PlayForward(); MenuTPs.onFinished.Clear(); EventDelegate.Add(MenuTPs.onFinished, OnShowComplete); if (!gameObject.activeSelf) { NGUITools.SetActive(gameObject, true); } EventDelegate.Execute(onShow); } }