04.08.2011, 14:12
I might not help you with this problem, but that's annoying to see people keep working with dini when they have Y_INI, which is faster, better, and have much more new futures. Even if you will fix this problem, dini is the slowest file reading and writing, so you will need to change this in future. WHY not changing now? Y_INI is the best.
Also, try this;
I'm still recommending you to change your file reading and writing include, really recommended.
Also, try this;
pawn Код:
new weapons[13][2];
for(new i; i < 13; i++) GetPlayerWeaponData(playerid, i, weapons[i][0], weapons[i][1]);
dini_IntSet(bestand, "Weap0", weapons[0][0]);
dini_IntSet(bestand, "Ammo0", weapons[0][1]);
dini_IntSet(bestand, "Weap1", weapons[1][0]);
dini_IntSet(bestand, "Ammo1", weapons[1][1]);
dini_IntSet(bestand, "Weap2", weapons[2][0]);
dini_IntSet(bestand, "Ammo2", weapons[2][1]);
dini_IntSet(bestand, "Weap3", weapons[3][0]);
dini_IntSet(bestand, "Ammo3", weapons[3][1]);
dini_IntSet(bestand, "Weap4", weapons[4][0]);
dini_IntSet(bestand, "Ammo4", weapons[4][1]);
dini_IntSet(bestand, "Weap5", weapons[5][0]);
dini_IntSet(bestand, "Ammo5", weapons[5][1]);
dini_IntSet(bestand, "Weap6", weapons[6][0]);
dini_IntSet(bestand, "Ammo6", weapons[6][1]);
dini_IntSet(bestand, "Weap7", weapons[7][0]);
dini_IntSet(bestand, "Ammo7", weapons[7][1]);
dini_IntSet(bestand, "Weap8", weapons[8][0]);
dini_IntSet(bestand, "Ammo8", weapons[8][1]);
dini_IntSet(bestand, "Weap9", weapons[9][0]);
dini_IntSet(bestand, "Ammo9", weapons[9][1]);
dini_IntSet(bestand, "Weap10", weapons[10][0]);
dini_IntSet(bestand, "Ammo10", weapons[10][1]);
dini_IntSet(bestand, "Weap11", weapons[11][0]);
dini_IntSet(bestand, "Ammo11", weapons[11][1]);
dini_IntSet(bestand, "Weap12", weapons[12][0]);
dini_IntSet(bestand, "Ammo12", weapons[12][1]);