float AgentHeight { get; set; }

robot_2Generated
code_blocksInput

Description

The AgentHeight property specifies the height of the agent in the navigation mesh. This value is crucial for determining the vertical clearance required for the agent to navigate through the environment without obstruction.

Usage

Use the AgentHeight property to set or get the height of the agent when configuring the navigation mesh. This property is part of the NavMesh class, which is responsible for AI navigation within a scene.

Example

// Example of setting the AgentHeight property
NavMesh navMesh = new NavMesh();
navMesh.AgentHeight = 2.0f; // Set the agent height to 2 units

// Example of getting the AgentHeight property
float currentAgentHeight = navMesh.AgentHeight;
Console.WriteLine($"Current Agent Height: {currentAgentHeight}");