Pool
Implementation of Unity's ObjectPool. (https://docs.unity3d.com/ScriptReference/Pool.ObjectPool_1.html)
Includes both standard class version and MonoBehaviour version.
GameObjectPool
Standart class version.
Contructor
Name
Type
Description
defaultCapacity
int
The default number of objects to allocate in the pool at initialization.
maxSize
int
The maximum size of the pool.
prewarm
bool
A boolean indicating whether to preallocate the default capacity of objects in the pool (default is true).
collectionCheck
bool
A boolean indicating whether to perform collection checks (default is true).
Usage
GameObjectPoolList
MonoBehaviour, list of pools. Create and destroy multiple pools.
MonoGameObjectPool
MonoBehaviour version of GameObjectPool. Auto prewarm on Awake.
Last updated