Esempio n. 1
0
        public void SetFriendGameState(ulong ullUid, uint dwLogicWorldID, COM_ACNT_GAME_STATE State, uint startTime, string nickName = "", bool IgnoreWorld_id = false)
        {
            FriendInGame game = null;

            for (int i = 0; i < this.gameStateList.Count; i++)
            {
                game = this.gameStateList[i];
                bool flag = false;
                if (!IgnoreWorld_id)
                {
                    flag = (game.ullUid == ullUid) && (game.dwLogicWorldID == dwLogicWorldID);
                }
                else
                {
                    flag = game.ullUid == ullUid;
                }
                if (flag)
                {
                    game.State          = State;
                    game.dwLogicWorldID = dwLogicWorldID;
                    game.startTime      = startTime;
                    return;
                }
            }
            this.gameStateList.Add(new FriendInGame(ullUid, dwLogicWorldID, State, startTime, nickName));
        }
Esempio n. 2
0
        public bool IsFriendInGamingState(ulong ullUid, uint dwLogicWorldID, COM_ACNT_GAME_STATE State)
        {
            FriendInGame game = null;

            for (int i = 0; i < this.gameStateList.Count; i++)
            {
                game = this.gameStateList[i];
                if ((game.ullUid == ullUid) && (game.dwLogicWorldID == dwLogicWorldID))
                {
                    return(game.State == State);
                }
            }
            return(false);
        }
Esempio n. 3
0
        public COM_ACNT_GAME_STATE GetFriendInGamingState(ulong ullUid, uint dwLogicWorldID)
        {
            FriendInGame game = null;

            for (int i = 0; i < this.gameStateList.Count; i++)
            {
                game = this.gameStateList[i];
                if (((game != null) && (game.ullUid == ullUid)) && (game.dwLogicWorldID == dwLogicWorldID))
                {
                    return(game.State);
                }
            }
            return(COM_ACNT_GAME_STATE.COM_ACNT_GAME_STATE_IDLE);
        }
Esempio n. 4
0
        public FriendInGame GetFriendInGaming(ulong ullUid, uint dwLogicWorldID)
        {
            FriendInGame game = null;

            for (int i = 0; i < this.gameStateList.Count; i++)
            {
                game = this.gameStateList[i];
                if (((game != null) && (game.ullUid == ullUid)) && (game.dwLogicWorldID == dwLogicWorldID))
                {
                    return(game);
                }
            }
            return(null);
        }