Create Blend Space animation, choose UE5 mannequin, name as StrafeBlendSpace
Name and change horziontal axis and vertical axis, and tick snap to grid
Add the animstartpack to project, choose those 5 Idle Rifle anim (idle, joggle foward, backward, left, right) and retarget it form ue4 to ue5 character
Drag the rifle idle anim at all 5 direction points when speed is 0
Put forward anim in centre, left, right on direction -/+90, and backward on both -/+180 direction
Create a Anim BP, name as StarfeAnimBP
Drag the Blendspace in graph, promote variables speed and direction
To event graph:
Go to 3rd person BP
Viewport, choose Mesh component
change Anim Class:
To let character always look forward to the camera
in character movement component,
tick use controller dersired rotation; while untick orient rotation to movement
To fix snappy movement,
Open strafe blend space
add weight speed to 30
increase smoothing time to 0.35 on both horizontal and vertical axis: