Notifications
Clear all

[Closed] Check if UVWMap modifier is applied

Good morning!

I tried several ways, but didn’t come up to a solution that lets me select all objects in a scene which have a UVW Map modifier in the stack.
I tried

select (for o in geometry where o.modifiers == Uvwmap collect o)

But all the maxscript listener replies is an “ok” 🙁

Does anyone around already done a script on this?

Thanks in advance for all your help.

5 Replies

You can use my script to do it for any modifier:
http://www.scriptspot.com/3ds-max/modifier-modifier-zorb

With your code you are not looping through all the modifers on each object
try this:

MySelection=#()
for obj in objects do (for mod in obj.modifiers do (if classof mod == uvwmap do (append Myselection obj)))
Select MySelection

I did come up with combining 2 for-loops as well now, but didn’t get the if-clause to work correctly.

Thanks for your short script. It works nice!

Now, how can I easily invert the selection to get all objects without the specific modifier being selected? – My brain is stuck in some way. Monday morning. I need more coffee

Not to forget the wonderfull syntax of the for loop (compared to the languages i know max his for is verry flexible)

--clearSelection()
for obj in geometry do for modi in obj.modifiers where classof modi == Uvwmap do selectMore obj

Edit:
Well to keep it simple “max select invert”, and otherwise you can check up on “findItem” combined with a for loop that collects “classof obj”

max select invert

So easy, as it is