Animation pausing on client but not on server

I have a command that plays an animation (on a local script) when you type /surrender then waits for the animation to almost be done and pauses. The issue is, the animation is pausing on the one who sent the command but not the server.

Client:


Server:

Code:

currentAnimation:Play()
task.wait(currentAnimation.Length * 0.99) -- (I preloaded the animation btw)
currentAnimation:AdjustSpeed(0)

Please let me know if this is a studio bug or my script!

In the Animator documentation, it states that if an Animator object is under a Humanoid or AnimationController, the animation should run on the Client. The Animator object has to also be created on the Server to be replicated.

Well the animation plays, it just doesn’t pause at the end.