Posted: Nov 30, 2009
Category:
If you have a plug-in which you don’t want exposed to the 3ds Max user interface you can return “FALSE” (or 0) from the “IsPublic()” exported DLL function. This has the sometimes undesirable side-effect that MAXScript can’t create the object.
To explicitly expose the hidden class to MAXScript you can use the MAXClass macro. For example adding the following line to a modifier plug-in project named DeleteSplineModifier would expose it to MAXScript even if it IsPublic() returns FALSE:
MAXClass delete_spline ( _T("DeleteSplineModifier"), Class_ID(SDELETE_CLASS_ID, 0), OSM_CLASS_ID, &modifier, md_auto_parms, end );
|
In order to post any comments, you must be logged in!
|
| Posted by Chris Johnson on Apr 03, 2010 at 03:57 AM
|
You should probably provide a little more context as to where you find this macro:
this class... MAXClass is not a macro, but a class definition found in:
\maxsdk\include\maxscript\maxwrapper\mxsobjects.h
(using the new file name... sorry but I'm not looking up the old file name in pre Max 2012 SDK's)
And that class takes a variable arguments constructor... *Hideous*. So you better know what you are doing when using it, cause those things are notoriously difficult to debug.
|