Advertisement
Guest User

find

a guest
Mar 11th, 2020
209
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 1.80 KB | None | 0 0
  1. YCMD:find(playerid, params[], help) {
  2.     if(JobWorking[playerid] == 1) return 1;
  3.     if(CP[playerid] != 0 || targetfind[playerid] != -1) return ShowPlayerDialog(playerid, DIALOG_CHECKPOINT, DIALOG_STYLE_MSGBOX, "Checkpoint", "Ai deja un checkpoint activ.\nDoresti sa-l anulezi? Daca da, apasa pe 'Ok'.", "Ok", "Exit");
  4.     new id,giveplayer[30],string[100];
  5.     if(PlayerInfo[playerid][pJob] != 6 && PlayerInfo[playerid][pMember] != 11 && !IsACop(playerid)) return SCM(playerid, COLOR_GREY, "Nu ai jobul 'Detective'.");
  6.     if(sscanf(params, "u",id)) return SCM(playerid, COLOR_GREY, "USAGE: {FFFFFF}/find <playerid/name>");
  7.     if(!IsPlayerConnected(id) || id == INVALID_PLAYER_ID) return SCM(playerid, COLOR_GREY, "Acel player nu este conectat.");
  8.     if(Spectate[id] != 255) return SCM(playerid, COLOR_GREY, "Acel player este ocupat!");
  9.     if(id == playerid) return SCM(playerid, COLOR_GREY, "Nu poti folosi aceasta comanda asupra ta!");
  10.     if(togfind[id] == 1) return SCM(playerid,COLOR_GREY, "Acel player nu poate fi urmarit!");
  11.     if(GetPVarInt(id, "Undercover") == 1) return SCM(playerid, COLOR_GREY, "Acel player este ocupat!");
  12.     if(BizRobbed[playerid] != 0) return 1;
  13.     if(togfind[id] == 1 && OnDuty[playerid] == 0 && PlayerHit[playerid] == -1) return SCM(playerid, COLOR_LGREEN, "Eroare: Acel player nu poate fi urmarit!");
  14.     UsedFind[playerid] = 1;
  15.     GetPlayerName(id, giveplayer, sizeof(giveplayer));
  16.     new Float:X,Float:Y,Float:Z;
  17.     GetPlayerPos(id, X,Y,Z);
  18.     SetPlayerCheckpointEx(playerid, X,Y,Z, 3.5);
  19.     targetfind[playerid] = id;
  20.     CP[playerid] = 53;
  21.     format(string, sizeof(string), "* Punctul rosu a fost setat pe %s (%d) care se afla in zona %s.",giveplayer,id,GetPlayerZone(id));
  22.     SCM(playerid,COLOR_YELLOW,string);
  23.     for(new m; m < 2; m++) {
  24.         if(PlayerInfo[playerid][pDailyMission][m] == 12) CheckMission(playerid, m);
  25.     }
  26.     return 1;
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement