MaxScript获取元素数量的一个思路
Fn GetMeshElementsCount meshObject = ( exsList = #() sourceFaceList = #{} for i = 1 to getNumFaces meshObject.mesh do ( curList = (meshop.getElementsUsingFace meshObject.mesh i) as array if curList.Count > 0 do ( if exsList.Count == 0 do append exsList curList isExit = true for tempList in exsList where tempList[1] == curList[1] do isExit = false if isExit == true do append exsList curList ) ) exsList.Count ) GetMeshElementsCount $