Attaching client to moving pawn annoying jitter [HELP]

Hi,
I have a networking problem that’s driving me crazy the past week, using the ThirdPersonTemplate I have a dedicated server with 1 client, the server attach the client to a pawn using a socket then starts moving the pawn, everything is good but the client sees the pawn jittering badly.

here’s a video: UE4 Attach to component jitter - YouTube

Pawn is replicated and have movement replicated as well, pawn moves by the server with the FloatingPawnMovement.
Here’s how I attach in the server

The only way to solve the issue is to disable movement replication for the character after attaching it, but this leads to another problem which is that if I have multiple characters attached they’ll stop seeing each other at a certain distance.

My googling skills have failed me, please help. Thank you.

I have the same problem on 4.19.2. Could you find the solution?

Hi again, I found the solution. There are several ways to get rid of jittering:

  1. Disabling Character Pawn’s tick
  2. Disabling Character Movement Component’s tick
  3. Disabling Character Movement Component’s Replication.

I prefer the second one.

Hi, thank you for sharing your solutions, I’ve tried similar things and yes disabling the tick of the MovementComponent seems to work well, also sometimes you might need to disable the characters’s movements replication as well.

Cheers.

Hi, I have the same problem. I have a horse and a rider. I attach the rider to the horse, and then when I make him move, the horse starts to jitter a lot making the animation look bad.

Please note this problem happens only on DEDICATED server, will not happen on Listen Server started from the editor.

The following fixed it for me.

On the SERVER:

rider->AttachToComponent(ridingLocation,rules);

rider->SetActorRotation(FRotator(0, 0, 0));

rider->GetCharacterMovement()->DisableMovement();

rider->GetMovementComponent()->SetComponentTickEnabled(false);

rider->GetMovementComponent()->SetIsReplicated(false);

rider->GetCharacterMovement()->SetMovementMode(EMovementMode::MOVE_Flying);

rider->GetCapsuleComponent()->SetCollisionEnabled(ECollisionEnabled::NoCollision);

On the CLIENT:

rider->GetCharacterMovement()->DisableMovement();

rider->GetMovementComponent()->SetComponentTickEnabled(false);

rider->GetMovementComponent()->SetIsReplicated(false);

If you dont do the part on the client it will NOT work. You can find the same functions in Blueprints.

I suggest you possess the horse instead of attaching the character to it.
I think the issue with that is how the server is updating the location of the horse, it might be that it’s not smooth or it’s not interpolated.

I could be wrong.

Hi, Possess is not good for me, when you possess you “become the horse”, it means all my stats are lost, inventory is lost, any interaction, key setup, everything is lost. The solution above works very well for me.