Method ReleaseInstance
ReleaseInstance(GameObject)
Releases and destroys an object that was created via Addressables.InstantiateAsync.
Declaration
public static bool ReleaseInstance(GameObject instance)
Parameters
Type | Name | Description |
---|---|---|
GameObject | instance | The GameObject instance to be released and destroyed. |
Returns
Type | Description |
---|---|
bool | Returns true if the instance was successfully released. |
ReleaseInstance(AsyncOperationHandle)
Releases and destroys an object that was created via Addressables.InstantiateAsync.
Declaration
public static bool ReleaseInstance(AsyncOperationHandle handle)
Parameters
Type | Name | Description |
---|---|---|
AsyncOperationHandle | handle | The handle to the game object to destroy, that was returned by InstantiateAsync. |
Returns
Type | Description |
---|---|
bool | Returns true if the instance was successfully released. |
ReleaseInstance(AsyncOperationHandle<GameObject>)
Releases and destroys an object that was created via Addressables.InstantiateAsync.
Declaration
public static bool ReleaseInstance(AsyncOperationHandle<GameObject> handle)
Parameters
Type | Name | Description |
---|---|---|
AsyncOperationHandle<GameObject> | handle | The handle to the game object to destroy, that was returned by InstantiateAsync. |
Returns
Type | Description |
---|---|
bool | Returns true if the instance was successfully released. |