28.06.2012, 20:07
I want to make this command to use Cases.
the main command is /improve and sub is paintjob
Is he does /improve paintjob 1 so i will do something in case one till 2 and 3
here is the code
the main command is /improve and sub is paintjob
Is he does /improve paintjob 1 so i will do something in case one till 2 and 3
here is the code
Код:
else if(!strcmp(x_imp,"paintjob",true)) { tmp = strtok(cmdtext, idx); if(!strlen(tmp)) { SendClientMessage(playerid, COLOR_GREY, ">> Please choose paintjob 0-2 ,3 to remove!"); return 1; } new paint = strval(tmp); if(paint < 0 && paint > 3) { SendClientMessage(playerid, COLOR_GREY, ">> Please choose paintjob 1-2 ,0 to remove!"); return 1; } ChangeVehiclePaintjob(vehicleid,paint); VehicleInfo[vehicleid][vPaintJob] = paint; format(string, sizeof(string), "* %s sprays the vehicle.", sendername); ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); return 1; }