Extends: GSAIGroupBehavior < GSAISteeringBehavior
Calculates an acceleration that repels the agent from its neighbors in the
given GSAIProximity
.
The acceleration is an average based on all neighbors, multiplied by a strength decreasing by the inverse square law in relation to distance, and it accumulates.
Type | Name |
---|---|
float | decay_coefficient |
Type | Name |
---|---|
bool | func _report_neighbor(neighbor: GSAISteeringAgent) -> bool |
var decay_coefficient: float
The coefficient to calculate how fast the separation strength decays with distance.
func _report_neighbor(neighbor: GSAISteeringAgent) -> bool
Callback for the proximity to call when finding neighbors. Determines the amount of
acceleration that neighbor
imposes based on its distance from the owner agent.