//----------------------------副本引导----------------------------------------------------------------------------------------------------------------------------- /// <summary> /// 副本引导UI /// </summary> void ShowFBGuideUI() { ComBatCopyDataManager copyMgr = DataManager.Manager <ComBatCopyDataManager>(); if (false == copyMgr.IsEnterCopy) { this.m_widget_copyGuide.gameObject.SetActive(false); return; } CopyDataBase copyDb = GameTableManager.Instance.GetTableItem <CopyDataBase>(copyMgr.EnterCopyID); if (copyDb == null) { return; } if (true == DataManager.Manager <ComBatCopyDataManager>().m_haveShowCopyGuide) { return; } DataManager.Manager <ComBatCopyDataManager>().m_haveShowCopyGuide = true; CopyTargetGuideDataBase ctGuideDb = GameTableManager.Instance.GetTableItem <CopyTargetGuideDataBase>(copyDb.guideId); if (ctGuideDb == null) { return; } this.m_widget_copyGuide.gameObject.SetActive(true); m_label_copyGuideDes.text = ctGuideDb.guideStr; StartCoroutine(DelayToCloseCopyGuide(ctGuideDb.time)); }
/// <summary> /// 通过[ID]二分快速查表 /// </summary> /// <param name="Id">ID</param> /// <returns></returns> public static CopyTargetGuideDataBase Query(this List <CopyTargetGuideDataBase> sorted, uint Id) { var key = new CopyTargetGuideDataBase() { Id = Id }; var comparer = new Comparer1(); var index = sorted.BinarySearch(key, comparer); return(index >= 0 ? sorted[index] : default(CopyTargetGuideDataBase)); }