Blackboard variables not being overwritten

I have the following test behavior:

Where I have a blackboard variable called RunSpeed which is used by the FollowTarget action node as TargetSpeed parameter.

I have shorten the FollowTarget script to be:

public class FollowTarget : Action {
    public BlackboardVariable<GameObject> Agent = new();
    public BlackboardVariable<float> TargetSpeed;
    protected override Status OnStart() {
        if (!Agent.Value) {
            return Status.Failure;
        }

        Debug.Log("Target speed " + TargetSpeed.Value); // This returns 5.0f

        return Status.Running;
    }
}

As can be seen from the first image I had set up the blackboard variable to be 2, but when I use it in the node script it comes as 5.
The runtime debug log:
image

I believe the value of 5 comes from what is set up in the node inspector, but it should not be using that value, it should use the blackboard value.
image

I am using Unity 2022.3.29
Muse Behavior 0.10.1

Is there something that I am missing?
I have already pressed the Delete Runtime Assets button from the behavior graph, and restarted unity, but the issue persists.

I have made another experiment adding a new blackboard variable public BlackboardVariable<string> Test;

And then using it in the OnStart method of the node to print the value as Debug.Log("TEST value" + Test.Value);.
I would expect it to print “TEST value2foo”, but it’s not printing the name of the variable…

Now I am puzzled if there is a problem with the serialization of the Blackboard variables?

Ok, this is rather embarrassing I was looking at the wrong node in the BT X_x

That is because there are 2 FollowTarget nodes, I was looking at the wrong one.


:man_facepalming:

Sorry about that, I will let myself out :grimacing:

Easiest solution ever! Woohoo :slight_smile:

No worries, it happens. I’m glad it works. Phew! :sweat_smile:

Muse is being replaced with Unity AI and all Muse experimental packages are now sunset. Read more about Unity AI here: Unity AI: AI Game Development Tools & RT3D Software | Unity