Animation Status Update (Q3 2024) Unite Announcement

Well, this post will make a nice departure (and arrival) from my previous ones!

I think the correct term is WOO HOO!
So excited to be able to share this announcement with all of you, as we have all waited long enough.

While this post coincides with my regular quarterly updates, it really just serves as a follow-up to our first official announcement about the new animation system, which was shown at the Unite 2024 roadmap session on September 19th 2024.

Here is the link to the entire Roadmap presentation on Youtube. However I have started it at the animation section.

The roadmap session is a look at what we are currently working on, which we hope/expect/should appear in a future version of Unity. During this session, we took a look at the new animation system in more detail.

As the session is not a deep dive but more of a glimpse, I will attempt to put a little more colour into what was shown, as it will no doubt generate a ton of questions. I will also try to follow the presentation order as much as possible.

Note, the content used during the animation section of the roadmap presentation started out as the FPSSample, but was rebuilt, simply to test the new system internally. So it is not supposed to represent the end result of where it can go, but rather to simply illustrate some of the new capabilities; and in a way which might give a reasonable comparison to a known Mecanim project.

Three big things before we begin:

  1. I want to remind everyone that I can’t always respond to every question, especially if they are overly technical, or due to my not always having time, maybe double-secret probation stuff, or other constraints.
  2. These are highlights only. Expect more to come in the future.
  3. Even though we have shown some highlights, STUFF CAN CHANGE!

Note. Below I have included some direct quotes from the presentation in italics.

Right then, here we go.

Intro

In my previous post, I mentioned we needed to think far ahead. So a big focus for the new system is being prepared to handle massive animation demands for many years to come, no matter the team size. Smaller teams will want need to punch above their weight, and larger teams will demand a high degree of flexibility and customization.

Typically there is always at least one person who wears the hat of a Gameplay Programmer. They represent the design vision and write the gameplay code related to characters, cameras and controllers. They also support Technical Animators and Animators. The Technical Animator is most frequently the link between animators and gameplay programmers. Amongst other things, they oversee character creation, and create custom tooling to control the animation pipeline between the DCC and the engine.

Digging into these roles and what they need to be successful has been the basis for our initial design. If we try and please everyone for everything in the first iteration, we actually will end up pleasing no one. Sure, there will always be exceptions, and nuance in these roles for every production, but during our many interviews (yes, we actually did loads) we understood these roles to be the cornerstone of the animation pipeline.

Previewing

Animation - Preview

We will start with a really big change. You will see everywhere in the new system, that in just one-click, you can preview everything in a project, without having to load it into the scene first. This will reduce frustration and human error, as it only shows the compatible clips that the character can use.

This really is a big deal, but it sounds so innocuous. I am sure many of you at some point have struggled to know exactly what could be used where, and sometimes went bonkers as you probably ended up loading everything into one scene, as it was the only way to preview everything.

We added a kind of “scene within a scene” to enable a better previewing workflow. There will probably end up being some limitations, but man it opens up a world of experimentation. You will no longer bang your head on your desk as you try to navigate hundreds of clips to find compatible ones, especially when they’re all named “idle 001”.
For another preview example, check out the sockets section as well.

We are really excited about this new previewing workflow, and I am pretty sure you all will be too.

Skeleton Editing

Animation - Skeleton Editing

In a similar vein as above, knowing exactly what is in your imported file (like an FBX) is not only a bit of a black art, but often rather fragile, as any changes you need to make requires breaking the link, since the file is read-only. This workflow really needed to be changed.

When bringing in your FBX file, I am pretty sure, the first thing you want to do is look at your skeleton hierarchy, then wanting or needing to make just some small edits, like renaming to your convention, disabling the face, or making larger edits like changing the default pose from T to A etc. Then if you make a change in your DCC, all that hard work was a major pain to redo or manage. Well, these changes will not only be simple to achieve, but are stored locally, making updates from the DCC far less painful.

Sockets

Animation - Sockets

There is a new socket object which is used as a virtual transform. It no longer has to be fragile bones made in the DCC.

