PDA

View Full Version : anyway to intercept/record maxscript in plugin?


nathan7
01-30-2008, 09:17 AM
anyway to intercept/record maxscript in plugin?

hi, i need a way to intercept/record what the user is doing inside my plugin, i need to get the strings of script and do some work on it, anyone?

vScourge
01-30-2008, 03:05 PM
You can acquire the current contents of the Macro Recorder like this:

mrBuffer = macrorecorder as string
mrCommands = filterString mrBuffer "\n\r"

That gives you an array of command strings to manipulate.

Unfortunately, this doesn't prevent the user from clearing the macrorecorder display by hand, leaving you with nothing.

There's also no way (to my knowledge) to enable/disable the macrorecorder itself. You can force it on prior to startup by setting this value in 3dsmax.ini, however:

[MAXScript]
EnableMacroRecorder=1

nathan7
01-30-2008, 03:28 PM
Hi Adam:
this is not c++ code right? what is it?

mrBuffer = macrorecorder as string
mrCommands = filterString mrBuffer "\n\r"

vScourge
01-30-2008, 03:33 PM
Sorry, it's MaxScript. If you're talking about a compiled plugin, you may have more options available. I'm not as familiar with the SDK.

CGTalk Moderation
01-30-2008, 03:33 PM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.