Advertisement
Guest User

Untitled

a guest
Feb 18th, 2018
162
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.99 KB | None | 0 0
  1. CMD:ccfp(playerid, params[])
  2. {
  3. admin
  4. new range, carid, color1, color2, Float:rPos[4], x, string[180];
  5. //new Float:pX,Float:pY,Float:pZ;
  6. if(sscanf(params, "iiii", carid, color1, color2, range)) return SendClientMessage(playerid, -1, "USAGE: {FFFFFF}/ccfp <carid> <color1> <color2> <range>");
  7. GetPlayerPos(playerid, rPos[0], rPos[1], rPos[2]);
  8. foreach(Player,i) {
  9. if(IsPlayerInRangeOfPoint(i, range, rPos[0], rPos[1], rPos[2])) {
  10. GetPlayerPos(i,rPos[0], rPos[1], rPos[2]);
  11. x++;
  12. }
  13. }
  14. if(carid < 400 || carid > 611) return SendClientMessage(playerid, -1, "Invalid car [400-611]");
  15. if(color1 > 255 || color1 < 0 || color1 > 255 || color2 < 0) return SendClientMessage(playerid, -1, "Invalid color [1-255]");
  16. carid = CreateVehicle(carid,rPos[0], rPos[1], rPos[2],0.0,color1,color2,0,0);
  17.  
  18. format(string, sizeof(string), "AdmCmd: %s a dat o masina %d la %d jucatori pe o raza de %dm.", GetName(playerid),carid, x, range);
  19. SendClientMessage(playerid, -1, string);
  20. return 1;
  21. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement