GSAIMatchOrientation

Extends: GSAISteeringBehavior

Description

Calculates an angular acceleration to match an agent’s orientation to that of its target. Attempts to make the agent arrive with zero remaining angular velocity.

Properties

TypeName
GSAIAgentLocationtarget
floatalignment_tolerance
floatdeceleration_radius
floattime_to_reach
booluse_z

Property Descriptions

target

var target: GSAIAgentLocation

The target orientation for the behavior to try and match rotations to.

alignment_tolerance

var alignment_tolerance: float

The amount of distance in radians for the behavior to consider itself close enough to be matching the target agent’s rotation.

deceleration_radius

var deceleration_radius: float

The amount of distance in radians from the goal to start slowing down.

time_to_reach

var time_to_reach: float = 0.1

The amount of time to reach the target velocity

use_z

var use_z: bool

Whether to use the X and Z components instead of X and Y components when determining angles. X and Z should be used in 3D.