Hi, trying to upload my android game to google play, found out that i need to use a neutral age screen to show ads properly to children. I’m showing a “Are you under the age of 13?” Dialogue box on the first start up of the game, and storing the value in playerprefs. Is this is right way to go? Also I’m calling the InitializeAds() method from the main menu script.
private void Awake()
{
if(Instance == null)
{
Instance = this;
MobileAds.Initialize(initStatus => { });
}
else
{
Destroy(gameObject);
}
}
public void InitializeAds()
{
if (PlayerPrefs.GetString("Under13") == "yes")
{
Debug.Log("Under13");
RequestConfiguration requestConfiguration = new RequestConfiguration.Builder()
.SetMaxAdContentRating(MaxAdContentRating.PG)
.build();
MobileAds.SetRequestConfiguration(requestConfiguration);
}
if (PlayerPrefs.GetString("RemoveAds") == "remove")
{
RequestRewardedAd();
}
else
{
RequestBanner();
RequestInterstitial();
RequestRewardedAd();
}
DontDestroyOnLoad(gameObject);
}