UKismetSystemLibrary::LoadInterstitialAd
#include "Kismet/KismetSystemLibrary.h"
Access: public
Specifiers: staticUFUNCTIONBlueprintCallable
Description
Requests that a fullscreen interstitial AdMob ad be loaded in the background so it's ready to display later.
Caveats & Gotchas
- • Android only — the header explicitly scopes this to Android, unlike the banner functions which support both iOS and Android.
- • This only loads the ad; you must call ShowInterstitialAd afterward to actually display it, and IsInterstitialAdAvailable to check load status.
- • Loading is asynchronous — there is no completion callback exposed here, so poll IsInterstitialAdAvailable/IsInterstitialAdRequested before assuming the ad is ready.
Signature
static void LoadInterstitialAd(int32 AdIdIndex) Parameters
| Name | Type | Description | Default |
|---|---|---|---|
| AdIdIndex | int32 | Index of the ad unit ID to load, from the platform's configured ad IDs. | — |
Return Type
void Example
Preload an interstitial ad ahead of a level transition C++
UKismetSystemLibrary::LoadInterstitialAd(0);
// Later, once loaded:
if (UKismetSystemLibrary::IsInterstitialAdAvailable())
{
UKismetSystemLibrary::ShowInterstitialAd();
} See Also
Tags
Version History
Introduced in: 4.0
| Version | Status | Notes |
|---|---|---|
| 5.6 | stable | — |
Feedback
Was this helpful?