Utility Function Type

What is a Utility Function Type?


In TAI the Utility Function Type is used to evaluate different Plan Trees. Each Plan Tree is given a float score. The Decider Type can then use this information to aid in choosing which Plan to run.

Utility Function Types follows the familiar TAI ScriptableObject pattern of having a base class inherit from ScriptableObject. Custom logic can be easily achieved though a new class that inherits from the Utility Function Type base class and overrides its Evaluate method.

Included Utility Function Types


The base Utility Function Type class provides a few key ratios for determining how much weight side effects should be given versus the main Drive Level rate decrease. Side effects are any changes that occur that are not changes to the main DriveType changes. Drive Level rate is the total decrease to the main DriveType Level divided by the estimated time to complete the plan.

There is also a UtilityAIUTF provided which entirely uses Utility Modifiers to calculate the Utility of a Mapping. This should be used with the UtilityAIDT. (Utility AI Decider Type)