Replicated movement jittering

Hi,

I’ve spend two days trying to find any answer with no luck, so I would like to post question here. The problem in “jittery” movement when using character movement component built in replication. Here is link to video:

I’ve tried different setting under character movement (networking) section. And it doesn’t affect problem enough.
In video I used Net PktLag 50, 100 and 150. And I found that on 50 it jitters more than on 100 :confused:

I also find that jittering noticeably affected by NetUpdateFrequency (in video it set on 60). But again if I use NetUpdateFrequency=100 and fps=60 caps it’s jitters more than on NetUpdateFrequency=60 and fps=60.

And now I understand that I don’t understand build in movement replication behavior :slight_smile:

The weird thing that jittering occur even in full speed continued movement in one direction. I mean, any prediction errors should not affect lagged on 50 ms movement when we moving with constant speed in one direction. Whats going on here?

Any ideas how all this stuff working and how to configure it?

My guess would be, that you also replicate the location or rotation somewhere else.
Make sure that you only replicate components that really need to be replicated (the CharacterMovementComponent does NOT need to be replicated!).
The CharacterMovementComponents replication does work out of the box, so the problem is caused by you.

That’s interesting guess, but no:)

I found what’s going on. It wasn’t mentioned in documentation (or I missed it), but there is one important thing: location smoothing actually applied not to the CapsuleComponent (root), but only to SkeletalMesh itself (it’s only cosmetic). And since for debug purposes I just added my own StaticMesh on the top, I saw all that root jittering.