Run time error 6 - Invalid Instruction
#2

I had this happen to me lol.
It's usually just a missing bracket:

pawn Код:
stock SaveAllVehicles()
{
    new saveindex = 0;
    new fname[50];
    for(new i = 0; i < MAX_VEHICLES; i ++)
    {
        if(validcar[i])
        {
            format(fname, sizeof(fname), "Vehicles/%d.ini", saveindex);
            SaveVehicle(i, fname);
            saveindex ++;
        }
}
^That was your code. Replace it with this:

pawn Код:
stock SaveAllVehicles()
{
    new saveindex = 0;
    new fname[50];
    for(new i = 0; i < MAX_VEHICLES; i ++)
    {
        if(validcar[i])
        {
            format(fname, sizeof(fname), "Vehicles/%d.ini", saveindex);
            SaveVehicle(i, fname);
            saveindex ++;
        }
    }
}
Reply


Messages In This Thread
Run time error 6 - Invalid Instruction - by Scarred - 14.12.2011, 23:49
Re: Run time error 6 - Invalid Instruction - by Rob_Maate - 15.12.2011, 02:03
Re: Run time error 6 - Invalid Instruction - by Scarred - 15.12.2011, 18:50
Re: Run time error 6 - Invalid Instruction - by Rob_Maate - 15.12.2011, 20:25

Forum Jump:


Users browsing this thread: 4 Guest(s)