ScriptSpot

Forum topic · General Scripting

how to select all the faces of a mesh, in one go

By Caustic · 2016-06-28

Description

I am still somewhat new to max scripting, so this question might be a bit noobish.

I have this ;
polyop.setFaceSelection holCyl #{1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48}

Every face of the mesh needs to be mentioned, which is a ridiculous, is there a better faster more elegant way?

Comments (5)

.

miauu · 2016-06-30

If the object is selected and you are in Face or Polygon subobject level you can use


max select all

Caustic · 2016-06-30

*

Swordslayer · 2016-06-30

polyop.setFaceSelection holCyl #all

by the way, your bitarray can be also written as #{1..48} or #{1..polyop.getNumFaces holCyl}

Caustic · 2016-06-30

Thanx!!
that's three answers
for the price of one ;)

barigazy · 2016-06-30

one more ;)

holcyl.selectedfaces = #{1..holcyl.faces.count}