function SaveCars()
{
for(local a = 0; a < GetVehicleCount(); a ++)
{
local vee = FindVehicle(a);
if(vee) {
WriteIniString("Stats.ini","Vehicle", "ID", vee.ID.tointeger() ) // the error appears here.
}
}
}
So i want to write all vehicle ids, in the ini and im getting this gay error as escribed in the topic title
how fix?
Have you tried using WriteIniNumber
just for the heck of it?
As I mean I think it's possible.
Of course I will be honest I have been drinking
Of course there is no real documentation what WriteIniNumber is used for. I know positions work, But I do not this it's only for float values
ill try it next day, im sleeping.
and playing on android at same time[size]
Try vee.ID.tostring()
k, testing right now.
now
[vehicle]
id = 179.000000
in the .ini
:/ i want to save for every veh, veh1,veh2,veh3,veh4, etc ..
Use this:
function SaveCars()
{
for(local a = 0; a < GetVehicleCount(); a ++)
{
local vee = FindVehicle(a);
if(vee) {
WriteIniString("Stats.ini","Vehicle" + i, "ID", vee.ID.tostring() );
}
}
}