Fixed poses not being saved correctly for some .NET versions.

This commit is contained in:
originalnicodr committed 2025-01-20 13:21:09 -03:00
1 parent ca46607c49
commit e7d591176e
1 file changed
+4 -3
+4 -3
View File
@@ -75,9 +75,10 @@ namespace UnityExplorer.Serializers
this.scale = scale;
}
public readonly Vector3 position;
public readonly Vector3 angles;
public readonly Vector3 scale;
// They cant be read-only because it causes problems with XML serialization in older versions of .NET
public Vector3 position { get; set; }
public Vector3 angles { get; set; }
public Vector3 scale { get; set; }
public void CopyToTransform(Transform transform){
transform.localPosition = position;