Quantcast
Channel: Answers for "How to properly use Yield for a coroutine?"
Browsing latest articles
Browse All 6 View Live

Answer by Mike 3

the function that you call needs to be of type IEnumerator - this is done implicitly when you use yield in the function, but if you add in a return (or it is possible to get through the function...

View Article



Answer by Absyss

what Mike meant is following:function myFirstFunction():IEnumerator { ... } function mySecondFunction():IEnumerator { ... } ... yield myFirstFunction(); yield mySecondFunction(); this way the compiler...

View Article

Answer by Techsuport

you could do something like a call back, so even though you cant get the return right away, you can have function B call function D in the same class as function A to continue on where A left off....

View Article
Browsing latest articles
Browse All 6 View Live




Latest Images