I searched for the solution, but all I found is that we have to use the polyop.getElementsUsingFace() function.
but how??
I tried to store all the elements into an array:
currentElement = #()
elementsArr = #(currentElement)
for i = 1 to $.getNumFaces() do(
currentElement = (polyop.getElementsUsingFace $ i as array)
-- print currentElement
for o = 1 to elementsArr.count do(
if (findItem elementsArr[o] currentElement) == 0 then(
append elementsArr currentElement
)
else(
exit
)
)
)
this runns an endless loop…
strange things for me I remarked are, that if you enable the “print currentElement”, it doesn’t print an array. only a number. doing this afterwards it prints an array.
I also tried to add a loop that runs trough each item in the currentElement, so finditem searches for a variable, not an array, but somehow this ended up again in an endless loop, but didn’t do what I want.
I hope somebody can help with that.
tnx