Fix material duplication clean comparing with non-GP mats

1.8.11

- fixed: cleaning materials duplication checked against name without checking material GP type
This commit is contained in:
pullusb
2024-11-27 14:33:20 +01:00
parent 772af8cb3f
commit 19c43e6268
3 changed files with 8 additions and 1 deletions
+3
View File
@@ -1855,6 +1855,9 @@ def clean_mats_duplication(ob, skip_different_materials=True):
basemat = bpy.data.materials.get(match.group(1))
if not basemat:
continue
if not basemat.is_grease_pencil:
## Skip material with matching "stem" but not being GP material
continue
diff = different_gp_mat(mat, basemat)
if diff:
print(f'! {ob.name} : {diff}')