Why use blackboards?

Hi guys - im new to unreal, and i’ve just started to implement som basic AI functionality.

I was wandering why one would use the blackboard as a memory storage for the AI component, instead of having a strongly typed class instance on the actor that runs the behaviour tree?

To me, it seems rather tedious to cast everything as actors/enums etc. everytime i need a task or a decorator. Could you guys enlighten me?

Thanks in advance :slight_smile:

I think this should help answer your question, there is a section with exactly what you are asking.

Blackboard Documentation

Hi Rekenq, thanks for reply - this a actually a rather good thread. Thanks for sharing.

But i fail to see how eg. 10 variables in a blackboard (that needs constant casting / and get-set blackboardvalues) is smarter than storing just 1 blackboard value as an object, and then just cast that single object and have strongly typed values to use on that object.

You’ll gain “Centralized data”, “Caclucation caching” and “Efficient Event-Driven behaviour” (as per the thread you posted)

I suppose casting andd checks if cast is valid is rather expensive on tasks that run frequently?

I feel the same way, did you ever figure this out?

Yeah, I don’t get it , too.

I finally ended up just creating my own AI within the actor’s blueprint so much more easier and it’s all right there in one spot

I finally ended up just creating my own AI within the actor’s blueprint so much more easier and it’s all right there in one spot