using System; using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.EventSystems; using UnityEngine.UI; using System.Linq; using EnhancedUI.EnhancedScroller; namespace Snxxz.UI { public class RunePanel : OneLevelWin { RuneModel model { get { return ModelCenter.Instance.GetModel(); } } protected override void AddListeners() { base.AddListeners(); SetFunctionListener(0, OnRuneMosaic); SetFunctionListener(1, OnRuneBreak); SetFunctionListener(2, OnRuneMixture); } private void OnRuneMixture() { CloseSubWindows(); WindowCenter.Instance.Open(); functionOrder = 2; } private void OnRuneBreak() { CloseSubWindows(); WindowCenter.Instance.Open(); functionOrder = 1; } private void OnRuneMosaic() { CloseSubWindows(); WindowCenter.Instance.Open(); functionOrder = 0; } protected override void OnPreOpen() { model.onJumpToCompose += JumpToComposeEvent; } protected override void OnActived() { base.OnActived(); } protected override void OnAfterOpen() { } protected override void OnPreClose() { model.onJumpToCompose -= JumpToComposeEvent; CloseSubWindows(); } private void JumpToComposeEvent() { m_Group.TriggerByOrder(2); } } }