[AJUDA] ERRO salvar, carregar
#1

pawn Код:
public LoadStuff()
{
 new arrCoords[4][64];
 new strFromFile2[128];
 new File: file = fopen("Configs/stuff.ini", io_read);
 if (file)
    {
        fread(file, strFromFile2);
        split(strFromFile2, arrCoords, ',');
        Jackpot = strval(arrCoords[0]);
        Tax = strval(arrCoords[1]);
        TaxValue = strval(arrCoords[2]);
        fclose(file);
    }
    return 1;
}

public SaveStuff()
{
 new coordsstring[128];
    format(coordsstring, sizeof(coordsstring), "%d,%d,%d", Jackpot,Tax,TaxValue);
 new File: file2 = fopen("Configs/stuff.ini", io_write);
    fwrite(file2, coordsstring);
    fclose(file2);
    return 1;
}
pawn Код:
C:\DOCUME~1\PEUMEN~1\Desktop\SAMP03~1\GAMEMO~1\BTG.pwn(20194) : warning 219: local variable "file" shadows a variable at a preceding level
C:\DOCUME~1\PEUMEN~1\Desktop\SAMP03~1\GAMEMO~1\BTG.pwn(20198) : error 004: function "split" is not implemented
C:\DOCUME~1\PEUMEN~1\Desktop\SAMP03~1\GAMEMO~1\BTG.pwn(20211) : warning 219: local variable "file2" shadows a variable at a preceding level
Linha 20194
pawn Код:
new File: file = fopen("Configs/stuff.ini", io_read);
Linha 20198
pawn Код:
split(strFromFile2, arrCoords, ',');
Linha 20211
pawn Код:
new File: file2 = fopen("Configs/stuff.ini", io_write);
Reply


Messages In This Thread
[AJUDA] ERRO salvar, carregar - by peumenezes - 04.05.2012, 08:23
Re: [AJUDA] ERRO salvar, carregar - by peumenezes - 04.05.2012, 08:31
Re: [AJUDA] ERRO salvar, carregar - by WLSF - 04.05.2012, 08:34

Forum Jump:


Users browsing this thread: 1 Guest(s)