03.01.2017, 22:31
Hello Community
Right now im making a veh but don't want them to remain on the server so i wanna make a delete command
Now i now that i need a variable to save the spawned cars in like "new adminCar[MAX_VEHICLE];"
so but how can i build my veh command.
That what i have so far
Would be nice if you can help me
Right now im making a veh but don't want them to remain on the server so i wanna make a delete command
Now i now that i need a variable to save the spawned cars in like "new adminCar[MAX_VEHICLE];"
so but how can i build my veh command.
That what i have so far
Код:
dcmd_veh(playerid,params[]) { if(isPlayerAnAdmin(playerid,1)) { new vehid, color1, color2; if(sscanf(params,"iii",vehid,color1,color2)) SendClientMessage(playerid,Color_Info,"Usage: /veh <vehid> <color1> <color2>"); else if(vehid == INVALID_VEHICLE_ID) SendClientMessage(playerid, Color_Error,"Falsche VehicleId"); else { if(vehid >400 || vehid < 611) { new Float:x,Float:y,Float:z; GetPlayerPos(playerid,x,y,z); new cCar = CreateVehicle(vehid, x, y, z, 90, color1, color2, -1); // That the part i dont know what to do PutPlayerInVehicle(playerid,cCar,0); } } } else { SendClientMessage(playerid,Color_Error,"Du bist kein Admin!"); return 1; } return 1; }