I have a class where the the a coroutine function which is getting called multiple times. I would like to know how to check whether all the coroutines are done or not.
Here is my example:
class something
{
void CallCoroutine(int param)
{
StartCoroutine(func(param));
}
IEnumerator func(int param)
{
while(somecondition is true) //This condition returns returns value for sure. Either true or false
yield return WaitForEndOfFrame();
yield return null;
}
}
Here the function CallCoroutine() called for some 15 times.
I want to check if any coroutines are running or not. Please give me suggestions how to fix this.
Thank you in advance.