active material in browser

hello,
everybody. i was making a simple material script. it need to open the mat library browser and work with the selected material.

is there any way to get the selected mat from material browser as in activematerialslot() in matedit window? there is a materialbutton to pick material .but i cant find any other way. could you guys help? thanks

Comments

Comment viewing options

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

shortly - no

You can get the active slot in medit:
mtl = meditMaterials[activeMeditSlot]
but no way to do the same with mat libraries.
You can grab from there by index:
mtl = currentMaterialLibrary[1]

my recent MAXScripts RSS (archive here)

zahid hasan's picture

shortly-thanks

thanks for confirming.
btw, your layer cleaner script is big time saver for me. :-)

Comment viewing options

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