Class CallbacksRegister
Namespace: TycoonTerrain.Core
Assembly: TycoonTerrainAssembly.dll
Syntax
public class CallbacksRegister
Constructors
CallbacksRegister()
Declaration
public CallbacksRegister()
Methods
GetCallbacksForBounds(IntBound)
Get all the callbacks that lie within a given bounds.
Declaration
public IEnumerable<OnBoundsChangeCallback> GetCallbacksForBounds(IntBound bounds)
Parameters
| Type | Name | Description |
|---|---|---|
| Int |
bounds | The bounds to check against. |
Returns
| Type | Description |
|---|---|
| IEnumerable<On |
GetCallbacksForBounds(int2)
Get all the callbacks that lie within a given bounds.
Declaration
public IEnumerable<OnBoundsChangeCallback> GetCallbacksForBounds(int2 position)
Parameters
| Type | Name | Description |
|---|---|---|
| Unity. |
position | The position to check against. |
Returns
| Type | Description |
|---|---|
| IEnumerable<On |
IsHandleRegistered(CallbackHandle)
Returns whether the given callback handle is currently registered in this collection.
Declaration
public bool IsHandleRegistered(CallbackHandle handle)
Parameters
| Type | Name | Description |
|---|---|---|
| Callback |
handle | The handle. |
Returns
| Type | Description |
|---|---|
| Boolean |
Register(IntBound, OnBoundsChangeCallback)
Adds the given callback handler to the collection.
Declaration
public CallbackHandle Register(IntBound bounds, OnBoundsChangeCallback callback)
Parameters
| Type | Name | Description |
|---|---|---|
| Int |
bounds | The bounds. |
| On |
callback | The callback. |
Returns
| Type | Description |
|---|---|
| Callback |
Unregister(CallbackHandle)
Removes the callback and its bounds from the collection.
Declaration
public void Unregister(CallbackHandle handle)
Parameters
| Type | Name | Description |
|---|---|---|
| Callback |
handle |