Thread in Unity!

Just a quick update about something that I discovered this weekend

Thread Ninja - Multithread Coroutine

Basically what this do is, you can run a heavy task on another thread, this makes the task run keeping the FPS at some acceptable level while running your task, example:

   1:  for(int i = 0 ; i < int.MaxValue; i++)
   2:  {
   3:  }

This will lock your Unity until this finish, but if you make the same thing using the Tread Ninja. the Unity will keep running without problem or slowdown.

   1:  this.StartCoroutineAsync(IEnumeratorYourAsyncRoutine());
   2:   
   3:  IEnumeratorYourAsyncRoutine()
   4:  {
   5:      for(int i =0;i < int.MaxValue; i++)
   6:      {
   7:      }
   8:  }

This is awesome! One big problem using this, if that you can't move anything from Unity inside this coroutine, but if you want you can use this little help here:

   1:  yield return Ninja.JumpToUnity;

This can be a big saver for some things, and best of all, is FREE!