Google Play Games Services

Type Library
Revision Release 2021.3646
Keywords google, google play games services, achievements, leaderboards, multiplayer
Platforms Android
Sample https://github.com/coronalabs/com.coronalabs-plugin.gpgs.v2

Beta version

This plugin is currently in beta. API may change without notice. iOS version will be available later.

Overview

This plugin enables access to Google Play Games Services API, such as achievements, leaderboards and multiplayer.

Backward compatipility

This plugin has full backward compatibility with the gameNetwork.* API. To use it, however, you have to require "plugin.gpgs.v2" before using gameNetwork.

Syntax

local gpgs = require( "plugin.gpgs.v2" )

Project Settings

To use this plugin, add an entry into the plugins table of build.settings. When added, the build server will integrate the plugin during the build phase.

settings = {
    plugins = {
        ["plugin.gpgs.v2"] = {
            publisherId = "com.coronalabs",
            supportedPlatforms = {["android"] = true, ["android-kindle"] = true}
        }
    }
}

Additionally, you must specify the Google Play Games App ID in the android table of build.settings as the googlePlayGamesAppId key:

settings = {

    android =
    {
        googlePlayGamesAppId = "YOUR_APPLICATION_ID",
    },
}

Nodes

The plugin is divided into API nodes for better organization.

gpgs.*

Overview

This is the base API node for the plugin. It manages connection to the Google's servers, authentication and general SDK tasks.

Functions

Events

Types

Game