How do you save a selection set of edges in Polyedit
Is there an easy way in Max script to save a set of edges to a named selection set while inside polyedit? This is easy to do in max while poly editing, but how do you do this in a script? I want to save selections (bitarrays) of edges while poly editing, so the object can later be edited using these named sets of edges.
Thanks,
Billibong
Comments
hi, u can add these edges to
hi,
u can add these edges to an array:
u must select u'r object,if not u'll get an error, paste the following script in a new maxscript-file then evaluate it (Ctrl+E) in order to save u'r edges selection into a varriable "my_selection", :
--the start
my_selection=#{}
for i=1 to ($.selectededges.count) do (
append selection ($.selectededges[i].index)
)
---u can re-excute it to get more selections
---just change "my_selection" by another name
----------------------------------------------
Now if u want to get u'r selection just tape this function in maxscript listener :
----------------------------------------------
$.EditablePoly.setselection #edge my_selection
----------------------------------------------
(u can also make each script in macroscript window to get it quickly)
Hope it's what u want! Good luck
learn more,learn as fast as u can, coz u can be not able to learn more tommorow!!
Hi i had some sort of
Hi i had some sort of similar problems that billibong had and i tried out your recipet but it doesnt worked.
it gave back this error:
-----------------------------
#{}
-- Error occurred in i loop
-- Frame:
-- i: 1
-- No ""append"" function for $selection
#{}
#{}
OK
--------------------------------
Theres another problem what maybe you can help on. I just try to append 2 edge selection
-----------------------
ami = $.selectedEdges
ami2 = $.selectedEdges
append ami ami2
-----------------------
it gave back that error:
-------------------------
-- Runtime error: Operation not supported on this type of selection: #edges(514, 574, 575, 576, 577, 578, 590, 591, 592, 593, 594, 638, 639, 640, 641, 642, 643, 644, 645, 646, 652, ... : $Editable_Poly:Sphere01 @ [3.145920,-19.551071,0.000000])
-------------------------
so for some reason its says it don't want 2 edge selections but in the max script refernce it says it need 2 edge selections \append <edgeselection> (<edgeselection> | <integer>)\ i dunno how or why so if you or someone could help me it would be great.
The main thing what i want to reach is to add 2 edgeselections into one.
thx for your help.