mysel = selection as array
for obj in selection do obj.layer.select true
$.ishidden = true
mysel.ishidden = false
in big scene , speed is very slow
is that good idea ?
Forum topic · Scripts Wanted
By dussla · 2013-05-21
mysel = selection as array
for obj in selection do obj.layer.select true
$.ishidden = true
mysel.ishidden = false
in big scene , speed is very slow
is that good idea ?
Use with redraw off
miauu · 2013-05-21
with redraw off
(
-- code here.
)
or use disableSceneredraw()/enbleSceneRedraw()
...hide unselected nodes in the own layer
barigazy · 2013-05-21
Yup. As Kostadin said "with redraw off (/*...your code...*/)"
layNames = #()
for o in selection do appendIfUnique layNames o.layer.name
with redraw off
(
for i = 1 to layNames.count do
(
(LayerManager.getLayerFromName layNames[i]).nodes &theNodes
hide (for o = 1 to theNodes.count where not theNodes[o].isSelected collect theNodes[o])
)
free layNames
)
pls i use max9 32bit, that is not work
dussla · 2013-05-21
perpect
good good good
thank you really really
barigazy · 2013-05-21
If you have problem then change 2nd line to
for o in selection where finditem layNames o.layer.name == 0 do append layNames o.layer.name
wow man ... max 9
barigazy · 2013-05-21
I did not know anything about mxs when I used this version. Maxscript is changed a lot since max9. You will have more problems with newer code.
miauu · 2013-05-21
Hey, Branko, if I remember correctly for CheckMate tools contest(TurboSquid), one of the requirements was the tools to support max7. :)
Max 9 with AVG extension is good enough.
:)
barigazy · 2013-05-21
are you kidding me. That's the challange more then contest.:) Sure max9 is more powerful then max7. Do you remember last comment on these thread on first page :)
http://forums.cgsociety.org/showthread.php?f=98&t=1070669 Denis put very nice(funny) message for max9 and below users.