Skip to content

Commit

Permalink
Fix console traceback when using custom node group inputs
Browse files Browse the repository at this point in the history
  • Loading branch information
oRazeD committed Jun 8, 2021
1 parent e743df4 commit da5f245
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions node_group_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ def ng_setup(self, context):
ng_normal.outputs.new('NodeSocketShader','Output')
ng_normal.inputs.new('NodeSocketShader','Saved Surface')
ng_normal.inputs.new('NodeSocketShader','Saved Volume')
ng_normal.inputs.new('NodeSocketVector','Saved Displacement')
ng_normal.inputs.new('NodeSocketShader','Saved Displacement')

# Create group nodes
geo_node = ng_normal.nodes.new('ShaderNodeNewGeometry')
Expand Down Expand Up @@ -57,7 +57,7 @@ def ng_setup(self, context):
ng_ao.outputs.new('NodeSocketShader','Output')
ng_ao.inputs.new('NodeSocketShader','Saved Surface')
ng_ao.inputs.new('NodeSocketShader','Saved Volume')
ng_ao.inputs.new('NodeSocketVector','Saved Displacement')
ng_ao.inputs.new('NodeSocketShader','Saved Displacement')

# Create group nodes
ao_node = ng_ao.nodes.new('ShaderNodeAmbientOcclusion')
Expand Down Expand Up @@ -89,7 +89,7 @@ def ng_setup(self, context):
ng_height.outputs.new('NodeSocketShader','Output')
ng_height.inputs.new('NodeSocketShader','Saved Surface')
ng_height.inputs.new('NodeSocketShader','Saved Volume')
ng_height.inputs.new('NodeSocketVector','Saved Displacement')
ng_height.inputs.new('NodeSocketShader','Saved Displacement')

# Create group nodes
camera_data_node = ng_height.nodes.new('ShaderNodeCameraData')
Expand Down Expand Up @@ -121,7 +121,7 @@ def ng_setup(self, context):
ng_alpha.outputs.new('NodeSocketShader','Output')
ng_alpha.inputs.new('NodeSocketShader','Saved Surface')
ng_alpha.inputs.new('NodeSocketShader','Saved Volume')
ng_alpha.inputs.new('NodeSocketVector','Saved Displacement')
ng_alpha.inputs.new('NodeSocketShader','Saved Displacement')

# Create group nodes
camera_data_node = ng_alpha.nodes.new('ShaderNodeCameraData')
Expand Down

0 comments on commit da5f245

Please sign in to comment.