Why isn't the object value being set in the behavior tree?

I’m trying to make this guy walk around when he hears a noise, and although he hears it, he doesn’t do anything.I thought I was making the proper connections setting the variable as an object and the decorator activating when the trigger is set, but every time nothing happens. He just stays idle. Can you tell me what I’m doing wrong from these pictures?

No I don’t. As a matter of fact I’m not sure if I’m even using an AI controller.

I’m going to be honest, I didn’t know how to plug in the AI controller. And when I got as far as I did without it I figured I didn’t need it.

I know I sound like an idiot, but could you please tell me how and where to plug it in?

Do you have this node somewhere in your AI controller?


Haha, no problem just wanted to make sure where we were at with unreal familiarity and BTs before I started trying to trouble shoot . So anytime you create a “Behavior Tree” you need to have an AI controller that will use it and then a pawn for that controller to possess. So you always create these 3 assets together anytime you are using Behavior tree AI. So the behavior tree is obviously the “brain” where you code all your logic of what you want the AI pawn to do. The controller is like the “nervous system” it directs the pawn’s behavior based on what the BT tells it to do. And the pawn is well…the pawn. So you have a behavior tree, but you need an AI controller, and then you need to tell your AI pawn to use the AI controller you created. You do that on the right hand side details panel of the AI pawn BP, select the “self” component and you should see that option for what controller to use in the details. As for the controller, now that the pawn knows who controls it, you need to tell your AI controller where to get the “instructions”. This can be hard coded with blueprint nodes by “you” within the controller BP or as you have chosen you can create a behavior tree to do that “thinking”. But the AI controller needs to be told it should get its instructions from a behavior tree in addition to whatever you code within it, hence where the “Run Behavior Tree” node comes in. That tells the AI controller to link up with a behavior tree and get instructions from it. Hope that helps.

No problem, guess you didn’t need the long explanation after all! Glad you got it figured out.

Not a problem friend. I didn’t start using behavior trees for close to a year after I started with Unreal. I always found them kind of intimidating and complicated and so I just scripted my own AI logic, worked pretty well for what I needed (none of my AI were too complicated). But I did pick up enough about behavior trees to help out I guess. If you have other questions don’t hesitate to ask

Actually Nevermind I fixed the problem. Thank you for addressing the real cause.

I’m just trying to get around UE4 so any info is helpful. Thanks for taking the time to write all that anyway.