Group Object List and Restarting Behavior Trees

Hey,

So I am currently attempting to create something where if the AI agent takes damage than he will flee. I got that working thankfully. The question I have is when I want to restart the behavior tree for each person I don't want to restart it for each guard individually. I want to add a GameObject List variable for the "Guards" but obviously, that is not possible. Is there some way I can go around this? I provided some photos of the BT.

Thanks, David

Screenshot 01.JPGGuard.JPG
 
The group field is used if you have multiple behavior trees on the same GameObject. In your case you want to restart the behavior trees on different objects which the task doesn't support. To add support for that you'd change the behaviorGameObject field to a SharedGameObjectList field and then loop across those trees.
 
Top