Method SelectTool
SelectTool(Transform, Type, bool, bool)
Select tools from the menu
Declaration
bool SelectTool(Transform rayOrigin, Type toolType, bool despawnOnReselect = true, bool hideMenu = false)
Parameters
| Type | Name | Description |
|---|---|---|
| Transform | rayOrigin | The rayOrigin that the tool should spawn under |
| Type | toolType | Type of tool to spawn/select |
| bool | despawnOnReselect | Despawn the tool, if re-selected while already the current tool |
| bool | hideMenu | Whether to hide the menu after selecting this tool |
Returns
| Type | Description |
|---|---|
| bool | Whether the tool was successfully selected |