From 91bebe0c523b76e660faeeb5e9199fb4f3cef450 Mon Sep 17 00:00:00 2001 From: GAMMACASE <31375974+GAMMACASE@users.noreply.github.com> Date: Wed, 22 Jul 2026 23:16:21 +0300 Subject: [PATCH] Restore l2cache.h & correct ehandle.h includes --- game/shared/ehandle.h | 1 + public/tier0/l2cache.h | 46 ++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 47 insertions(+) create mode 100644 public/tier0/l2cache.h diff --git a/game/shared/ehandle.h b/game/shared/ehandle.h index 8997761e..26c2055c 100644 --- a/game/shared/ehandle.h +++ b/game/shared/ehandle.h @@ -12,6 +12,7 @@ #endif #include "entity2/entitysystem.h" +#include "entity2/entityinstance.h" #include "entityhandle.h" // -------------------------------------------------------------------------------------------------- // diff --git a/public/tier0/l2cache.h b/public/tier0/l2cache.h new file mode 100644 index 00000000..d1a00db4 --- /dev/null +++ b/public/tier0/l2cache.h @@ -0,0 +1,46 @@ +//========= Copyright © 1996-2005, Valve Corporation, All rights reserved. ============// +// +// Purpose: +// +//=============================================================================// +#ifndef CL2CACHE_H +#define CL2CACHE_H +#ifdef _WIN32 +#pragma once +#endif + +class P4Event_BSQ_cache_reference; + +class CL2Cache +{ +public: + + CL2Cache(); + ~CL2Cache(); + + void Start( void ); + void End( void ); + + //------------------------------------------------------------------------- + // GetL2CacheMisses + //------------------------------------------------------------------------- + int GetL2CacheMisses( void ) + { + return m_iL2CacheMissCount; + } + +#ifdef DBGFLAG_VALIDATE + void Validate( CValidator &validator, tchar *pchName ); // Validate our internal structures +#endif // DBGFLAG_VALIDATE + +private: + + int m_nID; + + P4Event_BSQ_cache_reference *m_pL2CacheEvent; + int64 m_i64Start; + int64 m_i64End; + int m_iL2CacheMissCount; +}; + +#endif // CL2CACHE_H