> For the complete documentation index, see [llms.txt](https://tg-dev.gitbook.io/tg-dev-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tg-dev.gitbook.io/tg-dev-docs/tg-waypoint/exports/client.md).

# Client

### Client Exports

All exports are client-side.

#### Set Waypoint

```lua
exports['tg-waypoint']:NewWaypoint(x, y, z)
```

Examples:

```lua
exports['tg-waypoint']:NewWaypoint(215.34, -810.12, 30.73)
```

```lua
exports['tg-waypoint']:NewWaypoint(vector3(215.34, -810.12, 30.73))
```

```lua
exports['tg-waypoint']:NewWaypoint({
    x = 215.34,
    y = -810.12,
    z = 30.73
})
```

Returns `true` when the waypoint is set and `false` when the coordinates are invalid.

#### Clear Waypoint

```lua
exports['tg-waypoint']:ClearWaypoint()
```

Returns `true` if a waypoint existed, otherwise `false`.

#### Open Settings

```lua
exports['tg-waypoint']:OpenSettings()
```

You can also open the settings menu with the client event:

```lua
TriggerEvent('tg-waypoint:OpenSettings')
```
