Added the raycast  function. It compiles. Now to test to see if it works.