I’m currently writing a burst capable HTN planning AI and I’m looking for a little advice.
Normally a HTN planner is programmed with classes and interfaces and all that which we don’t have access to in burst compiled code. For example there are many different tasks that all implement the same functions of ConditionsMet(), GetCost() etc etc.
My current solution is to use an enum for all the different tasks, and call a function containing a switch case to redirect the function call and parameters based on the enum.
While this is very doable and is working fine so far, am I missing something? Are there any better or faster techniques out there?