fix annoying script error
authorhgn <hgodden00@gmail.com>
Mon, 15 Jan 2024 05:19:25 +0000 (05:19 +0000)
committerhgn <hgodden00@gmail.com>
Mon, 15 Jan 2024 05:19:25 +0000 (05:19 +0000)
blender_export.py

index e9b7a1e46d8d7c9ceb6b4cdb70e22baaf6ca178e..f64989bf1cb66dae2e51249e382f3075f378e58c 100644 (file)
@@ -737,14 +737,17 @@ def material_info(mat):
       if node == None:#{
          _graph_read.extracted = []
 
+         done = False
          for node_idname in node_def:#{
             for n in mat.node_tree.nodes:#{
                if n.name == node_idname:#{
                   node_def = node_def[node_idname]
                   node = n
+                  done = True
                   break
                #}
             #}
+            if done: break
          #}
       #}
 
@@ -2561,7 +2564,6 @@ class SR_MATERIAL_PANEL(bpy.types.Panel):
       _.layout.prop( active_mat.SR_data, "shader" )
       _.layout.prop( active_mat.SR_data, "surface_prop" )
       _.layout.prop( active_mat.SR_data, "collision" )
-      _.layout.prop( active_mat.SR_data, "tex_diffuse_rt" )
 
       if active_mat.SR_data.collision:#{
          box = _.layout.box()
@@ -2598,6 +2600,10 @@ class SR_MATERIAL_PANEL(bpy.types.Panel):
          box.prop( active_mat.SR_data, "cubemap" )
          box.prop( active_mat.SR_data, "tint" )
       #}
+
+      _.layout.label( text="" )
+      _.layout.label( text="advanced (you probably don't want to edit these)" )
+      _.layout.prop( active_mat.SR_data, "tex_diffuse_rt" )
    #}
 #}