Behavior Package 1.0.1 is released! Update: 1.0.3 is out

Update 1.0.4 is out! See the changes here Behavior Package 1.0.4 Released! Changelog inside

Update: 1.0.3 is now available! Changelog added above 1.0.2

We’ve released Behavior 1.0.1! You can now get it on the package manager and it should be visible for everyone on Unity 6000.0.16f1+ :partying_face:

We (the team) are very excited to share this with you and hope you’ll love this new tool.

Please use the Behavior tag to engage with us! The team is very active here to help users and take in feedback.

If you’re not familiar with Behavior, this is our new Behavior Tree / Behavior Graph tool for Unity 6. You can find our documentation here:

[1.0.3] - 2024-10-14

Changelog

Added

  • TriggerEvent now logs message when EventChannel is not assigned.
  • Added MakeSceneActive option to LoadLevel node for Additive mode.
  • Added new UI visualization for Shared blackboard variables.

Changed

  • Improved logging details when an exception is raised about an invalid node transformer.
  • Added logging on domain reload when any node BlackboardVariable is found that doesn’t have the [SerializeReference] attribute.
  • Added logging on domain reload when any Composite field of type Node is found that doesn’t have the [SerializeReference] attribute.
  • Added missing Switch node inspector.
  • Fixed Shared Blackboard Variable causing a stack overflow in case it was referencing itself.
  • Fixed invalid generation of Shared Blackboard Variable on the source runtime blackboard asset.
  • Blackboard variable Exposed and Shared values can now be toggled on and off from the variable instead of right-clicking.
  • Changed variable renaming to trim out any leading or trailing whitespace.
  • The branch generation correction feature has been disabled for backend related issues.

Fixed

  • Fixed dynamic subgraph not initializing local event channels.
  • Fixed dynamic subgraph overriding shared blackboard variables.
  • Fixed static subgraphs not passing down same type component variables properly.
  • Fixed audio resources being able to be passed into an audio clip link field when they shouldn’t be.
  • Fixed any component being able to be passed into any component link field instead of only when it’s a subclass.
  • Fixed cast variable types not working correctly in subgraphs.
  • Fixed subgraph blackboard variables not marked as exposed showing in parent graph node inspector.
  • Fixed a bug where StartOnEvent node (Restart mode) would only execute the first node of a sequence after restarting in case it was restarted by a TriggerEvent node on the same frame.
  • Fixed an issue with node wizard preview not displaying when typed variable fields were added.
  • Fixed Muse branch generation correction deleting the previously generated branch if a valid output failed to be generated.
  • Fixed placeholders not generating properly with generative AI.
  • Fixed top and bottom lines of edge where the end is above the start not being selectable.
  • Fixed Blackboard editor not syncing with changes from graph when the graph default blackboard was being edited.
  • Fixed nullref exception caused by renaming a type serialized in a Blackboard Variable.
  • Fixed blackboard and graph editor toolbar height changing on smaller window sizes.

[1.0.2] - 2024-09-20

Added

  • Tooltip to display the variable type name on story editor dropdowns.

Changed

  • Nodes that generate their own children (for example Switch and Flow nodes with named ports) will auto align their children better than before.
  • Condition context menu will show “Inspect Script” instead of “Edit Script” when opened for a built-in condition.
  • Switch Node: Removed the warnings about no connected child during operation to avoid spamming the log.

Fixed

  • Text truncate issues on story editor dropdown elements.
  • Blackboard variables from added blackboard assets can now be dragged and dropped onto fields in nodes.
  • Fixed CheckCollisionsInRadiusAction failling to assign collided object if the BBV value was null.
  • Nodes with inherited named children (i.e. Node connections) weren’t showing the base class’ nodes.
  • Fixed Event Channel variables not appearing in link searches for non-event nodes.
  • Fixed the Self variable not working in Dynamic Subgraphs.

