|
@@ -200,6 +200,19 @@ namespace CommonLang.Geometry
|
|
|
|
|
|
#region Public Methods
|
|
|
|
|
|
+ public void Set(float x, float y, float z)
|
|
|
+ {
|
|
|
+ this.X = x;
|
|
|
+ this.Y = y;
|
|
|
+ this.Z = z;
|
|
|
+ }
|
|
|
+ public void Set(Vector3 vec)
|
|
|
+ {
|
|
|
+ this.X = vec.X;
|
|
|
+ this.Y = vec.Y;
|
|
|
+ this.Z = vec.Z;
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
@@ -509,6 +522,11 @@ namespace CommonLang.Geometry
|
|
|
Z == other.Z;
|
|
|
}
|
|
|
|
|
|
+ public bool Equal(Vector3 other, float precision)
|
|
|
+ {
|
|
|
+ return Math.Abs(X - other.X) < precision && Math.Abs(Y - other.Y) < precision && Math.Abs(Z - other.Z) < precision;
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
|
|
|
|