Skip to content
Snippets Groups Projects
Commit 76fd74e0 authored by Campbell Barton's avatar Campbell Barton
Browse files

add support for object materials. fixes bug [#36899]

parent 4486f3db
No related branches found
No related tags found
No related merge requests found
......@@ -284,6 +284,15 @@ def cell_fracture_objects(scene, obj,
objects.append(obj_cell)
# support for object materials
if use_data_match:
for i in range(len(mesh_dst.materials)):
slot_src = obj.material_slots[i]
slot_dst = obj_cell.material_slots[i]
slot_dst.link = slot_src.link
slot_dst.material = slot_src.material
if use_debug_redraw:
scene.update()
_redraw_yasiamevil()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment