[pomoc]Ar komanda

Započeo Arnel_Bp
14. Jun 2014. Zaključano
829
pregleda
19
postova
Arnel_Bp
5
Underboss
14. Jun 2014.
Skripta koju koristim: moja od 0
Detaljan opis problema: problem je u tome sto komanda radi, ali ako sam policajac ili TEAM_BOUNTY kad kucam /ar id onda izbacuje mi duplu poruku, sve ovo... ako me shvatate, mozeli ko ovo da mi ispravi... znaci pokazuje mi poruku i za cop i za team bountly pa ako moze neko ovo da mi vidi, hvala unaprijed..
Dio skripte:
CMD:ar(playerid, params[])
{
if(Ulogiran == 0) return SendClientMessage(playerid, 0xFF0000FF, "Moras se spawnati da bi mogao da koristis ovu komandu");
  if(gTeam == TEAM_FBI || gTeam == TEAM_ARMY || gTeam == TEAM_COP || gTeam == TEAM_BOUNTY)
  {
new id,string;
if(sscanf(params, "ui", id)) return SCM(playerid, 0xFF0000FF, "Koristi: /ar ");
if(!IsPlayerConnected(id)) return SCM(playerid, 0xFF0000FF, "ID igraca koji ste unijeli nije online.");
if(IsPlayerInAnyVehicle(id)) return SCMF(playerid, 0xFF0000FF, "Igrac %s(%d) je u vozilu i nemozes njega uhapsiti. Probaj ga navuci da izadje iz vozila ili pucaj u vozilo",GetName(id),id);
if(IsPlayerInAnyVehicle(playerid)) return SCMF(playerid, 0xFF0000FF, "Ne mozes uhapsiti %s(%d) jer si u vozilu, napusti vozilo i pokusaj opet uhapsiti nekoga",GetName(id),id);
if(GetDistanceBetweenPlayers(playerid,id) > 4) return SCMF(playerid, 0xFF0000FF, "Igrac %s(%d) je suvise daleko od tebe, probaj mu se pribliziti",GetName(id),id);
    if(Ulogiran == 0) return SCMF(playerid,  0xFF0000FF, "Igrac %s(%d) je mrtav, nemozes uhapsiti njega",GetName(id),id);
    if(Jailed ==1) return SCMF(playerid,  0xFF0000FF, "Igrac %s(%d) je vec u zatvoru...",GetName(id),id);
if(gTeam == TEAM_BOUNTY && EscapedConvict == 1 && GetPlayerWantedLevel(id) >=10)
  SetPlayerInterior(id,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(id, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(id, AlcatrazArrestedSpawn);
  new oname;
    new pname;
    GetPlayerName(playerid,oname, 24);
GetPlayerName(id, pname, 24);
    format(string, sizeof(string), "Bounty Hunter %s(%d) has re-captured Escaped Convict %s(%d) and has sent the suspect to Alcatraz",oname,playerid,pname,id);
    SendClientMessageToAll(0x00C7FFAA, string);
    SendClientMessage(id, 0xA9A9A9AA, "|_You Have Been Busted By A Bounty Hunter_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Bounty Hunter %s(%d)",oname,playerid);
    SendClientMessage(id,0x00C7FFAA, string);
    SendClientMessage(id,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(id,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent escaped prisoner %s(%d) to Alcatraz - you receive a $5000 re-capture bonus",pname,id);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Bounty Hunter %s(%d)",pname,id,oname,playerid);
    printf("%s", string);
    SendClientMessage(id,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,5000);
Jailed =1;
InAlcatraz =1;
triedtoescaperecent =1;
ResetPlayerWeapons(id);
JailTime =320;
JailTimeServed =0;
EscapedConvict =0;
SetPlayerWantedLevel(id,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
    if(EscapedConvict == 1 && GetPlayerWantedLevel(id) >=10)
    SetPlayerInterior(id,10);
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(id, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(id, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Officer %s(%d) ",pname,id,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);

    SendClientMessage(id, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Officer %s(%d)",oname,playerid);
    SendClientMessage(id,0x00C7FFAA, string);
    SendClientMessage(id,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(id,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent escaped prisoner %s(%d) to Alcatraz - you receive a $4000 re-capture bonus",pname,id);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Officer %s(%d)",pname,id,oname,playerid);
    printf("%s", string);
    SendClientMessage(id,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,4000);
Jailed =1;
InAlcatraz =1;
triedtoescaperecent =1;
ResetPlayerWeapons(id);
JailTime =320;
JailTimeServed =0;
EscapedConvict =0;
SetPlayerWantedLevel(id,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
}
else return SendClientMessage(playerid, 0xFF0000FF, "Ova komanda je namijenjena za oficire San Andreasa.Nisi ovlascen da koristis ovu komandu.");
return 1;
}

Neke slike/video za lakse dobivanje pomoci(neobavezno):
James_SmithXDl
6
OG Legend
14. Jun 2014.
jao bre kolika komanda...
pa proveris da li je id uhvatio jedan ili drugi tim i na osnovu tog saljes mu poruku
Arnel_Bp
5
Underboss
14. Jun 2014.
Quote from June 14, 2014, 2:35 pm:
jao bre kolika komanda...
pa proveris da li je id uhvatio jedan ili drugi tim i na osnovu tog saljes mu poruku


Pa mozes li mi to uradit/ispravit
James_SmithXDl
6
OG Legend
14. Jun 2014.
Ja nisam ovde da radim neko da pomognem reko sam ti sve ukljuci malo mozdane vijuge,nikad neces naucit ako drugi radi.
Arnel_Bp
5
Underboss
14. Jun 2014.
nesto sam probo da ispravim ovako ali ne ide...
CMD:ar(playerid, params[])
{
if(Ulogiran == 0) return SendClientMessage(playerid, 0xFF0000FF, "Moras se spawnati da bi mogao da koristis ovu komandu");
  if(gTeam == TEAM_FBI || gTeam == TEAM_ARMY || gTeam == TEAM_COP || gTeam == TEAM_BOUNTY)
  {
new id,string;
if(sscanf(params, "ui", id)) return SCM(playerid, 0xFF0000FF, "Koristi: /ar ");
if(!IsPlayerConnected(id)) return SCM(playerid, 0xFF0000FF, "ID igraca koji ste unijeli nije online.");
if(IsPlayerInAnyVehicle(id)) return SCMF(playerid, 0xFF0000FF, "Igrac %s(%d) je u vozilu i nemozes njega uhapsiti. Probaj ga navuci da izadje iz vozila ili pucaj u vozilo",GetName(id),id);
if(IsPlayerInAnyVehicle(playerid)) return SCMF(playerid, 0xFF0000FF, "Ne mozes uhapsiti %s(%d) jer si u vozilu, napusti vozilo i pokusaj opet uhapsiti nekoga",GetName(id),id);
if(GetDistanceBetweenPlayers(playerid,id) > 4) return SCMF(playerid, 0xFF0000FF, "Igrac %s(%d) je suvise daleko od tebe, probaj mu se pribliziti",GetName(id),id);
    if(Ulogiran == 0) return SCMF(playerid,  0xFF0000FF, "Igrac %s(%d) je mrtav, nemozes uhapsiti njega",GetName(id),id);
    if(Jailed ==1) return SCMF(playerid,  0xFF0000FF, "Igrac %s(%d) je vec u zatvoru...",GetName(id),id);
if(gTeam == TEAM_BOUNTY && EscapedConvict == 1 && GetPlayerWantedLevel(id) >=10)
{
  SetPlayerInterior(id,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(id, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(id, AlcatrazArrestedSpawn);
  new oname;
    new pname;
    GetPlayerName(playerid,oname, 24);
GetPlayerName(id, pname, 24);
    format(string, sizeof(string), "Bounty Hunter %s(%d) has re-captured Escaped Convict %s(%d) and has sent the suspect to Alcatraz",oname,playerid,pname,id);
    SendClientMessageToAll(0x00C7FFAA, string);
    SendClientMessage(id, 0xA9A9A9AA, "|_You Have Been Busted By A Bounty Hunter_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Bounty Hunter %s(%d)",oname,playerid);
    SendClientMessage(id,0x00C7FFAA, string);
    SendClientMessage(id,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(id,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent escaped prisoner %s(%d) to Alcatraz - you receive a $5000 re-capture bonus",pname,id);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Bounty Hunter %s(%d)",pname,id,oname,playerid);
    printf("%s", string);
    SendClientMessage(id,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,5000);
Jailed =1;
InAlcatraz =1;
triedtoescaperecent =1;
ResetPlayerWeapons(id);
JailTime =320;
JailTimeServed =0;
EscapedConvict =0;
SetPlayerWantedLevel(id,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
    if(EscapedConvict == 1 && GetPlayerWantedLevel(id) >=10)
    {
    SetPlayerInterior(id,10);
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(id, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(id, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Officer %s(%d) ",pname,id,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);

    SendClientMessage(id, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Officer %s(%d)",oname,playerid);
    SendClientMessage(id,0x00C7FFAA, string);
    SendClientMessage(id,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(id,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent escaped prisoner %s(%d) to Alcatraz - you receive a $4000 re-capture bonus",pname,id);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Officer %s(%d)",pname,id,oname,playerid);
    printf("%s", string);
    SendClientMessage(id,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,4000);
Jailed =1;
InAlcatraz =1;
triedtoescaperecent =1;
ResetPlayerWeapons(id);
JailTime =320;
JailTimeServed =0;
EscapedConvict =0;
SetPlayerWantedLevel(id,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
}
}
}
else return SendClientMessage(playerid, 0xFF0000FF, "Ova komanda je namijenjena za oficire San Andreasa.Nisi ovlascen da koristis ovu komandu.");
return 1;
}
Arnel_Bp
5
Underboss
14. Jun 2014.
sad mi ocitava ovo koristi: /ar id ali kada kucam neci id nista se ne pojavi... mozes li mi to fix brate?
James_SmithXDl
6
OG Legend
14. Jun 2014.
neradi dp!
if(sscanf(params, "u", id)) return SCM(playerid, 0xFF0000FF, "Koristi: /ar ");
Arnel_Bp
5
Underboss
14. Jun 2014.
Quote from June 14, 2014, 3:57 pm:
neradi dp!
if(sscanf(params, "u", id)) return SCM(playerid, 0xFF0000FF, "Koristi: /ar ");


i dalje isto kada kucam /ar i neci id nista mi se ne pojavljuje
James_SmithXDl
6
OG Legend
14. Jun 2014.
pa onda nije problem u parametrima nego u kodu ispod.
skriptas uzasno moram ti reci moras da razmisljas kako skratiti kod sto vise.
Arnel_Bp
5
Underboss
14. Jun 2014.
Quote from June 14, 2014, 4:59 pm:
pa onda nije problem u parametrima nego u kodu ispod.
skriptas uzasno moram ti reci moras da razmisljas kako skratiti kod sto vise.


pa sta cu ja kad ne umijem da prebacujem iz strcmp u zcmd, jedino ako mi mozes ti to prebaciti da ti dam kod, pa cu gledat i shvatiti... u ceu je problem ako ti nije muka... ako mozes ako ne nista onda hehhe
James_SmithXDl
6
OG Legend
14. Jun 2014.
reci mi sta ti tacno treba probacu..
Arnel_Bp
5
Underboss
14. Jun 2014.
Quote from June 14, 2014, 5:02 pm:
reci mi sta ti tacno treba probacu..


ovu komandu u zcmd pa cu ja posle varijable prilagodit sebi.. ti po ovome ako mozes prebaci, ova komanda je pravo rp.. ako imas vremena i hvala sto hoces kao si rekao 🙂
    
    if(strcmp(cmd, "/ar", true) == 0) {
    if(IsSpawned == 0) {
SendClientMessage(playerid, COLOR_ERROR, "You are dead. You cannot use this command");
    return 1;
    }
    if(gTeam != TEAM_COP && gTeam != TEAM_ARMY && gTeam != TEAM_BOUNTY) {
    SendClientMessage(playerid,COLOR_ERROR,"You are not a Law Enforcement officer ");
    return 1;
    }
    if(InDerby == 1) {
    SendClientMessage(playerid,COLOR_ERROR,"You cannot use this command while you are in the stadium");
    return 1;
    }
    if(Jailed ==1) {
    SendClientMessage(playerid, COLOR_ERROR, "You cannot use this command in jail");
    return 1;
    }
    tmp = strtok(cmdtext, idx);
    if(!strlen(tmp)) {
    SendClientMessage(playerid, COLOR_ERROR, "USAGE: /ar (id)");
    return 1;
    }
    giveplayerid = strval(tmp);
    if(!IsNumeric(tmp)) {
    SendClientMessage(playerid, COLOR_ERROR, "USAGE: /ar (id) ID Must be a number");
    return 1;
    }
    if(!IsPlayerConnected(giveplayerid)) {
    format(string, sizeof(string), "ID (%d) is not an active player", giveplayerid);
    SendClientMessage(playerid, COLOR_ERROR, string);
    return 1;
    }
    new oname;
    new pname;
    GetPlayerName(playerid,oname, 24);
GetPlayerName(giveplayerid, pname, 24);
if(GetPlayerWantedLevel(giveplayerid) <= 3) {
format(string, sizeof(string), "%s(%d) Does not have a warrant. You cannot arrest a player without a warrant",pname,giveplayerid);
SendClientMessage(playerid,COLOR_ERROR,string);
    return 1;
    }
    if(IsPlayerInAnyVehicle(playerid)) {
    SendClientMessage(playerid,COLOR_ERROR,"You cannot arrest a suspect if you are in a car");
    return 1;
    }
    if(IsPlayerInAnyVehicle(giveplayerid)) {
    format(string, sizeof(string), "%s(%d) Is in a vehicle. Get the suspect out before making the arrest",pname,giveplayerid);
    SendClientMessage(playerid,COLOR_ERROR,string);
    return 1;
    }
    if(GetDistanceBetweenPlayers(playerid,giveplayerid) > 4) {
    format(string, sizeof(string), "%s(%d) Is too far away. You cannot arrest that player",pname,giveplayerid);
    SendClientMessage(playerid,COLOR_ERROR,string);
    return 1;
    }
    if(IsSpawned == 0) {
format(string, sizeof(string), "%s(%d) Is dead. You cannot arrest a dead body",pname,giveplayerid);
    SendClientMessage(playerid,COLOR_ERROR,string);
    return 1;
    }
    SetPlayerVirtualWorld(giveplayerid,0);
    if(GetPlayerWantedLevel(playerid) >=1) {
    SendClientMessage(playerid,COLOR_ERROR,"You cannot use this command if you are wanted by the police");
    return 1;
    }
    if(gTeam == TEAM_BOUNTY && EscapedConvict == 0) {
    SendClientMessage(playerid,COLOR_ERROR,"That player is not on your bounty list. Type /bounty for details");
    return 1;
    }
    if(giveplayerid == playerid) {
    SendClientMessage(playerid,COLOR_ERROR,"You cannot arrest yourself");
    return 1;
    }
    if(gTeam == TEAM_BOUNTY && EscapedConvict == 1 && GetPlayerWantedLevel(giveplayerid) >=10) {
    SetPlayerInterior(giveplayerid,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(giveplayerid, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Bounty Hunter %s(%d) has re-captured Escaped Convict %s(%d) and has sent the suspect to Alcatraz",oname,playerid,pname,giveplayerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Busted By A Bounty Hunter_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Bounty Hunter %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent escaped prisoner %s(%d) to Alcatraz - you receive a $5000 re-capture bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Bounty Hunter %s(%d)",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,5000);
Jailed =1;
InAlcatraz =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =320;
JailTimeServed =0;
EscapedConvict =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }
 
    if(EscapedConvict == 1 && GetPlayerWantedLevel(giveplayerid) >=10) {
    SetPlayerInterior(giveplayerid,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(giveplayerid, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent escaped prisoner %s(%d) to Alcatraz - you receive a $4000 re-capture bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Escaped Convict %s(%d) has been re-arrested and sent to Alcatraz by Officer %s(%d)",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,4000);
Jailed =1;
InAlcatraz =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =320;
JailTimeServed =0;
EscapedConvict =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }
    if(GetPlayerWantedLevel(giveplayerid) >=4 && GetPlayerWantedLevel(giveplayerid) <=5) {
    SetPlayerInterior(giveplayerid,3);
    new rnd;
    rnd = random(sizeof (ArrestedSpawn));
    SetPlayerPos(giveplayerid, ArrestedSpawn, ArrestedSpawn, ArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, ArrestedSpawn);
    format(string, sizeof(string), "Wanted suspect %s(%d) has been arrested by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You were Arrested by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from jail or a Police Officer/Jail Turnkey can release you early");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If jail life sucks for you... Why not try /escape");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have arrested %s(%d) - you receive a $1500 bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Wanted suspect %s(%d) has been arrested by Officer %s(%d)",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,1500);
Jailed =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =80;
JailTimeServed =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }
    if(GetPlayerWantedLevel(giveplayerid) >=6 && GetPlayerWantedLevel(giveplayerid) <=8) {
    SetPlayerInterior(giveplayerid,3);
    new rnd;
    rnd = random(sizeof (ArrestedSpawn));
    SetPlayerPos(giveplayerid, ArrestedSpawn, ArrestedSpawn, ArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, ArrestedSpawn);
    format(string, sizeof(string), "Wanted suspect %s(%d) has been arrested by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You were Arrested by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from jail or a Police Officer/Jail Turnkey can release you early");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If jail life sucks for you... Why not try /escape");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have arrested %s(%d) - you receive a $2000 bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    format(string, sizeof(string), "Wanted suspect %s(%d) has been arrested by Officer %s(%d)",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,2000);
Jailed =1;

StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =140;
JailTimeServed =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }

    if(GetPlayerWantedLevel(giveplayerid) == 9) {
    SetPlayerInterior(giveplayerid,3);
    new rnd;
    rnd = random(sizeof (ArrestedSpawn));
    SetPlayerPos(giveplayerid, ArrestedSpawn, ArrestedSpawn, ArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, ArrestedSpawn);
    format(string, sizeof(string), "Wanted suspect %s(%d) has been arrested by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You were Arrested by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from jail or a Police Officer/Jail Turnkey can release you early");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If jail life sucks for you... Why not try /escape");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have arrested %s(%d) - you receive a $2500 bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Wanted suspect %s(%d) has been arrested by Officer %s(%d)",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,2500);
Jailed =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =200;
JailTimeServed =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }
    if(GetPlayerWantedLevel(giveplayerid) >=10 && GetPlayerWantedLevel(giveplayerid) <=14) {
    SetPlayerInterior(giveplayerid,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(giveplayerid, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Most Wanted suspect %s(%d) has been sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent Most Wanted suspect %s(%d) to Alcatraz - you receive a $3000 bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Most Wanted suspect %s(%d) has been arrested and sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,3000);
Jailed =1;
InAlcatraz =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =280;
JailTimeServed =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }
    if(GetPlayerWantedLevel(giveplayerid) >=15 && GetPlayerWantedLevel(giveplayerid) <=24) {
    SetPlayerInterior(giveplayerid,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(giveplayerid, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Most Wanted suspect %s(%d) has been sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent Most Wanted suspect %s(%d) to Alcatraz - you receive a $3500 bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Most Wanted suspect %s(%d) has been arrested and sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,3500);
Jailed =1;
InAlcatraz =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =320;
JailTimeServed =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +1);
return 1;
    }
    if(GetPlayerWantedLevel(giveplayerid) >=25) {
    SetPlayerInterior(giveplayerid,10);
    new rnd;
    rnd = random(sizeof (AlcatrazArrestedSpawn));
    SetPlayerPos(giveplayerid, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn, AlcatrazArrestedSpawn);
    SetPlayerFacingAngle(giveplayerid, AlcatrazArrestedSpawn);
    format(string, sizeof(string), "Most Wanted suspect %s(%d) has been sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    SendClientMessageToAll(0x00C7FFAA, string);
   
    SendClientMessage(giveplayerid, 0xA9A9A9AA, "|_You Have Been Arrested_|");
    format(string, sizeof(string), "You have been sent to Alcatraz by Officer %s(%d)",oname,playerid);
    SendClientMessage(giveplayerid,0x00C7FFAA, string);
    SendClientMessage(giveplayerid,0x00C7FFAA,"You will be auto-released from Alcatraz once you have served your sentence");
    SendClientMessage(giveplayerid,0x00C7FFAA,"If Alcatraz life sucks for you... Why not ask a friend to visit you? /reqvisit (id)");
    SendClientMessage(playerid, 0xA9A9A9AA, "|_Suspect Arrested_|");
    format(string, sizeof(string), "You have sent Most Wanted suspect %s(%d) to Alcatraz - you receive a $4000 bonus",pname,giveplayerid);
    SendClientMessage(playerid,0x00C7FFAA, string);
    GameTextForPlayer(playerid,"~b~Suspect Arrested",5000,3);
    format(string, sizeof(string), "Most Wanted suspect %s(%d) has been arrested and sent to Alcatraz by Officer %s(%d) ",pname,giveplayerid,oname,playerid);
    printf("%s", string);
    SendClientMessage(giveplayerid,0xFF7F50AA,"If you leave the server while you are in jail you WILL be banned");
    GivePlayerMoney(playerid,4000);
Jailed =1;
InAlcatraz =1;
StoleCopCarRecent =0;
triedtoescaperecent =1;
ResetPlayerWeapons(giveplayerid);
JailTime =420;
JailTimeServed =0;
SetPlayerWantedLevel(giveplayerid,0);
oscore = GetPlayerScore(playerid);
  SetPlayerScore(playerid, oscore +2);
    }
    return 1;
    }


pa cu posle ja gledat odavde da shvatim gde sam napravio gresku...
James_SmithXDl
6
OG Legend
14. Jun 2014.
necu je prebacivati reci sta treba da sadrzi komanda da ti uradim princip i onda ti je lako.
Arnel_Bp
5
Underboss
14. Jun 2014.
Quote from June 14, 2014, 5:07 pm:
necu je prebacivati reci sta treba da sadrzi komanda da ti uradim princip i onda ti je lako.


Pa ovo iz komande sto sam ti gore dao...
James_SmithXDl
6
OG Legend
14. Jun 2014.
uradicu ti ja samo pojasni sta da sadrzava.
ovaj kod je neuredan.

Morate biti prijavljeni da biste odgovorili na ovu temu.

Prijava

© 2026 SmartShark. All rights reserved.

Powered by Momentum|v2026.3.001 Alpha