Guest User

Untitled

a guest
Dec 15th, 2019
186
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.44 KB | None | 0 0
  1. // Commandes Admin
  2. else if(!strcmp(cmd, "add", true))
  3. {
  4.  
  5.  
  6. if(sscanf(params,"{s[32]}iii", model, color1, color2))
  7. {
  8. SendClientMessage(playerid, -1, "{a3a3a3}COMMANDE: {FFFFFF}(/v)ehicule add [model] [color1] [color2]");
  9. return 1;
  10. }
  11.  
  12. GetPlayerPos(playerid, x, y, z);
  13. GetPlayerFacingAngle(playerid, a);
  14.  
  15. //CreateVehicle(model, x, y, z, a, color1, color2, -1, 0);
  16.  
  17. mysql_format(mysql, query, sizeof(query), "INSERT INTO serveur_vehicules (model, x, y, z, a, color1, color2, immatriculation) VALUES('%d', '%f', '%f', '%f', '%f', '%d', '%d', 'AUCUNE')", model, x, y, z, a, color1, color2);
  18. mysql_pquery(mysql, query, "SQL_CallVehicleCreate", "idffffdd", playerid, model, x, y, z, a, color1, color2);
  19.  
  20. return 1;
  21. }
  22.  
  23.  
  24. else if(!strcmp(cmd, "stats", true))
  25. {
  26. new vehicleid = GetPlayerVehicleID(playerid);
  27. GetVehicleHealth(vehicleid, vhealth);
  28. if(!vInfo[vehicleid][vExist]) return 1;
  29.  
  30. format(string, sizeof(string), "Immatriculation:[%s], Health:[%.2f], Couleur principale[{%06x}%d{FFFFFF}], Couleur secondaire[{%06x}%d{FFFFFF}]", vInfo[vehicleid][vPlaque], vhealth, VehicleColoursTableRGBA[vInfo[vehicleid][vColor1]] >>> 8, vInfo[vehicleid][vColor1], VehicleColoursTableRGBA[vInfo[vehicleid][vColor2]] >>> 8, vInfo[vehicleid][vColor2]);
  31. SendClientMessage(playerid, -1, string);
  32. return 1;
  33. }
Advertisement
Add Comment
Please, Sign In to add comment