Ejemplo n.º 1
0
 private void ClickToRecharge(GameObject go)
 {
     Singleton <ShopView> .Instance.ThroughShop = ETypicalShop.Recharge;
     CtrlManager.OpenWindow(WindowID.ShopViewNew, null);
     CtrlManager.CloseWindow(WindowID.MenuBottomBarView);
     this.CloseThisWindow(null);
 }
Ejemplo n.º 2
0
 private void CloseView(GameObject obj)
 {
     if (null != obj)
     {
         CtrlManager.CloseWindow(WindowID.TrumpetView);
     }
 }
Ejemplo n.º 3
0
        public override void RegisterUpdateHandler()
        {
            CtrlManager.CloseWindow(WindowID.MenuBottomBarView);
            Singleton <MenuTopBarView> .Instance.DoOpenOtherViewAction(0.25f);

            this.RefreshUI();
        }
Ejemplo n.º 4
0
        private void OnClick_ShowGoodsPackage(GameObject obj = null)
        {
            CtrlManager.OpenWindow(WindowID.PurchasePopupView, null);
            Singleton <PurchasePopupView> .Instance.onSuccess.Add(delegate
            {
                CtrlManager.CloseWindow(WindowID.HomePayView);
            });

            if (this.Pack1.gameObject.activeInHierarchy)
            {
                Singleton <PurchasePopupView> .Instance.Show(ETypicalCommodity.NewbieHeroGiftPackage, false);
            }
            else if (this.Pack2.gameObject.activeInHierarchy)
            {
                Singleton <PurchasePopupView> .Instance.Show(ETypicalCommodity.LuxuriousHeroGiftPackage, false);
            }
            else if (this.Pack3.gameObject.activeInHierarchy)
            {
                Singleton <PurchasePopupView> .Instance.Show(ETypicalCommodity.NewYearGiftPackage, false);
            }
            else
            {
                CtrlManager.CloseWindow(WindowID.PurchasePopupView);
            }
        }
Ejemplo n.º 5
0
 public override void HandleAfterOpenView()
 {
     AutoTestController.InvokeTestLogic(AutoTestTag.Home, delegate
     {
         CtrlManager.CloseWindow(WindowID.AnnouncementView);
     }, 1f);
 }
Ejemplo n.º 6
0
 public override void RegisterUpdateHandler()
 {
     CtrlManager.CloseWindow(WindowID.MenuBottomBarView);
     this.Hidden(false);
     MobaMessageManager.RegistMessage((ClientMsg)21049, new MobaMessageFunc(this.OnClickArrow));
     MobaMessageManager.RegistMessage((ClientMsg)21046, new MobaMessageFunc(this.OnChangeNPC));
 }
 private void CloseWindow(GameObject obj)
 {
     if (null != obj)
     {
         MobaMessageManagerTools.SendClientMsg(ClientV2C.coalesceviewCloseView, null, false);
         CtrlManager.CloseWindow(WindowID.SynthesisPopupView);
     }
 }
Ejemplo n.º 8
0
 public void CloseViewClick(GameObject obj)
 {
     if (this.canClick)
     {
         this.canClick = false;
         CtrlManager.CloseWindow(WindowID.UnlockView);
         this.text_str = string.Empty;
         this.CheckShowType();
     }
 }
Ejemplo n.º 9
0
 private void AddDiamond(GameObject objct_1 = null)
 {
     if (!Singleton <ShopView> .Instance.IsOpen)
     {
         Singleton <ShopView> .Instance.ThroughShop = ETypicalShop.Recharge;
         CtrlManager.OpenWindow(WindowID.ShopViewNew, null);
         CtrlManager.CloseWindow(WindowID.MenuBottomBarView);
     }
     else
     {
         Singleton <ShopView> .Instance.SetShopType(6);
     }
 }
Ejemplo n.º 10
0
 private void ClickCloseRuneView(GameObject obj)
 {
     if (null != obj)
     {
         if (null != Singleton <PropertyView> .Instance.transform && Singleton <PropertyView> .Instance.gameObject.activeInHierarchy)
         {
             MobaMessageManagerTools.SendClientMsg(ClientV2C.propviewInitToggle, PropertyType.Info, false);
             MobaMessageManagerTools.SendClientMsg(ClientV2C.propviewChangeToggle, PropertyType.Info, false);
             MobaMessageManagerTools.SendClientMsg(ClientV2C.runesviewCloseView, null, false);
         }
         CtrlManager.CloseWindow(WindowID.RunesOverView);
     }
 }
Ejemplo n.º 11
0
 public override void Init()
 {
     base.Init();
     this.TitleLabel = this.transform.Find("Anchor/Panel/Title").GetComponent <UILabel>();
     this.proxy      = this.transform.GetComponent <AwardViewContainer>();
     this.sample     = this.proxy.rewardItem;
     UIEventListener.Get(this.proxy.buttonGetAward.gameObject).onClick = delegate
     {
         CtrlManager.CloseWindow(WindowID.AwardView);
         if (this.onClose != null)
         {
             this.onClose();
         }
     };
 }
