How to correctly orientate a lagging top-down camera?

Hi,

I have a top-down camera (-Z) that follow a pawn using a spring arm with some lag. I need my camera to always point at that pawn. This imply some rotation when the arm is late because of the lag. That camera can rotate on its yaw and pitch axes but can’t roll (so north is always at the top of the screen).

I’ve tried to script it, using the security camera bluprint from Blueprints example project. This resulted in this, among many other tries :

I’ve got two issues :

  • I can’t get the yaw and pitch to work while blocking the roll
  • The camera refuses to pitch more than -90 degrees. It turns around and pitch up again (which seems to be a normal behavior for a FPS game but I need my camera to be upside down sometime)

I’m not very comfortable with 3D geometry. Do you have a solution or example to my problem?

Thanks !

You should be able to use the Blueprint node “Find Look at Rotation” which I believe will achieve the rotation that you want (it doesn’t affect roll). As for making your camera pitch upside down, I believe there are options to alter the rotation limits for each axis so that you can pitch past 90 degrees etc. Also this thread may help you:

You may need to do some separate handling with Find Look at Rotation so that it works properly with going upside down.