-
Notifications
You must be signed in to change notification settings - Fork 0
Pooling.SendToPool
Andrés Eduardo Maldonado edited this page Jun 14, 2019
·
2 revisions
Static method from Pooling.
Collects the object to its pool then deactivates it, ready for next use. If it doesn't have a pool, it will be destroyed. A message in the console should confirm this.
This will call IPoolable.OnPoolUnSpawn.
// Called when we are done with this object.
public void Teminate()
{
Pooling.SendToPool(gameObject);
}
static public void SendToPool(GameObject obj)
Type | Argument | Description |
---|---|---|
GameObject | obj | The Game Object to take back. |