that team check should be needed
This commit is contained in:
parent
b195c60ad7
commit
7ff7ba764d
@ -683,7 +683,7 @@ public int GetClosestClient_option1(int targeteam, int client)
|
|||||||
int nearest = -1;
|
int nearest = -1;
|
||||||
bool bot_alternative = false;
|
bool bot_alternative = false;
|
||||||
for (int i = 1; i <= MaxClients; i++)
|
for (int i = 1; i <= MaxClients; i++)
|
||||||
if (IsValidClient(i) && IsPlayerAlive(i) && !is_bot_player(i))
|
if (IsValidClient(i) && IsPlayerAlive(i) && GetClientTeam(i) == targeteam && !is_bot_player(i))
|
||||||
{
|
{
|
||||||
if (!IsAbleToSee(client, i))
|
if (!IsAbleToSee(client, i))
|
||||||
continue;
|
continue;
|
||||||
|
Loading…
Reference in New Issue
Block a user