About this site
ScriptSpot is a diverse online community of artists and developers who come together to find and share scripts that empower their creativity with 3ds Max. Our users come from all parts of the world and work in everything from visual effects to gaming, architecture, students or hobbyists.
Comments
BitArray.NumberSet
Hi Titane,
shortly getFaceSelection() return BitArray.
I think this example will explain what you need:
Cheers!
my recent MAXScripts RSS (archive here)
Hello ! Perhaps not very
Hello !
Perhaps not very elegant, but it works... I don't know how to use bitarray, so I convert to array...
Thanks ! :-)
-----
h=0
poly = selection[1]
fSel = polyop.getFaceSelection poly
classOf fSel -- BitArray
fSelA = fSel as array
for a=1 to fSel.numberSet do
(
h+=10
print fSel.numberSet
vList = polyop.getVertsUsingFace poly fSelA[a]
polyop.moveVert poly vList [0,0,h]
)
update poly
---
so, the job done :)
Working with BitArrays is more faster than Arrays,
but use what you like and found as easy ;)
my recent MAXScripts RSS (archive here)
problem is : the selection
problem is : the selection order is not conserved....
Example
Cheers!
my recent MAXScripts RSS (archive here)
Hello Anubis ! Thanks for
Hello Anubis !
Thanks for help but I don't understand something.
I need to make a loop to move up each face with an incremental value.
Can I tape : "fSel.count" ? because fSel.count give me total faces, not just selected faces.
I know that I'm a poor scripter but I don't understand what is wrong with the following...
h=0
poly = selection[1]
fSel = polyop.getFaceSelection poly
for a=1 to fSel.count do
(
h+=1
vList = polyop.getVertsUsingFace poly fSel[a]
polyop.moveVert poly vList [0,0,h]
)
update poly