IPoolReceiver Interface

Ultimate Pooling

IPoolReceiver Interface
Implement this interface when you want to receive spawned and despawned events sent to the pooled object. This interface will typically be implemented by a mono behaviour script that is attached to a pooled object which will then receive the appropriate event when it is spawned or despawned. Alternativley you can inherit from PoolBehaviour which provides default overridable behaviour for these events. (Modifies the objects enabled state to show or hide the object).

Namespace: UltimatePooling
Assembly: Assembly-CSharp (in Assembly-CSharp.dll) Version: 0.0.0.0
Syntax
public interface IPoolReceiver
UltimatePooling.IPoolReceiver = function();
UltimatePooling.IPoolReceiver.createInterface('UltimatePooling.IPoolReceiver');

The IPoolReceiver type exposes the following members.

Methods
  NameDescription
Public methodOnDespawned
Called when an object is about to be returned to the pool. Note that this method will not be called when the object is destroyed.
Public methodOnSpawned
Called when an object has been spawned from the pool. This event allows the state of the object to be reset so it can be treaded as a newly created object. Note that this method will not be called when the object is first created.
Top
See Also