I am trying to make a shovel system. But there is a problem about digging. I don’t want that player is able to dig water so I tried to use some RayCast scripts but now it says Air when I print material. I am not sure why. (The script below is not made by me.)
local ray = Ray.new(Part.Position,Part.CFrame:VectorToWorldSpace(Vector3.new(0,-3,0)))
local hit,position,normal,material = workspace:FindPartOnRay(ray,Part)