AngelScript
|
Path: /sdk/add_on/contextmgr/
The CContextMgr
is a class designed to aid the management of multiple simultaneous scripts executing in parallel. It supports both concurrent script threads and co-routines.
If the application doesn't need multiple contexts, i.e. all scripts that are executed always complete before the next script is executed, then this class is not necessary.
Multiple context managers can be used, for example when you have a group of scripts controlling ingame objects, and another group of scripts controlling GUI elements, then each of these groups may be managed by different context managers.
Observe, that the context manager class hasn't been designed for multithreading, so you need to be careful if your application needs to execute scripts from multiple threads.