[Closed] Running a maxscript on a server using commandline
I’m trying to run a maxscript in server mode – i.e. – on an unlicensed machine, from the commandline.
I’ve tried:
3dsmax.exe -s -u MAXScript myscript.ms
and various other switches. 3dsmax seems to load, and then closes, and the script is not executing.
This needs to happen locally on the machine, not as a backburner job. Is this possible?
Depends what you are trying to do, some features aren’t supported in maxscript running in slave mode.
No interface features are used. To determine if the script is running I am writing text to a file.
I think server mode requires/assumes a connection to backburner before doing anything.
-Johan
Is there anything stopping you from sending off an empty rendering job with a pre-render script to do your bidding instead?
If you need something done, that’s not max specific, on a render machine why not use cmdJob with a custom python/c#/bat file? And have you taken a look at 3dsmaxcmd.exe?
-Johan
I’ve had my attempt at trying this some time ago. Turns out that if there is nothing to render max just quits.
So the only way to pull this off is to put the script as a pre-render script in an empty max scene.
The most flexible way to do this is to make a max file that has a prerender-script that in turn loads an external script file. This way you can have a static max file and a customizable external script file.