예제 #1
0
        public static void OnRaidQueryFriend(ThriftSCMessage msg)
        {
            var themsg = msg.GetContent() as SCRaidQueryFriend;
            if (themsg != null)
            {
                //var e = new FriendEvent();
                //e.RaidFriend = themsg;
                //EventManager.Instance.Post(e);
                MissionModelLocator.Instance.FriendsMsg = themsg;

                if (HeroModelLocator.AlreadyRequest == false)
                {
                    HeroModelLocator.Instance.GetHeroPos = RaidType.GetHeroInBattle;
                    var csmsg = new CSHeroList();
                    NetManager.SendMessage(csmsg);
                }
                else
                {
                    WindowManager.Instance.Show(typeof(SetBattleWindow), true);
                    WindowManager.Instance.Show<RaidsWindow>(false);
                }
            }
            else
            {
                PopTextManager.PopTip("返回战斗的数据错误");
            }
        }
예제 #2
0
    private void OnFriendSelected(GameObject obj)
    {
        var control = obj.GetComponent<FriendItemControl>();

        MissionModelLocator.Instance.FriendData = control.FriendData;
        if (HeroModelLocator.AlreadyRequest == false)
        {
            HeroModelLocator.Instance.GetHeroPos = RaidType.GetHeroInBattle;
            var csmsg = new CSHeroList();
            NetManager.SendMessage(csmsg);
        }
        else
        {
            WindowManager.Instance.Show(typeof(BattleConfirmTabWindow), true);
        }
        MissionModelLocator.Instance.MissionStep = RaidType.StepConfirm;
    }
예제 #3
0
 public static void OpenHeroWin()
 {
     if (HeroModelLocator.AlreadyRequest == false)
     {
         HeroModelLocator.Instance.GetHeroPos = RaidType.GetHeroInHeroPanel;
         var csmsg = new CSHeroList();
         NetManager.SendMessage(csmsg);
     }
     else
     {
         WindowManager.Instance.Show<UIHeroCommonWindow>(true);
     }
 }
예제 #4
0
 private void ToHeroHandler(GameObject obj)
 {
     WindowManager.Instance.Show(WindowGroupType.Popup, false);
     if (HeroModelLocator.AlreadyRequest == false)
     {
         HeroModelLocator.Instance.GetHeroPos = RaidType.GetHeroInHeroPanel;
         var csmsg = new CSHeroList();
         NetManager.SendMessage(csmsg);
     }
     else
     {
         WindowManager.Instance.Show<UIHeroCommonWindow>(true);
     }
 }