Third person aiming issues

Hi!

I am building a third person shooter with the third person starter pack and I am having an issue with my aiming.

When the weapon is at hip level the character can move freely from left to right but I would like to make it strafe when pointing the gun forward. I tried some stuff in blueprint but I can’t seem to find the right way to do it.

Any help would be greatly appreciated!

The answer to your problem is with the Yaw controls.
i don’t know how you’ve set up your aim, but you should have a button for aiming down the sights. You need a branch from this that sets the ‘Use Control Rotation Yaw’ to true when you are aiming down the sights, and False when you release the button.
That way, your character will always face forward when you are aiming.
Hope this helps!

Thank you Trueform, yes that was the missing node. That being done it creates another problem though. When I aim, I move my camera over the character’s right shoulder as to not aim right behind its head, but depending on where I am facing in world rotation, my camera seems to also rotate and do not stay over the right shoulder, so I might end up aiming properly when I aim at world yaw = 0 (image 1), but behind its head when its at yaw = 90 or -90 and over the left shoulder when its at 180 (image 2)

.

How should I lock the camera rotation in place so I’m always aiming over the right shoulder?

Actually the right image is the second one.

No problem, I’m pleased it worked! As for the second issue, having never tried myself I’m not too sure… if I were to hazard a guess, though, I’d look into the clamp option. You can find a similar problem here:

https://forums.unrealengine.com/development-discussion/blueprint-visual-scripting/36802-limiting-camera-rotation

It should do what you want it to, more or less.

My issue seems to be that my camera is also rotating, not only the spring arm and I can’t find how to stop that without locking everything in place, which is what clamping does.

If the spring arm were to rotate with the player and the camera to keep pointing forward, my issue would be resolve, but I’m not very familiar with camera and spring arm settings.

'm not sure I can be much help there, sorry. I’m still learning things myself, and I’ve only just started looking at aiming and spring arms. I assume you’ve tried referencing just the spring arm itself in the blueprint, but keep trying - there’s always a way to do these kinds of things. Maybe learn all you can about the camera elements, and everything will fall into place.

The problem was with the spring arm. I was using a timeline to change between two camera offsets to get it from behind the character to over the shoulder. I was doing so by changing the values of the camera boom’s target offset using a timeline. It was a good idea, but, the target offset was updating improperly with the pawn’s rotation, I had to update the socket offset instead, which keeps relative to the pawn’s rotation, thus always behind.

I looked at my current project, and mine seems to do everything you want yours to. I’ve added an attachment for the blueprint so you can see how mine works. In addition, try this tutorial:

it explains the timeline I added, and it really helped me understand cameras more. I changed a few things on the blueprint myself to prevent aiming while jumping, etc, but hopefully it will solve your problem.

At least you fixed it!