diff --git a/core/HalfLife2.cpp b/core/HalfLife2.cpp index ba6885e2..a8fb7caf 100644 --- a/core/HalfLife2.cpp +++ b/core/HalfLife2.cpp @@ -51,6 +51,10 @@ #include #endif +#if SOURCE_ENGINE == SE_TF2 || SOURCE_ENGINE == SE_DODS || SOURCE_ENGINE == SE_HL2DM || SOURCE_ENGINE == SE_CSS +#define SE_SDK2013_2025 +#endif + typedef ICommandLine *(*FakeGetCommandLine)(); #define TIER0_NAME FORMAT_SOURCE_BIN_NAME("tier0") @@ -1065,7 +1069,7 @@ CBaseEntity *CHalfLife2::ReferenceToEntity(cell_t entRef) { /* Proper ent reference */ int hndlValue = entRef & ~ENTREF_MASK; -#if SOURCE_ENGINE == SE_TF2 +#if defined(SE_SDK2013_2025) auto hndl = CBaseHandle::UnsafeFromIndex(hndlValue); #else CBaseHandle hndl(hndlValue); @@ -1173,7 +1177,7 @@ int CHalfLife2::ReferenceToIndex(cell_t entRef) { /* Proper ent reference */ int hndlValue = entRef & ~ENTREF_MASK; -#if SOURCE_ENGINE == SE_TF2 +#if defined(SE_SDK2013_2025) auto hndl = CBaseHandle::UnsafeFromIndex(hndlValue); #else CBaseHandle hndl(hndlValue); @@ -1243,7 +1247,7 @@ cell_t CHalfLife2::ReferenceToBCompatRef(cell_t entRef) } int hndlValue = entRef & ~ENTREF_MASK; -#if SOURCE_ENGINE == SE_TF2 +#if defined(SE_SDK2013_2025) auto hndl = CBaseHandle::UnsafeFromIndex(hndlValue); #else CBaseHandle hndl(hndlValue); diff --git a/hl2sdk-manifests b/hl2sdk-manifests index 20b3a014..931f7aa5 160000 --- a/hl2sdk-manifests +++ b/hl2sdk-manifests @@ -1 +1 @@ -Subproject commit 20b3a014264b38908c4a5d4eb263ba2c488f3dc1 +Subproject commit 931f7aa57823c3bcf34f1867e28d8d12769a8ba7