Help with unjail timer
#1

Ok guys i would love to know how to make a timer for my jail script, like, if a player is 3 wanted stars, they get 10 min in jail, then the unjail after 10 mins are up. I know how to make the timer, i am just confused with the GetPlayerWantedLevel

Can i get a similar one to this?

Код:
if GetPlayerWantedLevel(ID,3<=))*then SetTimer("Wanted",900000,false);
Reply
#2

Ok guys if you dont understand, i mean is there a way to put this, what have i done wrong?

Код:
if GetPlayerWantedLevel(ID,3<=))*then SetTimer("Wanted",900000,false);
Guys any help would be appreciated.
Reply
#3

Nice.Thanks
Reply
#4

Whats that supposed to mean?

If it helped you i am happy it helped you but sad it did not help me.
Reply
#5

i geuss put in your jail command something like:

pawn Код:
if(GetPlayerWantedLevel(playerid) > 2) return SetTimerEx(playerid,"YourJailTimer",600000,false,"i",othername
change "othername" to the variable you used to store the other players name in, the "i", stands for interval which is a number

then down the bottom:
pawn Код:
public YourJailTimer(playerid)
{
      //unjail him here
      return 1;
}
Reply
#6

pawn Код:
if(GetPlayerWanted(playerid) <= 3) return SetTimerEx("WantedT1",,600000,false,"i",playerid);

forward WantedT1(playerid);
public WantedT1(playerid)
{
         SendClientMessage(playerid,COLOR,"You been released.");
         SetPlayerPos(playerid,x,y,z);     //Set there pos to where u want
         return 1;
}
?? D:
Reply
#7

Thanks guys, btw i used Cale's script because he was first, and Cale you for got to tell me to forward the timer, and a little errors, but i fixed them.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)