diff --git a/__init__.py b/__init__.py index 4023153..23999b6 100644 --- a/__init__.py +++ b/__init__.py @@ -2,7 +2,7 @@ bl_info = { "name": "Rig Picker", "author": "Christophe Seux", "version": (0, 1), - "blender": (3, 0, 1), + "blender": (3, 0, 2), "location": "", "description": "", "warning": "", @@ -38,11 +38,15 @@ if "bpy" in locals(): importlib.reload(module) def register(): + if bpy.app.background: + return for name in modules: module = importlib.import_module(name, __name__) module.register() def unregister(): + if bpy.app.background: + return for name in reversed(modules): module = importlib.import_module(name, __name__) module.unregister()