bim.convert_to_blender to ignore linked files

This commit is contained in:
Andrej730
2024-08-21 15:30:49 +05:00
parent 12a7b8a79e
commit 84a8c5dfeb
@@ -90,12 +90,18 @@ class ConvertToBlender(bpy.types.Operator):
def execute(self, context):
for obj in bpy.data.objects:
if obj.library:
continue
if obj.type in {"MESH", "EMPTY"}:
tool.Ifc.unlink(obj=obj)
data = obj.data
if tool.Geometry.has_mesh_properties(data):
if data.library:
continue
data.BIMMeshProperties.ifc_definition_id = 0
for material in bpy.data.materials:
if material.library:
continue
tool.Ifc.unlink(obj=material)
context.scene.BIMProperties.ifc_file = ""
context.scene.BIMDebugProperties.attributes.clear()