feat: add initial People Playground mod development kit
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
URL: https://wiki.studiominus.nl/internalReference/ObjectPoolBehaviour.html
|
||||
Title: People Playground Modding - ObjectPoolBehaviour
|
||||
==================================================
|
||||
|
||||
public class ObjectPoolBehaviour
|
||||
Inherits MonoBehaviour
|
||||
Handles object pools
|
||||
Fields
|
||||
public const string PoolableTag
|
||||
No description provided
|
||||
Constant value: "Poolable"
|
||||
|
||||
public GameObject Prefab
|
||||
Prefab to use for the pool
|
||||
|
||||
public uint MaxPoolSize
|
||||
Maximum size of the pool
|
||||
|
||||
public float InactivityThresholdInSeconds
|
||||
The amount of time the pool has to be unused for it to delete everything
|
||||
|
||||
Methods
|
||||
public int GetPoolSize()
|
||||
Returns the amount of active or inactive objects in the pool
|
||||
|
||||
public int GetActivePoolSize()
|
||||
Returns the amount of active (in-use) objects in the pool
|
||||
|
||||
public int GetInactivePoolSize()
|
||||
Returns the amount of inactive (available) objects in the pool
|
||||
|
||||
public void Clear()
|
||||
[NaughtyAttributes.Button]
|
||||
Reset the pool. This will delete all pooled objects.
|
||||
|
||||
public GameObject Request(Vector2 position)
|
||||
Try to request an object from the pool. Returns null if nothing is available.
|
||||
|
||||
public void Return(GameObject poolable)
|
||||
Return an object to the pool, making it available to request again
|
||||
|
||||
public int GetGetPoolSize()
|
||||
[System.Obsolete("GetPoolSize")]
|
||||
No description provided
|
||||
|
||||
public int GetGetActivePoolSize()
|
||||
[System.Obsolete("GetActivePoolSize")]
|
||||
No description provided
|
||||
|
||||
public int GetGetInactivePoolSize()
|
||||
[System.Obsolete("GetInactivePoolSize")]
|
||||
No description provided
|
||||
Reference in New Issue
Block a user