修改
This commit is contained in:
@@ -43,9 +43,7 @@ def create_nothing_material():
|
||||
def create_emissive_material():
|
||||
mat = bpy.data.materials.new(name="emissive")
|
||||
mat.use_nodes = True
|
||||
bsdf = mat.node_tree.nodes["Principled BSDF"]
|
||||
|
||||
# 在Blender 4.0+中,发光属性可能位置不同
|
||||
bsdf = mat.node_tree.nodes["Principled BSDF"]
|
||||
try:
|
||||
if "Emission" in bsdf.inputs:
|
||||
bsdf.inputs["Emission"].default_value = (1.0, 0.8, 0.2, 1.0)
|
||||
|
||||
Reference in New Issue
Block a user