27.03.2009, 01:54
new
const perGain = 10000,//10k
const modDamage = 100,//default vehicle health is 1000.0
const defaultPrice = 0
Float:Vechp;
GetVehicleHealth(GetPlayerVehicleID(playerid),Vech p);
new
const earnCash = perGain*(Vechp/modDamage)+defaultPrice;
GivePlayerMoney(playerid,earnCash);
printf("earn %d",earnCash);
Converse thought.
Edited some type error
const perGain = 10000,//10k
const modDamage = 100,//default vehicle health is 1000.0
const defaultPrice = 0
Float:Vechp;
GetVehicleHealth(GetPlayerVehicleID(playerid),Vech p);
new
const earnCash = perGain*(Vechp/modDamage)+defaultPrice;
GivePlayerMoney(playerid,earnCash);
printf("earn %d",earnCash);
Converse thought.
Edited some type error