local sphere = game.Workspace:WaitForChild(“Part”)
local player = game.Players.LocalPlayer
local mouse = player:GetMouse()
while true do
local ray = Ray.new(workspace.CurrentCamera.CFrame.Position,mouse.Hit.Position)
local hit,position,normal = workspace:FindPartOnRayWithIgnoreList(ray,{workspace.CurrentCamera})
print(normal)
wait()
end
i have a sphere in workspace where i put my cursor over, but it keeps on printing 0,0,0
Can you please format your code. Second, what are you trying to achieve. Third, what’s the error. I don’t wanna repeat this statement over and over again whenever I see a similar topic that only has this kind of style to ask the problem.
i have a 3d circle called a sphere and i am trying to get the normal of a sphere by casting a ray from the workspace camera to my mouse, that mouse is pointed towards the spherical object mentioned previously.
even though my mouse is pointed on the sphere it seems to be printing 0,0,0 which is definately not the surfaces normal because a surfaces normal usually points in either one of the axis.