Why Stop() only work on client?

Hello i have a problem with all my animations script
When i stop any animation its still playing on server screen
how can i make it stop on server screen too?

here the example

local CoolAnim = game.Workspace.CoolAnim
local UAnim = game.Workspace:FindFirstChild(player.Name).Humanoid:LoadAnimation(CoolAnim)
UAnim:Play()
wait(5)
UAnim:Stop() -- but its wont stop on server screen for some reason

thanks for trying to help

1 Like

Is this script a server script or a local script?

It would need to be done on the ServerSide, as anything that’s being represented on the ServerSide, will be replicated to others. (Most of the time)

So in your case, you need to use a Script.

Animations being done on player’s characters should be done in LocalScripts, however. But animations being done on NPCs should be done in Scripts. So actually, OP needs a LocalScript.

Example: The Animate script in the player’s character is a LocalScript, since it’s animating the player’s character.

1 Like

Indeed, I just thought about that. Thank You for that! :slight_smile:

Are you sure it’s not stopped on the ServerSide?
@Shakychn_cool

yes i am sure because when i checked it on server screen he still was playing the animation
and animation:Stop() was in script not in local in ServerScriptStorage

When you say “he” , is it referencing an NPC or a Regular Player?