28.03.2014, 16:26
try this
You need it to check if its gov if not what else to do. Your did not charge them and charged them
Код:
CMD:refuel(playerid, params[])//Fuel System CMD REDONE BY BELKIN { for(new i=1; i < MAX_FUEL_STATIONS; i++) { if(FuelStationCreated[i]) { if(IsPlayerInRangeOfPoint(playerid, 15.0, FuelStationPos[i][0], FuelStationPos[i][1], FuelStationPos[i][2])) { if (!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid,0xFFC800FF,"You are not in an vehicle!"); if (isrefuelling[playerid]) return SendClientMessage(playerid,0xFFC800FF,"refuelling your vehicle!"); if(!IsACop(playerid) || !IsAGov(playerid) || !IsMedic(playerid)) GivePlayerCash(playerid, 0); else GivePlayerCash(playerid, -100); SetCameraBehindPlayer(playerid); TogglePlayerControllable(playerid,0); isrefuelling[playerid] = 1; TextDrawSetString(td_fuel[playerid],"Refuelling..."); SetTimerEx("timer_refuel",4500,false,"i",playerid); } } } SendClientMessage(playerid, COLOR_RED, "You are not in a fuel station!"); return 1; }