While we see this as a requirement for pretty much every 3D character, you can use sockets whenever you want to attach one object to another.
Because we have made it a dedicated object in Unity, we can make a bunch of assumptions and workflows around it. It does not get destroyed when updating the original character hierarchy, and so all of its position and orientation are kept, as well as any graph rigging setup (see below).

For anyone who has set up more than one character with more than one weapon, I am pretty sure you have at one time said “OH FFS, I just want to preview all my weapons with all my characters and animation in one place PLEEEEASE!” Instead, you end up loading everything all into one scene, yet again.

Well, that is a statement we never want you to have to utter again, as you will be able to preview AND edit the socket, ensuring the position and orientation are correct for all animations.

Clip Markup

Animation - Clip Markup

The presentation video had to start somewhere, so maybe clip markup is slightly out of order, given you might add that before sockets, but anyway here it is.

In Mecanim, we currently force you to make permanent decisions when importing, while offering limited customization, basic previewing, all restricted to inspectors only.

It is slow with large data sets, limited to read-only clips, and adding animation events is via an inspector only. This is a major source of frustration for pretty much everyone, and well, that sucks.

So there will no longer be commitments up front when importing, as you will be able to preview everything, edit your clip, and add custom properties. You will be able to create and edit animation events using multiple tracks and range markup.

The multiple tracks and range markup is going to give you sooo much more control, especially when using it in the state machine. But it will also address some events not firing, as before they all used to be on the same frame, and if a frame was dropped…boom! Everything got screwed up.

Clip Markup should give you a truck-load more freedom in how you manage events, making gameplay much slicker for one.

Remapping

Animation - Remapping

You will be able to remap anything to anything, independent of naming, hierarchy or proportions. It will even work offline and at runtime.

It will be a universal solution, fully customizable, supporting things like non-bipedal, fingers, tails, faces, backward legs, etc. You will be able to remap 1:1, 1:Many, Many:1, and it should all work with any custom constraint. All of which can be saved as a template.

Remapping covers the vast majority of use cases, though does not try to “retarget” things like IK constraints, which means you will have to manage the constraints yourself (see custom nodes later.)

Graphs and Tooling

Animation - Graphs and Tooling

Oh boy, this is probably the biggest shift for us, resulting in a serious investment in graphs in general and their tooling. Graphs are at the center of everything in the new animation system.

They are designed to give Technical Animators more creative freedom for all their gameplay implementation, without having to code. Graphs are approachable yet extensible, and will reduce production bottlenecks, as they ease the burden on programmers. They are built on a new graph stack, and can be packaged and reused.

A key point to understand is it will be a choice. You will be able to build what you need through code, or take advantage of the graph tooling, or a mix.

You will be able to set up, rig, debug (read more about visual debugging below) and reuse pretty much everything via a graph. Controlled by local and reusable blackboard variables, they can even feed into the State Machine, all without having to write a line of code.

Sub-graphs will be a great way to manage or package parts of a graph, and will for sure be exciting for our Asset Store creators. Sub-graphs really will be a powerful tool for creating modular and reusable animation logic. They promote organization and flexibility in the animation workflow. Much easier to copy and reuse sub-graphs, than it is a bunch of code. Oh, and you will be able to use these graphs on different characters, independent of the skeleton, but, more about this at another time.

These new graphs and tooling will come with a comprehensive node library, but most importantly, you will be able to create your own custom nodes. A get-out-of-jail-free-card if you will! These custom nodes will also use the same backend as the shipped animation nodes.

Animation - Graphs and Tooling Overview

They are built on a new graph stack, which is an evolution of Graph Tools Foundation (GTF), with an optional runtime which is an evolution of Data Flow Graph (DFG).

This new graph stack will consist of an authoring and runtime layer. It will be multithreaded and should support horizontal/vertical layouts, debugging and live editing, flow graphs and state machines.

Okay now to veer off course for a bit. A follow-up question might be “What about GraphView?” Well, we are not touching it. It is still experimental and will be until the day it retires. We know it is still being used as there is no decent alternative from us, but hopefully, one day everyone will have migrated to the new system (including all of Unity), so there will no longer be a need for anyone to keep using GraphView.

I was going to do my Q3 update on just the graph stuff, but when it became clear we would be able to announce something at Unite, I thought to just wait, so I could include it here.

Hierarchical Layered State Machine

