Help with animation for a 3D turret model

Godot Version

Godot 4.3

Question

I have a 3D model of a turret with three animations:

Rotate: rotates turret one full turn
Elevate: elevates barrel from horizontal to vertical
Recoil: plays a recoil oneshot

I would like to combine these animations. I have an AnimationTree in which I have the three animations combined through ADD2 nodes with add_amount set to 1, so they are all playing properly on the model. The issue is, they all simply play to the end. I need to be able to set the frames on each of the animations, and it’s not clear how I do that.

This could easily be an XY problem; maybe I’m asking the wrong question? My intent here:

  • blend/add all the animations
  • position the turret by setting the animation frames for rotation and elevation to the appropriate values (eg: set the rotation animation to 0.25 to rotate 90 degrees, set the elevation to max by setting the elevation animation to 1.0)
  • play the recoil oneshot on top of the accumulated position
  • playback speed on the position animations needs to be 0, which I think I can do by setting speed_scale to 0, if I can figure out where

Assuming I’m doing this properly, I need to be able to find the animations used by the AnimationTree so I can control playback speed.

Ultimately, either I’d like to know how to access the animations feeding the AnimationTree, or if I’m doing this wrong, I’d like to know how to do this correctly. I’d prefer not to have to reach into the models and set bone positions manually.

I’m open to ideas here; I’m kind of stuck on this.

Sounds better suited to “poses” than actual animations, I would try using one-frame animations for a minimum and maximum pose, BLEND2 your rotate/elevate poses then ADD2 them together and play the recoil animation.

AnimationTree really likes playing animations so time seeking on it may be more difficult, but there is a TimeSeek node in the blend tree, and a TimeScale node I would set to 0.

I’ll give that a try. Thanks!

TimeSeek and TimeScale did the trick.