]> git.tdb.fi Git - libs/gl.git/blobdiff - blender/io_mspgl/export_mesh.py
Add an object property to control compound exporting
[libs/gl.git] / blender / io_mspgl / export_mesh.py
index 18ae856a927ce8f28b70a45c51ab4ed5b9cfda00..cc8ee6ff9abbc1696fe2e13b16e752761ae7c58c 100644 (file)
@@ -194,6 +194,15 @@ class MeshExporter:
        def export(self, context, out_file):
                if self.compound:
                        objs = context.selected_objects
+                       check = objs
+                       while check:
+                               children = []
+                               for o in check:
+                                       for c in o.children:
+                                               if c.compound:
+                                                       children.append(c)
+                               objs += children
+                               check = children
                else:
                        objs = [context.active_object]