diff --git a/addons/io_hubs_addon/components/definitions/audio_params.py b/addons/io_hubs_addon/components/definitions/audio_params.py index f174bc5a..d8d0d3b3 100644 --- a/addons/io_hubs_addon/components/definitions/audio_params.py +++ b/addons/io_hubs_addon/components/definitions/audio_params.py @@ -18,13 +18,13 @@ class AudioParams(HubsComponent): 'display_name': 'Audio Params', 'node_type': NodeType.NODE, 'panel_type': [PanelType.OBJECT, PanelType.BONE], - 'version': (1, 0, 0) + 'version': (1, 0, 1) } overrideAudioSettings: BoolProperty( name="Override Audio Settings", description="Override Audio Settings", - default=True) + default=False) audioType: EnumProperty( name="Audio Type", @@ -119,6 +119,11 @@ def migrate(self, migration_type, panel_type, instance_version, host, migration_ migration_report.append( f"Warning: The Media Cone angles may not have migrated correctly for the Audio Params component on the {panel_type.value} {host_reference}") + if instance_version <= (1, 0, 0): + if self.get("overrideAudioSettings") is None: + migration_occurred = True + self.overrideAudioSettings = True + return migration_occurred def draw(self, context, layout, panel): diff --git a/addons/io_hubs_addon/components/definitions/audio_target.py b/addons/io_hubs_addon/components/definitions/audio_target.py index 9be112f4..5592c04e 100644 --- a/addons/io_hubs_addon/components/definitions/audio_target.py +++ b/addons/io_hubs_addon/components/definitions/audio_target.py @@ -122,6 +122,10 @@ class AudioTarget(HubsComponent): description="Show debug visuals", default=False) + @classmethod + def init(cls, obj): + obj.hubs_component_audio_params.overrideAudioSettings = True + def draw(self, context, layout, panel): dep_name = AudioSource.get_name() diff --git a/addons/io_hubs_addon/components/definitions/audio_zone.py b/addons/io_hubs_addon/components/definitions/audio_zone.py index da3324c8..e290a393 100644 --- a/addons/io_hubs_addon/components/definitions/audio_zone.py +++ b/addons/io_hubs_addon/components/definitions/audio_zone.py @@ -61,6 +61,10 @@ def create_gizmo(cls, ob, gizmo_group): return gizmo + @classmethod + def init(cls, obj): + obj.hubs_component_audio_params.overrideAudioSettings = True + def migrate(self, migration_type, panel_type, instance_version, host, migration_report, ob=None): migration_occurred = False if instance_version < (1, 0, 0):