Max 合并同名材质
2022-02-21 本文已影响0人
锦囊喵
Max 中清理材质球,使所有名称一样的材质球合并为一个
names = #()
materials = #()
-- append names 1
-- finditem names 1
-- finditem names 2
for obj in geometry where (canConvertTo obj Editable_Mesh) do
(
index = finditem names obj.material.name
if (index == 0) then
(
append names obj.material.name
append materials obj.material
)
else
(
obj.material =materials[index]
)
print obj.material.name
)