Animation - State Machine

I went into some detail in my previous post about this, so it is nice to be able to show you a peek behind the curtains now.

The all-new State Machine is truly hierarchical, designed to scale even if you have thousands of animation sources. It’s highly organized, and much easier to read, refactor and reuse, with layers, blend spaces, subgraphs and integrated rig graphs, as well as constraints and math ops

You will be able to easily swap animation while keeping your orchestration logic intact.
It not only offers a serious level of control over your production but incredible performance at scale

Just so you don’t have to completely review the old post, I’ll do a bit of a summary here.
Designed for performance at scale. it’s truly hierarchical, easy to refactor and reuse orchestration logic.
When it comes to transitions, we will support multiple per frame. Transitions can be time/ratio/metadata based, and can be overridden.

There will be per-bone weight masking, instead of per layer. Inside the State Machine you will have math ops and integrated rig graphs, AND access to constraints in states.

This sounds like a small point, but will have a big impact. Constraints in states will allow creating custom rig setups per state. Meaning, in one state you could have a graph controlling the IK on the lower body, and have a completely different IK graph in another state controlling the upper body. These rig graphs can then be activated or deactivated using the state’s transition system.

The new State Machine has inverted exit rules which will make life so much easier, because every state no longer needs to know all the exit conditions for all other things, so you will be able to exit from the parent state. The new system will also support multiple animation sources that can contribute to the frame’s final rendered pose.

A few other bits and pieces. Easy re-connectability of nodes, and copy/paste with connections. There are no doubt a few other things I have missed, but we will cover them in time.

The big takeaway is, as we examined the Mecanim architecture over the years, there was simply no way we could do half this stuff without pretty much rewriting it. Which is why we made a clean break, and started preparing the new State Machine for a long future.

Visual Debugging

Animation - Visual Debugging

Okay, while it is difficult to choose from everything we have gone through so far, I guess you could say I saved the best until last. Eh, okay penultimate, but that really doesn’t roll off the tongue.

Everyone knows that detecting erroneous setups or defective gameplay behaviors in an animation system are a huge time-consuming aspect of game development. So quickly identifying the source of these problems offers tremendous value for anyone in the animation pipeline.

Pretty much everything in the new animation system will be debuggable.
It starts with the animation “Recorder”. Anyone on your team can record then rewind animation game data and step through frame by frame. Not only step through, but step into. Whether a graph or the State Machine. You’ll be able to debug events, transitions, blackboard, inspectors, layers, and masks. Plus select/isolate in real-time as you navigate complex systems.
Sure it will help you accurately pinpoint the issues, but it will also mean you can iterate faster, identify bottlenecks early, resulting in higher fidelity gameplay.

We are working on live visual graph debugging, with in-game recording and replay.
Making it easy to navigate the source of any animation problem, no matter how complex the setup.
You can rewind game data and step through frame by frame.
Not only will it ensure you ship fewer In-game bugs, but also means you can afford to make large changes, even late into your production.

That last thing right there…is going to be massive! By making graphs and the state machine far more robust and easy to refactor, when you identify the problem you will have the confidence to make changes, even big changes, instead of avoiding the issue, praying it will not fall apart.

Pipeline and Performance

1000 Knights
Knight by Dmitriy Poskrebyshev Castle by Astrofish Games

The new animation system is designed with performance in mind.
It is built on ECS, and equally works with GameObjects.
Written in C# and HPC#, all animation runtime code is burst compatible, meaning high performance native execution. You will have control over execution order, and customizable phases, and all callbacks are deferred.

The ECS/GameObject flexibility is not to be overlooked. Even when you are using GameObjects we are still using ECS under the hood. So you can take advantage of the best of both worlds as you see fit, without having to make any decisions up front.

For instance Unity Entities/Baking animation runtime code is backed by Entities that offers optimized runtime memory layout for memory caching and data streaming, authored assets and runtime data. The new system can take decisions for optimization at runtime without impacting the authoring data, offering a more lean data representation at runtime, by optimizing transform marshaling inside a frame.

Some other stuff which might fly under the radar:

We have removed some old limitations such as sync point bottlenecks, not having deferred callbacks, and have removed the rebinding overheads when changing animations at runtime. This last one was simply not possible to workaround, and was such a major pain for so many productions. Now it will be gone.

