Quick Start
private CloudWalletPlugin _cloudWalletPlugin;
public string Account { get; private set; }
public void Start()
{
// Instantiate the WaxCloudWalletPlugin
_cloudWalletPlugin= new GameObject(nameof(CloudWalletPlugin )).AddComponent<CloudWalletPlugin >();
// Assign Event-Handlers/Callbacks
_cloudWalletPlugin.OnLoggedIn += (loginEvent) =>
{
Account = loginEvent.Account;
Debug.Log($"{loginEvent.Account} Logged In");
};
_cloudWalletPlugin.OnError += (errorEvent) =>
{
Debug.Log($"Error: {errorEvent.Message}");
};
_cloudWalletPlugin.OnTransactionSigned += (signEvent) =>
{
Debug.Log($"Transaction signed: {JsonConvert.SerializeObject(signEvent.Result)}");
};
// Inititalize the WebGl binding while passign the RPC-Endpoint of your Choice
_cloudWalletPlugin.InitializeWebGl("https://wax.greymass.com");
// NOTE! For other Build Targets you will need to call the related initialize Methods
// allowing to provide the necessary parameters needed for Mobile or Desktop-Builds
}Last updated
