Is loading animations on the server bad practice, and if it is, why is it?

Good day to the beautiful people reading this:

For a project of mine, I’ve been loading combat animations on the server and they seem to be working fine, but after I mentioned how I did it to a friend he mentioned that it is bad to run animations on the server, and should instead be played on the client, which would automatically be replicated to the server.

Could one of you gigabrain chads explain why that is the case?

Much appreciated and have a great night y’all

7 Likes

Gigabrain chads? What :skull:

I… Honestly dont know, but it’s probably dosen’t matter. But probably the server, because sometimes the cilent wont replicate.

3 Likes

Here’s my take. It really does not matter, it just depends on your preference/what you’re trying to go for. Me personally I do animations on the client since for inputs it’s just easier like that.

Have a nice rest of your day or night!

3 Likes

loading animations on the client is a better idea instead of loading it on the server mainly for performance and such. there’s always a delay on the server when doing things, meaning loading animations on the server will always have a slight delay compared to the client. loading it on the client makes it feel more responsive and satisfying in general

that’s just my main reason for doing it tho. i recommend loading them on the client but if it works well for you then go ahead :+1:

2 Likes

Entirely depends on what the animation is for.

Is it for an NPC that exists on the server?

You are most likely controlling that NPC from a server script. Therefore, load it on the server.

Is it for the player’s character (or an NPC that only exists on the client)?

You totally could handle a player’s animations from the server if you wanted to, but generally it’s more practical to handle player animations on the client.

In most games the player/client is in full control of their character, so player animations need to be played from the client to be properly synced with player inputs. Otherwise, playing animations from the server may result in input lag between an input and the animation being played.

Additionally, if every player has multiple custom animations, keeping track of all of them on the server would be cumbersome, so storing animations on the client is also easier organizationally.

5 Likes

ty champ makes sense to me

take care!

1 Like

Animations ALWAYS play for everybody no matter if you play it from the client or server.

1 Like

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