Hey @artsa ,
There are some changes in the Blenders Python script since this course.
From the ‘voxelfy_1,1.py’ script included when downloading the source files, make the following changes.
Line 108
currently:
bpy.ops.object.modifier_apply(apply_as=’DATA’, modifier=”DataTransfer”)
delete apply_as=’DATA’, to read:
bpy.ops.object.modifier_apply(modifier=”DataTransfer”)
Line 123
currently:
bpy.ops.mesh.select_random(percent=count, seed=count)
change percent to ratio and after count / 100:
bpy.ops.mesh.select_random(ratio=count / 100, seed=count)
line 123 is part of the operation to reduce each face to a single color.
the select random operation now uses a ratio between 0 and 1 instead of a percentage between 0 and 100, so dividing by 100 will give 0.01, 0.02, 0.03 etc, etc, while looping through the count.
0.01 is equivalent to 1%, 0.02 = 2%, 0.03 = 3%, etc, etc.
This should work now as intended in Blender v3.0
Hope this helps.
@jlampel , if you have the time, would it be worth updating the script with the source files?