ScriptSpot home

Purge Empty Layers

Downloads

3ds Max compatibility
See original listing claims
Community reviewsNo reviews yet.

Listing details

Version
1.0
From original requirements
2010–2015
Original version requirement
3ds max 2010 - 2015
Author’s update date
Legacy votes
1
Listing created
How compatibility works

Compatibility comes from the author’s supported range or requirements in the original listing. A tested version records what the author tried.

“2020 unconfirmed” in the catalog means support for 3ds Max 2020 is still unknown.

Community reports record successful tests on specific releases.

Posted by

Digital Animation Services

David Sparks

More by this author

Description

This script deletes all empty layers. In max 2015 (at this time) it can keep ALL nested layers (user prompt) if any one of them has objects on it. In other words, if a user chooses "Yes" at the query, ONLY layers with NO children AND no objects will be deleted. All nested hierarchies are maintained down to the last layer that has objects in it. Choosing "No" at the prompt will unnest all layers and delete all empty layers. When using a version of max prior to 2015, the script will simpy delete any empty layers. There are no nesting options in previous versions of the Layer Manager. See the examples below.

Query option when executing the macroscript

Query option when executing the macroscript. Note: This will only show when using Max 2015.

 

The results of the Layer Explorer after running the script when the "Keep Nested Layers" option is chosen.

 

The results of the Layer Explorer after running the script on the same scene when the user chooses NOT to keep nested layers.

See the included README.txt file for installation instructions.

Reminder, this is a macroscript for quick execution from the UI.

I want to send a shoutout to user LoneRobot where he posted a quick help script for similar functionality a while back. A line of his code reminded me about the "by" descriptor for use in "for" loops. I used his method of cycling through  a loop backwards setting the "by" option to -1. Thanks!

Comments (2)
Draftsman35

Thanks

it helped me a lot

e.ov

thank you

Thanks for usefull script. And for selector "keep nested layers" - it' s very usefull.