Exemplo n.º 1
0
 private void SetConstraintsData()
 {
     foreach (Constraint constraint in ConstraintManager.GetAllConstraints())
     {
         ConstraintData constraintData = new ConstraintData
         {
             type = constraint.constraintType
         };
         Utils.GetTransformRelativePathTo(constraint.gobject.transform, rootTransform, out constraintData.source);
         Utils.GetTransformRelativePathTo(constraint.target.transform, rootTransform, out constraintData.target);
         SceneData.Current.constraints.Add(constraintData);
     }
 }