Hello, I am watching a video about Patrolling & States using this video I’m at 28:40-minute mark
I am having trouble with the blackboards they show red when I try to use them
That shows that it’s condition is not met, therefore the tasks under that sequence composite of yours won’t be triggered.
I think I need to add one more thing. You might say, well other decorators’s conditions are also not met, how can they not have that red line next to them? It’s because even though their values are also false, they are not currently being checked. That red line you see here appears when the execution flow of the behavior tree ends up in a given composite which has a decorator on it, and fails to execute it.
What? I didn’t ask any questions, let alone a second one
If you’re referring to this:
I elaborated on my explanation based on a hypothetical question by you.
If you didn’t mean to ask the meaning of the red line there, but rather why your decorator fails, you’d need to provide additional infos such as:
- The screenshot of your blueprint where you set the blackboard key that stores a bool type variable inside which your decorator is bound to
- A screenshot showing in which conditions does that blueprint code where you set your blackboard key’s value to true as bool gets triggered
- A screenshot showing which blackboard key is your decorator bound to, which you can check from that window on the right side when you click on your decorator
Without these, it is not possible to know where your issue might be.
So… where’s the part where you set that blackboard key’s value as bool? With the current info, it seems like there’s no reason for that decorator to succeed. You need to have a set value as bool node, connect a make literal name node to it (and insert your blackboard key’s name in there), and set it’s value to true. Make sure the task you include this code is a task which can be executed. Do not perform this in one of the tasks that are under that composite of yours which has that decorator on it.
so i should put it in the BTD_Patrol_Route or else also should I do the same for the Combate State