PDA

View Full Version : syntax for flipping a boolean setting?


Decency
11-05-2009, 03:53 PM
For example, if I have a toggle set to on, I want maxscript to turn it off. If it is off, I need maxscript to turn it on.

MarcoBrunetta
11-05-2009, 04:06 PM
You can easily use NOT to flip a boolean value. So if you have:


(
local someVar = true

someVar = NOT someVar --Will set the var to false
someVar = NOT someVar --Will set the var to true again
)

Decency
11-05-2009, 04:24 PM
Thanks man, thats exactly what I needed!

CGTalk Moderation
11-05-2009, 04:24 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.