JUtils
A unity utilities library
|
Makes it easier to work with object pools More...
Static Public Member Functions | |
static PoolItem | SpawnPoolItem (PoolItem template, Vector3? position=null, Quaternion? rotation=null, Vector3? localScale=null, Transform parent=null) |
Spawns a pooled item from the prefab More... | |
static ObjectPool | GetObjectPool (PoolItem template) |
Get or create an object pool for the given prefab More... | |
static bool | DestroyObjectPool (PoolItem template, bool cleanObjects=true) |
Destroys the object pool assigned to the prefab More... | |
Additional Inherited Members | |
Protected Member Functions inherited from JUtils.AutoSingletonBehaviour< ObjectPoolManager > | |
virtual void | Awake () |
virtual void | OnDestroy () |
Properties inherited from JUtils.AutoSingletonBehaviour< ObjectPoolManager > | |
static T | instance [get] |
static bool | exists [get] |
Makes it easier to work with object pools
|
inlinestatic |
Destroys the object pool assigned to the prefab
References JUtils.AutoSingletonBehaviour< ObjectPoolManager >.instance.
|
inlinestatic |
Get or create an object pool for the given prefab
References JUtils.AutoSingletonBehaviour< ObjectPoolManager >.instance.
|
inlinestatic |
Spawns a pooled item from the prefab
References JUtils.ObjectPoolManager.GetObjectPool(), and JUtils.ObjectPool.SpawnItem().