Ejemplo n.º 12
0
 private void OpenWaitingView(bool b)
 {
     if (b)
     {
         if (!Singleton <NewWaitingView> .Instance.IsOpened)
         {
             CtrlManager.OpenWindow(WindowID.NewWaitingView, null);
         }
         this.RefreshWaitingViewText();
     }
     else if (Singleton <NewWaitingView> .Instance.IsOpened)
     {
         CtrlManager.CloseWindow(WindowID.NewWaitingView);
     }
 }
Ejemplo n.º 13
0
        private void SucceedInCreatingCount()
        {
            ModelManager.Instance.Get_userData_X().LoginCount++;
            if (GlobalSettings.isLoginByHoolaiSDK)
            {
                InitSDK.instance.SetExtData("3");
                AnalyticsToolManager.Register(ModelManager.Instance.Get_accountData_X().AccountId);
            }
            else if (GlobalSettings.isLoginByAnySDK)
            {
                InitSDK.instance.SetAnySDKExtData("2");
            }
            Singleton <MenuTopBarView> .Instance.RefreshUI();

            CtrlManager.CloseWindow(WindowID.SummonerRegisterView);
            NewbieManager.Instance.TryProcessNewbieGuide();
        }
        private void ClickSkillItem(GameObject obj = null)
        {
            if (!this.skillObjDict[obj.name].IsCanChoice())
            {
                CtrlManager.CloseWindow(WindowID.TipView);
                Singleton <TipView> .Instance.SetText("技能还未解锁", 0f);

                CtrlManager.OpenWindow(WindowID.TipView, null);
                return;
            }
            this.ShowSkillData(obj.name);
            if (this.clickSkillCallBack != null)
            {
                this.clickSkillCallBack(obj.name);
            }
            CtrlManager.CloseWindow(WindowID.PvpChoiceSkillView);
        }
Ejemplo n.º 15
0
 private void GoToRank(GameObject go)
 {
     if (this.skipPage == "1")
     {
         Singleton <RankView> .Instance.selectBtn = "Ladder";
     }
     else if (this.skipPage == "2")
     {
         Singleton <RankView> .Instance.selectBtn = "MagicBottle";
     }
     else
     {
         Singleton <RankView> .Instance.selectBtn = "Charming";
     }
     CtrlManager.OpenWindow(WindowID.RankView, null);
     CtrlManager.CloseWindow(WindowID.MenuBottomBarView);
 }
Ejemplo n.º 16
0
 private void OnResetBtn(GameObject go)
 {
     if (LevelManager.Instance.CheckSceneIsTest())
     {
         if (LevelManager.Instance.IsServerZyBattleType)
         {
             return;
         }
         GameObject gameObject = GameObject.FindGameObjectWithTag("Player");
         if (gameObject != null)
         {
             Units       component = gameObject.GetComponent <Units>();
             UtilCounter counter   = UtilManager.Instance.GetCounter(UtilType.Exp);
             ExpValue    expValue  = counter.GetValue(PlayerControlMgr.Instance.GetPlayer().unique_id) as ExpValue;
             expValue.AddExp(-expValue.CurExp);
             component.skillManager.SkillPointsLeft = 0;
             for (int i = 0; i < 4; i++)
             {
                 List <SkillDataKey> skillsByIndex = component.getSkillsByIndex(i);
                 if (skillsByIndex != null)
                 {
                     for (int j = 0; j < skillsByIndex.Count; j++)
                     {
                         skillsByIndex[j] = new SkillDataKey(skillsByIndex[j].SkillID, 0, skillsByIndex[j].Skin);
                         Skill skillById = component.getSkillById(skillsByIndex[j].SkillID);
                         if (skillById != null)
                         {
                             skillById.SetLevel(0);
                         }
                     }
                 }
             }
             SkillCounter skillCounter = UtilManager.Instance.GetCounter(UtilType.Skill) as SkillCounter;
             skillCounter.OnHeroLevelup(component, 0);
             component.level = 1;
             component.UpLevel();
             CtrlManager.CloseWindow(WindowID.SkillView);
             CtrlManager.OpenWindow(WindowID.SkillView, null);
         }
     }
 }
Ejemplo n.º 17
0
        private void ShowResult()
        {
            if (GameManager.Instance == null)
            {
                return;
            }
            SurrenderMgr surrenderMgr = GameManager.Instance.SurrenderMgr;

            if (surrenderMgr == null)
            {
                return;
            }
            int num = Mathf.CeilToInt((float)surrenderMgr.ValidVoters * 0.7f);

            if (num <= surrenderMgr.AcceptCount)
            {
                CtrlManager.CloseWindow(WindowID.SurrenderView);
                return;
            }
            this._comps.ShowVotePanel(false);
            this._comps.ShowResultPanel(true);
            string resultText  = string.Empty;
            int    acceptCount = surrenderMgr.AcceptCount;
            int    num2        = surrenderMgr.Votes - surrenderMgr.AcceptCount;
            int    num3        = surrenderMgr.OurTeamCount - surrenderMgr.Votes;
            string format      = "投票结果{0}票同意 {1}票拒绝 {2}票弃权 投降失败";

            resultText = string.Format(format, acceptCount, num2, num3);
            this._comps.SetResultText(resultText);
            if (this._closeTask == null)
            {
                this._closeTask           = new Task(this.TimerEnumerator(4f), false);
                this._closeTask.Finished += delegate(bool manual)
                {
                    this._closeTask = null;
                    CtrlManager.CloseWindow(WindowID.SurrenderView);
                };
                this._closeTask.Start();
            }
        }
