I currently have AI enemy characters setup to follow the player, however their rotation seems to keep snapping towards the player and it looks awful and broken. I’ve tried turning on/off enable strafing, have tried desired rotation/orient rotation to movement, with the rotation rate set to 5, but it still consistently snaps towards the rotation instead of smoothly turning. Is there an option elsewhere outside the character I’ve missed?
I’d greatly appreciate a response as the way it rotates now looks like a rushed and broken system and I wouldn’t want to release a game like this.
Go to your AI Pawn and under Components > CharacterMovement > Enable “Orient Rotation to Movement”
Then under Defaults > Pawn > Disable “Use Controller Rotation Yaw” & Under Character Movement > set “Yaw” to a value you like (for example 180).
I hope that helps.
Thank you very much :D, the “Use Controller Rotation Yaw” was the option I had missed to turn off that fixed it :)!
This doesnt work at all. The “Orient rotation to movement” and so fort do absolutely nothing to the rotation smoothness. Is something changed in latest versions of UE???
enabling Orient rotation to movement only not going to work
u must go to your AI Pawn Class default, and do as he said :
“Then under Defaults > Pawn > Disable “Use Controller Rotation Yaw” & Under Character Movement > set “Yaw” to a value you like (for example 180).”
Or “RInterp To” node where the target is the players position and the node includes time and rotation speed.
From my experience, this does achieve slow rotation of the meshes inside moving actor towards the final rotation, but the direction of the actor’s root movement (the forward vector) is still changing instantaneously.
Say you’ve got 3 target points (or a baseball field for that matter) in NavMesh and you want the actor to run from one to the next. My question is, is it possible to achieve a trajectory similar to a real baseball player, who would run in a smooth trajectory, even if it’s a bit longer, and not running to 1st base, turning in an instant and run towards the second and so forth?
I had the same problem , but when I tried it on two different computers with one being the host and the other the client , it worked perfect , everything was smooth. But if I tried to launch 2 clients on the same computer , the rotation wasnt smooth.
Thanks TJ worked amazingly.
Just wanted to say thanks to SwiftIllusion, this was exactly what I was looking for!
Thanks a lot ! “Use Controller Rotation Yaw” was the option I had missed to turn off
Thanks for this, I messed with a bunch of rotation settings to get that working, but had missed the “Use Controller Rotation Yaw” under the pawn - definitely got the other settings working.
Check that your spring arm “Use Pawn Control Rotation” is also disabled.