Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CMD:ccfp(playerid, params[])
- {
- admin
- new range, carid, color1, color2, Float:rPos[4], x, string[180];
- //new Float:pX,Float:pY,Float:pZ;
- if(sscanf(params, "iiii", carid, color1, color2, range)) return SendClientMessage(playerid, -1, "USAGE: {FFFFFF}/ccfp <carid> <color1> <color2> <range>");
- GetPlayerPos(playerid, rPos[0], rPos[1], rPos[2]);
- foreach(Player,i) {
- if(IsPlayerInRangeOfPoint(i, range, rPos[0], rPos[1], rPos[2])) {
- GetPlayerPos(i,rPos[0], rPos[1], rPos[2]);
- x++;
- }
- }
- if(carid < 400 || carid > 611) return SendClientMessage(playerid, -1, "Invalid car [400-611]");
- if(color1 > 255 || color1 < 0 || color1 > 255 || color2 < 0) return SendClientMessage(playerid, -1, "Invalid color [1-255]");
- carid = CreateVehicle(carid,rPos[0], rPos[1], rPos[2],0.0,color1,color2,0,0);
- format(string, sizeof(string), "AdmCmd: %s a dat o masina %d la %d jucatori pe o raza de %dm.", GetName(playerid),carid, x, range);
- SendClientMessage(playerid, -1, string);
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement