diff --git a/spine-csharp/src/Bone.cs b/spine-csharp/src/Bone.cs index 7041346c4..1e1974cda 100644 --- a/spine-csharp/src/Bone.cs +++ b/spine-csharp/src/Bone.cs @@ -38,7 +38,7 @@ namespace Spine { internal BoneData data; internal Skeleton skeleton; internal Bone parent; - internal List children; + internal List children = new List(); internal float x, y, rotation, rotationIK, scaleX, scaleY; internal bool flipX, flipY; internal float m00, m01, m10, m11; @@ -79,7 +79,6 @@ namespace Spine { this.data = data; this.skeleton = skeleton; this.parent = parent; - this.children = new List(); SetToSetupPose(); } diff --git a/spine-unity/Assets/spine-unity/AtlasAsset.cs b/spine-unity/Assets/spine-unity/AtlasAsset.cs index a76839407..5096d3869 100644 --- a/spine-unity/Assets/spine-unity/AtlasAsset.cs +++ b/spine-unity/Assets/spine-unity/AtlasAsset.cs @@ -97,13 +97,11 @@ public class MaterialsTextureLoader : TextureLoader { } page.rendererObject = material; - //deal with really, really old atlas files - if (page.width == 0 || page.height == 0) - { - page.width = material.mainTexture.width; - page.height = material.mainTexture.height; - } - + // Very old atlas files expected the texture's actual size to be used at runtime. + if (page.width == 0 || page.height == 0) { + page.width = material.mainTexture.width; + page.height = material.mainTexture.height; + } } public void Unload (object texture) {