Refuel command bugged please help
#3

Code:
stock StopRefueling(playerid)
{
	GivePlayerCash(playerid, -100);
  	SendFormattedMessage(playerid, COLOR_WHITE,"Your vehicle's tank has been refilled for $100.");
Code:
forward ReFill(playerid);
public ReFill(playerid)
{
	if(!IsAtFuelStation(playerid) || !IsPlayerInAnyVehicle(playerid) || VehicleFuel[GetPlayerVehicleID(playerid)] >= 100.0 || GetPlayerCash(playerid) < 1)
	{
		StopRefueling(playerid);
	}
	else
	{
	    new engine,lights,alarm,doors,bonnet,boot,objective;
    	GetVehicleParamsEx(GetPlayerVehicleID(playerid),engine,lights,alarm,doors,bonnet,boot,objective);
		if(engine == VEHICLE_PARAMS_ON) return StopRefueling(playerid);
		VehicleFuel[GetPlayerVehicleID(playerid)] += 1.0; RefuelingVehiclePrice[playerid] += 30;
		if(VehicleFuel[GetPlayerVehicleID(playerid)] >= 100.0) VehicleFuel[GetPlayerVehicleID(playerid)] = 100.0;
	}
	return true;
}
I didn't exactly know wich one of the two so I posted these two hope this is what you mean
Reply


Messages In This Thread
Refuel command bugged please help - by William1122 - 09.01.2013, 12:23
Re: Refuel command bugged please help - by JavoDiaz - 09.01.2013, 12:44
Respuesta: Refuel command bugged please help - by William1122 - 09.01.2013, 13:04
Respuesta: Refuel command bugged please help - by William1122 - 09.01.2013, 19:31
Re: Refuel command bugged please help - by RedCrossER - 09.01.2013, 19:40
Re: Refuel command bugged please help - by park4bmx - 09.01.2013, 20:16
Respuesta: Refuel command bugged please help - by William1122 - 09.01.2013, 22:40

Forum Jump:


Users browsing this thread: 2 Guest(s)