Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

When playing an animation in player character, should you use a local script or a script?

Asked by 7 years ago
Edited 7 years ago

I was wondering whether you should use a local script or a regular script when playing an animation in a player's character

Can other players see the animation if filtering enabled is on, and the animation is played on a local script?

2 answers

Log in to vote
3
Answered by 7 years ago

Yes. Because the character's Humanoid replicates to the server, playing animations locally will replicated to the server automatically. A rule of thumb is to do whatever you can on the client, as to not slow down the server. And because you can do this on the client, you should.

If you were going to play animations for NPCs that everyone would see, you could do this on the server. But in this case, play the animations locally and they'll replicate.

0
Thank you! NovaMagic 73 — 7y
0
Should changing a player's walk speed also be done in a local script instead of a regular script in FE? NovaMagic 73 — 7y
Ad
Log in to vote
0
Answered by 7 years ago

I am almost 100% sure that animations can only be played from local scripts. As for the FE thing I have no clue sorry. My guess would be that FE doesn't impact the animation even if in a local script

0
Just checked on wiki. They should be played in local script. Here is the artical: http://wiki.roblox.com/index.php?title=Animations It says this in the "Playing Animation in Player Character" section User#15461 0 — 7y

Answer this question