From 686160738a385f6939ee3248943f60600e0873da Mon Sep 17 00:00:00 2001 From: Ryan Inch Date: Tue, 23 Jul 2024 02:43:27 -0400 Subject: [PATCH] Support importing older scale audio feedback components. Skip importing properties for components if they don't have any. Older scale audio feedback components didn't have component properties and were just the name and an empty string. --- addons/io_hubs_addon/components/hubs_component.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/addons/io_hubs_addon/components/hubs_component.py b/addons/io_hubs_addon/components/hubs_component.py index 7f68e87a..6ea4a6f7 100644 --- a/addons/io_hubs_addon/components/hubs_component.py +++ b/addons/io_hubs_addon/components/hubs_component.py @@ -123,9 +123,10 @@ def gather(self, export_settings, object): @classmethod def gather_import(cls, gltf, blender_host, component_name, component_value, import_report, blender_ob=None): component = import_component(component_name, blender_host) - for property_name, property_value in component_value.items(): - assign_property(gltf.vnodes, component, - property_name, property_value) + if component_value: + for property_name, property_value in component_value.items(): + assign_property(gltf.vnodes, component, + property_name, property_value) def post_export(self, export_settings, host, ob=None): '''This is called by the exporter after the export process has finished'''