# sm.pathfinder.getSortedNodes

Find all nearby path nodes

**Kind:** Function

**Environments:** Game

## Game

``` { .lua .api-signature }
sm.pathfinder.getSortedNodes( worldPosition, minDist, maxDist )
```

[Open the full Game reference](../Game-Script-Environment/Static-Functions/sm.pathfinder.md#getsortednodes)

**Availability:** Server only

**Parameters:**

| Name | Type | Description |
| --- | --- | --- |
| `worldPosition` | [Vec3](../Game-Script-Environment/Userdata/Vec3.md) | The position to look in |
| `minDist` | number | Minimum distance around pos |
| `maxDist` | number | Maximum distance around pos |

**Returns:**

| Type | Description |
| --- | --- |
| table | Table of PathNodes sorted closest to farthest |
