PlayGames

  • The PlayGames class serves as the main entry point to access Google Play Games Services functionality through various APIs and interfaces.

  • You can obtain specific client instances like AchievementsClient, EventsClient, LeaderboardsClient, PlayersClient, RecallClient, PlayerStatsClient, GamesSignInClient, and SnapshotsClient for use within an Android Activity.

  • Each get*Client method returns a new instance of the corresponding client, allowing access to specific game services features.

  • Additional information on getting started with Google Play Games Services for Android is available through the provided quickstart guide.

public final class PlayGames extends Object

Main entry point for the Games APIs. This class provides APIs and interfaces to access the Google Play Games Services functionality.

For more information, see the getting started guide.

Public Method Summary

static AchievementsClient
getAchievementsClient(Activity activity)
Returns a new instance of AchievementsClient for use in an Activity.
static EventsClient
getEventsClient(Activity activity)
Returns a new instance of EventsClient for use in an Activity.
static GamesSignInClient
getGamesSignInClient(Activity activity)
Returns a new instance of GamesSignInClient for use in an Activity.
static LeaderboardsClient
getLeaderboardsClient(Activity activity)
Returns a new instance of LeaderboardsClient for use in an Activity.
static PlayerStatsClient
getPlayerStatsClient(Activity activity)
Returns a new instance of PlayerStatsClient for use in an Activity.
static PlayersClient
getPlayersClient(Activity activity)
Returns a new instance of PlayersClient for use in an Activity.
static RecallClient
getRecallClient(Activity activity)
Returns a new instance of RecallClient for use in an Activity.
static SnapshotsClient
getSnapshotsClient(Activity activity)
Returns a new instance of SnapshotsClient for use in an Activity.

Inherited Method Summary

Public Methods

public static AchievementsClient getAchievementsClient (Activity activity)

Returns a new instance of AchievementsClient for use in an Activity.

Parameters
activity The Activity for this client.

public static EventsClient getEventsClient (Activity activity)

Returns a new instance of EventsClient for use in an Activity.

Parameters
activity The Activity for this client.

public static GamesSignInClient getGamesSignInClient (Activity activity)

Returns a new instance of GamesSignInClient for use in an Activity.

Parameters
activity The Activity for this client.

public static LeaderboardsClient getLeaderboardsClient (Activity activity)

Returns a new instance of LeaderboardsClient for use in an Activity.

Parameters
activity The Activity for this client.

public static PlayerStatsClient getPlayerStatsClient (Activity activity)

Returns a new instance of PlayerStatsClient for use in an Activity.

Parameters
activity The Activity for this client.

public static PlayersClient getPlayersClient (Activity activity)

Returns a new instance of PlayersClient for use in an Activity.

Parameters
activity The Activity for this client.

public static RecallClient getRecallClient (Activity activity)

Returns a new instance of RecallClient for use in an Activity.

Parameters
activity The Activity for this client.

public static SnapshotsClient getSnapshotsClient (Activity activity)

Returns a new instance of SnapshotsClient for use in an Activity.

Parameters
activity The Activity for this client.