Community
3ds Max Programming
Welcome to Autodesk’s 3ds Max Forums. Share your knowledge, ask questions, and explore popular 3ds Max SDK, Maxscript and Python topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

MaxScript CoronaMaterial Falloff and IOR

5 REPLIES 5
SOLVED
Reply
Message 1 of 6
cfGVREN
1135 Views, 5 Replies

MaxScript CoronaMaterial Falloff and IOR

Hi all,

 

i need a MaxScript, which searches all used coronaMtl, changes ReflectIOR to 1.52 and all Falloff Maps Type to Perpendicular/Parallel.

 

This is what i have so far:

 

coronaMats = getClassInstances CoronaMtl
 for mat in coronaMats do
 (
	mat.fresnelIor = 1.52
	mat.texmapReflect.type = 1

 )

 

It works vor the IOR, but if after the Reflect Falloff map is something else (like CollerCorrection) i get an error...

what can i do/add?

 

Thank you!

Labels (1)
5 REPLIES 5
Message 2 of 6
cfGVREN
in reply to: cfGVREN

Does anyone have an idea? 🙂

Message 3 of 6
Swordslayer
in reply to: cfGVREN

Message 4 of 6
cfGVREN
in reply to: Swordslayer

Doesnt seam to be the Solution 😞

 

There is no error message, if i use your code, but it is not changing the falloff map type...

I guess this time it is, because of the ColorMap at the end?

 

Here is an Image of my TestMaterial

 

MaterialTest.PNG

Message 5 of 6
Swordslayer
in reply to: cfGVREN

Oh, so you want to change it anywhere in the mat hierarchy? You can always do it like this:

 

(getClassInstances Falloff target:mat).type = 1
-- or (getClassInstances Falloff target:mat.texmapReflect).type = 1 if you want to limit it to that one slot
Message 6 of 6
cfGVREN
in reply to: Swordslayer

Thats it! Thank you so much!

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Technology Administrators


Autodesk Design & Make Report