That CGTalk forum thread looks neat, but too complex for my taste :). Here’s the full setup in detail.
In this directory (every file in this directory will be executed by max at startup):
C:\Program Files\Autodesk\3ds Max Design 2011\stdplugs\stdscripts
I have a file called “Autoupdating.ms”
which looks like this:
(
try (
local filesMcr = getFiles "\\\\Library\maxscript\AutoUpdating\*.mcr"
local filesMs = getFiles "\\\\Library\maxscript\AutoUpdating\*.ms"
local filesMse = getFiles "\\\\Library\maxscript\AutoUpdating\*.mse"
join filesMs filesMCR
join filesMs filesMse
for f in filesMs do (
filein f
)
format "AutoUpdating Scripts Current(% scripts)\n" (filesMs.count as string)
) catch ( Print "AutoUpdating Scripts problem, check network connection..." )
)
Now, if you just do that, when you close and restart max and open the listener (MAXScript->Listener), you’ll see this printed “AutoUpdating Scripts Current(0 scripts)”. So we need to change the paths in the script to point to somewhere on our network.
\\\\Library\maxscript\AutoUpdating\*.mcr
\\\\Library\maxscript\AutoUpdating\*.ms
\\\\Library\maxscript\AutoUpdating\*.mse
Change these to a folder on your network
Drive letters can be used for instance, a directory on your W: drive called “Scripts”
W:\\Scripts\\AutoUpdate\\*.ms
a UNC path on your \\servername\Scripts\AutoUpdate
\\\\servername\\Scripts\\AutoUpdate\\*.ms
note: the double slashes mean single slashes to max because of reserved slashes for things like newline characters (\n)
note: the *.ms, *.mcr, *.mse - This is so when the script loads at runtime it gathers all of the ms, mcr, and mse files in the directory and runs them.
That’s it. Hope that works!
-Colin