Class PoolData
Inheritance
System.Object
PoolData
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: GameKit.Dependencies.Utilities.ObjectPooling
Assembly: GameKit.Dependencies.dll
Syntax
public class PoolData
Constructors
PoolData(GameObject, Single)
Declaration
public PoolData(GameObject prefab, float expirationDuration)
Parameters
Type | Name | Description |
---|---|---|
UnityEngine.GameObject | prefab | |
System.Single | expirationDuration |
Fields
Objects
Objects currently in the pool.
Declaration
public ListStack<GameObject> Objects
Field Value
Type | Description |
---|---|
ListStack<UnityEngine.GameObject> |
Prefab
Prefab for this pool.
Declaration
public readonly GameObject Prefab
Field Value
Type | Description |
---|---|
UnityEngine.GameObject |
Methods
Cull()
Returns a list of GameObjects which were culled from the stack using the default expiration duration.
Declaration
public List<GameObject> Cull()
Returns
Type | Description |
---|---|
System.Collections.Generic.List<UnityEngine.GameObject> |
PoolExpired()
Returns if the pool has expired due to inactivity.
Declaration
public bool PoolExpired()
Returns
Type | Description |
---|---|
System.Boolean |