Skip to content

Commit

Permalink
Fix replay workaround not triggering (#2033)
Browse files Browse the repository at this point in the history
  • Loading branch information
hydrogen-mvm committed Jul 29, 2023
1 parent 8d60a46 commit a20eb08
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 7 deletions.
6 changes: 2 additions & 4 deletions extensions/sdktools/hooks.cpp
Expand Up @@ -65,9 +65,6 @@ SH_DECL_HOOK2_void(INetChannel, ProcessPacket, SH_NOATTRIB, 0, struct netpacket_
SourceHook::CallClass<IBaseFileSystem> *basefilesystemPatch = NULL;

CHookManager::CHookManager()
#if SOURCE_ENGINE == SE_TF2
: replay_enabled("replay_enabled", false)
#endif
{
m_usercmdsPreFwd = NULL;
m_usercmdsFwd = NULL;
Expand Down Expand Up @@ -446,7 +443,8 @@ void CHookManager::NetChannelHook(int client)

/* Initial Hook */
#if SOURCE_ENGINE == SE_TF2
if (replay_enabled.GetBool())
ConVarRef replay_enable("replay_enable", false);
if (replay_enable.GetBool())
{
if (!m_bFSTranHookWarned)
{
Expand Down
3 changes: 0 additions & 3 deletions extensions/sdktools/hooks.h
Expand Up @@ -90,9 +90,6 @@ class CHookManager : IPluginsListener, IFeatureProvider
#endif
INetChannel *m_pActiveNetChannel;
bool m_bFSTranHookWarned = false;
#if SOURCE_ENGINE == SE_TF2
ConVarRef replay_enabled;
#endif
};

extern CHookManager g_Hooks;
Expand Down

0 comments on commit a20eb08

Please sign in to comment.