Esempio n. 1
0
        public void Show()
        {
            if (null == this._root)
            {
                return;
            }
            CUIFormScript statViewFormScript = this.m_statViewFormScript;

            if (statViewFormScript == null)
            {
                return;
            }
            statViewFormScript.Appear(enFormHideFlag.HideByCustom, true);
            if (this.list != null)
            {
                this.list.SelectElement(-1, true);
                this.list.SelectElement(this._defaultSelectIndex, true);
            }
            this.SortHeroAndPlayer();
            this.UpdateBattleState(null);
            this.UpdateKDAView();
            Singleton <CUIEventManager> .GetInstance().AddUIEventListener(enUIEventID.Battle_ReviveTimeChange, new CUIEventManager.OnUIEventHandler(this.UpdateBattleState));

            Singleton <EventRouter> .GetInstance().AddEventHandler <PoolObjHandle <ActorRoot>, int>("HeroSoulLevelChange", new Action <PoolObjHandle <ActorRoot>, int>(this.onSoulLvlChange));

            this.RefreshVoiceStateIfNess();
            Singleton <CUIParticleSystem> .get_instance().Hide(null);
        }
Esempio n. 2
0
    public static string ShowFormBattle()
    {
        CUIFormScript form = Singleton <CUIManager> .get_instance().GetForm(FightForm.s_battleUIForm);

        if (form != null)
        {
            form.gameObject.CustomSetActive(true);
            form.Appear(enFormHideFlag.HideByCustom, true);
            return("已恢复");
        }
        return("不在战斗中");
    }
Esempio n. 3
0
        public override void Process(AGE.Action _action, Track _track)
        {
            if (this.bIncludeBattleUi)
            {
                CUIFormScript formScript = Singleton <CBattleSystem> .GetInstance().m_FormScript;

                if (formScript != null)
                {
                    if (this.bOpenOrClose)
                    {
                        formScript.Appear();
                        if (GameSettings.EnableOutline)
                        {
                            Transform transform = Camera.main.transform.Find(Camera.main.name + " particles");
                            if (null != transform)
                            {
                                Camera component = transform.GetComponent <Camera>();
                                if (null != component)
                                {
                                    string[] layerNames = new string[] { "3DUI" };
                                    component.cullingMask |= LayerMask.GetMask(layerNames);
                                }
                            }
                        }
                        else
                        {
                            Camera   main       = Camera.main;
                            string[] textArray2 = new string[] { "3DUI" };
                            main.cullingMask |= LayerMask.GetMask(textArray2);
                        }
                    }
                    else
                    {
                        formScript.Hide(true);
                        if (GameSettings.EnableOutline)
                        {
                            Transform transform2 = Camera.main.transform.Find(Camera.main.name + " particles");
                            if (null != transform2)
                            {
                                Camera camera2 = transform2.GetComponent <Camera>();
                                if (null != camera2)
                                {
                                    string[] textArray3 = new string[] { "3DUI" };
                                    camera2.cullingMask &= ~LayerMask.GetMask(textArray3);
                                }
                            }
                        }
                        else
                        {
                            Camera   camera3    = Camera.main;
                            string[] textArray4 = new string[] { "3DUI" };
                            camera3.cullingMask &= ~LayerMask.GetMask(textArray4);
                        }
                    }
                }
            }
            if (this.bIncludeBattleHero)
            {
                CUIFormScript script2 = Singleton <CBattleHeroInfoPanel> .GetInstance().m_FormScript;

                if (script2 != null)
                {
                    if (this.bOpenOrClose)
                    {
                        script2.Appear();
                    }
                    else
                    {
                        script2.Hide(true);
                    }
                }
            }
            if (this.bIncludeFpsForm)
            {
                CUIFormScript form = Singleton <CUIManager> .GetInstance().GetForm(CUICommonSystem.FPS_FORM_PATH);

                if (form != null)
                {
                    if (this.bOpenOrClose)
                    {
                        form.Appear();
                    }
                    else
                    {
                        form.Hide(true);
                    }
                }
            }
        }
Esempio n. 4
0
        public override void Process(AGE.Action _action, Track _track)
        {
            if (this.bIncludeBattleUi)
            {
                CUIFormScript fightFormScript = Singleton <CBattleSystem> .GetInstance().FightFormScript;

                if (fightFormScript != null)
                {
                    if (this.bOpenOrClose)
                    {
                        fightFormScript.Appear(enFormHideFlag.HideByCustom, true);
                        if (GameSettings.EnableOutline)
                        {
                            Transform transform = Camera.main.transform.Find(Camera.main.name + " particles");
                            if (null == transform)
                            {
                            }
                        }
                    }
                    else
                    {
                        fightFormScript.Hide(enFormHideFlag.HideByCustom, true);
                        if (GameSettings.EnableOutline)
                        {
                            Transform transform2 = Camera.main.transform.Find(Camera.main.name + " particles");
                            if (null == transform2)
                            {
                            }
                        }
                    }
                }
            }
            if (this.bIncludeBattleHero)
            {
                CUIFormScript formScript = Singleton <CBattleHeroInfoPanel> .GetInstance().m_FormScript;

                if (formScript != null)
                {
                    if (this.bOpenOrClose)
                    {
                        formScript.Appear(enFormHideFlag.HideByCustom, true);
                    }
                    else
                    {
                        formScript.Hide(enFormHideFlag.HideByCustom, true);
                    }
                }
            }
            if (this.bIncludeFpsForm)
            {
                CUIFormScript form = Singleton <CUIManager> .GetInstance().GetForm(CUICommonSystem.FPS_FORM_PATH);

                if (form != null)
                {
                    if (this.bOpenOrClose)
                    {
                        form.Appear(enFormHideFlag.HideByCustom, true);
                    }
                    else
                    {
                        form.Hide(enFormHideFlag.HideByCustom, true);
                    }
                }
            }
        }