MCPcopy Create free account
hub / github.com/alliedmodders/sourcemod / CloseSourceMod

Method CloseSourceMod

core/sourcemod.cpp:462–481  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

460}
461
462void SourceModBase::CloseSourceMod()
463{
464 if (!sSourceModInitialized)
465 return;
466
467 SH_REMOVE_HOOK(IServerGameDLL, LevelInit, gamedll, SH_MEMBER(this, &SourceModBase::LevelInit), false);
468 SH_REMOVE_HOOK(IVEngineServer, GetMapEntitiesString, engine, SH_MEMBER(this, &SourceModBase::GetMapEntitiesString), false);
469
470 if (g_Loaded)
471 {
472 /* Force a level end */
473 LevelShutdown();
474 ShutdownServices();
475 }
476
477 /* Rest In Peace */
478 sCoreProviderImpl.ShutdownBridge();
479
480 g_pPawnEnv = NULL;
481}
482
483void SourceModBase::ShutdownServices()
484{

Callers 1

UnloadMethod · 0.80

Calls 1

ShutdownBridgeMethod · 0.80

Tested by

no test coverage detected