Is it possible to replicate animations on each client (except movement)?

Hello dear community

I love the engine! A big thx to the epic devs!

Now to my question: Is it possible to replicate animations on each client (except movement)?

if yes, does it work only with states/state machines? Or just with montages?

I played around with replication and I always got to print out the message to all clients and the server itself. I am also able to distinguish the different options in regard to replication.
But I was never able to replicate custom animations. I don´t use a montage. I use the normal state machine.

The blueprint is pretty simple: When I press the LMB, a boolean is set to true. I cast it to the anim blueprint and execute it. It works without networking.

How would I tackle this problem? I don´t know, how to tell the clients that I did an animation and it should replicate to all clients.

I would be very happy if someone could give an answer/hint/solution :).

Thank you for reading.

Kind regards,

Here is how I do it:

Setup variables in your Character blueprint for managing the state of your animations (i.e. IsCrouching).
Set these variables to Replication: Replicated.

When the crouch key is pressed on the client, call a function on the server and change the value of the replicated variable in the Character blueprint on the server side. (Variables only replicate from Server to Client, they do not replicate from Client to Server).

The server function in the Character blueprint should be set to Replicates: “Run on Server” and the Reliable checkbox should be checked.

In your Animation blueprint use these replicated variables to set the variables that control your state machine. Set the variables using the Event Blueprint Update Animation node.

Thanks for the answer. I will try it right away. Sorry for the late response. Anyway, thanks again^^.

Oh My God , I’ve asked two question also in the anserhub , waiting , trying , frustrating , and getting mad .
Until I saw your solution , so big thanks .

Hey Guys,

just want to add these 2 pictures. First is from the Character Blueprint and the second one of the Animation Blueprint the Character is using.

i had this problem a while ago and also fixed it with help from here.
I think specially the first picture could help, with hold the overview and
know what happens.

i also used Dartanllas explanation and i think what you see is what he said :slight_smile:
correct me, if something is wrong.

Kick = could also something else

greetz.

You saved my day man :slight_smile: I’ve been struggling to do that for a few days already.

Awesome. Thank you very much for the help!

This helped me as well. Thank you :slight_smile:

why would you call a server event from the server?
Just call the dang event.