コード例 #1
0
        public static NetworkSession Create(
            NetworkSessionType sessionType,
            IEnumerable <SignedInGamer> localGamers,
            int maxGamers,
            int privateGamerSlots,
            NetworkSessionProperties sessionProperties
            )
        {
            IAsyncResult result = BeginCreate(
                sessionType,
                localGamers,
                maxGamers,
                privateGamerSlots,
                sessionProperties,
                null,
                null
                );

            while (!result.IsCompleted)
            {
                if (!GamerServicesDispatcher.UpdateAsync())
                {
                    activeAction.IsCompleted = true;
                }
            }
            return(EndCreate(result));
        }
コード例 #2
0
        public static NetworkSession JoinInvited(
            int maxLocalGamers
            )
        {
            IAsyncResult result = BeginJoinInvited(maxLocalGamers, null, null);

            while (!result.IsCompleted)
            {
                if (!GamerServicesDispatcher.UpdateAsync())
                {
                    activeAction.IsCompleted = true;
                }
            }
            return(EndJoinInvited(result));
        }
コード例 #3
0
        public static NetworkSession Join(
            AvailableNetworkSession availableSession
            )
        {
            IAsyncResult result = BeginJoin(availableSession, null, null);

            while (!result.IsCompleted)
            {
                if (!GamerServicesDispatcher.UpdateAsync())
                {
                    activeAction.IsCompleted = true;
                }
            }
            return(EndJoin(result));
        }
コード例 #4
0
        public static AvailableNetworkSessionCollection Find(
            NetworkSessionType sessionType,
            IEnumerable <SignedInGamer> localGamers,
            NetworkSessionProperties searchProperties
            )
        {
            IAsyncResult result = BeginFind(
                sessionType,
                localGamers,
                searchProperties,
                null,
                null
                );

            while (!result.IsCompleted)
            {
                if (!GamerServicesDispatcher.UpdateAsync())
                {
                    activeAction.IsCompleted = true;
                }
            }
            return(EndFind(result));
        }
コード例 #5
0
        public static NetworkSession Create(
            NetworkSessionType sessionType,
            int maxLocalGamers,
            int maxGamers
            )
        {
            IAsyncResult result = BeginCreate(
                sessionType,
                maxLocalGamers,
                maxGamers,
                null,
                null
                );

            while (!result.IsCompleted)
            {
                if (!GamerServicesDispatcher.UpdateAsync())
                {
                    activeAction.IsCompleted = true;
                }
            }
            return(EndCreate(result));
        }