# GetNavMeshLayerNames()

> Get all the navmesh layer names.

## Definition

* **Type:** Method
* **Namespace:** [UnityEditor](/engine/6000.5/script-reference/unityeditor.md)
* **Assembly:** UnityEditor.CoreModule

> **Warning:**
>
> **Deprecated.** GetNavMeshLayerNames has been deprecated. Use NavMesh.GetAreaNames instead.
>
> **Upgrade to** [NavMesh.GetAreaNames](/engine/6000.5/script-reference/unityengine/ai/navmesh/getareanames.md)

```csharp
public static string[] GetNavMeshLayerNames()
```

### Returns

| Type                                                               | Description                                  |
| ------------------------------------------------------------------ | -------------------------------------------- |
| [string\[\]](https://learn.microsoft.com/dotnet/api/system.string) | An array of the names of all navmesh layers. |
