It seems like you are lerping the position to a 3rd person camera and not your first person camera. Do you have the default 3rd person cam on a spring arm in your character BP?
So do you want to have the camera stay on the weapon during ADS and then return to the 3rd person view or do you have a 1st person position in mind for the relaxed stance?
Are you updating HipfireLocation? Take into account that the camera boom has it’s own parameters such as length that need to be changed. It would be better to probably un-parent the camera from the boom while in ads or you may be fighting it’s movement.
If you decide on keeping it then once you leave ads you need to set the same parameters for the spring arm and camera location as before ads’ing.
Also make sure you are not messing up local space and world space.
GetSocketLocation returns the coordinates in world space so you would need to transform it to local space if you want to use retrelativelocation.
to get the relative transform, or just do the calculations in world space
Try going into an outside view and debug drawing spheres at the projected target coordinates to see where they line up in space. (set a longer persistent time and bind it to a keypress for tests)
Personally I use Set View Target w/Blend. Have that handle transition from character cam to weapon cam which is a component in the weapon class. Weapon class event adjusts the socket offset based what optic is being used (red dot, holo, irons, acog etc).
thanks @Rev0verDrive - so a second camera?
I have seen people use this on youtube and i didn’t know if it was good practice? Or is that what a lot of studios do with 2 Cameras?