[HELP] Can't save stats
#1

Well, everytime theres a gmx my stats go 0 and everyone else's stats
Code:

Quote:

public CheckStats(playerid)
{
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "money", GetPlayerMoney(i));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "AdminLevel", (PlayerInfo[i][AdminLevel]));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "score", GetPlayerScore(i));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "Bombs", (PlayerInfo[i][Bombs]));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "PainKillers", (PlayerInfo[i][PainKillers]));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "Kills", (PlayerInfo[i][Kills]));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "Deaths", (PlayerInfo[i][Deaths]));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "Level", (PlayerInfo[i][Level]));
for(new i; i < GetMaxPlayers(); i++) if(IsPlayerConnected(i))dini_IntSet(file, "RemoteBombs", (PlayerInfo[i][RemoteBombs]));
return 1;
}

Thats on login CMD:

Quote:

SetTimerEx("CheckStats", 60*1000, 1, "i", playerid);
SetPlayerScore(playerid, dini_Int(file, "score"));
GivePlayerMoney(playerid, dini_Int(file, "money"));
PlayerInfo[playerid][AdminLevel]=dini_Int(file,"AdminLevel");
PlayerInfo[playerid][Bombs]=dini_Int(file,"Bombs");
PlayerInfo[playerid][PainKillers]=dini_Int(file,"PainKillers");
PlayerInfo[playerid][Level]=dini_Int(file,"Level");
PlayerInfo[playerid][Kills]=dini_Int(file,"Kills");
PlayerInfo[playerid][Deaths]=dini_Int(file,"Deaths");
PlayerInfo[playerid][RemoteBombs]=dini_Int(file,"RemoteBombs");

Reply


Messages In This Thread
[HELP] Can't save stats - by Maxips2 - 09.06.2010, 23:20
Re: [HELP] Can't save stats - by RichyB - 10.06.2010, 06:09
Re: [HELP] Can't save stats - by Maxips2 - 10.06.2010, 11:13
Re: [HELP] Can't save stats - by DJDhan - 10.06.2010, 11:31
Re: [HELP] Can't save stats - by Assyria - 10.06.2010, 12:01
Re: [HELP] Can't save stats - by Jakku - 10.06.2010, 17:30
Re: [HELP] Can't save stats - by PotH3Ad - 10.06.2010, 17:39
Re: [HELP] Can't save stats - by Jakku - 10.06.2010, 17:41
Re: [HELP] Can't save stats - by [GOD]Dragonster82 - 30.08.2011, 08:40

Forum Jump:


Users browsing this thread: 2 Guest(s)