Unity
Unity Standard
Configure the SDK
You need to add your Appkey manually in your project if you haven’t added your game’s store link in the MAS dashboard yet. You can find your app key in MAS dashboard.
Go to Yodo1
-> MAS Settings
in Unity Editor. And you can set up app-key and AdMob key for both Android and iOS.
Android settings
iOS settings
Initialize the SDK
You can initialize the SDK in the Awake
method of your MonoBehaviour
class.
using Yodo1.MAS;
public class YourClass : MonoBehaviour
{
void Awake()
{
Yodo1U3dMas.InitializeMasSdk();
}
}
You can check the initialization status using callbacks.
Yodo1U3dMasCallback.OnSdkInitializedEvent += (success, error) =>
{
if (success)
{
Debug.Log("[Yodo1 Mas] The initialization has succeeded");
}
else
{
Debug.Log("[Yodo1 Mas] The initialization has failed with error " + error.ToString());
}
};