Hey everybody,
I think I have a bug I have been stuck for the past few hours:
It seems that SetBlackboardValueAsBool and GetBlackboardValueASBool are not working properly.
When I set a breakpoint in c++ in those functions the KeyName says ‘None’
Would you know if there is anything wrong with my setup?
So this is the task that is calling both functions:
The tree run fine appart from the fact that the blackboard values are not read nor written properly.
I read that the beh trees are experimental, is that a known bug?
Additional info:
the task portrayed in the screenshot is the SetCurrentPlayer task
The IsTeamTurn decorator is supposed to read this CurrentTeam blackboard value but this is not working either. GetBackboardValueAs bool always returns false because the FName = ‘None’
I can’t see any place where you’re assigning value to the Current TeamFBlackboardKeySelector from the first screen. BB selectors are not super slick in terms of BP API so the most reliable way to pick values for them is to expose them to be set as BT node’s property in the BT asset.
It’s not enough to name a FBlackboardKeySelector the same as one of the BB keys.
Also, when building BP-implemented BT decorators you really want to use 4.7 (preview builds already available).
4.7 ? Okay I will try it as soon as it becomes stable.
the most reliable way to pick values for them is to expose them to be set as BT node’s property in the BT asset.
So I should implement a c++ version of that node instead? Using a FBlackboardKeySelector as a property ?
I can’t see any place where you’re assigning value to the Current Team FBlackboardKeySelector from the first screen.
Well there is a SetBlackboardValueAsBool there right?
So I should implement a c++ version of that node instead? Using a FBlackboardKeySelector as a property ?
I’m sorry, I assumed BP usage. C++ rulez and you can do anything with it
Well there is a SetBlackboardValueAsBool there right?
I meant the key selector variable in your BP, named Current Team in the first screen, doesn’t get it’s value set, so we don’t know which Blackboard key it refers to.
After a while I realised that I was not using parrallels properly so I am using services instead.
Also moving my nodes to c++ completly freed me. Blackboard values are now written and read properly here are details for the community: