I create sprint movementm how replicate it to multiplayer?

@Wapiti-Blue hello to make it work for the multiplayer you will need to change the speed for both the server and the client. Here is how you can do it.

  1. Create a variable bIsSprinting with type bool.

  2. Make it so it replicates with RepNotify

  3. When you do that you will get a function called OnRep_bIsSprinting put that code in there

  4. Create two functions: ServerWalk, ServerSprint and very important make them to run on the server in the details panel

  5. And this is what is left to do

Explanation: Everytime you change the isSprinting variable the OnRep_bIsSprinting will call taking the side(Server/Client) based on what side the bIsSprinting was changed. Like this we are able to replicate our speed for more information about multiplayer in unreal engine i recommend reading this: Multiplayer in Blueprints | Unreal Engine 4.27 Documentation

Edit: I also read you have ticked somethings evolving replication yeah uncheck them everything you need is already selected for you by default.

2 Likes