27.11.2014, 08:52
Can't figure out why.
This, is under OnPlayerDisconnect.
This, is under OnPlayerDisconnect.
pawn Код:
stock SaveUser(playerid)
{
PlayerInfo[playerid][Money] = GetPlayerMoney(playerid);
PlayerInfo[playerid][Level] = GetPlayerScore(playerid);
new INI:File = INI_Open(UserPath(playerid));
INI_SetTag(File,"====[PLAYER INFORMATION]====");
INI_WriteString(File,"Name",PlayerInfo[playerid][Name]);
INI_WriteInt(File,"Password",PlayerInfo[playerid][Password]);
INI_WriteInt(File,"Level",PlayerInfo[playerid][Level]);
INI_WriteInt(File,"Money",PlayerInfo[playerid][Money]);
INI_WriteInt(File,"AdminLevel",PlayerInfo[playerid][AdminLevel]);
INI_WriteInt(File,"Age",PlayerInfo[playerid][Age]);
INI_WriteInt(File,"Gender",PlayerInfo[playerid][Gender]);
INI_WriteInt(File,"Skin",PlayerInfo[playerid][Skin]);
INI_WriteInt(File,"RegDate",PlayerInfo[playerid][RegDate]);
INI_WriteInt(File,"RegMonth",PlayerInfo[playerid][RegMonth]);
INI_WriteInt(File,"RegYear",PlayerInfo[playerid][RegYear]);
INI_WriteInt(File,"TimesKicked",PlayerInfo[playerid][TimesKicked]);
INI_WriteInt(File,"Banned",PlayerInfo[playerid][Banned]);
INI_WriteString(File,"BannedBy",PlayerInfo[playerid][BannedBy]);
INI_WriteString(File,"BanReason",PlayerInfo[playerid][BanReason]);
INI_WriteInt(File,"TimesBanned",PlayerInfo[playerid][TimesBanned]);
INI_Close(File);
return 1;
}