Question Update: Why is motion matching not playing my walking loop animations?

I have just started experimenting with root motion in Unreal Engine, and I have faced a problem: Both Turn In Place and Idle animations have root motion enabled, and they are in separate states connected to each other in the state machine. From the Idle to Turn In Place animation state, the character turns 180 degrees using the Turn In Place animation, and when it transitions to the Idle state, it rotates back to whatever rotation the character had in the Idle animation.

Is there a setting that could help me keep root motion enabled for both animations while making Idle preserve the rotation that the Turn In Place animation had when it transitioned to Idle?

There is a Root Motion Root Lock setting that has three different options, but I’m not experienced with those.

Edit: I updated my question to this:

The snap back usually means the root motion only plays on the mesh and never reaches the capsule. Check three things. In the Anim Blueprint Class Defaults, set Root Motion Mode to Root Motion from Everything; the default only applies root motion from montages, so state machine animations turn the mesh and then reset. Keep Root Motion Root Lock on Ref Pose. On the character, turn off Use Controller Rotation Yaw and Orient Rotation to Movement while turning, or they overwrite the rotation the animation just applied.

(post deleted by author)