I made a crosshair GUI and now I want to find the Vector that the crosshair is pointing at. The crosshair's position is constant. Thx in advance for any help!
COMMUNITY QUESTION
How to find a vector from a screen position?
1 answer
local plr = game:GetService("Players").LocalPlayer
mouse = plr:GetMouse()
print(mouse.Hit.p) -- gets the Vector position of the mouse in 3d space, .p is for getting Vector3, because .Hit only gets CFrame.
remember, this is a local script.
2 comments
0
I appreciate the help... but you might want to read the comments above on my question
0
so what?
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
Well if the crosshair is the mouse at all times, have a look through the properties: https://developer.roblox.com/en-us/api-reference/class/Mouse
No, the crosshair is just two frames that sit in a constant position. It's for console users