Beispiel #1
0
    private void OnChangeMemberStatus(LoungeMemberStatus status)
    {
        //IL_006e: Unknown result type (might be due to invalid IL or missing references)
        int userId = status.userId;

        switch (status.GetStatus())
        {
        case LoungeMemberStatus.MEMBER_STATUS.QUEST_READY:
            if (status.isHost)
            {
                CreatePartyAnnounce(userId);
            }
            break;

        case LoungeMemberStatus.MEMBER_STATUS.QUEST:
        case LoungeMemberStatus.MEMBER_STATUS.FIELD:
        case LoungeMemberStatus.MEMBER_STATUS.ARENA:
            HomePeople.DestroyLoungePlayer(userId);
            break;

        case LoungeMemberStatus.MEMBER_STATUS.LOUNGE:
            SendRoomPosition(userId);
            NeedLoungeQuestBalloonUpdate = true;
            this.StartCoroutine(CreatePlayerOnChangedStatus(userId));
            break;
        }
    }
Beispiel #2
0
    private void DestoryMembersOnResume()
    {
        if (!(HomePeople == null) && HomePeople.loungePlayers != null)
        {
            for (int i = 0; i < HomePeople.loungePlayers.Count; i++)
            {
                int userId = HomePeople.loungePlayers[i].GetUserId();
                if (userId != 0)
                {
                    LoungeModel.SlotInfo slotInfoByUserId = MonoBehaviourSingleton <LoungeMatchingManager> .I.GetSlotInfoByUserId(userId);

                    if (slotInfoByUserId == null)
                    {
                        HomePeople.DestroyLoungePlayer(userId);
                    }
                    else if (MonoBehaviourSingleton <LoungeMatchingManager> .I.loungeMemberStatus != null)
                    {
                        LoungeMemberStatus loungeMemberStatus   = MonoBehaviourSingleton <LoungeMatchingManager> .I.loungeMemberStatus[userId];
                        LoungeMemberStatus.MEMBER_STATUS status = loungeMemberStatus.GetStatus();
                        if (status == LoungeMemberStatus.MEMBER_STATUS.QUEST || status == LoungeMemberStatus.MEMBER_STATUS.FIELD)
                        {
                            HomePeople.DestroyLoungePlayer(userId);
                        }
                    }
                }
            }
        }
    }
Beispiel #3
0
    public void OnRecvRoomLeaved(int id)
    {
        //IL_0064: Unknown result type (might be due to invalid IL or missing references)
        if (!(HomePeople == null))
        {
            if (HomePeople.DestroyLoungePlayer(id))
            {
                LoungeModel.SlotInfo slotInfoByUserId = MonoBehaviourSingleton <LoungeMatchingManager> .I.GetSlotInfoByUserId(id);

                SetAnnounce(new LoungeAnnounce.AnnounceData(LoungeAnnounce.ANNOUNCE_TYPE.LEAVED_LOUNGE, slotInfoByUserId.userInfo.name));
            }
            if (id != MonoBehaviourSingleton <UserInfoManager> .I.userInfo.id)
            {
                this.StartCoroutine(SendLoungeInfoForce());
            }
        }
    }
Beispiel #4
0
 public void OnRecvRoomKick(int id)
 {
     if (!(HomePeople == null))
     {
         if (MonoBehaviourSingleton <UserInfoManager> .I.userInfo.id == id)
         {
             EventData[] autoEvents = new EventData[2]
             {
                 new EventData("MAIN_MENU_LOUNGE", null),
                 new EventData("LOUNGE_KICKED", null)
             };
             MonoBehaviourSingleton <GameSceneManager> .I.SetAutoEvents(autoEvents);
         }
         else
         {
             HomePeople.DestroyLoungePlayer(id);
         }
     }
 }