Guest User

Untitled

a guest
Nov 4th, 2021
94
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 1.26 KB | None | 0 0
  1. CMD:ugraditablice(playerid, params[])
  2. {
  3.     if(!IsPlayerInRangeOfPoint(playerid, 3.0, 2531.3811, -1525.3307, 24.2332))
  4.         return SCM(playerid, 0xFFFFFFFF, "Nisi u radionici za postavljanje registarskih tablica.");
  5.  
  6.     new plate[10],
  7.         //auto = PlayerInfo[playerid][pPosedovanjeAuta],
  8.         vehicles = GetPlayerVehicleID(playerid),
  9.         string[64];
  10.  
  11.     if(sscanf(params, "s[10]", plate))
  12.         return SCM(playerid,0xFFFFFFFF,"/ugraditablice [tablice ime]");
  13.  
  14.     if(!IsPlayerConnected(playerid))
  15.         return SCM( playerid,0xFFFFFFFF, "[ERROR] "SIVA"Igrac nije konektovan");
  16.  
  17.     if(strlen(plate) <= 0 || strlen(plate) > 10)
  18.         return SCM( playerid,0xFFFFFFFF, "[ERROR] "SIVA"Tablice ne moze biti iznad 10 slova!");
  19.  
  20.  
  21.     strmid(VoziloInfo[auto][vTablice], plate, 0, strlen(plate), 255);
  22.  
  23.     SetVehicleNumberPlate(vehicles, VoziloInfo[auto][vTablice]);
  24.  
  25.     format(string, sizeof(string), "Postavili ste tablice na vase vozilo! Ime tablica: {FFFFFF}%s!", plate);
  26.     SendClientMessage(playerid, 0x33FF33AA, string);
  27.  
  28.     SCM(playerid, 0xFFFFFFFF,"[INFO] "SIVA"Nakon respawna vozila ce vam se ucitati tablice");
  29.  
  30.     SetVehicleToRespawn(VoziloInfo[auto][vID]);
  31.  
  32.     SacuvajVozilo(auto);
  33.  
  34.     SavePlayer(playerid);
  35.  
  36.     return 1;
  37. }
Advertisement
Add Comment
Please, Sign In to add comment