I have a script where you press play and an add pops up. I want to spread the ads out so you dont get flooded with them.
So the game is one where you have a 60 second timer in it and when the timer runs out game over so basically i want to make it so that you press play and see an add and then you press play again no ad Comes up (the script is deactivated) and then after 4 minutes have passed if i press play the ad script will activate again.
Use a coroutine with a boolean.
void Start()
{
StartCoroutine("Timer");
}
IEnumerator Timer()
{
while(true)
{
//turn ad off
showAd = false;
yield return new WaitForSeconds(240.0f);
showAd = true;
//can show ad
}
}