Reverted amb149

This commit is contained in:
Steve Dudenhoeffer 2007-08-16 15:16:41 +00:00
parent 550dbae0c7
commit 0bb430b3eb
2 changed files with 3 additions and 21 deletions

View File

@ -237,31 +237,11 @@ void EventsMngr::parserInit(int msg_type, float* timer, CPlayer* pPlayer, int in
if (pPlayer)
{
// seriously who writes an if statement like this
// if (!(*iter).m_FlagPlayer || (pPlayer->IsAlive() ? !(*iter).m_FlagAlive : !(*iter).m_FlagDead))
if (!(*iter).m_FlagPlayer)
if (!(*iter).m_FlagPlayer || (pPlayer->IsAlive() ? !(*iter).m_FlagAlive : !(*iter).m_FlagDead))
{
(*iter).m_Done = true;
continue;
}
else if ((*iter).m_FlagAlive) // can only be sent to an alive user
{
if (!pPlayer->IsAlive() ||
!pPlayer->ingame) // fix for amb149 - is_user_alive checks ingame status, so this should too
{
(*iter).m_Done = true;
continue;
}
}
else if ((*iter).m_FlagDead) // can only be sent to "dead" users
{
if (pPlayer->IsAlive() &&
pPlayer->ingame) // added to compliment amb149 fix: check both incase there is stale health data
{
(*iter).m_Done = true;
continue;
}
}
}
else if (!(*iter).m_FlagWorld)
{

View File

@ -116,6 +116,8 @@ native console_cmd(id,const cmd[],any:...);
* "c" - send only once when repeated to other players.
* "d" - call if is send to dead player.
* "e" - to alive.
* NOTE: Due to a long-standing bug that would break compatibility with old plugins,
* the client id should be checked for alive/dead state if you use d or e.
* Examples for conditions:
* "2=c4" - 2nd parameter of message must be sting "c4".
* "3>10" - 3rd parameter must be greater then 10.