example-app: Unity Ads adapter on Android (demo banner unit fills only through Unity Ads)

This commit is contained in:
CRTkafa 2026-10-10 06:32:57 +08:00
parent 6733e8bdae
commit 49942ac20e
2 changed files with 6 additions and 2 deletions

View file

@ -40,8 +40,9 @@ then repeat the iOS steps above (see the plugin README, "iOS setup").
## Notes ## Notes
- The demo app keys have no mediation adapters: fill comes from ironSource Ads (and Unity Ads where configured), and - Android includes the Unity Ads mediation adapter (`app/build.gradle`): Unity's demo Android banner unit only fills
natives may not fill on Android with the demo key (508 "No Native Ad configurations found"). through Unity Ads, so without it banners fail with 1044 "no available ad to load". Everything else fills from
ironSource Ads. Natives may not fill on Android with the demo key (508 "No Native Ad configurations found").
- `loadBanner` is one-shot per banner object; to retry right away, destroy and create the banner again. - `loadBanner` is one-shot per banner object; to retry right away, destroy and create the banner again.
- The web build (`npm run build`, open `www/index.html` through any static server) runs the plugin's web stub: - The web build (`npm run build`, open `www/index.html` through any static server) runs the plugin's web stub:
init and banners reject as unimplemented and nothing ever fills. init and banners reject as unimplemented and nothing ever fills.

View file

@ -36,6 +36,9 @@ dependencies {
implementation "androidx.coordinatorlayout:coordinatorlayout:$androidxCoordinatorLayoutVersion" implementation "androidx.coordinatorlayout:coordinatorlayout:$androidxCoordinatorLayoutVersion"
implementation "androidx.core:core-splashscreen:$coreSplashScreenVersion" implementation "androidx.core:core-splashscreen:$coreSplashScreenVersion"
implementation project(':capacitor-android') implementation project(':capacitor-android')
// Unity Ads mediation adapter: Unity's demo Android banner unit only fills through Unity Ads
implementation 'com.unity3d.ads-mediation:unityads-adapter:5.14.0'
implementation 'com.unity3d.ads:unity-ads:4.21.0'
testImplementation "junit:junit:$junitVersion" testImplementation "junit:junit:$junitVersion"
androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion" androidTestImplementation "androidx.test.ext:junit:$androidxJunitVersion"
androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion" androidTestImplementation "androidx.test.espresso:espresso-core:$androidxEspressoCoreVersion"