mirror of
https://github.com/ReactionQuake3/reaction.git
synced 2025-02-01 22:30:53 +00:00
FF/no-FF fixes. g_friendlyFire 0 = no FF, 1 = FF, 2 = no FF + knockback
This commit is contained in:
parent
dfa3a47fdd
commit
4109f03f9e
1 changed files with 11 additions and 1 deletions
|
@ -5,6 +5,9 @@
|
|||
//-----------------------------------------------------------------------------
|
||||
//
|
||||
// $Log$
|
||||
// Revision 1.37 2002/01/31 01:53:30 jbravo
|
||||
// FF/no-FF fixes. g_friendlyFire 0 = no FF, 1 = FF, 2 = no FF + knockback
|
||||
//
|
||||
// Revision 1.36 2002/01/12 20:02:16 hal9000
|
||||
// Verify we have a valid client pointer before using its members
|
||||
//
|
||||
|
@ -1343,6 +1346,12 @@ void G_Damage( gentity_t *targ, gentity_t *inflictor, gentity_t *attacker,
|
|||
return; // JBravo: No dmg during LCA
|
||||
}
|
||||
|
||||
// JBravo: FF control
|
||||
if (targ != attacker && targ->client && attacker->client &&
|
||||
targ->client->sess.sessionTeam == attacker->client->sess.sessionTeam &&
|
||||
!g_friendlyFire.integer)
|
||||
return;
|
||||
|
||||
// the intermission has allready been qualified for, so don't
|
||||
// allow any extra scoring
|
||||
if ( level.intermissionQueued ) {
|
||||
|
@ -1596,7 +1605,8 @@ void G_Damage( gentity_t *targ, gentity_t *inflictor, gentity_t *attacker,
|
|||
#else
|
||||
if ( targ != attacker && OnSameTeam (targ, attacker) ) {
|
||||
#endif
|
||||
if ( !g_friendlyFire.integer ) {
|
||||
// JBravo: more FF tweaks
|
||||
if ( g_friendlyFire.integer == 2 ) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue