Quantcast
Channel: Questions in topic: "ads"
Viewing all articles
Browse latest Browse all 1416

help with unity banner ads,

$
0
0
hey, ive recently made a mobile game that uses unity interstitial ads and have had no issue with them as it was fairly simple to write when i wanted them to play (after the player loses). however, i have no idea how to make banner ads play, attached ive added what i have for them so far and pressing "r" makes the unityads screen come up so it means they work fine but i have nothing written to say when or where they play. i have tried over a dozen coroutines but nothing seems to work and have been stuck. thank you in advance :) -j if (Input.GetKeyDown(KeyCode.R)) { // is the video ad ready to be played if (Monetization.IsReady(banner_ad)) { ShowAdPlacementContent ad = null; ad = Monetization.GetPlacementContent(banner_ad) as ShowAdPlacementContent; if (ad != null) { ad.Show(); } } } //input == R } public void ShowVideoOrInterstitialAD() { if (Monetization.IsReady(video_ad)) { ShowAdPlacementContent ad = null; ad = Monetization.GetPlacementContent(video_ad) as ShowAdPlacementContent; if (ad != null) { ad.Show(); } } } public void PlayBannerAD() { if (Monetization.IsReady(banner_ad)) { ShowAdPlacementContent ad = null; ad = Monetization.GetPlacementContent(banner_ad) as ShowAdPlacementContent; if (ad != null) { ad.Show(); } } } }// class,

Viewing all articles
Browse latest Browse all 1416

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>