From e3555c0fedb251ad35c2e0ed9677a81e2865ec03 Mon Sep 17 00:00:00 2001 From: RaphaelIT7 Date: Tue, 19 Nov 2024 23:05:55 +0100 Subject: [PATCH] sourcetv: enable this code again --- source/modules/sourcetv.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/source/modules/sourcetv.cpp b/source/modules/sourcetv.cpp index 854a38d..d50710b 100644 --- a/source/modules/sourcetv.cpp +++ b/source/modules/sourcetv.cpp @@ -94,14 +94,13 @@ static void hook_CSteam3Server_NotifyClientDisconnect(void* pServer, CBaseClient g_Lua->CallFunctionProtected(2, 0, true); } - // The code below is broken? Idk why. - /*auto it = g_pPushedCHLTVClient.find(hltv->Client(0)); + auto it = g_pPushedCHLTVClient.find((CHLTVClient*)pClient); if (it != g_pPushedCHLTVClient.end()) { g_Lua->ReferenceFree(it->second->iTableReference); g_Lua->CreateTable(); it->second->iTableReference = g_Lua->ReferenceCreate(); // Create a new empty Lua table for the next client. - }*/ + } } detour_CSteam3Server_NotifyClientDisconnect.GetTrampoline()(pServer, pClient);