I need to use sphere cast between two points to look for collisions.
But sphere cast doesn’t have a function to work between two points, it takes a start, a direction, and a distance. (Or a start and a ray, which is just the same data packaged differently.)
How can I make a quick conversion between these two? If I have start point and end point in 3D space, how to I change that end point into a direction and a distance?
Is there a function to generate a ray between two points, and a simple way to get the distance between the points?
I tried searching for this, but I get people being told to just use linecast instead. But I can’t use that here, unless there is some sort of sphere-lineCast I am unaware of.