unity-behavior

Manage Unity Behavior graphs, agents, and blackboard variables through reflection-based skills.

Updated Aug 18, 2026
One-click install
npx skills add https://github.com/ethanJPope/Our-Main-Hackathon-Game --skill unity-behavior-ethanjpope
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: unity-behavior
Source: https://github.com/ethanJPope/Our-Main-Hackathon-Game/tree/main/.agents/skills/unity-skills/skills/behavior
Command: npx skills add https://github.com/ethanJPope/Our-Main-Hackathon-Game --skill unity-behavior-ethanjpope

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Wiring NPC and AI decision logic in Unity requires repetitive manual work in the editor: locating behavior graph assets, attaching BehaviorGraphAgent components, binding runtime graphs, and setting blackboard variables. This Skill automates discovery, agent wiring, and blackboard read/write operations for the com.unity.behavior package. ## Core Features & Use Cases - Graph Discovery and Inspection: List behavior graph assets with node counts and runtime state, and inspect node topology, blackboard variables, and subgraph dependencies. - Agent Wiring: Add BehaviorGraphAgent components to GameObjects and bind validated runtime graphs in a single idempotent call. - Blackboard Access: Read and set blackboard variables on graph assets or per-agent overrides, with type-aware value normalization for vectors, colors, enums, and object references. - Use Case: You are building NPC AI for a scene. Use behavior_graph_list to find your patrol graph, behavior_agent_add to attach and bind it to each NPC, then behavior_blackboard_set to configure per-agent patrol speed overrides. ## Quick Start Ask the assistant to check whether the Unity Behavior package is installed and list all behavior graph assets in the project.

Frequently Asked Questions about unity-behavior

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up a Unity Behavior graph on an NPC?

First confirm the com.unity.behavior package is installed with behavior_status, then locate the graph with behavior_graph_list. Use behavior_agent_add with the GameObject and graphAssetPath to attach and bind the agent in one validated call.

How do I read and write blackboard variables in Unity Behavior?

Call behavior_blackboard_list first to get exact case-sensitive variable names and declared types, then use behavior_blackboard_set. Pass a GameObject locator for agent-level overrides or graphAssetPath to change the shared asset default.

Can I edit behavior graph nodes programmatically in Unity?

No, node-level graph editing is deliberately not supported because the authoring graph uses versioned SerializeReference polymorphic data requiring the package's command pipeline. Author nodes in the Behavior editor window, then use these skills to inspect and wire the graph.

Why does behavior_blackboard_set behave differently in play mode?

BehaviorGraphAgent instantiates a private graph copy on Init, which only occurs in play mode. Edit-mode writes become agent-level overrides shown in the Inspector, while play-mode writes go directly to the running graph instance for that agent only.

What happens if the Unity Behavior package is not installed?

Every skill returns a structured PACKAGE_NOT_INSTALLED response pointing at package_install, since the package is optional and accessed through reflection. Install com.unity.behavior, wait for the domain reload, then verify with behavior_status.