Share via


Guide.ShowGameInvite Method (PlayerIndex, Generic IEnumerable)

Displays the game invitation user interface, taking the sender's player index and an optional list of recipient gamers.

Syntax

'Declaration
Public Shared Sub ShowGameInvite ( _
         player As PlayerIndex, _
         recipients As IEnumerable(Of Gamer) _
)
public static void ShowGameInvite (
         PlayerIndex player,
         IEnumerable<Gamer> recipients
)
public:
static void ShowGameInvite(
         PlayerIndex player,
         IEnumerable<Gamer> recipients
)

Parameters

  • player
    Type: PlayerIndex
    Index of the player initiating the invitation.
  • recipients
    Type: IEnumerable<Gamer>
    List of gamers who receive the invitation. If null, the Guide prompts the player for a recipient gamer.

Remarks

You can check GamerPrivileges.AllowCommunication to determine if a player is allowed to send and receive communications before displaying a menu option that would call this method.

Dd282393.note(en-us,XNAGameStudio.42).gifWindows Phone Specific Information

This method is not used on Windows Phone. For game invitations on Windows Phone you must use the ShowGameInvite overload that takes a Session ID.

Requirements

Namespace: Microsoft.Xna.Framework.GamerServices

Assembly: Microsoft.Xna.Framework.GamerServices (in microsoft.xna.framework.gamerservices.dll)

See Also

Reference

GamerPrivileges.AllowCommunication Property
Guide Class
Guide Members
Microsoft.Xna.Framework.GamerServices Namespace

Platforms

Windows Phone