sourcemm/sample_mm/SamplePlugin.cpp
changeset 20 7d2ff2c0999b
parent 12 9fd53562f68c
child 22 3fe8e457c5a2
     1.1 --- a/sourcemm/sample_mm/SamplePlugin.cpp	Mon Apr 18 18:26:40 2005 +0000
     1.2 +++ b/sourcemm/sample_mm/SamplePlugin.cpp	Mon Apr 18 19:33:44 2005 +0000
     1.3 @@ -5,9 +5,9 @@
     1.4  
     1.5  PLUGIN_EXPOSE(SamplePlugin, g_SamplePlugin);
     1.6  
     1.7 -//SH_DECL_HOOK6(IServerGameDLL, LevelInit, SH_NOATTRIB, 0, bool, char const *, char const *, char const *, char const *, bool, bool);
     1.8 +SH_DECL_HOOK6(IServerGameDLL, LevelInit, SH_NOATTRIB, 0, bool, char const *, char const *, char const *, char const *, bool, bool);
     1.9  
    1.10 -//bool LevelInit_handler( char const *pMapName, char const *pMapEntities, char const *pOldLevel, char const *pLandmarkName, bool loadGame, bool background );
    1.11 +bool LevelInit_handler( char const *pMapName, char const *pMapEntities, char const *pOldLevel, char const *pLandmarkName, bool loadGame, bool background );
    1.12  
    1.13  bool SamplePlugin::Load(PluginId id, ISmmAPI *ismm, factories *list, char *error, size_t maxlen)
    1.14  {
    1.15 @@ -21,7 +21,7 @@
    1.16  		return false;
    1.17  	}
    1.18  
    1.19 -	//SH_ADD_HOOK_STATICFUNC(IServerGameDLL, LevelInit, isgd, LevelInit_handler, false);
    1.20 +	SH_ADD_HOOK_STATICFUNC(IServerGameDLL, LevelInit, isgd, LevelInit_handler, false);
    1.21  
    1.22  	return true;
    1.23  }
    1.24 @@ -31,7 +31,12 @@
    1.25  	return true;
    1.26  }
    1.27  
    1.28 -/*bool LevelInit_handler( char const *pMapName, char const *pMapEntities, char const *pOldLevel, char const *pLandmarkName, bool loadGame, bool background )
    1.29 +void SamplePlugin::AllPluginsLoaded()
    1.30 +{
    1.31 +	//we don't really care
    1.32 +}
    1.33 +
    1.34 +bool LevelInit_handler( char const *pMapName, char const *pMapEntities, char const *pOldLevel, char const *pLandmarkName, bool loadGame, bool background )
    1.35  {
    1.36  	FILE *fp = fopen("c:\\dump.txt", "at");
    1.37  	if (!fp)
    1.38 @@ -42,4 +47,4 @@
    1.39  	fclose(fp);
    1.40  
    1.41  	RETURN_META_VALUE(MRES_IGNORED, false);
    1.42 -}*/
    1.43 +}