Decider

What is a Decider?


A Decider handles all of the important decision making for an Agent. Specifically around when to plan and when to interrupt. It uses the Agent's Decider Type to handle all of the key logic. The Run method is the main entry point and is called every X + Random(Y) seconds by an Agent.


Click on the diagram for full size.

What is a Decider Type?


Script Reference

A Decider Type contains all of the key logic needed by the Decider. The Decider Type inherits from ScriptableObject (SO) and is a base class for Decider Types that can be added to an Agent Type. For example, UtilityAIDT inherits from Decider Type and overrides many of the Decider Type methods to implement a Utility AI decision process. There is usually only one SO asset for each Decider Type subclass unless your Decider Type has member variables. For more information on this pattern see the section on how Total AI uses ScriptableObjects for Logic Customization.

Planner Types


A Decider Type can have 0 to many Planner Types. It is up to the Decider Type to use these Planner Types to actually generate the Plans that it will then use to decide which Plan to run. It is most common for a Decider Type to have one Planner Type.