Ejemplo n.º 1
0
        public object Clone()
        {
            var bone = (Bone)MemberwiseClone();

            bone.Pivot    = (float[])Pivot?.Clone();
            bone.Pos      = (float[])Pos?.Clone();
            bone.Rotation = (float[])Rotation?.Clone();

            if (Cubes != null)
            {
                bone.Cubes = new List <Cube>();
                foreach (var cube in Cubes)
                {
                    bone.Cubes.Add((Cube)cube.Clone());
                }
            }

            return(bone);
        }