xboxlive_matchmaking_send_invites


Description

This function brings up the Xbox Live system dialog to allow a user to send invitations to their game. You specify the local user who should control the dialog (and who's friends list will be used by the dialog), the unique session ID value for the session they want to invite people to, and some default text to show in the dialog. You get the session ID from the async_load DS map generated by the function xboxlive_matchmaking_create().

The function will return -1 if the arguments are invalid or the user is not signed into Xbox Live, or a value greater than 0 otherwise.


Syntax:

xboxlive_matchmaking_send_invites(from_user, session_to_invite_into, text_to_add_to_invite);

Argument Description
from_user The local user ID for controlling the dialogue.
session_to_invite_into The unique session ID for the session to join.
text_to_add_to_invite A short text to add to the invitation.


Returns:

Integer


Example:

if gamepad_button_check_pressed(0, gp_face1)
{
xboxlive_matchmaking_send_invites(xboxlive_user_for_pad(0), global.session_ID, "Come and join my game!");
}

The above code checks for a gamepad button press and if one is detected then the Xbox Live dialog for session invites will be opened.