# Tool.getDirection

Returns the direction of where the player is viewing or aiming.

**Kind:** Function

**Environments:** Game

## Game

``` { .lua .api-signature }
tool:getDirection(  )
```

[Open the full Game reference](../Game-Script-Environment/Userdata/Tool.md#getdirection)

**Availability:** Client only

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `tool` | [Tool](../Game-Script-Environment/Userdata/Tool.md) | The tool. |

**Returns:**

| Type | Description |
| --- | --- |
| [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The player's view direction. |
