navcat docs
    Preparing search index...

    Type Alias AgentParams

    type AgentParams = {
        autoTraverseOffMeshConnections?: boolean;
        collisionQueryRange: number;
        debugObstacleAvoidance?: boolean;
        height: number;
        maxAcceleration: number;
        maxSpeed: number;
        obstacleAvoidance?: ObstacleAvoidanceParams;
        pathOptimizationRange?: number;
        queryFilter: QueryFilter;
        radius: number;
        separationWeight: number;
        updateFlags: number;
    }
    Index

    Properties

    autoTraverseOffMeshConnections?: boolean

    If true, agents will automatically traverse off-mesh connections with a linear interpolation. If false, the agent will enter OFFMESH state and populate offMeshAnimation data, but the animation must be implemented externally, and completeOffMeshConnection must be called when done.

    true
    
    collisionQueryRange: number

    Collision query range (in world units), determines how far to look for neighboring agents and obstacles.

    debugObstacleAvoidance?: boolean

    Whether to collect debug data for obstacle avoidance visualization.

    false
    
    height: number

    Agent height (in world units), used for visualization and spatial queries

    maxAcceleration: number

    Maximum acceleration (in world units per second squared), controls how quickly an agent can change velocity.

    maxSpeed: number

    Maximum speed (in world units per second), the agent will not exceed this speed.

    obstacleAvoidance?: ObstacleAvoidanceParams

    Obstacle avoidance parameters, configures the adaptive sampling algorithm for velocity planning

    
    

    DEFAULT_OBSTACLE_AVOIDANCE_PARAMS

    pathOptimizationRange?: number

    Path visibility optimization range (in world units), the maximum distance to raycast for path shortcuts.

    radius * 30.0
    
    queryFilter: QueryFilter

    Query filter used for navmesh queries, determines which polygons the agent can traverse and the cost of traversal

    radius: number

    Agent radius (in world units), used for collision detection and avoidance calculations

    separationWeight: number

    Separation weight, controls the strength of separation behavior from other agents, only applied when the flag CrowdUpdateFlags.SEPARATION is given

    updateFlags: number

    Flags that control agent behavior

    CrowdUpdateFlags