I've created an AnimationTree that contains a AnimationNodeBlendTree to control all the animations on my 3D character. One of the nodes is my tree is for the character dying, which I've implemented as a Transition node named 'dead'. When I set its state to 'dead' in code, the dying animation is played and it ends with the model lying still on the ground. At this point, I want to code to check that the animation has finished playing so that I can queue the enemy character for deletion. How can I check if this node has finished playing so that I can delete it from my scene?
I should add that the animations are imported from a Blender file, so I cannot manually edit them inside Godot to add things like function calls. Also, the death animation does not loop, so it holds on the last frame when it finishes.
