Aligning object to face normal with local rotation
Hello!
My script aligns object to face like this:
https://i.imgur.com/SggAqvx.png
But i need to get this:
https://i.imgur.com/gmuYhav.png
there is a code i used:
faces = (polyOp.getFaceSelection $Box001) as array face = faces[1] theMatrix = matrixFromNormal(polyOp.getFaceNormal $Box001 face) theMatrix.row4 = polyOp.getFaceCenter $Box001 face $object.transform = theMatrix
Help me, friends :)
Comments
.
http://www.scriptspot.com/forums/3ds-max/scripts-wanted/align-object-to-...
http://www.scriptspot.com/3ds-max/scripts/clone-align-on-faces
Tools and Scripts for Autodesk 3dsMax
thank you! second one does it
thank you!
second one does it right, but it too complicated for me to understand
i write simple script that creates and aligns helper grid on selected face and i can't rotate it right way. So can you please fix my code if you know how
.
align to normal
там все понятно должно быть
.
The best way is to try to learn something from the code that works for you.
But(not the best solution):
Tools and Scripts for Autodesk 3dsMax
Thanx a lot, miauu!
Thanx a lot, miauu!