How to get a number?
#3

Well, personally I believe it would be easier to use a hand-made equation to determine the price. First of all set up a global variable such as "Fuel[MAX_VEHICLES]" and set the fuel when a vehicle spawns and such (to 100 unless you are wanting to make it a saved variable, then set it to the saved variable's number. And in terms of gas prices, use this equation - it should work:
pawn Код:
new gas, calculation;
new vehicleid = GetPlayerVehicleID(playerid);
gas = Fuel[vehicleid];
new calcuation = 100-fuel*2;
Something similar to that. The 2 stands for how much each gallon/percentage will cost.
Reply


Messages In This Thread
How to get a number? - by Lajko1 - 24.11.2013, 18:20
Re: How to get a number? - by Jefff - 24.11.2013, 18:25
Re: How to get a number? - by nmader - 24.11.2013, 18:28
Re: How to get a number? - by Lajko1 - 24.11.2013, 18:46
Re: How to get a number? - by Lajko1 - 24.11.2013, 20:11
Re: How to get a number? - by iPrivate - 24.11.2013, 20:24
Re: How to get a number? - by Lajko1 - 24.11.2013, 20:51
Re: How to get a number? - by Jefff - 24.11.2013, 21:02
Re: How to get a number? - by Lajko1 - 24.11.2013, 21:09
Re: How to get a number? - by Jefff - 24.11.2013, 21:14

Forum Jump:


Users browsing this thread: 2 Guest(s)