-
-
Notifications
You must be signed in to change notification settings - Fork 23
PoolingSystem
Matt Dean edited this page Jan 15, 2020
·
1 revision
BACK > Scripting API
The main static class for kPooling. This class defines all the API required for creating and managing pools, as well as getting and returning instances.
return bool
Tests for existing Pool of type T with given key.
| Argument | Type | Description |
|---|---|---|
| key | object | Unique identifier for Pool. |
return void
Creates a new Pool of type T.
| Argument | Type | Description |
|---|---|---|
| key | object | Unique identifier for Pool. |
| source | T | The object to base instances from. |
| instanceCount | int | Amount of instances to create. |
return void
Destroys existing Pool of type T with given key.
| Argument | Type | Description |
|---|---|---|
| key | object | Unique identifier for Pool. |
return bool
Tries to get an Instance of type T from Pool with given key.
| Argument | Type | Description |
|---|---|---|
| key | object | Unique identifier for Pool. |
| source | out T | Returned instance. |
return void
Returns an Instance of type T to Pool with given key.
| Argument | Type | Description |
|---|---|---|
| key | object | Unique identifier for Pool. |
| source | T | Instance to return. |