Aim offset to be controlled from Real-world mouse location

I am trying to get my Aim offset to be controlled from Real-world mouse location but I’m not having any luck.
basically I want the player to aim in the X,Y,Z where the real-world mouse location is I have tried a few things.
the line trace shows where the player is aiming and where the mouse location is