3 * ===============================================================
4 * SourceMod SDK Tools Extension
5 * Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
6 * ===============================================================
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * as published by the Free Software Foundation; either version 2
11 * of the License, or (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
24 #ifndef _INCLUDE_SOURCEMOD_EXTENSION_PROPER_H_
25 #define _INCLUDE_SOURCEMOD_EXTENSION_PROPER_H_
29 * @brief SDK Tools extension code header.
32 #include "smsdk_ext.h"
33 #include <IBinTools.h>
34 #include <IPlayerHelpers.h>
35 #include <IGameHelpers.h>
36 #include <IEngineSound.h>
39 * @brief Implementation of the SDK Tools extension.
40 * Note: Uncomment one of the pre-defined virtual functions in order to use it.
42 class SDKTools : public SDKExtension, public IHandleTypeDispatch
45 void OnHandleDestroy(HandleType_t type, void *object);
47 virtual bool SDK_OnLoad(char *error, size_t maxlength, bool late);
48 virtual void SDK_OnUnload();
49 virtual void SDK_OnAllLoaded();
50 //virtual void SDK_OnPauseChange(bool paused);
51 virtual bool QueryRunning(char *error, size_t maxlength);
52 virtual bool QueryInterfaceDrop(SMInterface *pInterface);
53 virtual void NotifyInterfaceDrop(SMInterface *pInterface);
55 #if defined SMEXT_CONF_METAMOD
56 virtual bool SDK_OnMetamodLoad(ISmmAPI *ismm, char *error, size_t maxlen, bool late);
57 //virtual bool SDK_OnMetamodUnload(char *error, size_t maxlen);
58 //virtual bool SDK_OnMetamodPauseChange(bool paused, char *error, size_t maxlen);
62 extern IServerGameEnts *gameents;
63 extern IBinTools *g_pBinTools;
64 extern IGameConfig *g_pGameConf;
65 extern IGameHelpers *g_pGameHelpers;
66 extern HandleType_t g_CallHandle;
67 extern IEngineSound *engsound;
69 #endif //_INCLUDE_SOURCEMOD_EXTENSION_PROPER_H_