I made this into a tool:

script.Parent.RayMaker.Changed:connect(function()
	local ray = Ray.new(script.Parent.RayMaker.Position,script.Parent.RayMaker.CFrame.lookVector*500)
	local hit, position = workspace:FindPartOnRay(ray)
	print (position)
end)

But so far it's not outputting anything.

1 comment

0

Use variables for your ray vector3's so we can actually see your code.