Having trouble with Ray-Box and Ray-Sphere intersections