I copied the code of the interstitial from here https://developers.google.com/mobile-ads-sdk/docs/admob/advanced but it doesnt' work. When the app calls the method interstitial.isLoaded(), it crashes. This is the logcat:
04-06 14:40:09.320 29704-30638/? W/dalvikvm﹕ threadid=16: thread exiting with uncaught exception (group=0x4145e438)
04-06 14:40:09.330 29704-30638/? E/AndroidRuntime﹕ FATAL EXCEPTION: Thread-3225
java.lang.IllegalStateException: isLoaded must be called on the main UI thread.
at bkm.b(SourceFile:174)
at xx.e(SourceFile:210)
at yh.onTransact(SourceFile:66)
at android.os.Binder.transact(Binder.java:326)
at com.google.android.gms.internal.ac$a$a.isReady(Unknown Source)
at com.google.android.gms.ads.InterstitialAd.isLoaded(Unknown Source)
at com.MyApp.GameActivity.displayInterstitial(GameActivity.java:75)
at com.MyApp.GameActivity$GameView.onDraw(GameActivity.java:300)
at com.MyApp.GameActivity$GameLoop.run(GameActivity.java:524)
04-06 14:40:09.330 441-4437/? W/ActivityManager﹕ Force finishing activity...
How is it possible? Can you please explain me step-by-step what I have to do to show this interstitial? Thank you in advance