Ejemplo n.º 18
0
        public override void HandleAfterOpenView()
        {
            this.clickCd = false;
            SendMsgManager.Instance.SendMsg(MobaGameCode.DealGameReport, null, new object[0]);
            if (Singleton <MenuBottomBarView> .Instance.IsOpen)
            {
                CtrlManager.CloseWindow(WindowID.MenuBottomBarView);
            }
            if (PvpMatchMgr.State == PvpMatchState.Matching)
            {
                this.ShowMatchingFrame();
            }
            else if (PvpMatchMgr.State == PvpMatchState.Matched)
            {
                this.ShowMatchingFrame();
            }
            PvpLevelStorage.DispatchChooseGameMsg();
            bool flag = CharacterDataMgr.instance.GetUserLevel(ModelManager.Instance.Get_userData_X().Exp) >= BaseDataMgr.instance.GetDataById <SysBattleSceneVo>("80006").scene_limit_level;

            this._daluandou.FindChild("Lock").gameObject.SetActive(!flag);
            this._daluandou.GetComponent <BoxCollider>().enabled = flag;
            if (flag)
            {
                this._task_timeLock = this._timeLockCMgr.StartCoroutine(this.RankTimeLock(), true);
            }
            this._timeLockCMgr.StartCoroutine(this.RankSeasonLock(), true);
            bool flag2 = CharacterDataMgr.instance.GetUserLevel(ModelManager.Instance.Get_userData_X().Exp) >= BaseDataMgr.instance.GetDataById <SysBattleSceneVo>("80021").scene_limit_level;

            this._jbs.FindChild("Lock").gameObject.SetActive(!flag2);
            this._jbs.GetComponent <BoxCollider>().enabled = flag2;
            if (flag2)
            {
                this._timeLockCMgr.StartCoroutine(this.LeagueTimeLock(), true);
            }
            AutoTestController.InvokeTestLogic(AutoTestTag.EnterPvp, delegate
            {
                this.ClickFightWithRobot(null);
            }, 1f);
        }
Ejemplo n.º 19
0
 private void OnClickPlay(GameObject go)
 {
     CtrlManager.CloseWindow(WindowID.PvpWaitView);
     PvpMatchMgr.Instance.ForceSelectHero();
 }
Ejemplo n.º 20
0
 private void Click_CloseView(GameObject go)
 {
     CtrlManager.CloseWindow(WindowID.ChangeAvatarView);
 }
Ejemplo n.º 21
0
 private void OnBtnCancel(GameObject button = null)
 {
     CtrlManager.CloseWindow(WindowID.NewPopView);
     this.Func_CallBack(EPopViewRet.eCancel);
 }
Ejemplo n.º 22
0
 public void CloseViewWait()
 {
     CtrlManager.CloseWindow(WindowID.TipView);
 }
Ejemplo n.º 23
0
 private void SystemBackButton_Event(GameObject Object_1 = null)
 {
     CtrlManager.CloseWindow(WindowID.SystemSettingView);
 }
Ejemplo n.º 24
0
 private void SystemBlackList_Event(GameObject Object_1 = null)
 {
     CtrlManager.CloseWindow(WindowID.SystemSettingView);
     CtrlManager.OpenWindow(WindowID.BlackListView, null);
 }
Ejemplo n.º 25
0
 private void OnClickPause(GameObject go)
 {
     CtrlManager.CloseWindow(WindowID.PvpWaitView);
     Singleton <MenuTopBarView> .Instance.TryShowTimeTips();
 }
Ejemplo n.º 26
0
 private void Close()
 {
     CtrlManager.CloseWindow(WindowID.ActivityView);
     Singleton <MenuView> .Instance.CheckActivityState();
 }
Ejemplo n.º 27
0
 private void OnCloseBtn(GameObject go)
 {
     CtrlManager.CloseWindow(WindowID.DetailsInfo);
 }
Ejemplo n.º 28
0
 private void OnBtnOk(GameObject obj = null)
 {
     CtrlManager.CloseWindow(WindowID.NewPopView);
     this.Func_CallBack(EPopViewRet.eOk);
 }
Ejemplo n.º 29
0
 private void CloseTheView(GameObject obj = null)
 {
     CtrlManager.CloseWindow(WindowID.LevelupView);
 }
 private void ClickBackBtn(GameObject obj = null)
 {
     CtrlManager.CloseWindow(WindowID.PvpChoiceSkillView);
 }