Notifications
Clear all
[Closed] Ifdef equivalent in maxscript
Page 2 / 2
Prev
May 29, 2019 10:06 pm
So if worcks in this case exactly like ifdesf? I was thinking about such solution, but you completlly right, my imagination stoped me from doing that, as in programming languages, I normally using like C++, something like this would never worck. Many thanks.
May 29, 2019 10:06 pm
Nah it wasn´t as easy, I tried firs this:
if myVar==undefined then
(
global myVar=OK
MyAttribute = attributes "my attribute"
(
...
)
)
It didn´t worck, as MyAttribute was seen as a local whatever and not avaible after exiting if statement, at the end have to change my code to:
if MyAttribute==undefined then
(
global MyAttribute = attributes "my attribute"
(
...
)
)
Which seems to worck.
May 29, 2019 10:06 pm
It is a great discovery and completely undoes the previous logic. Congratulations!
Page 2 / 2
Prev