
initialize-ai-navigation
Sets up and configures Unity AI Navigation, including NavMesh surfaces, agents, obstacles, and links. Use when the user asks about navigation meshes, pathfinding, patrol routes, or obstacle avoidance.
- Installs
- 48
- Last 24h
- —
- Trending rank
- —
- Security
- Not audited
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/unity-technologies/unity-agent-plugin --skill initialize-ai-navigation- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads initialize-ai-navigation automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
SKILL.md
The instructions your agent reads when the skill is triggered.
Determine what the user needs and guide them through navigation setup. See navigation-system.md for expanded component details, API notes, code recipes, and troubleshooting.
Passing C# to script eval
script eval compiles a statement block, not a file. Two consequences, both of which cause a
compile error rather than a warning:
- No
usingdirectives. The compiler readsusing UnityEngine;as a resource-disposal statement and rejects it (CS0210). - Types must be fully qualified. A bare
AssetDatabaseorVolumedoes not resolve (CS0246/CS0103), and a bareObjectis ambiguous withobject(CS0104).
Where a snippet below is written as a file — with usings, for readability, or because it is
meant to be saved into the project — qualify the types before passing it to script eval.
Routing Logic
| User Says | Interpretation |
|---|---|
| "add navigation" / "set up nav" | Full setup: NavMeshSurface + bake + NavMeshAgent |
| "make this character navigate" | Add NavMeshAgent, ensure NavMesh exists |
| "add pathfinding" | NavMeshAgent + movement script |
| "agent won't move" / "path not found" | Troubleshoot — see Troubleshooting Decision Tree in reference |
| "avoid obstacles" | NavMeshObstacle with carving or avoidance |
| "connect two areas" / "jump across" | NavMeshLink between areas |
| "patrol between points" | NavMeshAgent + patrol script |
| "click to move" | NavMeshAgent + raycast click-to-move script |
| "animate the character while navigating" | Couple Animator with NavMeshAgent |
| "different agent sizes" | Configure agent types in Navigation window |
| "areas and costs" / "restrict areas" | NavMesh area types, modifiers, and agent area masks |
Workflow
0. Package Installation Check
Before doing anything else, verify that com.unity.ai.navigation is installed. If it's missing,
add it to Packages/manifest.json under dependencies — Unity resolves it when the Editor next
regains focus, and this needs no Editor connection:
"com.unity.ai.navigation": "<current 2.x version>"
Don't invent the version string. Read the current one from the Unity registry —
https://packages.unity.com/com.unity.ai.navigation lists every published version — or copy the version an
adjacent Unity package in this manifest already uses. A version that doesn't exist makes
Unity fail resolution silently, so a wrong guess looks like nothing happened.
Proceed only once it's confirmed installed. If you have a live Editor to run C# in, see
navigation-system.md for the Client.Add equivalent.
1. Pre-Flight: Assess Current Navigation Setup
Before making changes, inspect what already exists:
- Find the existing navigation components. With a connected Editor, query the live scene for
NavMeshSurface,NavMeshAgent,NavMeshObstacle,NavMeshLinkandNavMeshModifier— see theunity-cliskill for driving a running Editor. Without one, search the scene and prefab files for those component names. - Check configured agent types via Window > AI > Navigation > Agents tab.
- Summarize ALL detected navigation components before proposing changes.
2. Gather Missing Information
Before creating components, ensure the user has specified: walkable surfaces, agent type/size, agent behavior, obstacles, links, and area/cost requirements. Ask if anything is unclear. See the Information Gathering Checklist in the reference for full details.
3. Planning & Execution
Follow this general order. See the Component Setup Guide in the reference for detailed step-by-step instructions per component:
- NavMesh Surface — create the walkable mesh (bake it)
- NavMesh Agent — add pathfinding characters
- NavMesh Obstacle — add dynamic obstacles
- NavMesh Link — connect disconnected NavMesh areas
- NavMesh Modifier / Modifier Volume — fine-tune area types
- Scripts — movement, patrol, click-to-move, animation coupling (see Common Recipes in reference)
4. Validation
After setup, confirm:
- NavMesh is baked and visible (blue overlay)
- NavMeshSurface agent type matches NavMeshAgent agent type
- Agents have a valid path to their destination
- Obstacles carve or obstruct correctly
- Links have both ends connected and Activated is enabled
- Area masks allow the intended movement
- No conflicting components (see Mixing Components Guide in reference)
- If using Rigidbody with NavMeshAgent, Is Kinematic is enabled
5. Final Confirmation
Summarize what was created or changed:
- NavMesh Surfaces: which GameObject, agent type, geometry mode, bake status
- NavMesh Agent(s): which GameObject, speed, stopping distance, area mask
- NavMesh Obstacle(s): which GameObject, shape, carve on/off
- NavMesh Link(s): start/end, bidirectional, area type
- Scripts: which scripts attached to which GameObjects
- Any manual steps required (adjust waypoints, re-bake after scene changes, etc.)
FAQ
What does the initialize-ai-navigation skill do?
Sets up and configures Unity AI Navigation, including NavMesh surfaces, agents, obstacles, and links. Use when the user asks about navigation meshes, pathfinding, patrol routes, or obstacle avoidance.
How do I install initialize-ai-navigation?
Run npx skills add https://github.com/unity-technologies/unity-agent-plugin --skill initialize-ai-navigation in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/initialize-ai-navigation/ (personal) or .claude/skills/initialize-ai-navigation/ (project).
Which AI agents can use initialize-ai-navigation?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is initialize-ai-navigation safe to install?
No partner security audit is available yet. Skills can run commands and scripts, so read the SKILL.md and any bundled files before installing.
Who maintains initialize-ai-navigation?
It is published by unity-technologies in unity-technologies/unity-agent-plugin. It has 48 recorded installs.
More from unity-technologies/unity-agent-plugin
unity-cli
unity-technologies/unity-agent-plugin
Controls the Unity Editor and projects from the command line, driving a running Editor to edit scenes and assets or run C. Use when asked to install or manage Editors, licenses, or projects, set up version control, build, test, configure the Unity MCP server, or run any unity command.
urp-postprocessing
unity-technologies/unity-agent-plugin
Sets up, configures, and debugs URP post-processing with the Volume framework. Use for bloom, tonemapping, color adjustments, depth of field, vignette, or other Volume overrides.
ui-ugui
unity-technologies/unity-agent-plugin
Open the skill to read its SKILL.md instructions.
unity-package-management
unity-technologies/unity-agent-plugin
Open the skill to read its SKILL.md instructions.
ui-uitk
unity-technologies/unity-agent-plugin
Open the skill to read its SKILL.md instructions.
localization
unity-technologies/unity-agent-plugin
Sets up and configures Unity Localization, including locales, String and Asset Tables, and CJK fonts. Use when the user asks to add languages, translate UI text, or mentions i18n or multilingual support.
Popular other skills
hyperframes-cli
heygen-com/hyperframes
The HyperFrames CLI by job - scaffold, check, look at frames, edit the timeline, preview, render locally or in the cloud, publish, project history - plus reading its JSON and recovering from build or render failures.
triage
mattpocock/skills
Move issues and external PRs through a state machine of triage roles, categorise, verify, grill if needed, and write agent-ready briefs.
ask-matt
mattpocock/skills
Ask which skill or flow fits your situation. A router over the skills in this repo.
to-questionnaire
mattpocock/skills
Turn a decision you can't fully answer into a questionnaire for someone else to fill in.
loop-me
mattpocock/skills
Grill me about specs for the workflows I want to build, within this workspace.