Calling track_set_enabled() multiple times slows down the game

Godot Version



I have multiple scenes (i cloned the player 20 times for testing) that need to call track_set_enabled() in order to allow, or not allow, an animation to use its call method track.

Apparently doing this operation many times is too much for the engine and the game starts to jitter until the animation is finished.

I also tried putting a delay in each of the cloned players to see if the problem was caused by the functions being called at the exact same time, and i got a ever increasing lag every time the call was made.

When i do track_set_enabled() multiple times from a single scene though, it works fine.

What is going on exactly? Is there any workaround to disable/enable tracks or animation events?

I highly doubt the issue is that. Still, you could try reproducing it in a new project and open an issue here Issues · godotengine/godot · GitHub if you are able to reproduce it explaining your problem and attaching that new project