[Bf-blender-cvs] [17a7b942e16] temp-lineart-contained: GPencil: Fix minor stuff in obj_add

YimingWu noreply at git.blender.org
Mon May 24 15:56:37 CEST 2021


Commit: 17a7b942e166a5c80425ef07d62e601e32575009
Author: YimingWu
Date:   Mon May 24 21:39:53 2021 +0800
Branches: temp-lineart-contained
https://developer.blender.org/rB17a7b942e166a5c80425ef07d62e601e32575009

GPencil: Fix minor stuff in obj_add

===================================================================

M	source/blender/editors/object/object_add.c

===================================================================

diff --git a/source/blender/editors/object/object_add.c b/source/blender/editors/object/object_add.c
index b0255e79858..14a101378b0 100644
--- a/source/blender/editors/object/object_add.c
+++ b/source/blender/editors/object/object_add.c
@@ -1433,10 +1433,7 @@ static int object_gpencil_add_exec(bContext *C, wmOperator *op)
         id_us_plus(&md->target_material->id);
       }
 
-      if (use_lights) {
-        ob->dtx |= OB_USE_GPENCIL_LIGHTS;
-      }
-      else {
+      if (!use_lights) {
         ob->dtx &= ~OB_USE_GPENCIL_LIGHTS;
       }



More information about the Bf-blender-cvs mailing list