PHP код:
public UserSave(playerid)
{
if(loggedin[playerid] == true)
{
new file[64], Float:X, Float:Y, Float:Z, Float:Rot, Float:Health, Float:Armour;
format(file, sizeof(file), USER_PATH, GetPlayerNameEx(playerid));
GetPlayerPos(playerid, X, Y, Z);
GetPlayerFacingAngle(playerid, Rot);
GetPlayerHealth(playerid, Health);
GetPlayerArmour(playerid, Armour);
dini_IntSet(file, "Register", PlayerInfo[playerid][pRegister]);
dini_IntSet(file, "Cash", GetPlayerCash(playerid));
dini_IntSet(file, "Account", PlayerInfo[playerid][pAccount]);
dini_IntSet(file, "Level", PlayerInfo[playerid][pLevel]);
dini_IntSet(file, "Exp", PlayerInfo[playerid][pExp]);
dini_IntSet(file, "Skin", PlayerInfo[playerid][pSkin]);
dini_IntSet(file, "Gender", PlayerInfo[playerid][pGender]);
dini_FloatSet(file, "Health", Health);
dini_FloatSet(file, "Armour", Armour);
dini_FloatSet(file, "PosX", X);
dini_FloatSet(file, "PosY", Y);
dini_FloatSet(file, "PosZ", Z);
dini_FloatSet(file, "Rot", Rot);
dini_IntSet(file, "Interior", GetPlayerInterior(playerid));
dini_IntSet(file, "VW", GetPlayerVirtualWorld(playerid));
dini_IntSet(file, "Admin", PlayerInfo[playerid][pAdmin]);
dini_IntSet(file, "Ban", PlayerInfo[playerid][pBan]);
dini_IntSet(file, "BanEnd", PlayerInfo[playerid][pBanEnd]);
}
return 1;
}