示例#1
0
        /// <summary>
        /// Invites the given users on behalf of the acting user to the given party (associated with a specific Title ID).
        /// </summary>
        /// <param name="party">The party to invite remote users to.</param>
        /// <param name="remoteUsersToInvite">Remote users to invite to the party.</param>
        public void InviteToParty(XboxParty party, IEnumerable <XboxRemoteUser> remoteUsersToInvite)
        {
            if (party == null)
            {
                throw new ArgumentNullException("party");
            }

            if (remoteUsersToInvite == null)
            {
                throw new ArgumentNullException("remoteUsersToInvite");
            }

            this.Console.Adapter.InviteToParty(this.Console.SystemIpAddressAndSessionKeyCombined, party.TitleId, this.Xuid, (from xu in remoteUsersToInvite select xu.Xuid).ToArray());
        }
示例#2
0
        /// <summary>
        /// Removes the given users from the given party belonging to a specific title ID.
        /// </summary>
        /// <param name="party">The party to remove local users from.</param>
        /// <param name="localUsersToRemove">Local users to remove from the party.</param>
        public void RemoveLocalUsersFromParty(XboxParty party, IEnumerable <XboxUser> localUsersToRemove)
        {
            if (party == null)
            {
                throw new ArgumentNullException("party");
            }

            if (localUsersToRemove == null)
            {
                throw new ArgumentNullException("localUsersToRemove");
            }

            this.Console.Adapter.RemoveLocalUsersFromParty(this.Console.SystemIpAddressAndSessionKeyCombined, party.TitleId, (from xu in localUsersToRemove select xu.Xuid).ToArray());
        }
示例#3
0
        /// <summary>
        /// Creates a party for the given title ID (if one does not exist) and adds the given local users to it.
        /// </summary>
        /// <param name="party">The party to add local users to.</param>
        /// <param name="localUsersToAdd">Users to add to the party.</param>
        public void AddLocalUsersToParty(XboxParty party, XboxUser[] localUsersToAdd)
        {
            if (party == null)
            {
                throw new ArgumentNullException("party");
            }

            if (localUsersToAdd == null)
            {
                throw new ArgumentNullException("localUsersToAdd");
            }

            this.Console.Adapter.AddLocalUsersToParty(this.Console.SystemIpAddressAndSessionKeyCombined, party.TitleId, this.Xuid, (from xu in localUsersToAdd select xu.Xuid).ToArray());
        }