From d77290c497d4aa022dd709435fea3823e36e4a51 Mon Sep 17 00:00:00 2001 From: puzl Date: Sun, 7 May 2006 19:35:45 +0000 Subject: [PATCH] o removed 'enemy approaches' warning during round warmup git-svn-id: https://unknownworlds.svn.cloudforge.com/ns1@463 67975925-1194-0748-b3d5-c16f83f1a3a1 --- releases/3.2.0/settings.scr | 2 +- releases/3.2.0/source/mod/AvHGamerules.cpp | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/releases/3.2.0/settings.scr b/releases/3.2.0/settings.scr index d9d70036..e0935d2d 100644 --- a/releases/3.2.0/settings.scr +++ b/releases/3.2.0/settings.scr @@ -32,7 +32,7 @@ // Half-Life Server Configuration Layout Script (stores last settings chosen, too) -// File generated: Thu Mar 03 11:29:18 PM +// File generated: Sun May 07 10:30:06 AM // // // Cvar - Setting diff --git a/releases/3.2.0/source/mod/AvHGamerules.cpp b/releases/3.2.0/source/mod/AvHGamerules.cpp index 9821beea..cb5c16e6 100644 --- a/releases/3.2.0/source/mod/AvHGamerules.cpp +++ b/releases/3.2.0/source/mod/AvHGamerules.cpp @@ -1072,12 +1072,13 @@ bool AvHGamerules::CanEntityDoDamageTo(const CBaseEntity* inAttacker, const CBas *outScalar = theScalar; } - if(!theTeamsAreDifferent && !AvHSUGetIsExternalClassName(STRING(inReceiver->pev->classname))) + if(!theTeamsAreDifferent && !AvHSUGetIsExternalClassName(STRING(inReceiver->pev->classname)) && theGameHasStarted ) { AvHHive *theHive=(AvHHive *)dynamic_cast(inReceiver); - if ( theHive != NULL && !this->GetIsEntityUnderAttack(theHive->entindex()) ) { + if ( theHive != NULL ) { theCanDoDamage=false; - GetGameRules()->TriggerAlert((AvHTeamNumber)inAttacker->pev->team, ALERT_HIVE_DEFEND, theHive->entindex()); + if ( !this->GetIsEntityUnderAttack(theHive->entindex()) ) + GetGameRules()->TriggerAlert((AvHTeamNumber)inAttacker->pev->team, ALERT_HIVE_DEFEND, theHive->entindex()); } }