void AddFunction(Action function); 

Adds a function to the internal thread pool. All functions are synchronized and executed precisely once per frame during Unity’s update call. Data exclusive to the main thread can be accessed during the normal Update function and used in every parallel executed function. Unless variables are accessed from multiple parallel functions, there will be no race conditions, and no additional steps are needed to ensure data integrity.

Parameters

function

Function to be added. Only takes functions with no parameters and no return value.

Example