Since I have updated to 4.15, my animation blueprint gives me warnings on pure functions from my AnimInstance class, custom anim node implementations and various functions within the animation blueprint. Since I am using a lot of these to drive the animation, the warnings of course reflect this.
So, what does thread safe even mean and how do I make something thread safe? I have never worked with multi threading before, so this confuses me and, well, those warnings are REALLY annoying.
We need a way to mark e.g. pure functions as thread safe to supress these warnings. I haven’t yet found a way to do this, could someone from epic confirm whether it’s possible to do this in UE4.15 or if it will need a fix in a later engine build. From a workflow perspective I’m expecting something like the pure toggle to mark the function thread-safe.
UFUNCTION(BlueprintCallable, meta = (BlueprintThreadSafe))
I think you should ensure that you don’t query e.g. the character in these functions. The way I got around this is to rather push values from my Character during its tick to the AnimInstance instead of the AnimInstance querying the Character params. It unfortunately requires a lot of duplication.
If you do like that the variables used in the animbp but updated from outside may change in between BlueprintThreadSafeUpdateAnimation calls, so you have to take that into account.