Is it possible to blend a skeletal animation only on specified bones?

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By vrav

Hi there! I’m creating a 3D fantasy action game prototype and trying to plan ahead regarding animation blending. For example, I want the player to be able to walk with nothing in their hands, and also walk while holding a weapon or a shield.

Is it possible to blend in part of a skeletal animation only on specified bones? For example, I would blend from the pelvis down at 100% for the walk animation, blend in another animation for the left arm holding the shield, and finally another animation for the right arm holding the weapon.

I couldn’t find anything in the API that seems to reflect this possibility, and AnimationTreePlayer seems geared toward blending full body animations.

If I really have to create exponential full body animations for every combination of equipment, I can probably create a script for that in Blender, but ideally I would like to combine different animations for different bone hierarchies in the engine.

One possibility that comes to mind, if this isn’t possible via the animation blending API, is exporting the animation frames to a format readable by GDScript and using the skeletal bone transform API to blend them manually, but that seems like overkill. (Basically implementing custom animation blending in the scripting language.)