Jump to content
  • 0
Sign in to follow this  
CristianC

Problema wanted

Question

Cand se acorda wanted, primesti wanted pe - si creste pe -, de la -1 se face -2, -3, -4, etc...

Adica in loc sa expire wanted-ul, il ai pe - si nu mai expira.

 

CMD:su(playerid, params[])
{
    new id;
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_ERROR, "Tu nu esti logat si nu poti sa folosesti aceasta comanda!");
    if(!IsACop(playerid)) return SendClientMessage(playerid, COLOR_ERROR, "Nu faci parte din Police Department / FBI.");
    if(OnDuty[playerid] == 0)return SendClientMessage(playerid, COLOR_ERROR, "You are not on duty.");
    if(sscanf(params, "u",id)) return SendClientMessage(playerid, COLOR_WHITE, "{008080}Scrie: {FFFFFF}/su <Name/Playerid>");
    {
        if(IsACop(id)) return SendClientMessage(playerid, COLOR_ERROR, "You cannot suspect a cop.");
        if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
        IDWANTED[playerid] = id;
        new dialogstr[650], tstr[64];
        new coordsstring[64] = "Actiune\tWantedList\n";
        strcat(dialogstr, "Furtul unui vehicul\tW1\n");
        strcat(dialogstr, "Neconformare ordin jail\tW1\n");
        strcat(dialogstr, "Atacarea unui civil\tW2\n");
        strcat(dialogstr, "Neplata amendei\tW2\n");
        strcat(dialogstr, "Condus neregulamentar\tW2\n");
        strcat(dialogstr, "Patrunderea pe proprietati guvernamentale\tW2\n");
        strcat(dialogstr, "Atacarea unui politist\tW3\n");
        strcat(dialogstr, "Neconformare ordin\tW3\n");
        strcat(dialogstr, "Posesie droguri\tW3\n");
        strcat(dialogstr, "Omorare politist\tW4\n");
        strcat(dialogstr, "Dare de mita\tW4\n");
        strcat(dialogstr, "Kamikaze (omorarea mai multor jucatori bubuind o masina, avion etc.)\tW5\n");
        strcat(dialogstr, "Rapirea unui politist\tW5\n");
        strcat(dialogstr, "Runner\tW6\n");
        strcat(dialogstr, "DM in jail\tW6\n");
        strcat(dialogstr, "Complice la fuga unui criminal\tW6\n");
        strcat(dialogstr, "Complice rob\tW6\n");
        strcat(dialogstr, "Complice runner\tW6\n");
        strins(dialogstr, coordsstring, 0);
        format(tstr, sizeof(tstr), "Suspect");
        ShowPlayerDialog(playerid, DIALOG_WANTED, DIALOG_STYLE_TABLIST_HEADERS, tstr, dialogstr, "Confirma", "Anuleaza");
    }
    return 1;
}
      
	case DIALOG_WANTED:
    {
        if(response)
        {
            new id = IDWANTED[playerid],giveplayer[256], sendername[25],string[124];
            GetPlayerName(id, giveplayer, sizeof(giveplayer));
            GetPlayerName(playerid, sendername, sizeof(sendername));
            if(listitem == 0)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Furtul unui vehicul");
                WantedPoints[id] = 1;
                PlayerInfo[id][pWantedLevel] = 1;
                SetPlayerWantedLevel(id, 1);
                format(string, sizeof(string), "Ai comis o infractiune: Furtul unui vehicul, raportat de: %s. W: +1. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Furtul unui vehicul. Reporter: %s. W: +1. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 1)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Neconformare ordin jail");
                WantedPoints[id] = 1;
                PlayerInfo[id][pWantedLevel] = 1;
                SetPlayerWantedLevel(id, 1);
                format(string, sizeof(string), "Ai comis o infractiune: Neconformare ordin jail, raportat de: %s. W: +1. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Neconformare ordin jail. Reporter: %s. W: +1. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 2)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Atacarea unui civi");
                WantedPoints[id] = 2;
                PlayerInfo[id][pWantedLevel] = 2;
                SetPlayerWantedLevel(id, 2);
                format(string, sizeof(string), "Ai comis o infractiune: Atacarea unui civi, raportat de: %s. W: +2. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Atacarea unui civi. Reporter: %s. W: +2. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 3)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Neplata amendei");
                WantedPoints[id] = 2;
                PlayerInfo[id][pWantedLevel] = 2;
                SetPlayerWantedLevel(id, 2);
                format(string, sizeof(string), "Ai comis o infractiune: Neplata amendei, raportat de: %s. W: +2. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Neplata amendei. Reporter: %s. W: +2. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 4)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Condus neregulamentar");
                WantedPoints[id] = 2;
                PlayerInfo[id][pWantedLevel] = 2;
                SetPlayerWantedLevel(id, 2);
                format(string, sizeof(string), "Ai comis o infractiune: Condus neregulamentar, raportat de: %s. W: +2. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Condus neregulamentar. Reporter: %s. W: +2. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 5)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Patrunderea pe proprietati guvernamentale");
                WantedPoints[id] = 2;
                PlayerInfo[id][pWantedLevel] = 2;
                SetPlayerWantedLevel(id, 2);
                format(string, sizeof(string), "Ai comis o infractiune: Patrunderea pe proprietati guvernamentale, raportat de: %s. W: +2. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Patrunderea pe proprietati guvernamentale. Reporter: %s. W: +2. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 6)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Atacarea unui politist");
                WantedPoints[id] = 3;
                PlayerInfo[id][pWantedLevel] = 3;
                SetPlayerWantedLevel(id, 3);
                format(string, sizeof(string), "Ai comis o infractiune: Atacarea unui politist, raportat de: %s. W: +3. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Atacarea unui politist. Reporter: %s. W: +3. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 7)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Neconformare ordin");
                WantedPoints[id] = 3;
                PlayerInfo[id][pWantedLevel] = 3;
                SetPlayerWantedLevel(id, 3);
                format(string, sizeof(string), "Ai comis o infractiune: Neconformare ordin, raportat de: %s. W: +3. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Neconformare ordin. Reporter: %s. W: +3. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 8)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Posesie droguri");
                WantedPoints[id] = 3;
                PlayerInfo[id][pWantedLevel] = 3;
                SetPlayerWantedLevel(id, 3);
                format(string, sizeof(string), "Ai comis o infractiune: Posesie droguri, raportat de: %s. W: +4. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Posesie droguri. Reporter: %s. W: +4. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 9)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Kill Cop");
                WantedPoints[id] = 4;
                PlayerInfo[id][pWantedLevel] = 4;
                SetPlayerWantedLevel(id, 4);
                format(string, sizeof(string), "Ai comis o infractiune: Kill Cop, raportat de: %s. W: +4. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Kill Cop. Reporter: %s. W: +4. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 10)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Dare de mita");
                WantedPoints[id] = 4;
                PlayerInfo[id][pWantedLevel] = 4;
                SetPlayerWantedLevel(id, 4);
                format(string, sizeof(string), "Ai comis o infractiune: Dare de mita, raportat de: %s. W: +4. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Dare de mita. Reporter: %s. W: +4. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 11)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Kamikaze (omorarea mai multor jucatori bubuind o masina, avion etc.)");
                WantedPoints[id] = 5;
                PlayerInfo[id][pWantedLevel] = 5;
                SetPlayerWantedLevel(id, 5);
                format(string, sizeof(string), "Ai comis o infractiune: Kamikaze (omorarea mai multor jucatori bubuind o masina, avion etc.), raportat de: %s. W: +5. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Kamikaze (omorarea mai multor jucatori bubuind o masina, avion etc.). Reporter: %s. W: +5. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 12)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Rapirea unui politist");
                WantedPoints[id] = 5;
                PlayerInfo[id][pWantedLevel] = 5;
                SetPlayerWantedLevel(id, 5);
                format(string, sizeof(string), "Ai comis o infractiune: Rapirea unui politist, raportat de: %s. W: +5. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Rapirea unui politist. Reporter: %s. W: +5. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 13)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Runner");
                WantedPoints[id] = 6;
                PlayerInfo[id][pWantedLevel] = 6;
                SetPlayerWantedLevel(id, 6);
                format(string, sizeof(string), "Ai comis o infractiune: Runner, raportat de: %s. W: +6. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Runner. Reporter: %s. W: +6. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 14)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "DM in jail");
                WantedPoints[id] = 6;
                PlayerInfo[id][pWantedLevel] = 6;
                SetPlayerWantedLevel(id, 6);
                format(string, sizeof(string), "Ai comis o infractiune: DM in jail, raportat de: %s. W: +6. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: DM in jail. Reporter: %s. W: +6. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 15)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Complice la fuga unui criminal");
                WantedPoints[id] = 6;
                PlayerInfo[id][pWantedLevel] = 6;
                SetPlayerWantedLevel(id, 6);
                format(string, sizeof(string), "Ai comis o infractiune: Complice la fuga unui criminal, raportat de: %s. W: +6. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Complice la fuga unui criminal. Reporter: %s. W: +6. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 16)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Complice rob");
                WantedPoints[id] = 6;
                PlayerInfo[id][pWantedLevel] = 6;
                SetPlayerWantedLevel(id, 6);
                format(string, sizeof(string), "Ai comis o infractiune: Complice rob, raportat de: %s. W: +6. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Complice rob. Reporter: %s. W: +6. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
            if(listitem == 17)
            {
                if(!IsPlayerConnected(id)) return SendClientMessage(playerid, COLOR_ERROR, "Acel jucator nu este conectat.");
                if(id == playerid) return SendClientMessage(playerid, COLOR_ERROR, "Nu iti poti da singur wanted.");
                SetPlayerCriminal(id,255, "Complice runner");
                WantedPoints[id] = 6;
                PlayerInfo[id][pWantedLevel] = 6;
                SetPlayerWantedLevel(id, 6);
                format(string, sizeof(string), "Ai comis o infractiune: Complice runner, raportat de: %s. W: +6. Nivel de urmarire nou: %d.",sendername,PlayerInfo[id][pWantedLevel]);
                SendClientMessage(id, COLOR_RED2, string);
                format(string, sizeof(string), "Dispatch: %s [%d] has commited a crime: Complice runner. Reporter: %s. W: +6. New wanted level: %d.",giveplayer,id,sendername,PlayerInfo[id][pWantedLevel]);
                SendTeamMessage(20, COLOR_LIGHTBLUE, string);
                SendTeamMessage(8, COLOR_DBLUE, string);
                SendTeamMessage(3, COLOR_DBLUE, string);
                SendTeamMessage(2, COLOR_DBLUE, string);
                SendTeamMessage(1, COLOR_DBLUE, string);
            }
        }
    }

 

Edited by CristianC

Share this post


Link to post
Share on other sites

3 answers to this question

Recommended Posts

  • 0

Salut, cauta 

pWantedLevel

si vezi unde se scade, trebuie sa fie un timer sau ceva, in momentul cand e 0, stergi wanted-ul si opresti timerul, te adaptezi in functie de cum e construit sistemul tau, la prima vedere nu vad vreun motiv sa se seteze din prima cu -1, decat sa devina dupa

Share this post


Link to post
Share on other sites
  • 0
On 1/21/2020 at 9:15 PM, ionutdrg45 said:

Salut, cauta 


pWantedLevel

si vezi unde se scade, trebuie sa fie un timer sau ceva, in momentul cand e 0, stergi wanted-ul si opresti timerul, te adaptezi in functie de cum e construit sistemul tau, la prima vedere nu vad vreun motiv sa se seteze din prima cu -1, decat sa devina dupa

Da, este corect ce zice aici Ionut. Cel mai probabil ai wanted cu - din urmatoarele motive:

  1. Posibil ca timerul sa nu fie oprit cand trebuie
  2. Timerul sa fie global si sa necesite un if. Ex: if(PlayerInfo[playerid][pWantedLevel] != 0) ...
Edited by CTMBeast

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...

Important Information

This site uses cookies. By continuing browsing, you agree to the use of this information. For more details, see Terms of Use and Privacy Policy.