27.10.2010, 14:52
how to make when player have wantedstar more than 6 the curfew will turn off and when he have less than 6 the curfew will turn off
i just make it by myself but it cann't use
pawn Код:
forward AutoCurfew();
public AutoCurfew()
{
for(new i=0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(WantedLevel[i] >= 6)
{
acurfew = 1;
SendClientMessageToAll(0x00F600AA, "Curfew turn on");
}
if(WantedLevel[i] <= 5)
{
acurfew = 0;
SendClientMessageToAll(0x00F600AA, "Curfew turn off");
}
}
}
return 1;
}