15.05.2013, 09:24
Hello,
I need scripts to make a Most Wanted Suspect has a checkpoint on his self?
can someone help me?
I need scripts to make a Most Wanted Suspect has a checkpoint on his self?
can someone help me?
new bool:Marker[MAX_PLAYERS];
public OnGameModeInit()
{
SetTimer("CheckWanted", 2000, true);
return 1;
}
forward CheckWanted();
public CheckWanted()
{
for (new i = 0; i < MAX_PLAYERS; i ++)
{
if (!IsPlayerConnected(i)) continue;
if (GetPlayerWantedLevel(i) == 6)
{
// The player's color will be set and other players can see it on their radar.
SetPlayerColor(i, 0xFF0000FF);
Marker[i] = true;
}
else
{
if (Marker[i])
{
SetPlayerColor(i, 0xFFFFFFAA);
Marker[i] = false;
}
}
}
return 1;
}