Home


Interstitial Ads

Interstitial Ads are short static or video ads, usually shown between levels or when game is over.

if enhance.isInterstitialReady() then
    -- The ad is ready, show it
    enhance.showInterstitialAd()
end

Methods

enhance.isInterstitialReady

boolean enhance.isInterstitialReady(
    optional string placement = "default"
)

Check if an ad from any of the included SDK providers is ready to be shown.

Parameters:

optional string  placement - Specifies the internal placement of the ad (from the Enhance mediation editor).

Return Value:

Returns true if any ad is ready, false otherwise. When app is not Enhanced, always returns true.

enhance.showInterstitialAd

nil enhance.showInterstitialAd(
    optional string placement = "default"
)

Display an ad if any is currently available. The ad provider is selected based on your app's mediation settings.

Parameters:

optional string  placement - Specifies the internal placement of the ad (from the Enhance mediation editor).