====== PluginInit plugin export ======
Must-have plugin export which is used by PlayClaw to initialize plugin after load.
==== Syntax ====
PLUGIN_EXPORT DWORD PluginInit(
[in] DWORD dwPluginID
);
==== Parameters ====
dwPluginID [in]\\
Unique plugin ID given in this PlayClaw start. Plugin should keep it to use later in sdk functions.
==== Return value ====
Plugin must return a set of plugin flags. If plugin will not return **PC_PLUGIN_FLAG_IS_ACTIVE** flag then PlayClaw will count it is disabled and will unload plugin from memory.
==== Sample code ====
// global variable to store plugin id
DWORD m_dwPluginID = -1;
PLUGIN_EXPORT DWORD PluginInit(DWORD dwPluginID)
{
// store unique plugin id (we will need it for some functions)
m_dwPluginID = dwPluginID;
// additional init
// ...
// this is active plugin with overlay caps
return PC_PLUGIN_FLAG_IS_ACTIVE | PC_PLUGIN_FLAG_IS_OVERLAY;
}
==== See also ====
[[plugin_sdk:exports:PluginShutdown|PluginShutdown]]\\
[[plugin_sdk:exports:|Other export functions]]\\