Ejemplo n.º 1
0
 public static void Copy(GenericX source, GenericX target)
 {
     target.x    = source.x;
     target.y    = source.y;
     target.z    = source.z;
     target.w    = source.w;
     target.type = source.type;
 }
Ejemplo n.º 2
0
 public static bool Compare(GenericX a, GenericX b)
 {
     return
         ((a.type == b.type) &&
          (a.x == b.x) &&
          (a.y == b.y) &&
          (a.z == b.z) &&
          (a.type != XType.Quaternion || a.w == b.w));
 }
Ejemplo n.º 3
0
 public void OverwriteRotation(ref GenericX targetRotation)
 {
     if (type == XType.Quaternion || type == XType.XYZ)
     {
         targetRotation = this;
     }
     else
     {
         Debug.Log(Time.time + "  OverwriteRotation " + type);
         targetRotation.x = (IsX) ? x : targetRotation.x;
         targetRotation.y = (IsY) ? y : targetRotation.y;
         targetRotation.z = (IsZ) ? z : targetRotation.z;
     }
 }