However, it is freed from the memory before it can play the animation.
How can I implement this, but have it still play my full animation before it’s removed?
I haven’t tested that, but it’s similar to what I do with other nodes. Hope this helps
They could actually just turn off the looping function on the animated sprite.
ItsYoBoi | 2019-12-09 03:28
From the OP’s post, I don’t think looping is the issue. They want to remove the node, but only after the animation has had time to complete. Even with looping turned off, the call to queue_free will execute before the animation has played.
You can add a function track which calls certain functions at certain times(and can pass variables), you use it with the little + sign in the top left of the little animation box.
simply add that track to your scene and add a new key using right click on the track and you are free to go(or at least queue for it)
I can answer this for you. You don’t even have to write any code for it. If you go to the animated sprite and click on the “Dead” category you have for your character, you should see a “loop” option. If you simply turn that off, the animation will only play once.