- Home /
Question by
Gaming Worlds · Dec 24, 2015 at 05:11 AM ·
scripting problemtimeadsadvertising
How to make ad appear after a few seconds?
What is a simple script so that an unity ad shows up after a certain amount of time has passed?
Is it possible to do it with a Coroutine? If so how?
Comment
Best Answer
Answer by corn · Dec 24, 2015 at 10:55 PM
It's quite easy to do with a coroutine indeed, with WaitForSeconds.
IEnumerator delayedShowAd(float delay)
{
yield return new WaitForSeconds(delay);
Advertisement.Show();
}
void ShowAd(float delay)
{
StartCoroutine(delayedShowAd(delay));
}
Your answer
Follow this Question
Related Questions
Unity Ads Banner not working. 0 Answers
AdMob Rewarded Video Ad 0 Answers
Admob rewarded video working in Unity but not on android device. 0 Answers
Am I allowed to make money under 18 years old? 2 Answers
Delay Advertisements when switching between scenes? 0 Answers