So, what sort of performance can you expect?
Remember performance can be measured in different ways, such as by the number of transforms, or the cost of swapping animation, or whether code is Jobs/Burst compatible.

Well, to give you some idea regarding transforms, one early internal test has revealed we are far ahead of what we have today with Mecanim. This test has 300 characters, with 78 bones each, 10 clips and a 3 axial mixer, executing in under 2 milliseconds. It is still not finished, so this is pretty cool to see already. It will be even faster if you prefer a pure ECS implementation.

Another fun test was a couple of devs and a tech artist playing with some asset store content (in the above gif) to see how hard we could push the system. It was not optimized at all, just a test. But everyone was really happy with the result, so we decided to show it off at Unite.

We call it the 1000 knights scene. Here is the breakdown:

  • It uses HDRP
  • The new world building system
  • SpeedTree
  • Cinemachine
  • 40,000 DOTS physics rigid body arrows.
  • Each character was 100k triangles, had 24 bones, and used their own ECS StateMachine, and they were desynchronized.
  • Each had dynamic control of bones with constraint nodes, and used 2 sockets for their weapons.
  • Oh yeah, and it all ran at 30fps inside the Unity Editor.

Question Time

Some other questions I imagine you have.
I am guessing most of you are curious when you can get your hands on the new animation system?

  • Honestly I don’t know. The new animation system will be part of a broader Unity release, and not just a standalone package, so you will most likely be able to test it when it goes into open Beta. That will not be this year though.

When will there be more to see?

  • I suspect we won’t be showing much more until GDC.

What is happening with Mecanim?

  • As I have stated before, it will continue to be supported but not extended.

Where can I get more information on the new system?

  • As this announcement was only part of a roadmap session, getting into the nitty-gritty of what’s in, how it all works etc, will come at a future time. Again most likely at GDC.

Thank you!

This has been quite the journey already. Yes, we have made a couple of false starts along the way, but now that we can finally show you a proper peek into the future, I hope you are as excited to see it, as we are to show it to you.

I would also like to thank everyone in the Unity team who has helped us get to this point. For the past few years, they have been totally committed to delivering a solution that will make you proud you are a Unity user.

However, as with most teams who work behind-the-scenes, they rarely get the credit they deserve, but truly are the unsung heroes.

Chinny
Product Manager - Animation

76 Likes

This is beyond impressive, you can feel through all of these demos that you guys are passionate about improving this system without any spin or fluff and understand fully the needs of us developers when it comes to animations.

Stoked this team knows intimately existing bottlenecks and are highlighting the massive improvements that will rectify these shortcomings.

This is well integrated into the engine, the knee jerk reaction is “Holy moly this will makes our games MORE AWESOME and EASIER TO MAKE!” That’s the combo that really hits hard. Most all projects will benefit from this in massive ways and this opens Unity up to entirely new genres and games that push the envelope. We will absolutely 100% be able to make better games with less headache when you guys pull through on this.

Hats off, you guys “get it”. Hoping this success story can be a catalyst for more improvement.

THIS is what we need more of!

** The Unite showcase was a bit underwhelming, so it’s nice to get something so meaty here! This is the first thing I’ve seen from you Unity guys that inspires confidence in a long time. I’ll leave it at that as there has been no shortage of b*tching and moaning of late and I’m more than aware that this post may not entirely be welcome. I hope at the very least it’s a small consolation that you guys are winning over even the most vocal “haters” of the engine with this. An improved animations system this good is Huge.

5 Likes

Can’t wait to try it!

2 Likes

It’s… it’s beautiful. Thank you

3 Likes

Wow, this is a REALLY long post. And I enjoyed reading every word of it! The animation team really went far beyond for this one.

There were no mentions of determinism for netcode but honestly, it’s fine to save that for a later version. The existing feature set is already massive, like darn, this stuff is bloody impressive!

Can’t wait to get my hands on that new graph tools too. Just to be clear, it is general purpose and isn’t tied to the new animation system right? I have some other uses for it in mind.

Anyways, this is really great stuff. 2025 can’t come soon enough.

3 Likes

