AIBehavior is the base class for most AI scripting. AIBehavior replaces MonoBehavior and uses a modified Start/Update system to support the AI thinking pipeline. AIBehavior is typically managed by the Mind associated with an AI, which controls the timing and activation of the AIBehavior code. The contents of the InitBehavior and Act methods are up to the developer, but typically contain AI specific code that utilizes other supporting RAIN functions such as Steering, Pathfinding, Sensors, etc. More...
Public Member Functions | |
virtual void | InitBehavior (Agent actor) |
InitBehavior replaces MonoBehavior.Start() and is used for script initialization. Timing of InitBehavior is controlled by the Mind, but typically occurs before the first Act() call. | |
abstract bool | Act (Agent actor, float deltaTime) |
Act replaces MonoBehavior.Update() and is used for per-frame behavior generation. Timing of Act is controlled by the Mind, but typically occurs during the LateUpdate() step per frame. |
AIBehavior is the base class for most AI scripting. AIBehavior replaces MonoBehavior and uses a modified Start/Update system to support the AI thinking pipeline. AIBehavior is typically managed by the Mind associated with an AI, which controls the timing and activation of the AIBehavior code. The contents of the InitBehavior and Act methods are up to the developer, but typically contain AI specific code that utilizes other supporting RAIN functions such as Steering, Pathfinding, Sensors, etc.
abstract bool RAIN.Core.AIBehavior.Act | ( | Agent | actor, |
float | deltaTime | ||
) | [pure virtual] |
Act replaces MonoBehavior.Update() and is used for per-frame behavior generation. Timing of Act is controlled by the Mind, but typically occurs during the LateUpdate() step per frame.
actor | The AI Agent this script is producing Behavior for |
deltaTime | timestep in seconds |
Implemented in RAIN.BehaviorTrees.BTActivationManager.
virtual void RAIN.Core.AIBehavior.InitBehavior | ( | Agent | actor | ) | [virtual] |