Root motion with actors (not derived from characters)

I need to make my characters derived from actor, because i don’t need functionality that provides ACharacter(and another reasons), except Root motion

Code that provides root motion located in Character and CharacterMovementComponent modules.
I need to “copy” code that responsible for moving actor. But I don’t know where to begin unravel this clew.

I don’t need use anim montages, network replication. Only root component motion.

Can someone explain how it works about or reffer me to docs(that describe this process)?

Thanks

sorry for my bad english)

did it
maybe wrong, but it works

FRootMotionMovementParams RootMotionParams;

void AUnit::Tick(float DeltaSeconds)
{
if (SkeletalMesh)
{
FRootMotionMovementParams params = SkeletalMesh->ConsumeRootMotion();
RootMotionParams.Accumulate(params);
FTransform tr = SkeletalMesh->ConvertLocalRootMotionToWorld(RootMotionParams.RootMotionTransform);
FVector temp = tr.GetTranslation();
FVector prevLoc = GetActorLocation();
SetActorLocation(prevLoc + temp);
RootMotionParams.Clear();
}
Super::Tick(DeltaSeconds);
}