Can't save player's score and money when he quit the game
#5

Код:
public OnPlayerDisconnect(playerid, reason)
{
	dini_IntSet(file, "Score", PlayerInfo[playerid][pScore]);
	dini_IntSet(file, "AdminLevel",PlayerInfo[playerid][pAdminLevel]); 
	dini_IntSet(file, "RobLevel",PlayerInfo[playerid][pRobRank]);
	dini_IntSet(file, "Money", GetPlayerMoney(playerid));
return 1;
}
admin and rob pinfo work good

and for playerrigester

Код:
dini_IntSet(file, "AdminLevel",PlayerInfo[playerid][pAdminLevel] = 0); 
dini_IntSet(file, "RobLevel",PlayerInfo[playerid][pRobRank] = 0);
dini_IntSet(file, "Money",PlayerInfo[playerid][pCash] = 3000);
dini_IntSet(file, "Score",PlayerInfo[playerid][pScore] = 0);
and on login

Код:
	PlayerInfo[playerid][pAdminLevel] = dini_Int(file, "AdminLevel"); 
PlayerInfo[playerid][pScore] = dini_Int(file, "Score");
PlayerInfo[playerid][pCash] = dini_Int(file, "Money");
did you mean this? And where is problem...
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 2 Guest(s)