So i am working on a project but i can get a line trace to go from my camera to my curser location on screen, does any1 know how to do this?
Thanks, Mirik
So i am working on a project but i can get a line trace to go from my camera to my curser location on screen, does any1 know how to do this?
Thanks, Mirik
I can help you with that, but I’ll need a bit more detail about what exactly you’re trying to do.
Are you tracing from the screen toward the ground under the mouse? Unreal Engine already provides a function for that.
Or do you want to trace from the player’s camera toward the ground where the mouse is hovering? In that case, you’d first trace from the mouse cursor to find the hit location on the ground, then perform another trace from the camera to that point.
Or are you trying to trace toward the mouse’s actual 3D position? In that scenario, the mouse could be floating in the air — for example, in an RTS game when you zoom out, the cursor’s world position might not touch the ground.
so am trying to get a line trace by chanel from my screen to the ground under the mouse, what is that function called?
friendly regards, Mirik
Nvm thanks 2 you and chatgpt ive managed to find the function, thank you so much man