Very nice system look forward for tit :slight_smile:

Will we be able to play arbitrary animation on this system in runtime?
Like having coffee machine interaction animation on coffee machine script and play it on interacting character without the need to place that animation on character beforehand?

Thanks for the kind words.
Let’s circle back on determinism at a later date.
Yes, the graph tools are general purpose

4 Likes

Yes. More to come on that in the future

3 Likes

Thanks very much for the positive feedback, much appreciated.

4 Likes

I haven’t gotten around to digging into the details waiting until the Roadmap video is posted. After reading this post though. It seems you have gotten most of the important pieces from the animation system suggestion posted previously. I will do a deep dive and post more once I have all the information released so far.

For a first iteration you guys really knocked it out the park!

2 Likes

Good thing I have already prepared for disappointment with dotnet modernization already. Again with only promise for future and not even have beta for us to test it. Just waving picture of carrot to stall the bleeding. Even open beta is not in this year

Really, can’t it just be released as alpha right now?

But OK anyway. I would like to also ask what about this Animation Rigging | Animation Rigging | 1.3.0 package. Is it compatible in the new system or it was also be rewritten ? It seem the new system was already supersede this package too did it?

Also what about motion matching many people have been requested?

Hi there,
Many of you know me, I’ve been at Unity since 2011 and I’m one of the creators of Mecanim.

I’m so happy that we can finally start to show what we’ve been working on for the past few years. If it looks so amazing it’s because we did listen to all the feedback we’ve got over the years from all of you from the community up to AAA studios.

The new animation system is fully extensible and customizable, the state machine and graph tech stack is build on top of our low level HPC# API meaning that you can even hand code your animation behaviour if you wants to.

Can’t wait to see what you guys are going to create with this new system.

27 Likes

I may be in the minority, but I still think Mechanim is a pretty damned decent solution and I enjoy using it to this day. But this improved system looks LIGHT YEARS better!

What I love about this is you guys aren’t focusing on any high end bipedal type stuff,but instead focusing on tools that will make great GAMES and the process of making innovative gameplay systems and their subsequent visuals simpler and more robust. Really exciting stuff that will expand on the core of what Unity does best :+1: :+1:

4 Likes

The new system will indeed supersede the Animation Rigging package.

For Motion Matching, I did go into this a bit in my last post. In that “we are keeping Kinematica alive in-house to test it against the new system”
Whether we deliver a dedicated MM solution in the first version is still TBD though.

9 Likes

Oh man what a great update! Super cool stuff. Small question, will it be possible/easy to play one shot animations from code without having to do a bunch of other setup? I assume so, but always worth asking.

The remapping is cool. I am(was?) working on a remapping system haha. You are doing auto-mapping and it appears to be fully automatic. Is this just using the names to guess? I ask because I wonder how it would work for non-humaniods.

Funny enough I think one of the things I am most excited for is the new generic Graph system, that works at runtime too. Mostly because I do a lot of editor tooling. And probably because it was a surprise announcment, so more excited.

Anyway, the new animation system looks really cool, and its great to see a much cleaner and unified system! Thank you for the update and hard work!

4 Likes

Will we finally be able to create new AnimationClips at runtime like we could in the Legacy animation system? Needing to use the more than 10 year old system just for that one feature is … bad.

And speaking of Legacy, will it be going away? From what I’ve heard it still exists because of its unique features (i.e. creating animations at runtime) and performance (which the new system seems to focus on) so does that mean it will no longer be necessary?

Wow this is the best new Unity thing I’ve seen in a long time. I hope you put the roadmap video on YouTube asap, I think more people will be interested in that rather than the keynote.

2 Likes

Yes the plan is to be able to play one-shot animation from code :+1:

The remapping uses templates (which can be predefined) to direct what needs to remap to what, and how. We hope to make the population of these templates reasonably intelligent. Looking at naming and hierarchy etc. Anything it can’t work out should get its best guess, and any errors can simply be adjusted manually afterwards.

7 Likes

Will this properly replace Mecanim in Next Gen Unity or we’ll have yet another parallel system in place for the same thing?

yes, that’s the plan

Yes, at some point. But we will probably keep it around for a bit…just in case

2 Likes