From 6be20fdaaca0ff666080d4f995f458f76c8c8042 Mon Sep 17 00:00:00 2001 From: Greg Zaal Date: Wed, 25 Nov 2020 18:37:09 +0200 Subject: [PATCH] Fix settings disappearing --- ui.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ui.py b/ui.py index 6501579..29cb5c6 100644 --- a/ui.py +++ b/ui.py @@ -224,7 +224,7 @@ def draw_more_options_cycles(box, scene, light, material, node_strength, is_port drawfalloff = False if not light.data.use_nodes: drawfalloff = False - if drawfalloff: + if drawfalloff and node_strength is not None: col.prop(light, "GafferFalloff", text="Falloff") if node_strength.type != 'LIGHT_FALLOFF' and light.GafferFalloff != 'quadratic': col.label(text="Light Falloff node is missing", icon="ERROR") @@ -556,7 +556,7 @@ def draw_world(context, layout, gaf_props, scene, prefs, icons): if "_Light:_(" + light.name + ")_" in gaf_props.MoreExpand or gaf_props.MoreExpandAll: if scene.render.engine == 'CYCLES': - draw_more_options_cycles(box, scene, light, material, node_strength, is_portal) + draw_more_options_cycles(box, scene, light, material, None, is_portal) else: draw_more_options_eevee(box, scene, light) i += 1