2019-12-19 20:04:08 +01:00
|
|
|
extends GSTAgentLocation
|
|
|
|
class_name GSTSteeringAgent
|
2020-01-27 18:57:51 +01:00
|
|
|
# An extended `GSTAgentLocation` that adds velocity, speed, and size data. It is the character's
|
|
|
|
# responsibility to keep this information up to date for the steering toolkit to work correctly.
|
2019-12-16 17:22:03 +01:00
|
|
|
|
|
|
|
|
2020-01-27 18:57:51 +01:00
|
|
|
# The amount of velocity to be considered effectively not moving.
|
2020-01-16 09:44:44 +01:00
|
|
|
var zero_linear_speed_threshold := 0.01
|
2020-01-27 18:57:51 +01:00
|
|
|
# The maximum amount of speed the agent can move at.
|
2020-01-22 17:55:49 +01:00
|
|
|
var linear_speed_max := 0.0
|
2020-01-27 18:57:51 +01:00
|
|
|
# The maximum amount of acceleration that any behavior can apply to an agent.
|
2020-01-22 17:55:49 +01:00
|
|
|
var linear_acceleration_max := 0.0
|
2020-01-27 18:57:51 +01:00
|
|
|
# The maximum amount of angular speed the agent can rotate at.
|
2020-01-22 17:55:49 +01:00
|
|
|
var angular_speed_max := 0.0
|
2020-01-27 18:57:51 +01:00
|
|
|
# The maximum amount of angular acceleration that any behavior can apply to an agent.
|
2020-01-22 17:55:49 +01:00
|
|
|
var angular_acceleration_max := 0.0
|
2020-01-27 18:57:51 +01:00
|
|
|
# The current speed in a given direction the agent is traveling at.
|
2020-01-16 09:44:44 +01:00
|
|
|
var linear_velocity := Vector3.ZERO
|
2020-01-27 18:57:51 +01:00
|
|
|
# The current angular speed the agent is traveling at.
|
2020-01-16 09:44:44 +01:00
|
|
|
var angular_velocity := 0.0
|
2020-01-27 18:57:51 +01:00
|
|
|
# The radius of the sphere that approximates the agent's size in space.
|
2020-01-16 09:44:44 +01:00
|
|
|
var bounding_radius := 0.0
|
2020-01-27 18:57:51 +01:00
|
|
|
# Used internally by group behaviors and proximities to mark an agent as already considered.
|
2020-01-16 09:44:44 +01:00
|
|
|
var tagged := false
|