Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Get minimun distance a position and a vector. How to do this?

Asked by 3 years ago
Edited 3 years ago

What's the easiest method to get the perpendicular distance between a position of a part, and a vector? Is there an easy way without using complex Vector3 and CFrame algorithms?

Here's an easy representation. I'm trying to write a code to calculate the length of the red line:

https://imgur.com/PekvZ9L

Answer this question