Quantcast
Channel: Answers for "Using yield wait for seconds in my script, correctly"
Browsing all 4 articles
Browse latest View live

Answer by gregzo

You cannot use yield in Update()! Instead of calling Application.LoadLevel, call a function which will yield WaitForSeconds(5) and then load the next level. Try it, if you still have trouble with it...

View Article



Answer by BiG

I would modify the script as below. Just add the sound and the "stage complete" text! var countdown = false; function Update(){ var bricks = GameObject.FindWithTag("brick"); if(bricks == null...

View Article

Answer by gregzo

You cannot use yield in Update()! Instead of calling Application.LoadLevel, call a function which will yield WaitForSeconds(5) and then load the next level. Try it, if you still have trouble with it...

View Article

Answer by BiG

I would modify the script as below. Just add the sound and the "stage complete" text! var countdown = false; function Update(){ var bricks = GameObject.FindWithTag("brick"); if(bricks == null...

View Article
Browsing all 4 articles
Browse latest View live




Latest Images