/// <summary> /// 退出返回上一级 /// </summary> /// <param name="callback"></param> private void OnEsc(HotkeyCallback callback) { if (callback.performed) { MsgStarmapPanelState msg = new MsgStarmapPanelState(); msg.BeforeID = (ulong)m_Data.fixedStarId; UIManager.Instance.OpenPanel(UIPanel.StarGalaxyPanel, msg); } }
/// <summary> /// 星域点击事件 /// </summary> /// <param name="cell"></param> private void StarPointOnClick(StarmapPointElementBase cell) { m_CurrentCell = cell as StarGalaxyElement; MsgStarmapPanelState msg = new MsgStarmapPanelState(); msg.Data = m_CurrentCell.GetData(); m_CurrentCell = null; UIManager.Instance.OpenPanel(UIPanel.StarPlantPanel, msg); }
/// <summary> /// 返回上一级 /// </summary> /// <param name="callback"></param> private void OnEsc(HotkeyCallback callback) { if (callback.performed) { MsgStarmapPanelState msg = new MsgStarmapPanelState(); msg.Data = m_CfgStarmapProxy.GetFixedStarByTid(m_Data.fixedStarId); msg.BeforeID = m_Data.gamingmapId; UIManager.Instance.OpenPanel(UIPanel.StarPlantPanel, msg); } }
/// <summary> /// 行星点击事件 /// </summary> /// <param name="cell"></param> private void StarPointOnClick(StarmapPointElementBase cell) { if (m_Tweener != null) { return; } cell.SetToggleIsOn(false); m_CurrentPoint = cell as StarPlantElement; MsgStarmapPanelState msg = new MsgStarmapPanelState(); msg.Data = m_CurrentPoint.GetData(); m_CurrentPoint = null; m_Tweener = cell.transform.DOMove(CameraManager.GetInstance().GetUICameraComponent().transform.position, 1f).SetEase(Ease.OutCirc) .OnComplete( () => { m_Tweener = null; UIManager.Instance.OpenPanel(UIPanel.StarAreaPanel, msg); }); }