Gamebase SDK for Unity  1.5.0
Toast Gamebase Platform

◆ Login() [2/3]

static void Login ( string  providerName,
Dictionary< string, object >  additionalInfo,
GamebaseCallback.GamebaseDelegate< GamebaseResponse.Auth.AuthToken >  callback 
)
static

Logs the user in with the external authentication provider.

Since
Added 1.4.0.
Parameters
providerNameThe providerName which is authentication provider.
additionalInfoThe additionalInfo which is additional information using for login.
callbackLogin result callback, returns the authentication token as a result of login.

Example Usage :

public void Login(string providerName, Dictionary<string, object> additionalInfo)
{
Gamebase.Login(providerName, additionalInfo, (authToken, error) =>
{
if (Gamebase.IsSuccess(error))
{
string userId = authToken.member.userId;
Debug.Log(string.Format("Login succeeded. Gamebase userId is {0}", userId));
}
else
{
Debug.Log(string.Format("Login failed. error is {0}", error));
}
});
}