Method PolygonsWithinSqRange
PolygonsWithinSqRange(List<Vector3>, List<Vector3>, float)
Determines if two convex coplanar polygons are within a specified distance from each other.
Declaration
public static bool PolygonsWithinSqRange(List<Vector3> polygonA, List<Vector3> polygonB, float maxSqDistance)
Parameters
| Type | Name | Description |
|---|---|---|
| List<Vector3> | polygonA | The first polygon to test. Must be convex and coplanar with |
| List<Vector3> | polygonB | The second polygon to test. Must be convex and coplanar with |
| float | maxSqDistance | The square of the maximum distance allowed between the two polygons. |
Returns
| Type | Description |
|---|---|
| bool | True if the polygons are within the specified distance from each other, false otherwise. |