ZR: Allow DMG_BLAST and DMG_BURN if teams are different
This commit is contained in:
parent
38964c47ac
commit
323d46bbc2
@ -340,8 +340,18 @@ public Action DamageOnTakeDamage(int client, int &attacker, int &inflictor, floa
|
|||||||
return Plugin_Continue;
|
return Plugin_Continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Get zombie flag for each client.
|
||||||
|
new bool:clientzombie = InfectIsClientInfected(client);
|
||||||
|
new bool:attackerzombie = InfectIsClientInfected(attacker);
|
||||||
|
|
||||||
// If client is a zombie, then allow damage.
|
// If client is a zombie, then allow damage.
|
||||||
if (InfectIsClientInfected(client))
|
if (clientzombie)
|
||||||
|
{
|
||||||
|
return Plugin_Continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
// If client and attacker are not on the same team, then allow damage.
|
||||||
|
if (clientzombie != attackerzombie)
|
||||||
{
|
{
|
||||||
return Plugin_Continue;
|
return Plugin_Continue;
|
||||||
}
|
}
|
||||||
@ -364,8 +374,18 @@ public Action DamageOnTakeDamage(int client, int &attacker, int &inflictor, floa
|
|||||||
return Plugin_Continue;
|
return Plugin_Continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Get zombie flag for each client.
|
||||||
|
new bool:clientzombie = InfectIsClientInfected(client);
|
||||||
|
new bool:attackerzombie = InfectIsClientInfected(attacker);
|
||||||
|
|
||||||
// If client is a zombie, then allow damage.
|
// If client is a zombie, then allow damage.
|
||||||
if (InfectIsClientInfected(client))
|
if (clientzombie)
|
||||||
|
{
|
||||||
|
return Plugin_Continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
// If client and attacker are not on the same team, then allow damage.
|
||||||
|
if (clientzombie != attackerzombie)
|
||||||
{
|
{
|
||||||
return Plugin_Continue;
|
return Plugin_Continue;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user