예제 #1
0
        public bool OpenForm()
        {
            this._form = Singleton <CUIManager> .GetInstance().OpenForm(WatchForm.GetWatchFormName(), false, true);

            if (null == this._form)
            {
                return(false);
            }
            this._scoreHud = new WatchScoreHud(Utility.FindChild(this._form.gameObject, "ScoreBoard"));
            if (WatchForm.IsNeedShowCampMidInterface())
            {
                this._detailPanel       = this._form.GetWidget(0);
                this._camp1BaseList     = Utility.GetComponetInChild <CUIListScript>(this._detailPanel, "BaseInfoList1");
                this._camp1EquipList    = Utility.GetComponetInChild <CUIListScript>(this._detailPanel, "EquipInfoList1");
                this._camp2BaseList     = Utility.GetComponetInChild <CUIListScript>(this._detailPanel, "BaseInfoList2");
                this._camp2EquipList    = Utility.GetComponetInChild <CUIListScript>(this._detailPanel, "EquipInfoList2");
                this._camp1List         = Utility.FindChild(this._form.gameObject, "CampInfoList_1");
                this._camp2List         = Utility.FindChild(this._form.gameObject, "CampInfoList_2");
                this._camp1BaseSideList = Utility.GetComponetInChild <CUIListScript>(this._camp1List, "BaseInfoList");
                this._camp2BaseSideList = Utility.GetComponetInChild <CUIListScript>(this._camp2List, "BaseInfoList");
            }
            else
            {
                this._camp1List         = Utility.FindChild(this._form.gameObject, "CampInfoList_1");
                this._camp1BaseList     = Utility.GetComponetInChild <CUIListScript>(this._camp1List, "BaseInfoList");
                this._camp1EquipList    = Utility.GetComponetInChild <CUIListScript>(this._camp1List, "EquipInfoList");
                this._camp2List         = Utility.FindChild(this._form.gameObject, "CampInfoList_2");
                this._camp2BaseList     = Utility.GetComponetInChild <CUIListScript>(this._camp2List, "BaseInfoList");
                this._camp2EquipList    = Utility.GetComponetInChild <CUIListScript>(this._camp2List, "EquipInfoList");
                this._camp1BaseSideList = null;
                this._camp2BaseSideList = null;
            }
            this._hideBtn       = Utility.FindChild(this._form.gameObject, "PanelBtn/HideBtn");
            this._showBtn       = Utility.FindChild(this._form.gameObject, "PanelBtn/ShowBtn");
            this.competitionBtn = Utility.FindChild(this._form.gameObject, "PanelBtn/competitionBtn");
            this.competitionBtn.CustomSetActive(Singleton <WatchController> .GetInstance().CanShowActorIRPosMap());
            if (!WatchForm.IsNeedShowCampMidInterface())
            {
                this._heroInfoHud   = new HeroInfoHud(Utility.FindChild(this._form.gameObject, "HeroInfoHud"));
                this._replayControl = new ReplayControl(Utility.FindChild(this._form.gameObject, "ReplayControl"));
            }
            else
            {
                this._heroInfoHud   = null;
                this._replayControl = new ReplayControl(Utility.FindChild(this._form.gameObject, "PanelBtn"));
            }
            return(true);
        }
예제 #2
0
 public CUIFormScript LoadForm(CBattleSystem.FormType formType)
 {
     if (formType == CBattleSystem.FormType.Fight)
     {
         return(Singleton <CUIManager> .GetInstance().OpenForm(FightForm.s_battleUIForm, false, true));
     }
     if (formType == CBattleSystem.FormType.Watch)
     {
         if (Singleton <WatchController> .GetInstance().CanShowActorIRPosMap())
         {
             Singleton <CBattleStatCompetitionSystem> .GetInstance().PreLoadForm();
         }
         return(Singleton <CUIManager> .GetInstance().OpenForm(WatchForm.GetWatchFormName(), false, true));
     }
     return(null);
 }