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]