rhinoscriptsyntax docs do not help so much …
Compares two 3-D vectors.
rhinoscriptsyntax.VectorCompare (vector1, vector2)
rhinoscript.pointvector.VectorCompare (vector1, vector2)
Required. List of 3 numbers, Point3d, or Vector3d. The first 3-D vector to compare.
Required. List of 3 numbers, Point3d, or Vector3d. The second 3-D vector to compare.
If vector1 is less than vector2.
If vector1 is equal to vector2.
If vector1 is greater than vector2.
… but looking into pointvector.py, we cab see that …
def VectorCompare(vector1, vector2):
"""Compares two 3D vectors
vector1, vector2 = the vectors to compare
-1 if vector1 is less than vector2
0 if vector1 is equal to vector2
1 if vector1 is greater than vector2
vector1 = rhutil.coerce3dvector(vector1, True)
vector2 = rhutil.coerce3dvector(vector2, True)
… the method used here is
… And looking at RhinoCommon docs we can finally understand …
Public Function CompareTo ( _
other As Vector3d _
) As Integer
The other Vector3d to use in comparison.
0: if this is identical to other
-1: if this.X < other.X
-1: if this.X == other.X and this.Y < other.Y
-1: if this.X == other.X and this.Y == other.Y and this.Z < other.Z
… what that code is doing.
Definitely not the best documented rhinoscriptsyntax method …