disable module reload in background mode

blender3.6
Pullusb 2022-05-27 12:29:39 +02:00
parent 0b55bf671d
commit fd0dec4162
1 changed files with 4 additions and 3 deletions

View File

@ -33,9 +33,10 @@ functions = [
import bpy
if "bpy" in locals():
for name in modules + functions:
module = importlib.import_module(name, __name__)
importlib.reload(module)
if not bpy.app.background:
for name in modules + functions:
module = importlib.import_module(name, __name__)
importlib.reload(module)
def register():
if bpy.app.background: