Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/core/sp_main.cpp
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -370,9 +370,6 @@ bool CSourcePython::Load( CreateInterfaceFn interfaceFactory, CreateInterfaceFn
void CSourcePython::Unload( void )
{
Msg(MSG_PREFIX "Unloading...\n");

DevMsg(1, MSG_PREFIX "Unhooking all functions...\n");
GetHookManager()->UnhookAllFunctions();

#if defined(ENGINE_ORANGEBOX) || defined(ENGINE_BMS) || defined(ENGINE_GMOD)
if (m_pOldSpewOutputFunc)
Expand All @@ -387,10 +384,13 @@ void CSourcePython::Unload( void )

DevMsg(1, MSG_PREFIX "Resetting cache notifier...\n");
modelcache->SetCacheNotify(m_pOldMDLCacheNotifier);

DevMsg(1, MSG_PREFIX "Shutting down python...\n");
g_PythonManager.Shutdown();

DevMsg(1, MSG_PREFIX "Unhooking all functions...\n");
GetHookManager()->UnhookAllFunctions();

DevMsg(1, MSG_PREFIX "Clearing all commands...\n");
ClearAllCommands();

Expand Down