From 20c76179262ebd3b8ca9b503e72215f0b01e777c Mon Sep 17 00:00:00 2001 From: Alibek Omarov Date: Sun, 14 Apr 2024 12:12:07 +0300 Subject: [PATCH] Rename EFLAG_MONSTER to EFLAG_FLESH_SOUND (#449) This is mentioned in default delta.lst shipped with HL25: ``` DEFINE_DELTA( eflags, DT_INTEGER, 2, 1.0 ), // JoshA: Changed to 2 for EFLAG_FLESH_SOUND to fix flesh sounds on entities. If a mod ships updated DLLs and not this file, they just won't have that fix. ``` --- cl_dll/ev_hldm.cpp | 2 +- common/const.h | 2 +- dlls/client.cpp | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/cl_dll/ev_hldm.cpp b/cl_dll/ev_hldm.cpp index 2e6b4932..e28742f0 100644 --- a/cl_dll/ev_hldm.cpp +++ b/cl_dll/ev_hldm.cpp @@ -112,7 +112,7 @@ float EV_HLDM_PlayTextureSound( int idx, pmtrace_t *ptr, float *vecSrc, float *v // Player if( ( entity >= 1 && entity <= gEngfuncs.GetMaxClients() ) - || ( ( ent = gEngfuncs.GetEntityByIndex( entity )) && ( ent->curstate.eflags & EFLAG_MONSTER ))) + || ( ( ent = gEngfuncs.GetEntityByIndex( entity )) && ( ent->curstate.eflags & EFLAG_FLESH_SOUND ))) { // hit body chTextureType = CHAR_TEX_FLESH; diff --git a/common/const.h b/common/const.h index 5b7e1737..3e2989f5 100644 --- a/common/const.h +++ b/common/const.h @@ -127,7 +127,7 @@ // entity flags #define EFLAG_SLERP 1 // do studio interpolation of this entity -#define EFLAG_MONSTER 2 +#define EFLAG_FLESH_SOUND 2 // // temp entity events diff --git a/dlls/client.cpp b/dlls/client.cpp index 4e269eae..7e77f7b5 100644 --- a/dlls/client.cpp +++ b/dlls/client.cpp @@ -1313,11 +1313,11 @@ int AddToFullPack( struct entity_state_s *state, int e, edict_t *ent, edict_t *h && Entity->Classify() != CLASS_NONE && Entity->Classify() != CLASS_MACHINE ) { - SetBits( state->eflags, EFLAG_MONSTER ); + SetBits( state->eflags, EFLAG_FLESH_SOUND ); } else { - ClearBits( state->eflags, EFLAG_SLERP | EFLAG_MONSTER ); + ClearBits( state->eflags, EFLAG_SLERP | EFLAG_FLESH_SOUND ); } return 1;