02.02.2014, 03:45
All the stats except Password and Ip aren`t saving!
pawn Код:
public OnPlayerDisconnect(playerid, reason)
{
new h, m, s;
TotalGameTime(playerid, h, m, s);
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"data");
INI_WriteInt(File,"Cash",GetPlayerMoney(playerid));
INI_WriteInt(File,"Score",GetPlayerScore(playerid));
INI_WriteInt(File,"Admin",PlayerInfo[playerid][pAdmin]);
INI_WriteInt(File,"Kills",PlayerInfo[playerid][pKills]);
INI_WriteInt(File,"Deaths",PlayerInfo[playerid][pDeaths]);
INI_WriteInt(File,"Banned",PlayerInfo[playerid][pBanned]);
INI_WriteInt(File,"Cookies",PlayerInfo[playerid][pCookies]);
INI_WriteInt(File,"Vip",PlayerInfo[playerid][pVip]);
INI_WriteInt(File,"Seconds",s);
INI_WriteInt(File,"Minutes",m);
INI_WriteInt(File,"Hours",h);
INI_WriteString(File, "Ip",GetPlayerIPEx(playerid));
INI_Close(File);
return 1;
}