I heard character movement is automatically replicated and predicated.
But when it comes to launch character, it seems it doesn’t work well.
I’m running a dedicated server and two clients.
And I wanna launch my character during some periods by tick function.
there are some cases
Launch Character on server
There’s stuttering on my launched character. But it looks well in the other client.
Launch Character on client only
Different with other character movement like jump, Launch Character on Client is effecting client only. The other client player can’t see it.
Launch Character Multicast on server
Both client players can see the launched character, but there still a little stuttering on my launched character.
What is the best way to use launch character in multiplayer??
Thanks.
Generally the replication flow of these things is always kinda the same :
Listen for input (only on the controlling client machine, obviously)
Simulate movement (and FX) on controlling client machine
Send RPC (remote procedure call = replicated function) to server so the server can apply movement as well
Replicate info to other clients so they can apply movement (and FX) on your character as well
Each desired application does come with its own little twist though. For example in your case, you don’t need to replicate the Launch to other clients, because the builtin movement replication will handle it smoothly. If however you want to play some effects (sound,particles) along with that launch, then you will indeed have to multicast.
Hello. At first, Thank you so much!
But It works well when I set client number “1”, but when I increased the client user number “2”, the launched character start stuttering. actually, it seems stucked by invisible wall in his head.
What’s the problem?
Invisible wall generally means movement is not performed on server side. Client tries to move, server sends corrections, and client corrects itself back to whatever the server says.
I don’t experience any issue on my end with multiple clients and 200 simulated ping.
Maybe you have something set up wrong? You could share what you did.