Animation that is unlooped on the server plays looped on the client

I have an NPC animation using an AnimationController playing an animation that is not supposed to be looped. It plays as expected in play mode from the editor; in client/server test or in the field, however, while the animation plays unlooped as intended on the server, on the client it loops indefinitely

It happens every time that I have seen.
You can see an example in this place:

If you click the “Play Animation” part you will see the crossbow unfold repeatedly on the client. If you have some way to inspect the server you’ll see it only happen once. I can share code or add you to a group if you like.

The bug started happening as soon as I tried to implement this animation, so I don’t know how long it has been in Roblox.

1 Like

Hmmm…
They added this property somewhat recently, so I wonder if this has something to do with it:

My guess is that the AnimationTrack’s Looped property might not be replicating across the server/client boundary correctly.

If you can get a reference to the AnimationTrack on the client, can you hook up a debug print and see if it’s Looped property is set to true or not?

3 Likes

Excellent question, and you’re right - Looped is true in the animation track on the client.
I’ve added a gui button to my sample place to demo.

1 Like