From ce9e4f2854dca8d9e15934cbd07ab7b2e56908af Mon Sep 17 00:00:00 2001 From: Andrej730 Date: Tue, 25 Jun 2024 14:27:24 +0500 Subject: [PATCH] remove BIMObjectProperties from bpy.types.Material as deprecated #4843 --- src/blenderbim/blenderbim/bim/__init__.py | 1 - src/blenderbim/blenderbim/bim/ifc.py | 3 ++- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/blenderbim/blenderbim/bim/__init__.py b/src/blenderbim/blenderbim/bim/__init__.py index 375343a285..b6413dac28 100644 --- a/src/blenderbim/blenderbim/bim/__init__.py +++ b/src/blenderbim/blenderbim/bim/__init__.py @@ -224,7 +224,6 @@ def register(): bpy.types.Screen.BIMTabProperties = bpy.props.PointerProperty(type=prop.BIMTabProperties) bpy.types.Collection.BIMCollectionProperties = bpy.props.PointerProperty(type=prop.BIMCollectionProperties) bpy.types.Object.BIMObjectProperties = bpy.props.PointerProperty(type=prop.BIMObjectProperties) - bpy.types.Material.BIMObjectProperties = bpy.props.PointerProperty(type=prop.BIMObjectProperties) bpy.types.Material.BIMMaterialProperties = bpy.props.PointerProperty(type=prop.BIMMaterialProperties) bpy.types.Mesh.BIMMeshProperties = bpy.props.PointerProperty(type=prop.BIMMeshProperties) bpy.types.Curve.BIMMeshProperties = bpy.props.PointerProperty(type=prop.BIMMeshProperties) diff --git a/src/blenderbim/blenderbim/bim/ifc.py b/src/blenderbim/blenderbim/bim/ifc.py index ea871f1a35..4fbca1cb3a 100644 --- a/src/blenderbim/blenderbim/bim/ifc.py +++ b/src/blenderbim/blenderbim/bim/ifc.py @@ -358,7 +358,8 @@ class IfcStore: def purge_blender_ifc_data(obj: IFC_CONNECTED_TYPE) -> None: if isinstance(obj, bpy.types.Material): obj.BIMMaterialProperties.ifc_style_id = 0 - obj.BIMObjectProperties.ifc_definition_id = 0 + else: + obj.BIMObjectProperties.ifc_definition_id = 0 @staticmethod def execute_ifc_operator(operator: bpy.types.Operator, context: bpy.types.Context, is_invoke=False):