Godot Version
4.4
Question
I’m making a little animation where I want to move an play some sounds when an instantiated scene is added to the tree. The first node plays with no problem, but the second one does not. I receive some debug messages that say that the animation player can not find the path to the nodes to animate.
Looking into that I noticed that if two of this nodes happen to appear in the tree at the same time, the second one will have its name changed from “Control” to “Control@88”, for example, and this breaks the animation.
Is there a way to make the AnimationPlayer consider the nodes it have to play without taking the parents node name into account? I tried calling clear_caches() in the _ready() but it did nothing, if that was what i was supposed to use…
Here, more details:
The Scene
The animations inside the AnimationPlayer have an absolute path
The first node when added, keeps the scene name and plays Ok
If a second one appear before the previous one leaves, the name changes and the animation breaks.
The cache warnings.