summaryrefslogtreecommitdiff
path: root/src/cgame
diff options
context:
space:
mode:
authorTim Angus <tim@ngus.net>2006-07-02 15:55:55 +0000
committerTim Angus <tim@ngus.net>2006-07-02 15:55:55 +0000
commit061c247375c8aac977a3588a1dfb2382634da80e (patch)
tree5fd3e86653865a14453aff476956eac98e547490 /src/cgame
parente4d11790a55f620187a6359797128ee6d2c6e930 (diff)
* Obituaries that indicate team kills (tjw)
* g_mapConfigs no longer replaces maprotation.cfg settings (tjw)
Diffstat (limited to 'src/cgame')
-rw-r--r--src/cgame/cg_event.c17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/cgame/cg_event.c b/src/cgame/cg_event.c
index 7050f14d..bddc3a61 100644
--- a/src/cgame/cg_event.c
+++ b/src/cgame/cg_event.c
@@ -44,6 +44,7 @@ static void CG_Obituary( entityState_t *ent )
char className[ 64 ];
gender_t gender;
clientInfo_t *ci;
+ qboolean teamKill = qfalse;
target = ent->otherEntityNum;
attacker = ent->otherEntityNum2;
@@ -60,7 +61,11 @@ static void CG_Obituary( entityState_t *ent )
attackerInfo = NULL;
}
else
+ {
attackerInfo = CG_ConfigString( CS_PLAYERS + attacker );
+ if( ci && cgs.clientinfo[ attacker ].team == ci->team )
+ teamKill = qtrue;
+ }
targetInfo = CG_ConfigString( CS_PLAYERS + target );
@@ -324,8 +329,16 @@ static void CG_Obituary( entityState_t *ent )
if( message )
{
- CG_Printf( "%s %s %s%s\n",
- targetName, message, attackerName, message2 );
+ CG_Printf( "%s %s %s%s%s\n",
+ targetName, message,
+ ( teamKill ) ? S_COLOR_RED "TEAMMATE " S_COLOR_WHITE : "",
+ attackerName, message2 );
+ if( teamKill && attacker == cg.clientNum )
+ {
+ CG_CenterPrint( va ( "You killed " S_COLOR_RED "TEAMMATE "
+ S_COLOR_WHITE "%s", targetName ),
+ SCREEN_HEIGHT * 0.30, BIGCHAR_WIDTH );
+ }
return;
}
}