| | |
| | | using UnityEngine; |
| | | using UnityEngine.UI; |
| | | |
| | | namespace Snxxz.UI { |
| | | namespace Snxxz.UI
|
| | | { |
| | | |
| | | public class UpgradeWin : Window |
| | | { |
| | | [SerializeField] UIAlphaTween m_UIAlphaTween;
|
| | | [SerializeField] ScaleTween m_ScaleTween;
|
| | | [SerializeField] UIAlphaTween m_UIAlphaTween1; |
| | | [SerializeField] GameObject m_Guang; |
| | | {
|
| | | [SerializeField] ScaleTween m_ScaleTween; |
| | | [SerializeField] Text m_TextLV; |
| | | [SerializeField] UIEffect m_UIEffect; |
| | | #region Built-in |
| | | protected override void BindController() |
| | | { |
| | |
| | | } |
| | | |
| | | protected override void OnPreOpen() |
| | | { |
| | | // m_Guang.SetActive(false); |
| | | m_TextLV.text = PlayerDatas.Instance.baseData.LV.ToString(); |
| | | m_UIAlphaTween1.SetEndState(); |
| | |
|
| | |
|
| | | {
|
| | | m_TextLV.text = PlayerDatas.Instance.baseData.LV.ToString();
|
| | | } |
| | | protected override void OnActived()
|
| | | {
|
| | | m_UIAlphaTween.Play(ShowOverAlpha);
|
| | | m_UIEffect.Play();
|
| | | m_UIEffect.OnComplete = () => { CloseImmediately(); };
|
| | | m_ScaleTween.Play();
|
| | | } |
| | | protected override void OnAfterOpen() |
| | | {
|
| | | |
| | | WindowCenter.Instance.windowBeforeCloseEvent += windowBeforeClose;
|
| | | PlayerDatas.Instance.PlayerDataRefreshInfoEvent += Updatefighting;//数据的刷新(h0418) |
| | | } |
| | | |
| | | protected override void OnPreClose() |
| | | {
|
| | | if (m_UIEffect.IsPlaying)
|
| | | {
|
| | | m_UIEffect.Stop();
|
| | | }
|
| | | WindowCenter.Instance.windowBeforeCloseEvent -= windowBeforeClose;
|
| | | PlayerDatas.Instance.PlayerDataRefreshInfoEvent -= Updatefighting;//数据的刷新(h0418) |
| | | }
|
| | |
|
| | | protected override void OnAfterClose() |
| | | { |
| | | }
|
| | | #endregion
|
| | | private void windowBeforeClose(Window _window)
|
| | | {
|
| | | if (_window is MainInterfaceWin)
|
| | |
| | | }
|
| | | }
|
| | |
|
| | | protected override void OnAfterClose() |
| | | { |
| | | }
|
| | | #endregion |
| | | private void ShowOverAlpha()
|
| | | {
|
| | | m_UIAlphaTween.Play(true);
|
| | | m_UIAlphaTween1.Play(true);
|
| | | } |
| | | } |
| | | |
| | | } |