02.12.2019, 20:39
I believe reducing the number of times you call SetPlayerMarkerForPlayer could help you with your problem.
I would call SetPlayerMarkerForPlayer in both OnPlayerStreamIn and in OnPlayerStreamOut and then do checks between them.
Instead of your timer, the following would work:
I would call SetPlayerMarkerForPlayer in both OnPlayerStreamIn and in OnPlayerStreamOut and then do checks between them.
Instead of your timer, the following would work:
pawn Code:
public OnPlayerStreamOut(playerid, forplayerid)
{
if(IsACop(forplayerid) && IsACop(playerid))
{
SetPlayerMarkerForPlayer(playerid, forplayerid, COLOR_LIMEGREEN);
}
return 1;
}