select vertex by Z axis

when working with editable/edit poly - select one vertex - and script must select all vertexs which are on the same Z
i guess ot is simple but i'm totally not into maxscript

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Anubis's picture

@titane357 - "Yes, looks

@titane357 - "Yes, looks someting I wanted, but is the "loop" word that cause some misunderstanding :-))"

Yes, I think so "loop" word cause some misunderstanding. Thank you for noticed that! Poly ops Loop has no axis option and where is clearly visible so it used different method. I just tested the script only on primitives and the effect looks like loop. Maybe you will suggest a better name for the script? :)

"Something I don't understand is why need to pick an object ? It should work on selected object(s)... Can you explain ?"

I guess when people working on SubObject Level they works on single selected object. Else, of course I can extend the script to work with more than 1 selected object. And of course it would complicated the script a little, but why not... just say if you need this extra :) Now in the script you can see so my function is "independent" of the rollout, ie it can be used alone (without ui). Function has 3 argument: obj (mesh or poly - single node), axis (integer index 1,2,3 where 1=X, 2=Y, 3=Z) and divergency (float threshold). So same example loop for array of selected scene objects will be:
for i in selection do SelectVertLoop i 3 0
So tell me do you want to add this option in the rollout.

@harumscarum - "Thank you!! is it possibe to make it work with Edit Poly?"

Maybe, but at least I don't know how. I use the MAXScript only 6 months and just learn from the official Refernce. What I know is that Edit Poly is a different class of Editable Poly and has some different methods, but I don't find them in the Reference yet. Every help in this task is welcome or at least direct me where to look, thanks in advance.

my recent MAXScripts RSS (archive here)

harumscarum's picture

Thank you!! is it possibe to

Thank you!! is it possibe to make it work with Edit Poly?

titane357's picture

Yes, looks someting I

Yes, looks someting I wanted, but is the "loop" word that cause some misunderstanding :-))
Something I don't understand is why need to pick an object ? It should work on selected object(s)...
Can you explain ?

Anubis's picture

Hmm, seams to me you

Hmm, seams to me you describe my script but with different words, its do exactly the same even with more features, like to use it on other axis, not only by Z, and also have "threshold". And yes, harumscarum not mention about more features. I just add more, like to support array of verts selection, not only one. Finaly the script not only for him, but it's cover what he want. And if you also need this script, just test it, ok?

regards, Anubis

my recent MAXScripts RSS (archive here)

titane357's picture

I think that harumscarum

I think that harumscarum wants a script to select vertexes sharing same z position (with a threshold) to architectural purpose (I think : I need this tool too), so loops are not so helpfull...

Anubis's picture

I hope my last script is

I hope my last script is helps:
http://www.scriptspot.com/3ds-max/select-vertex-loop

my recent MAXScripts RSS (archive here)

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.