How To maintain Rotation After using Look at function

Hello everyone, I have a segment in my blueprint script which determines if I am looking at an enemy and then locks the rotation to the look at rotation, I can toggle the locked on to enemy boolean on and off, and when I toggle it off my rotation snaps to whatever it was before I locked on. How can I maintain the rotation prior to toggling off the boolean, as to not disorient the player.

I’m guessing since you set the world rotation of the camera component itself, the control rotation is different, and when you disable locking on the target, you set the camera to use the control rotation, which might still be changing by mouse input or however else you do it in your case. Perhaps you can try setting the control rotation to be equal to the current camera rotation right before doing the Set Use Pawn Control Rotation?