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

What I have done wrong ? (advertisement)

$
0
0
I want to embed banners in Unity using the ADS feature. But I get the error message: Adversiment does not contain a definition for IsReady. Here is the whole code: using System.Collections; using UnityEngine; using UnityEngine.Advertisements; public class BannerAd : MonoBehaviour { public string gameId = "4824753"; public string placementId = "ShopBanner"; public bool testMode = true; void Start () { // Initialize the SDK if you haven't already done so: Advertisement.Initialize (gameId, testMode); StartCoroutine (ShowBannerWhenReady ()); } IEnumerator ShowBannerWhenReady () { while (!Advertisement.IsReady (placementId)) { yield return new WaitForSeconds (0.5f); } Advertisement.Banner.Show (placementId); } } I hope you will help me ! Thanks

Viewing all articles
Browse latest Browse all 1416

Trending Articles



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