Table of Contents

LoginWithEpicGames

Methods
public static LoginOperation LoginWithEpicGames(string token, CancellationToken cancellationToken = default)

Login to coherence Cloud using an Epic Games account.

Parameters
Type Name Description
string token

Authentication token acquired from Epic Online Services.

CancellationToken cancellationToken

Used to cancel the operation.

Returns
Type Description
LoginOperation

The status of the asynchronous login operation.

Remarks

'Epic Auth Enabled' must be ticked in Project Settings on your Online Dashboard for this authentication method to be usable.

Examples
// Copyright (c) coherence ApS.
// See the license file in the package root for more information.

using System.Threading.Tasks;
using Coherence.Cloud;
using UnityEngine;

class LoginWithEpicGames : MonoBehaviour
{
    public async Task<PlayerAccount> Login(string token)
    {
        PlayerAccount playerAccount = await CoherenceCloud.LoginWithEpicGames(token);
        Debug.Log($"Logged in as: {playerAccount}.");
        return playerAccount;
    }
}