Notifications
Clear all

[Closed] How to avoid restarting Max for script update

you could just comment out the macroscript line and evaluate it as a normal rollout script until you are happy with it. I usually keep my macros and the script itself separate and just have a filein method on the mcr itself, pointing to the ms file.

Thanks.

Actually I’m including the script code into the Macroscript. Maybe it’s not the same as using that filein method :curious:

Cheers.

Hi Capt,

The way i understand it, and from what is written in the help, it’s a scope issue. filein will run the exterior file in a global scope, whereas include() is similar but will run in local scope of the block it is called within. The main difference is filein is like picking the script with the run script command, and include is like a run-time insertion of the code into what is currently being evaluated, and as a way of breaking long scripts into more managable/editable chunks.

Thanks guys for help and explanation. Using the method fileIn() I get the result I want: executing the script updated with the changes I made.
Now I unserstood a little bit more about Maxscript works. I appreciate

Have a nice day,
Cheers.

Page 2 / 2