Chartboost Interstitial won't show Ads on Unity

2.2k views Asked by At

Lately, I have been trying to add static interstitial ads into my Unity game. For some reason, I could not get the system to show anything, or even react to me. After trying to work with the base Chartboost plugin, I tried to match a tutorial that I was following and purchased Prime31's Chartboost plugin and have been using that. However, neither the base plugin, nor Prime31's plugin, seem to be allowing me to show any ads. The code is pretty much done inside a single object, and it seems simple enough.

public class Advertisement : MonoBehaviour {

    public string chartboostAppID = "5461129ec909a61e38b1505b";
    public string chartboostAppSignature = "672b3b34e3e358e7a003789ddc36bd2bc49ea3b5";

    // Use this for initialization
    void Start () {
        DontDestroyOnLoad(this.gameObject);
        ChartboostAndroid.init (chartboostAppID, chartboostAppSignature, true);

        ChartboostAndroid.cacheInterstitial(null);
    }

    void OnLevelWasLoaded(int level) {
        ChartboostAndroid.cacheInterstitial(null);

        if(Application.loadedLevelName == "Network Lobby") {
            showAds();
        }
    }

    public static void showAds() {
        Debug.Log("Showing ad");
        ChartboostAndroid.showInterstitial(null);
    }
}

As you can see, it's pretty straightforward. This object is created at the game's splash screen, which appears only once, and it's never destroyed until the program ends. The goal is, whenever I enter the lobby scene, I want to see an ad before going to the lobby's menus. As it is, I do see the log printing "Showing ad", so I know the function is being called. However, nothing appears. Do I need to disable the GUI system first? Is there a step I'm missing?

I have already performed the following steps:

  1. I have created and registered the app with chartboost, as well as double and triple checked the AppID and App Signature.
  2. I have created a publishing campaign and registered it to the app.
  3. I double-checked the orientation and confirmed that it's correct.
  4. I registered this specific device as a test device.
  5. The tutorial showed a call to ChartBoostAndroid.OnStart(), but there was no function like that for me to call. Perhaps that is from an older version?

I emailed Chartboost support and have not heard from them yet. I do not have that much time on this project, so if anyone can offer help, I'd appreciate it.

0

There are 0 answers