0
By Design

Follow action: can't follow a game object in a Behavior tree

Dornano 1 week ago in Behavior updated 5 days ago 6

I don't think it was made by design, but when I add a "Follow" action as a task inside a Behavior tree, I can't assign a Gameobject as a target. However, when I add the "Follow" action outside this tool, everything is working normally, I can put all the Gameobjects I want.


(Well done by the way for this Behavior asset. I just bought it today, and you made things easy for us, so great)

Unity version:
Game Creator version:

You are right.I see it only can select a game object from the assetsaand not the scene. Yes it would be nice to have this option.

I am sure Marti will take a look and see what can be done here.

Of course. Marti is the best x)

I just figured out that there is also the same issue when I want to drag and drop a local variable (bool) from my hierarchy to a condition inside the Behavior panel.

In behaviour you use the blackboard and use local variable, invoker or player and give it the same name in your behaviour tree and blackboard.

Then after saving the scene you can see in your behaviour component on the object that has the behaviour component you can now see that variable.

By Design

The Behavior Graph is a scriptable object and lives inside the Project (which doesn't know which scene is open at any given time). It's a limitation from Unity.

If you want to reference scene objects, you need to use, as Eagleeyez says, the Blackboard. In the Behavior component, you can sync the scene value.

Oh I understand. I was not aware of that. Well, I will try with the blackboard then, thanks ^^