I want to save the player health and armour but i can't make this ...
I tried and i tried and i tried but nothing ...
My last attempt [not work] :
[pawn]public SaveInfo()
{
for(new i = 0; i <= MAX_PLAYERS; i++) {
if(IsPlayerConnected(i) && PlayerInfo[Spawned] == 1 && PlayerInfo[Logged] == 1) {
format(file, sizeof(file), USERS_FILE, gPlayers);
new Float:health,Float:armour,string[256],str[256];
GetPlayerHealth(i,health);
format(string,sizeof(string),"%s",health);
GetPlayerHealth(i,armour);
format(str,sizeof(str),"%s",armour);
dini_Set(file, "Health", string);
dini_Set(file, "Armour", str);
}
}
}[/pawn]