Animations, particles and sounds server vs client side

(I’m unsure about the category, if this isn’t the correct one please tell me).
I’ve always done particles, animations and sounds on the server, but recently I’ve been told that it’s worse than having a remote to replicate such things to every client. For example, instead of doing the following:

-- Server Side
local soundCopy = sound:Clone()
soundCopy.Parent = Character.Head
soundCopy:Play()

It should be:

-- Server Side
PlaySound:FireAllClients(sound, Character.Head)
-- Client Side
PlaySound.OnClientEvent:Connect(function(sound, parent)
local soundCopy = sound:Clone()
soundCopy.Parent = parent
soundCopy:Play()
end)

And the same approach for animations and particles, but why? I don’t see why you would play animations client vs server side (I don’t believe the server would be handling them anyway), can’t see why you wouldn’t play a sound server side if everyone is meant to hear it and I can’t see why you’d want to parent a particle on the client (if the server doesn’t simulate them). If anyone could share some light on this I’d be really thankful!

Mainly to lessen the load on the server, and to make the vfx smoother. For example tweens are a lot nicer on the client than if you did them on the server

That’s true for tweens and those I’m aware of, because it would have to send new property data everytime it updates. But as I said, I don’t believe the server handles/renders sounds, particles and animations. Feel free to correct me if I’m wrong though.

The server will render sounds and particles if you create and enable them on the server. Animations should be played on the client 99% of the time too because it replicates automatically anyways

Okay, I see. But just to confirm, animations are also handled by the server should they be played from there, right?

It depends, but I usually create the animation on the client and it just replicates automatically. (for 1 player animations) but if you’re working on a 2 player animation that uses an animation event for example, it’s a lot easier to handle if you play both on the server instead. (But you should normally be playing them on the client)

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.