Reply
Reply
 
Thread Tools Display Modes
jeremiah_bigley's Avatar
Old (#1)
Can't seem to figure out how to make a if then statement change 2 things.
What I want is...


If 'something' == true then (do this and this)
else (do this)


What I am trying to do is create an edit poly NURMS toggle. I would like it to NURMS Subdivision on and Show Cage off, then go from 1 iteration, 2 iteration and back off.

(On, 1, 2, Off)

EDIT: NVM... Maxscript 101! Has someone else made it?! The answer is yes.
Sorry for not checking first.

Last edited by jeremiah_bigley; 10-03-2011 at 01:16 AM..
Offline , polygon, 663 Posts, Join Date May 2009, Location Coral Springs, Florida Send a message via Yahoo to jeremiah_bigley  
   Reply With Quote

monster's Avatar
Old (#2)
Ha, I have that exact script available on my website:

http://juantwo.com/maxscripts.html

It's called Toggle NURMSlevel.
Juan Martinez | Blog | Animator at Verse, Inc
Offline , polycounter, 953 Posts, Join Date Oct 2004, Location Dallas, TX USA Send a message via ICQ to monster Send a message via AIM to monster  
   Reply With Quote

jeremiah_bigley's Avatar
Old (#3)
well would you look at that! Yours was the one I found!
I did have a question though... the one you wrote toggles all objects globally. How would I go about tweaking it to just do the selected objects? What I tried was changing all of the 'objects' to $ which works... but when I have nothing selected I get an error.

I don't know enough to be able to do a check for that. :/


Btw man I love your scripts. And I am going to buy the game you just finished up once I graduate in December. ;) Been keeping an eye out and watching Chris' character art on facebook... I am stoked man!

Last edited by jeremiah_bigley; 10-03-2011 at 02:44 AM..
Offline , polygon, 663 Posts, Join Date May 2009, Location Coral Springs, Florida Send a message via Yahoo to jeremiah_bigley  
   Reply With Quote

monster's Avatar
Old (#4)
Thanks for the kind words. Yeah, Chris Moffitt is an awesome character artist. To change the script:

Each line that says:

Code:
for o in objects do
change it to

Code:
for o in selection do
Then you can change multiple object by just selecting them. Or just one if you only have one selected.

BTW, after you save you need to either evaluate the script or restart max.
Juan Martinez | Blog | Animator at Verse, Inc
Offline , polycounter, 953 Posts, Join Date Oct 2004, Location Dallas, TX USA Send a message via ICQ to monster Send a message via AIM to monster  
   Reply With Quote

jeremiah_bigley's Avatar
Old (#5)
Awesome man! I had something similar last night but I didn't know about evaluating the script. Works like a charm! I really appreciate the help and keep up the awesome work!
Offline , polygon, 663 Posts, Join Date May 2009, Location Coral Springs, Florida Send a message via Yahoo to jeremiah_bigley  
   Reply With Quote

Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Copyright 1998-2012 A. Risch