"Ads Ready" 5 times in a raw

Is that normal to receive it 5 times instead of one?
Screenshot_1

using UnityEngine;
using UnityEngine.Advertisements;

public class AdManager : MonoBehaviour, IUnityAdsListener
{
    [SerializeField] private bool testMode = true;

    public static AdManager Instance;
#if UNITY_ANDROID
    private string gameId = "47***99";
#elif UNITY_IOS
    private string gameId = "47***98";
#endif

    private GameOverHandler gameOverHandler;

    void Awake() {
        if(Instance != null && Instance !=this)
        {
            Destroy(gameObject);
        }
        else
        {
            Instance = this;
            DontDestroyOnLoad(gameObject);

            Advertisement.AddListener(this);
            Advertisement.Initialize(gameId, testMode);
        }
    }

    public void ShowAd(GameOverHandler gameOverHandler)
    {
        this.gameOverHandler = gameOverHandler;
        Advertisement.Show("Rewarded_Video");
    }

    public void OnUnityAdsDidError(string message)
    {
        Debug.Log($"Unity Ads Error: {message}");
    }

    public void OnUnityAdsDidFinish(string placementId, ShowResult showResult)
    {
        switch(showResult)
        {
            case ShowResult.Finished:
                gameOverHandler.ContinueGame();
                break;
            case ShowResult.Skipped:
                //Ad was skipped
                break;
            case ShowResult.Failed:
                Debug.LogError("Ad Failed");
                break;
        }
            
    }

    public void OnUnityAdsDidStart(string placementId)
    {
        Debug.Log("Ad Started");
    }

    public void OnUnityAdsReady(string placementId)
    {
        Debug.Log("Ads Ready");
    }
}

Searching for this, I found that others have experienced this phenomenon as well. That’s less worrisome than OnUnityAdsDidFinish firing multiple times.

So, will here be an Answear?

I wasn’t able to find an answer as to why, just that it does happen.

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms