From ac6d7c4384d12ce7ff59162db892139fc91109c1 Mon Sep 17 00:00:00 2001 From: Night Owl Date: Sun, 2 Jul 2017 19:35:16 +0500 Subject: [PATCH] Merge https://github.com/SamVanheer/HLEnhanced/commit/5cade5b7607da186349ad4c49fd778cff40ea3ee --- dlls/monsters.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/dlls/monsters.cpp b/dlls/monsters.cpp index cfe4c561..5f112a62 100644 --- a/dlls/monsters.cpp +++ b/dlls/monsters.cpp @@ -334,12 +334,10 @@ void CBaseMonster::Look( int iDistance ) { if( pev->spawnflags & SF_MONSTER_WAIT_TILL_SEEN ) { - CBaseMonster *pClient; - - pClient = pSightEnt->MyMonsterPointer(); + CBaseMonster *pClient = pSightEnt->MyMonsterPointer(); // don't link this client in the list if the monster is wait till seen and the player isn't facing the monster - if( pSightEnt && !pClient->FInViewCone( this ) ) + if( pClient && !pClient->FInViewCone( this ) ) { // we're not in the player's view cone. continue;