SA-MP Forums Archive
Removal off Fuel for Bikes - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Removal off Fuel for Bikes (/showthread.php?tid=555938)



Removal off Fuel for Bikes - weedxd - 09.01.2015

So basicly i have been shootin around trying to find a way how to do this but still can't :/
And this is all what i could do to remove engine for bikes but still i cant understand how to do that with fuel :/

PHP код:
if(vehicleid != 509 && vehicleid != 481 && vehicleid != 510)
    {
        
SetVehicleParamsEx(vehicleid1000000);
        foreach(
Playeri)
        { 
Would be grate if somone could give me an example of fuel removal

PHP код:
new Fuel[MAX_VEHICLES];
new 
FuelVar[MAX_VEHICLES];
new 
fMeter[MAX_PLAYERS];
new 
Refill[MAX_PLAYERS]; 



Re: Removal off Fuel for Bikes - HeLiOn_PrImE - 09.01.2015

There is a difference between GetPlayerVehicleID and GetVehicleModel.
Are you sure you are checking the right parameter?


Re: Removal off Fuel for Bikes - weedxd - 09.01.2015

Fixed onmy own like this:
PHP код:
public OnPlayerEnterVehicle(playeridvehicleidispassenger)
{
      if(
vehicleid == 509 || vehicleid == 481 || vehicleid == 510)
      {
       
Fuel[vehicleid] = 0;
       
fMeter[vehicleid] = 0;
      } 
Thanks anyway.