I am attempting to create a plane and set the color; the following code throws an error at this line:
bpy.data.materials['RSgreen'].diffuse_color=(0,0,0)
the error is: ValueError: bpy_struct: item.attr = val: sequences of dimension 0 should contain 4 items, not 3
which makes no sense to me; diffuse_color calls for 3 parameters in the documentation.
bpy.ops.mesh.primitive_plane_add(size=4,enter_editmode=False,location=(-2,-2,0.01))
bpy.context.active_object.name='Plane2'
bpy.ops.material.new()
bpy.data.materials[1].name='RSgreen'
bpy.data.materials['RSgreen'].diffuse_color=(0,0,0)
bpy.context.object.data.materials.append(bpy.data.materials['RSgreen'])