Fixed raycast so now gives good distance measurement as needed