Initialisation
First call to use SnapchatKit features
Initialise Snapchat Kit plugin by calling Initialise method. This initialises the plugin and returns a callback which has the success status.
1
SnapchatKitManager.Initialise(callback);
Copied!
Examples
1
SnapchatKitManager.Initialise((bool success, string error) =>
2
{
3
string message = success ? "Successfully Initialised" : "Failed Initialising
4
SnapchatKit : " +error;
5
Debug.Log(message);
6
});
Copied!
1
using VoxelBusters.SnapchatKit;
2
3
private void Initialise()
4
{
5
SnapchatKitManager.Initialise(OnInitialiseComplete);
6
7
// Another way to pass callback
8
/*
9
SnapchatKitManager.Initialise((bool success, string error) =>
10
{
11
string message = success ? "Successfully Initialised" : "Failed Initialising
12
SnapchatKit : " +error;
13
Debug.Log(message);
14
});*/
15
}
16
17
private void OnInitialiseComplete(bool success, string error)
18
{
19
string message = success ? "Successfully Initialised" : "Failed Initialising
20
SnapchatKit : " +error;
21
Debug.Log(message);
22
}
Copied!
Last modified 2yr ago
Copy link