little problem
#8

pawn Код:
forward BenzinUpdate(playerid);
public BenzinUpdate(playerid)
{
        new string[16];
        if(IsPlayerConnected(playerid))
        {
            new vehicle = GetPlayerVehicleID(playerid);
            if(IsPlayerInAnyVehicle(playerid) == 1)
            {
                new engine, lights, alarm, doors, bonnet, boot, objective;
                GetVehicleParamsEx(vehicle, engine, lights, alarm, doors, bonnet, boot, objective);
                if(Gas[vehicle] == 0 || engine == 0)
                {
                        format(string, sizeof(string), "FUEL: --");
                        SetVehicleParamsEx(vehicle,0,lights,alarm,doors,bonnet,boot,objective);
                }
                else if(Gas[vehicle] > 0 && Gas[vehicle] <= 100)
                {
                        format(string, sizeof(string), "FUEL: %d%",Gas[vehicle]);
                }
                TextDrawSetString(FuelDraw, string);
                return 1;
            }
            return 1;
        }
        return 1;
}
Reply


Messages In This Thread
little problem - by mineralo - 03.02.2012, 16:44
Re: little problem - by lamarr007 - 03.02.2012, 16:47
Re: little problem - by mineralo - 03.02.2012, 16:50
Re: little problem - by lamarr007 - 03.02.2012, 16:51
Re: little problem - by mineralo - 03.02.2012, 16:52
Re: little problem - by lamarr007 - 03.02.2012, 16:53
Re: little problem - by mineralo - 03.02.2012, 16:56
Re: little problem - by lamarr007 - 03.02.2012, 16:59
Re: little problem - by mineralo - 03.02.2012, 17:00
Re: little problem - by Vince - 03.02.2012, 17:01

Forum Jump:


Users browsing this thread: 1 Guest(s)