AnimationTree choose an Animation based on named parameter

Godot Version

4.6.dev6

Question

Hello everyone, I’m trying to figure out one thing. I created a Character Node with an AnimationTree and an AnimationPlayer that has an “idle” animation of 4 frames that I run through AnimationPlayer by changing the frame property from 0 to 3 on the Animation. It works fine.

But when adding a new Character that has 6 frames, as expected the Animation gets cutoff when calling the “idle” animation.

In this case, the AnimationTree calls a specific Node on the tree (the “idle” animation). Is it possible to have an intermediate step to, based on a parameter, find which Animation it should execute, maybe the name of the animation. Is this something possible?

I appreciate any help on advance.

We are going to need to see your code.