kloder-games / godot-admob

Module Admob for Godot engine
MIT License
360 stars 61 forks source link

Interstitial Ads Only Displaying Once #149

Closed ACB-prgm closed 4 years ago

ACB-prgm commented 4 years ago

OS target (Android/iOS): iOS 13.7 (iPhone X)

Godot version: 3.2.3 (stable)

Issue description: Idk if this is an issue or I am just misunderstanding, but for some reason, my interstitial ad will only play once per each app load. IE, the first time I open the app, the ad plays when I expect it to play but then when it should play a second time it doesn't appear. If I quit the app and reopen it, it shows the ad again the first time I would expect to see it. The game seems to run fine though, no crash or errors. I am running with test ads and haven't tried with real ads as I don't have an apple developer account yet, and want to make sure I can get ads working before I pay the $100.

I am currently calling loadInterstitial(id) in my singleton's _ready() function. Does that have something to do with it? Do I need to call it before each loadInterstitial(id) call? _on_interstitial_not_loaded() does not trigger.

gumaciel commented 4 years ago

Hello @ACB-prgm , you need to loadInterstitial after the interstitial closes (try on _on_interstitial_closed)

it's okay for you to load the interstitial into _ready, but every time you show it, you need to load it again, and the best place to do that is when the ad is closed

ACB-prgm commented 4 years ago

Everything worked great when I did as you said!