ObjectPool.

TryReleaseOrDestroyGameObject<T>(ObjectPool<T>, T) Method

Summary

If the `pool` isn't null this method releases the `component` to it, disables its UnityEngine.GameObject, and returns true. Otherwise this method destroys the UnityEngine.GameObject and returns false.
Assembly
Weaver.dll
Namespace
Weaver
Containing Type
ObjectPool

Syntax

public static bool TryReleaseOrDestroyGameObject<T>(this ObjectPool<T> pool, T component) 
    where T : Component

Type Parameters

Name Description
T

Parameters

Name Type Description
pool ObjectPool<T>
component T

Return Value

Type Description
bool