From 02ffffe05ae9c55da8a736fc8039cacf523f0fce Mon Sep 17 00:00:00 2001 From: Scott Ehlert Date: Fri, 2 Feb 2007 22:47:14 +0000 Subject: [PATCH] Oi, consistency... --HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40432 --- core/systems/PluginSys.cpp | 8 ++++---- core/systems/PluginSys.h | 10 +++++----- plugins/include/sourcemod.inc | 4 ++-- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/core/systems/PluginSys.cpp b/core/systems/PluginSys.cpp index 3be86aa47..6eb5941ef 100644 --- a/core/systems/PluginSys.cpp +++ b/core/systems/PluginSys.cpp @@ -243,7 +243,7 @@ void CPlugin::UpdateInfo() m_info.version = m_info.version ? m_info.version : ""; } -void CPlugin::Call_OnPluginInit() +void CPlugin::Call_OnPluginStart() { if (m_status != Plugin_Loaded) { @@ -263,7 +263,7 @@ void CPlugin::Call_OnPluginInit() pFunction->Execute(&result); } -void CPlugin::Call_OnPluginUnload() +void CPlugin::Call_OnPluginEnd() { if (m_status < Plugin_Paused) { @@ -959,7 +959,7 @@ bool CPluginManager::RunSecondPass(CPlugin *pPlugin, char *error, size_t maxleng } /* Tell this plugin to finish initializing itself */ - pPlugin->Call_OnPluginInit(); + pPlugin->Call_OnPluginStart(); return true; } @@ -1003,7 +1003,7 @@ bool CPluginManager::UnloadPlugin(IPlugin *plugin) pListener->OnPluginUnloaded(pPlugin); } /* Notify plugin */ - pPlugin->Call_OnPluginUnload(); + pPlugin->Call_OnPluginEnd(); } for (iter=m_listeners.begin(); iter!=m_listeners.end(); iter++) diff --git a/core/systems/PluginSys.h b/core/systems/PluginSys.h index fe5dc201c..b46bd3566 100644 --- a/core/systems/PluginSys.h +++ b/core/systems/PluginSys.h @@ -74,7 +74,7 @@ using namespace SourceHook; * 6. If the plugin has failed to load at this point, any dynamic natives it has added are scrapped. * Furthermore, any plugin that referenced these natives must now have pass 2 re-ran. * PASS THREE (not a real pass): - * 7. Once all plugins are deemed to be loaded, OnPluginInit() is called + * 7. Once all plugins are deemed to be loaded, OnPluginStart() is called */ #define SM_CONTEXTVAR_MYSELF 0 @@ -157,16 +157,16 @@ public: bool Call_AskPluginLoad(char *error, size_t maxlength); /** - * Calls the OnPluginInit function. + * Calls the OnPluginStart function. * NOTE: Valid pre-states are: Plugin_Created * NOTE: Post-state will be Plugin_Running */ - void Call_OnPluginInit(); + void Call_OnPluginStart(); /** - * Calls the OnPluginUnload function. + * Calls the OnPluginEnd function. */ - void Call_OnPluginUnload(); + void Call_OnPluginEnd(); /** * Toggles debug mode in the plugin diff --git a/plugins/include/sourcemod.inc b/plugins/include/sourcemod.inc index 4a168f605..936fc2f5b 100644 --- a/plugins/include/sourcemod.inc +++ b/plugins/include/sourcemod.inc @@ -55,12 +55,12 @@ public Plugin:myinfo; forward OnPluginStart(Handle:myself); /** - * Called before OnPluginInit, in case the plugin wants to check for load failure. + * Called before OnPluginStart, in case the plugin wants to check for load failure. * This is called even if the plugin type is "private." Any natives from modules are * not available at this point. Thus, this forward should only be used for explicit * pre-emptive things, such as adding dynamic natives, or setting certain types of load filters. * - * NOTE: It is not safe to call externally resolved natives until OnPluginInit(). + * NOTE: It is not safe to call externally resolved natives until OnPluginStart(). * NOTE: Any sort of RTE in this function will cause the plugin to fail loading. * * @param myself Handle to the plugin.