#Should i do my animations locally or server-side
1 messages · Page 1 of 1 (latest)
u could do it locally but its better to do it on the server side so it will always know what the character is doing
uhhhhhhhhhhhhhh........ no you should ALWAYS play animations client side so that the server doesnt have to constantly replicate the animation to other clients. It better if u just tell the server im playing this animation then the server will tell the others to play the animation.
yeah but then i have to deal with replicating an animation with code and it still leads to the server having to replicate it
Not really, roblox does this automatically
use Humanoid.Animator instance
to load the animation
its better on the Client, it replicates automatically to everyone
But make sure the Animator exist on the server
wb a motor6d
Motor6D its the way to tell roblox what parts can be animated, but as i said, just use Humanoid.Animator:LoadAnimation()
Even if that is called from the client it will replicate
yeah no but like let's say i have a weapon and i want replicated animations for that
if i have a thing that i pick up, when i pick it up i should do it on the server, for validation reasons, but should i do the pick up animation on the client by sending a signal/picking up the pick up signal from the client aswell or do i just do it all on the server
If you already have it all handled in the server play the animation in the server, sending it to the client*** i think*** its extra work, not sure how it can affect performance but for control i think it should be on the server ( if the server already handles all that )
i'm using a proximity prompt here, so it can easily have code that runs at the same ish time between client and server
since you can receive the proximityprompt.activated on the server
Problem is server validation, if you have validation in the server it can go wrong if the client play the animation without passing the validation
but if you find a way 100% use client
ik tsb has this problem i believe where you try to pick up a bin, and you see the pick up animation but it doesn't work so u have to do it again
roblox servers already replicate animations to all other players.(its why u can see cheaters have custom animations). But you should ALWAYS let the client do the heavy lifting for replication stuff like effects since its MUCH better on ur network. You can just tell the server oh yea im casting a fireball then the server will tell the other clients to create the fireball where the client said this way the server doesnt have to go back and fort telling all the clients to replicate the fireball from this position to another this will just waste bandwidth or whatever its called.
yeah vfx on the client makes sense