Random servers fail to load animations, animation events are never fired

Randomly, some servers will refuse to fire animation events, or update their .Length, despite them being loaded and being played.
This is something I thought that Roblox fixed long ago, because this isn’t a new issue:

(This is a thread from 2022 where I tried to get help since I did not have bug report access, at that time, I had to make a workaround for it, but today, with optimizations and faster developing I want to do in my game, I cannot maintain the fix I made (which is getting the keyframes of the animation and manually getting their times, to execute functions needed on each, it also has limits due to optimization)

This was also been reported before but without a good visual demonstration, I tried bumping it but got no attention from staff:

Even the Strongest Battlegrounds (200k+ players daily) developer faced this issue and was ignored

I hope to bring this up again, which may finally help to get this issue fixed.
Since this happens with random animations with random servers, we cannot replicate it, we can only wait for the issue to happen to get to the server and see that’s the bug that is hurting the server.
This issue is very important for my game because i’m starting to use GetMarkerReachedSignal and Stopped events more, and my game is a fighting game, with those events breaking it will hurt my community heavily.

Video demonstration:

External Media

(You can see the first 2 hits do not cast a hitbox, due to GetMarkerReachedSignal not firing), then I execute a script in console to check animation Length and Stopped events, which do not fire, despite the animation being played.

Expected behavior

I expect the animation track events to be fired properly, and the properties to update normally, as it does in healthy servers.

2 Likes

Issues like this have caused us to completely stop using animation markers as they’re consistently unreliable. This needs to be prioritized if Roblox wants people to use their in-house animation system and not have to deal with awful workarounds.

2 Likes

This is just an acknowledgment announcement!

We’ve filed a ticket into our internal database for this issue, and we will update you when we have further information!

Thanks for the report!

I’d like to add that I’ve made a way to detect broken animations on my game servers. If needed, I can provide the specific servers and animations for staff to debug. I’m unsure of the process, but since the issue isn’t consistent, we can at least identify affected servers when problems occur:

1 Like

Got a server where ALL animations that had events being listen to, did not work, none of it was working, first time I see this, generally it’s only 1, 2 per server, this one broke all animations that I used :GetMarkerReachedSignal on, had to shutdown it manually.

1 Like

Still happening, players report it being disruptive in our ranked gamemode when it happens there too.

Still happening, I’ve figured some other stuff out, I was trying to get the keyframes only if the animations failed to try to manually use them, and noticed that the AnimationClipProvider will hang on the GetAnimationClipAsync forever when the animation errors, I’ve also noticed when the animation errors, it appears in the console:


There was a lot of lines just of those animation errors in this specific server.

Despite the animation erroring (which shouldn’t), they still play on the client, so I assume it’s a server only problem.
This is getting very common on my game, specially weekends or the ranked gamemode with new servers being created with potential of being broken.

To detect broken animations, I first check if the AnimationTrack length is 0, then after 3 seconds using task.delay I check again the AnimationTrack properties for those values: Length == 0, IsPlaying, TimePosition == 0, if the animation is not loaded and still playing 3 seconds after, it warns the developers which server is broken, joining we can see it is just how we expect and then shutdown the server to avoid players being frustrated with some actions not working properly.

This is taking very long to get fixed considering my initial report from 2022 and the bug report from 2023, Is this a problem that cannot get fixed? The developers are meant to not use Markers and use a workaround since they seem to not be consistent in random servers?

This has also been happening in my game for a long time and now that I’m rewriting my game I can rule out that it’s anything with our code that’s been causing it.

My game relies a lot on animation events (particularly .Stopped) from firing to be able to give rewards for doing things etc. I’m running into the same issues with some animations just not loading at all too, but less frequently than the Stopped event not firing when the animation has visibly stopped.

At the moment the only thing that seems to be viable is a janky solution where the Stopped event is awaited manually so that the expected code is ran after it ends (based on its TimeLength property), but this isn’t the best solution as it doesn’t account for cases where the animation is stopped manually using :Stop(). Not to mention that the issue with animations not loading at all would interfere with this solution as the TimeLength property would be 0.

If you’ve found a good workaround for this, would appreciate if you could share it. It seems like this has been happening for some time so it does make me wonder what hacky solutions bigger games have had to implement to work around this issue.

1 Like

One of my developers made an attribute to the animations containing all the animation data such as length, keyframes and markers, then we load the animation using a different function and we can return a “fake animation” object when needed, this fake animation object is essentially a table that mimicks everything AnimationTracks does, while a script simulates the animation running and simulates the events firing, etc. The only solution is coming with something else to cover the animations problems, but this isn’t as viable to me as a normal AnimationTrack would be, since if you modify the marker location for example you need to relocate it in the attribute aswell, all changes you make to the animation you have to feed the new info all the time, etc, not to mention the engine running the animation stuff would be better than having to rely on the Luau side, but it’s what we have to do till they fix it (if they do) I guess

2 Likes