Calculate smooth transition between local space angles I'm trying to calculate direction of moving character (to rotate it's animation). I have something like this Character can have 4 cardinal directions. The rotation is calculated from the current cardinal direction. So for example For north we have 90 degrees from N to W and 90 degrees from N to E. From E to N we have 90 degrees and from E to S we have 90 degrees. The problem occurs when character is switching directions.It happens at about half the distance between cardinal directions. At this point current rotation is switching from negative to positive number (or other way around), and there is noticeable hitch. When for example going from E to N, it switches to N direction but it was at about 45 degrees which in N space it places for a frame or two between N and W directions. Why do I calculate angles in cardinal direction space ? Animations are prepared for strafing or moving backward (or any other angle) and I need to assume that the direction of animation is 0 degrees and calculate from here. Is there way to smoothly change angle between cardinal directions ? For now I tried to lerping between them when switching (which improved overall look but is far from smooth transition), tried to track from which direction the switch is coming, but it didn't really improved anything. FVector Right Character gt GetActorRightVector() FVector Forward Character gt GetActorForwardVector() FTransform Transform Character gt GetTransform() FVector CurrentAcceleration CMC gt GetCurrentAcceleration() FVector CurrentVelocity CMC gt Velocity FVector AccelerationDirection CurrentAcceleration.GetSafeNormal2D() FVector VelocityDirection CurrentVelocity.GetSafeNormal2D() FVector LocalAcceleration Transform.InverseTransformVectorNoScale(AccelerationDirection) FVector LocalVelocity Transform.InverseTransformVectorNoScale(VelocityDirection) float DeltaTime Output.AnimInstanceProxy gt GetDeltaSeconds() float Atan2Angle FMath Atan2(LocalVelocity.Y, LocalVelocity.X) const int32 ChildIndex FMath RoundToInt((Atan2Angle 2 PI) 4) 4 float VelAngle FMath RadiansToDegrees(VelQuat.GetAngle()) float OldOrient CurrentOrient EFCardinalDirection Dir static cast lt EFCardinalDirection gt (ChildIndex) EFCardinalDirection OldDir static cast lt EFCardinalDirection gt (OldDirection) float DirDot 0 main switch wihin which I determine from where calculate angle. switch (Dir) case EFCardinalDirection N FQuat ForwardQuat FQuat FindBetween(Forward, CurrentVelocity) float OrientN FRotator(ForwardQuat).Yaw CurrentOrient OrientN FMath FInterpConstantTo(OldOrient, OrientN, DeltaTime, 300.0f) break case EFCardinalDirection E FQuat LeftQuat FQuat FindBetween(Right, CurrentVelocity) float OrientE FRotator(LeftQuat).Yaw CurrentOrient OrientE FMath FInterpConstantTo(OldOrient, OrientE, DeltaTime, 300.0f) break case EFCardinalDirection S FQuat BackQuat FQuat FindBetween(Forward ( 1), CurrentVelocity) float OrientS FRotator(BackQuat).Yaw CurrentOrient OrientS break case EFCardinalDirection W FQuat RightQuat FQuat FindBetween(Right ( 1), CurrentVelocity) float OrientW FRotator(RightQuat).Yaw CurrentOrient OrientW FMath FInterpConstantTo(OldOrient, OrientW, DeltaTime, 300.0f) break default break