0
-- this function selects polygons assigned to mat and assigns a matid of count
-- mat is the mat to select the polys by and count is the mat id to assign to the polys
function assignMatId mat count = (
-- set the mat into meditMaterials in the second slot
meditMaterials[2] = mat
-- set the second slot to the active one
medit.SetActiveMtlSlot 2 true
-- select the polys assigned to mat
objarr = for obj in objects where obj.material == meditMaterials[medit.getActiveMtlSlot()] collect o
--assign selected polys a matid of count
--.. still writing this code
)
這是我正在嘗試編寫的功能。不過,我目前堅持選擇分配給墊的多邊形。 所以我的問題是:按材質選擇Polys maxscript
我將如何給予一個選定的材料(在meditMaterials中的activeSlot)選擇分配給它們的材料的所有聚合物。可能有多個物體分配給物體,因此它還需要選擇其他可編輯的多物體。
想從哪裏開始?