UniTask
Provides an efficient allocation free async/await integration for Unity.
About this mod Author’s original text
UniTask 2.5.0
Provides an efficient allocation free async/await integration for Unity.
- Struct based UniTask and custom AsyncMethodBuilder to achieve zero allocation
- Makes all Unity AsyncOperations and Coroutines awaitable
- PlayerLoop based task(UniTask.Yield, UniTask.Delay, UniTask.DelayFrame, etc..) that enable replacing all coroutine operations
- MonoBehaviour Message Events and uGUI Events as awaitable/async-enumerable
- Runs completely on Unity's PlayerLoop so doesn't use threads and runs on WebGL, wasm, etc.
- Asynchronous LINQ, with Channel and AsyncReactiveProperty
- TaskTracker window to prevent memory leaks
- Highly compatible behaviour with Task/ValueTask/IValueTaskSource
For technical details, see blog post: [UniTask v2 — Zero Allocation async/await for Unity, with Asynchronous LINQ
](
For advanced tips, see blog post: Extends UnityWebRequest via async decorator pattern — Advanced Techniques of UniTask
For usage details, check the original README.
Licensing
I did not make this library, I am simply uploading it so it can be used as a dependency in mods. The original repo (licensed under MIT) can be found here.
For Developers
NOTE: This is different than the UniTask package found on nuget!
The UniTask package on nuget is just for.NET, and doesn't contain many useful Unity-based utilities you may want.
If you'd like to use UniTask, I'd recommend referencing this package's DLLs directly.
Install & use Install: BepInEx plugin
- The archive from playbuff is the mod itself — usually a BepInEx plugin (a .dll or a plugin folder once unzipped).
- Recommended: use a community mod manager (such as r2modman) — pick this game, import the mod, and the manager sets up BepInEx and its dependencies for you.
- Manual route: install the BepInEx loader in the game folder, then drop the unzipped .dll or plugin folder into BepInEx/plugins/.
- Launch the game — the BepInEx console logs every plugin it loads; seeing this mod in the log means it is installed.
Mods with listed dependencies need those installed too, or they will not load. Options are usually changed in-game or in the plugin's config file.
Install these first, or the mod will not work: