Hi guys, i have a problem with a coroutine. When i debug the game i see the line of execution does not enter in the coroutine code:
void Update(){
if (iCondition==true){
StartCoroutine("iRun");
}
}
IEnumerator iRun(){ // In debug mode the tracing line dont pass this point
while (iCondition==true){
// ...... CODE ..... //
yield return 0;
}
}
When debug reaches the commented line, in the watch window i notice iCondition value is null. Any idea why is this happening?