[1.0.1] - 2024-09-18

  • Fixed an issue with the LinkField search menu popup element causing an exception on Event nodes.

  • Set variable value didn’t save the value if it was a cast blackboard variable.

  • Text alignment for conditions in the inspector will now center correctly.

  • Added missing space in variable comparison condition text.

  • Warning messages shown on GetVariable when trying to get an override variable from BlackboardReference.

1.0.0 changelog

If you missed the 1.0.0 release, which was pretty silent, here are the changes from the 1.0.0 preview:

Added

  • PlayParticleSystem node can now assign the spawned object to InstantiatedObject.

  • Conditions can now reference the GameObject associated with the graph.

  • Updated the vector LinkField UI to new improved design.

Changed

  • Renamed Unity Serialization Example to Runtime Serialization and Serialization MonoBehaviour class to SerializationExampleSceneController.

Fixed

  • Switch enum child ports weren’t interacting correctly after editing the enum while the graph is open.

  • Fixed a hang when deleting runtime assets when blackboards are referenced.

14 Likes

Interesting! I will try to give it a shot when I can.

3 Likes

Let’s see the tool in action

1 Like

Wow it’s immediately useful and extremely easy use. Even just using it briefly, impressed by how simple and powerful it is

1 Like

image
I did notice that these were generated at root of the assets folder of my test project when building (a WebGPU build)

Hey @Ofx360 ! I’m glad you like the package so far :slight_smile:

The IL2CPPTypes is needed to keep certain types used from being removed by the compiler / reference them correctly. As for the link file, we forgot to rename it to something more useful :sweat: I’ll need to check if it’s still needed and get back to you. Sorry!

FYI 1.0.2 is now out also! I edited the top post to reflect the changes :slight_smile:

3 Likes

Just my humble opinion, this package is the most important improvement Unity got over the last year. We work on games here, games have AI. And yet Unity, a game engine, had no tools for AI at all!
You either write them yourself or buy them.

And I tried many of solutions out there (I even sell one myself, he-he) and this behaviour package just better in every aspect.

We had graphics, we had physics, we had networking and now you guys covered the last base and did it great.

The only sad thing is that it doesn’t get all the attention it deserves, Unity doesn’t pitch it as much as other pillars. Hope it was matter of the official release and more and more people will appreciate your work.

Thanks! Congrats with the release!

Yeah, i figured! Though, i was wondering if its possible to generate those outside of the assets folder? Like in “Temp” within the project folder? That way there isn’t additional files being placed where people are working from, potentially confusing other or being checked into version control unnecessarily

1 Like

We’ll look into it! :slight_smile:

The timing of this could not be more perfect.

1 Like

Can I use this with ECS?

Can I use this with ECS?

At the moment this is using GameObjects and MonoBehaviours. ECS is on the roadmap.

1 Like

How do you bind to game state and create new nodes?
Best in class is PandaBT.

How good is the performance of Behaviour Graphs? What if e.g. I want to create a 2D scene with about 500 agents, all controlled by behaviour graphs?

The performance should be good in general, we are following best practices & we should be not creating to much garbage or overhead at runtime.

500 agents will be fine.

What do you mean exactly by binding game state?

Maybe I misunderstood something, but I can’t pass components to subgraphs – they always end up as ‘null’ there, regardless of whether they are custom or built-in components. Built-in types like strings and booleans, however, work perfectly fine.

parent graph:

sub graph:

gameobject:
grafik

console logs:

  1. [GameObject] colliderOnParent = GameObject (UnityEngine.BoxCollider2D)
  2. [GameObject] <no name> = null

Thank you for this package! :heart:

Thank you for having added this tool to Unity.
Just a question:
How can I execute a different branch from my code?
I think using messages would be an option. Is there an example of how to use a message from outside?
Thanks.

you can use a Restart If State changed followed by a switch on the state enum, as shown in the second half of the webinar https://youtu.be/sxeqj1HmDaM?feature=shared&t=1650
then in your code you’d do GetComponent<BehaviorGraphAgent>().BlackboardReference.SetVariableValue("State", newState);

1 Like