FPS Character rotation
I'm trying to do walking around a sphere but have a problem now. My character doesn't want to rotate properly, see a screen with character position on the top and in the bottom of a sphere:
I'm using custom pawn without inherited components.
You need to uncheck Use Pawn Control Rotation on the FirstPersonCamera settings. This controller rotation is designed for a flat world as far as I can tell.
What you need to do is keep track of your own rotational input. For LookUp, you want to FIrstPersonCamera.AddRelativeRotation for the Pitch value. For Turn, you want to AddActorLocalRotation for the yaw. You don't need to worry about Roll. Basically, we want the camera to stick to the rotation of the capsule, but we'll rotate it locally and it should be the same as if on a flat world. You will, however, have to limit the relative Pitch so the player can't flip their head upside down, but you can figure that out after getting this other stuff working.
answered May 08 '15 at 04:29 PM
Currently you're using set actor rotation. But the default FPS template rotation is bound to the controller. So you need to use 'set control rotation' instead of set actor rotation,
answered Apr 22 '15 at 10:07 AM
Sorry, don't really get your problem.
Maybe it's a problem with the default yaw scale of 2.5 in the player controller? You could try to uncheck 'use controller rotation yaw' in the class defaults of your pawn.
answered Apr 21 '15 at 01:35 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here