Posts: 14
Threads: 4
Joined: Dec 2010
Reputation:
0
Hello, at my GRP mod is Fuel system, so i decited to add few bikes in my server.
So, then player is getting on the bike its says 0Fuel.
how to make fuel inactive at bikes?
Posts: 844
Threads: 32
Joined: Apr 2009
Reputation:
0
define all bike ids and use a check if(!IsABike(vehicleid)) this will check if the vehicle is NOT a bike. use this onplayerentervehicle before the textdraw get shown.
Posts: 14
Threads: 4
Joined: Dec 2010
Reputation:
0
how to define all bikes ids?
Posts: 844
Threads: 32
Joined: Apr 2009
Reputation:
0
I forgot how to make to make an array l0l. anyway since im quite dizzy here are the bike ids.
Bike:509
BMX:481
MB:510
Posts: 165
Threads: 39
Joined: Jan 2009
Reputation:
0
if(GetPlayerVehicleID(playerid) == 509 || GetPlayerVehicleID(playerid) == 481 || GetPlayerVehicleID(playerid) == 510)
{
Fuel = 0 // or whatever function you use
return 1;
}
Posts: 844
Threads: 32
Joined: Apr 2009
Reputation:
0
use this: new vid=GetVehicleModel(GetPlayerVehicleID(playerid));
if(vid == 509 || vid == 481 || vid == 510)
{
// stuff here
return 1;
}
Posts: 14
Threads: 4
Joined: Dec 2010
Reputation:
0
This is what i find it my gm -
and i want to disable gas on bikes
if(model != BMX && model != MTBIKE && model != BIKE)
{
if(vehicleDB[vehicleid][gas] > aEda[model-400])
{
vehicleDB[vehicleid][gas]-=aEda[model-400];
new Float:vhp; GetVehicleHealth(vehicleid,vhp); if(vhp > 307) SetVehicleHealth(vehicleid,vhp-7);
}else{
if(vehicleDB[vehicleid][gas] > 0)
{
vehicleDB[vehicleid][gas]=0;
}else{
TogglePlayerControllable(playerid,false);
}
}
Posts: 38
Threads: 6
Joined: Dec 2010
Reputation:
0
like Mike say "my motto: Search before you post..."