Component · navigation
NavAgentType
A named agent type: its own baked mesh (dimensions) and traversal costs. Agents select it through
NavAgent.profile == profile.Fields
profile
u32Mesh profile ID shared by the type's agents and its bake.
default 0
name
stringInspector name (Humanoid, Brute, Drone).
default ""
radius
f32Bake radius in metres.
default 0.3m0.01 – 10
height
f32Bake clearance height in metres.
default 1.8m0.1 – 100
climb
f32Maximum step height in metres.
default 0.4m0 – 10
slope
f32Steepest walkable slope in degrees.
default 45deg0 – 89
areaCosts
list<f32>Cost multiplier per area ID (index 0..15); missing entries are 1.
default []
areaMask
u16Areas this type may enter (one bit per area).
default 65535
Usage
Every edit is an undoable command: from the CLI as below, or the same JSON from an agent over MCP. See component.add and property.set.
Add it
ara do component.add -p entity=name:Crate -p component=NavAgentType --why "Add NavAgentType"Set a field
ara do property.set -p entity=name:Crate -p path=NavAgentType.profile -p value=0 --why "Tune NavAgentType"In a scene document
{
"NavAgentType": {
"profile": 0
}
}From C#
/// <summary>Configure a navigation profile for low steps.</summary>
public static void UseNavAgentType(Entity entity, in Tick tick)
{
ref var component = ref World.Get<NavAgentType>(entity);
component.Climb = 0.5f;
}From C#
Scripts read and write it with Get<NavAgentType>(); see the NavAgentType struct.