updated sample extension for IMemUtils support
--HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40969
This commit is contained in:
parent
35c13983df
commit
1200ee470e
@ -50,6 +50,7 @@
|
|||||||
//#define SMEXT_ENABLE_HANDLESYS
|
//#define SMEXT_ENABLE_HANDLESYS
|
||||||
//#define SMEXT_ENABLE_PLAYERHELPERS
|
//#define SMEXT_ENABLE_PLAYERHELPERS
|
||||||
//#define SMEXT_ENABLE_DBMANAGER
|
//#define SMEXT_ENABLE_DBMANAGER
|
||||||
#define SMEXT_ENABLE_GAMECONF
|
//#define SMEXT_ENABLE_GAMECONF
|
||||||
|
//#define SMEXT_ENABLE_MEMUTILS
|
||||||
|
|
||||||
#endif // _INCLUDE_SOURCEMOD_EXTENSION_CONFIG_H_
|
#endif // _INCLUDE_SOURCEMOD_EXTENSION_CONFIG_H_
|
||||||
|
@ -48,6 +48,9 @@ IDBManager *dbi = NULL; /**< DB Manager */
|
|||||||
#if defined SMEXT_ENABLE_GAMECONF
|
#if defined SMEXT_ENABLE_GAMECONF
|
||||||
IGameConfigManager *gameconfs = NULL; /**< Game config manager */
|
IGameConfigManager *gameconfs = NULL; /**< Game config manager */
|
||||||
#endif //SMEXT_ENABLE_DBMANAGER
|
#endif //SMEXT_ENABLE_DBMANAGER
|
||||||
|
#if defined SMEXT_ENABLE_MEMUTILS
|
||||||
|
IMemoryUtils *memutils = NULL;
|
||||||
|
#endif
|
||||||
|
|
||||||
/** Exports the main interface */
|
/** Exports the main interface */
|
||||||
PLATFORM_EXTERN_C IExtensionInterface *GetSMExtAPI()
|
PLATFORM_EXTERN_C IExtensionInterface *GetSMExtAPI()
|
||||||
@ -100,6 +103,9 @@ bool SDKExtension::OnExtensionLoad(IExtension *me, IShareSys *sys, char *error,
|
|||||||
#if defined SMEXT_ENABLE_GAMECONF
|
#if defined SMEXT_ENABLE_GAMECONF
|
||||||
SM_GET_IFACE(GAMECONFIG, gameconfs);
|
SM_GET_IFACE(GAMECONFIG, gameconfs);
|
||||||
#endif
|
#endif
|
||||||
|
#if defined SMEXT_ENABLE_MEMUTILS
|
||||||
|
SM_GET_IFACE(MEMORYUTILS, memutils);
|
||||||
|
#endif
|
||||||
|
|
||||||
if (SDK_OnLoad(error, maxlength, late))
|
if (SDK_OnLoad(error, maxlength, late))
|
||||||
{
|
{
|
||||||
|
@ -42,6 +42,9 @@
|
|||||||
#if defined SMEXT_ENABLE_GAMECONF
|
#if defined SMEXT_ENABLE_GAMECONF
|
||||||
#include <IGameConfigs.h>
|
#include <IGameConfigs.h>
|
||||||
#endif
|
#endif
|
||||||
|
#if defined SMEXT_ENABLE_MEMUTILS
|
||||||
|
#include <IMemoryUtils.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined SMEXT_CONF_METAMOD
|
#if defined SMEXT_CONF_METAMOD
|
||||||
#include <ISmmPlugin.h>
|
#include <ISmmPlugin.h>
|
||||||
@ -207,6 +210,9 @@ extern IDBManager *dbi;
|
|||||||
#if defined SMEXT_ENABLE_GAMECONF
|
#if defined SMEXT_ENABLE_GAMECONF
|
||||||
extern IGameConfigManager *gameconfs;
|
extern IGameConfigManager *gameconfs;
|
||||||
#endif //SMEXT_ENABLE_DBMANAGER
|
#endif //SMEXT_ENABLE_DBMANAGER
|
||||||
|
#if defined SMEXT_ENABLE_MEMUTILS
|
||||||
|
extern IMemoryUtils *memutils;
|
||||||
|
#endif
|
||||||
|
|
||||||
#if defined SMEXT_CONF_METAMOD
|
#if defined SMEXT_CONF_METAMOD
|
||||||
PLUGIN_GLOBALVARS();
|
PLUGIN_GLOBALVARS();
|
||||||
|
Loading…
Reference in New Issue
Block a user