main()
function of a normal C program; its where things start. You may also implement a function called messiahExit() which will get called when your plugin is being unloaded; unlike messiahEntry() this function is not required. Rather than hard coding the signatures of these functions you are advised to use the Entry Point Macros. These macros, _pluginEntry() and _pluginExit(), define the signatures of messiahEntry() and messiahExit() respectively. Using these macros will help to shield your code from changes in messiahAPI.
// Check API VERSION _API_CHECKVERSION(_MESSIAH_API_VERSION); // Check the program _API_CHECKPROGRAM(_MESSIAH_PROGRAM_STUDIO); // Only run in messiah:studio // Set the plugin's name _API_PLUGIN_NAME("YourPluginName"); // Set component retrieval function _API_GETAPIFUNC;
_MESSIAH_PLUGIN_ALL("YourPluginName");
#define _MAINPLUGIN_FILE #include "YourPluginName.h" _pluginEntry { // Plugin Setup and Component Retrieval _MESSIAH_PLUGIN_ALL("YourPluginName"); // Register Modules // ... return FX_PLUGIN_OK; } _pluginExit { // Cleanup // ... }
© 2003 pmG WorldWide,
LLC.
|
Last
Updated on Thu Jul 10 04:49:37 2003
|