Hello,
I have some big calculations to do and want the game continue to run while this calculations (generating a terrain) are running.
How can I do that in c#?
Hello,
I have some big calculations to do and want the game continue to run while this calculations (generating a terrain) are running.
How can I do that in c#?
You can use the normal C# System.Threading library. Here’s the official MSDN tutorial: http://msdn.microsoft.com/en-us/library/aa645740(v=vs.71).aspx
Just be careful not to call any Unity API functions from anything other than the main thread. Some basic data types are safe (Vector3, Color, etc), but don’t call anything on GameObjects or Components.