I am(beginner) currently working on a side scroller game.And i have probem with my characters rotation.I’ve changed my camera rotation because of shader issues like this:
Just the second value.(Was 180.0f)
Character is now facing the old position of camera while rotating.I want it to be turning by camera side. I couldn’t find any documentations about it.It might be very easy solution but i can’t find sorry.
You should look in to API reference for available options, CameraBoom is spring arm component:
Good option is also make blueprint out of your character and try experiment with camera boom there, once oyu got settings oyu got set those settings in C++
My problem is with my character rotation, cam works fine.Sorry if I can’t express myself clear.
In here my character turns to direction I am moving,but its turning from wrong direction.
It turns clockwise while turning right but i want it to turn counter clockwise.I want to see chars face whiel turning.
Thanks for your answer but my problem is not about the camera it is about the character.As i see i couldn’t express myself clear sorry.
Here character is facing the direction we are moving.
Here is a example
[video.][2]
I want to see chars face while turning.
Edit:I forgot to mention that, game is 2.5D char only moves left and right.
if I understand correctly your CameraBoom is rotating together with your character, ie. following its yaw; so the behaviour you describe it’s expected (CameraBoom does rotate together with your character, so it’ll always try to position itself either behind, in front, or to side, according to how you did set it up).
Try to play with your CameraBoom settings under the “Camera Settings” tab - in particular “Use Pawn Control Rotation” and “Inherit Yaw”. Start by disabling both to understand the difference (looks like so far you’ve just tinkered with Character and Character Movement, but both CameraBoom and Camera have their set of options to let you specify their behavior in relation to character rotation).
now it’s superclear. A video tells more than a thousand words
So I opened the SideScroller template, that behaves exactly as you want: the character shows her face when turning. I could just tell you have a look and re-do things the same way!
To discover what variables affect that behavior, I then tried to have her behave the opposite way, eg. as in your “bugged” case.
The fastest way to do that was to just position the camera on the other side, and change the direction of the movement input vector.
These are the two variables I changed
in the SpringArm (your CameraBoom) changed the Absolute rotation from (0,0, 180) to (0,0,0)
the world direction vector in the “Add Movement Input” function, changed from (0,-1,0) to (0,1,0)
So yeah, I’d just tell you put the camera on the other side!!