-
Notifications
You must be signed in to change notification settings - Fork 1
interstitial
Interstitials are full-screen ads shown at natural pauses: between levels, on game over, or when returning to the menu.
Check this before showing interstitial-related UI or running interstitial logic.
playgama_bridge_advertisement_is_interstitial_supported()Platform support · 26 of 28 platforms
Supports: absolute_games, bitquest, crazy_games, dlightek, facebook, game_distribution, gamepush, gamesnacks, huawei, jio_games, lagged, microsoft_store, msn, ok, playdeck, playgama, poki, portal, samsung, telegram, tiktok, vk, xiaomi, y8, yandex, youtube
Does not support: discord, reddit
Set the minimum delay between interstitial attempts. The SDK uses this delay to prevent ads from appearing too often.
// Get delay, default value = 60 seconds
playgama_bridge_advertisement_minimum_delay_between_interstitial()
// Set new delay
playgama_bridge_advertisement_set_minimum_delay_between_interstitial(30)The SDK tracks the delay internally. Set the required interval once; if you call showInterstitial() too early, Bridge waits or skips according to platform behavior instead of showing ads too frequently.
Track state changes to drive ad-specific logic. For muting and pausing, prefer the universal platform events described below instead of reacting to each ad state separately.
playgama_bridge_advertisement_interstitial_state()Possible values: loading, opened, closed, failed.
// To track interstitial ad state changes, subscribe to the event
// via Async Social Event
if async_load[? "type"] == "playgama_bridge_advertisement_interstitial_state_changed" {
switch async_load[? "data"] {
case "loading":
// your logic here
break
case "opened":
// your logic here
break
case "closed":
// your logic here
break
case "failed":
// your logic here
break
}
}Request an interstitial at a natural pause, such as a level transition, game over screen, or return to menu.
var placement = "test_placement" // optional
playgama_bridge_advertisement_show_interstitial(placement)