Notifications
Clear all

[Closed] script runs second time, but not the first time…

Cool And in total agreement!

Ironically, his rollouts are already prefixed! Ha ha

…I’m not going to bother with checking whether A and B are numbers. I simply expect that all the scripts using it will call it correctly, and if a third party should use it and decide to send it a string for absolutely no good reason… well, not my problem.

defining the type of variabls is what I was looking for but in max all variables seem to be type free

I do understand the struct thing now…but i have still little trouble to use it
I need some experience

1 Reply
(@zeboxx2)
Joined: 11 months ago

Posts: 0

In Maxscript 2009 you can access any value by using
NameRollout.NameSpinner.value
The global issue has been eliminated
but if you try with global he doesn’t find the value, pretty frustrating

<rollout>.<control>.<something> has been available at least since Max5… pretty sure in Max4 as well

Speaking of rollout Scoping. I’ve been passing values into rollouts by using an “init” function in the rollout, instead of the “on open” which is with in the scope of the R.O.


(
rollout myrollout "Look at ME!"
(
label LB00 ""

function init NodeorDataIwantToWorkWithandIsNotSelectedorGloballyscoped =
	(
   LB00.text = NodeorDataIwantToWorkWithandIsNotSelectedorGloballyscoped
	)
 )

createDialog myrollout 300 90
myrollout.init "Look At Me"
)

It works, but is there a better way to get data, that is not globally scoped, into the scope of a rollout? and no, that’s not a typical variable name for me…

Haha! I was about to say…

Page 2 / 2