Stats don't save on disconnect
#1

Hello,

The stats like position don't save on disconnect, and they don't to in a timer. I know that the callback gets called, cause a message with 'It gets called' just gets called.

pawn Код:
public StatsSave(playerid)
{
    if(PlayerInfo[playerid][IsLogged] == 1 && PlayerInfo[playerid][IsPlayerSpawned] == 1)
    {
        new Playername[MAX_PLAYER_NAME];
        GetPlayerRPName(playerid,Playername,sizeof(Playername));
        format(file,sizeof(file),"JoAdmin/Accounts/%s.ini",Playername);
        dini_IntSet(file, "Money", GetPlayerMoney(playerid));
        dini_IntSet(file, "Score", GetPlayerScore(playerid));
        dini_IntSet(file, "Skin", GetPlayerSkin(playerid));
        GetPlayerPos(playerid,X,Y,Z);
        Int = GetPlayerInterior(playerid);
        dini_FloatSet(file, "PosX", X);
        dini_FloatSet(file, "PosY", Y);
        dini_FloatSet(file, "PosZ", Z);
        dini_FloatSet(file, "Interior",Int);
        dini_IntSet(file, "InJail",PlayerInfo[playerid][IsJailed]);
        SendClientMessage(playerid,COLOR_WHITE," It gets called.");
    }
    return true;
}
So it doesnt save the stats.. Ain't that weird?

Regards, Jochem

Note: everything is allright. format of file is ok.
Reply


Messages In This Thread
Stats don't save on disconnect - by Jochemd - 12.09.2010, 09:29
Re: Stats don't save on disconnect - by miokie - 12.09.2010, 09:33
Re: Stats don't save on disconnect - by Jochemd - 12.09.2010, 09:41
Re: Stats don't save on disconnect - by LifeStyle - 12.09.2010, 10:17
Re: Stats don't save on disconnect - by Jochemd - 12.09.2010, 10:23
Re: Stats don't save on disconnect - by Jochemd - 12.09.2010, 11:04
Re: Stats don't save on disconnect - by Rudyy - 12.09.2010, 11:07
Re: Stats don't save on disconnect - by Jochemd - 12.09.2010, 11:12
Re: Stats don't save on disconnect - by Rudyy - 12.09.2010, 11:13
Re: Stats don't save on disconnect - by Jochemd - 12.09.2010, 11:24

Forum Jump:


Users browsing this thread: 1 Guest(s)