Hi.
I need some help in working with MAXScript State Sets.
I have read page http://docs.autodesk.com/3DSMAX/15/ENU/MAXScript-Help/index.html?url=fil…. But I could not find the answers to two questions.
1. How to find out the name of the State Set which the script is executed?
2. How to programmatically create a State Set the template?
I need to write a generic script that will change the names of files in the external render, depending on the names of State Set, which give a command to render.
For example this:
vr = renderers.current
sName = stateSet.Name
FullPathRAW = "D:/_"+ sName + ".exr"
FullPathCNL = "D:/_"+ sName + ".tif"
vr.output_rawFileName = FullPathRAW
vr.output_splitfilename = FullPathCNL
/* render outputwidth:640 outputheight:480 outputfile:("D:/test.png") vfb:on */
Comments (7)
Comment policy
On the first question I found a solution:
The question remains 2.
Are you read this from mxs help?
http://docs.autodesk.com/3DSMAX/15/ENU/MAXScript-Help/index.html?url=fil…
Yes, I've read.
But I could not find there the answers to these questions.
By the way, the version that I have described, is only at the top level.
For Sub-State must change the index of the array.
What about this
stateCount = masterState.Children.count
--create template for the first item ei. stateset
masterState.Children.item[0].CreateTemplate()
I do not speak English.
Maybe I did not put the question correctly. I do not want to create a template. How to do it I found.
I want to create a State Set using an already created template.
Max2012 and Max2013 have different state scene managment system.
Also you can read this thread
http://www.scriptspot.com/forums/3ds-max/general-scripting/apply-a-state…
Thanks for the link. I will read.
But I am looking for information on State Sets, and not on the Scene State.