Notifications
Clear all
[Closed] Detect that 3dsmax can execute script safely
Sep 26, 2019 5:21 pm
I’m sending scripts as string from external application to max and it turns out that max can execute incoming strings right away without any bother that rendering process may be active and etc… It feels like I can potentially break something up.
Is there any way to detect that script can be executed safely?
2 Replies
Sep 26, 2019 5:21 pm
the SDK function
BOOL ExecuteMAXScriptScript ( MCHAR * s, BOOL quietErrors = FALSE, FPValue * fpv=NULL )
returns FALSE if the script fails to compile or execute.
Sep 26, 2019 5:21 pm
Thanks, Klvnk.
Calling render() indeed return false when something is rendering at the moment.
But renderMap works just fine… and renders the map while max is busy… looks like there is no easy way to detect
.
g = (dotNetClass "Autodesk.Max.GlobalInterface").Instance
g.executemaxscriptscript "box();render()" true (g.fpvalue.create())
returns false but box is still being created