Код:
public OnPlayerUpdateTime(playerid)
{
if(gPlayerLogged[playerid] == 1)
{
new string[128], string3[64], playername3[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername3, sizeof(playername3));
format(string3, sizeof(string3), "users/%s.ini", playername3);
new INI:PlayerAcc = INI_Open( string3 );
INI_WriteString( PlayerAcc, "Key", PlayerInfo[playerid][pKey]);
INI_WriteInt( PlayerAcc, "Level", PlayerInfo[playerid][pLevel]);
INI_WriteInt( PlayerAcc, "AdminCRP", PlayerInfo[playerid][pAdminECRP]);
INI_WriteInt( PlayerAcc, "Facciones", PlayerInfo[playerid][pFacciones]);
INI_WriteInt( PlayerAcc, "Helper", PlayerInfo[playerid][pHelper]);
INI_WriteInt( PlayerAcc, "ConnectedTime", PlayerInfo[playerid][pConnectTime]);
INI_WriteInt( PlayerAcc, "Registered", PlayerInfo[playerid][pReg]);
INI_WriteInt( PlayerAcc, "Sex", PlayerInfo[playerid][pSex]);
INI_WriteInt( PlayerAcc, "Age", PlayerInfo[playerid][pAge]);
INI_WriteInt( PlayerAcc, "Origin", PlayerInfo[playerid][pOrigin]);
INI_WriteInt( PlayerAcc, "Walk", PlayerInfo[playerid][pWalk]);
INI_WriteInt( PlayerAcc, "Respect", PlayerInfo[playerid][pExp]);
INI_WriteInt( PlayerAcc, "Money", GetPlayerMoney(playerid));
INI_WriteInt( PlayerAcc, "Bank", PlayerInfo[playerid][pAccount]);
INI_WriteInt( PlayerAcc, "Cheques", PlayerInfo[playerid][pCheques]);
INI_WriteInt( PlayerAcc, "Kills", PlayerInfo[playerid][pKills]);
INI_WriteInt( PlayerAcc, "Deaths", PlayerInfo[playerid][pDeaths]);
INI_WriteInt( PlayerAcc, "Arrested", PlayerInfo[playerid][pArrested]);
INI_WriteInt( PlayerAcc, "LottoNr", PlayerInfo[playerid][pLottoNr]);
INI_WriteInt( PlayerAcc, "Job", PlayerInfo[playerid][pJob]);
INI_WriteInt( PlayerAcc, "Jailed", PlayerInfo[playerid][pJailed]);
INI_WriteInt( PlayerAcc, "JailTime", PlayerInfo[playerid][pJailTime]);
INI_WriteInt( PlayerAcc, "Materiales", PlayerInfo[playerid][pMats]);
INI_WriteInt( PlayerAcc, "Drogas", PlayerInfo[playerid][pDrugs]);
INI_WriteInt( PlayerAcc, "Speed", PlayerInfo[playerid][pSpeed]);
INI_WriteInt( PlayerAcc, "Ectasy", PlayerInfo[playerid][pEctasy]);
INI_WriteInt( PlayerAcc, "Ritalin", PlayerInfo[playerid][pRitalin]);
INI_WriteInt( PlayerAcc, "Heroina", PlayerInfo[playerid][pHeroina]);
INI_WriteInt( PlayerAcc, "Marihuana", PlayerInfo[playerid][pMarihuana]);
INI_WriteInt( PlayerAcc, "Leader", PlayerInfo[playerid][pLeader]);
INI_WriteInt( PlayerAcc, "Member", PlayerInfo[playerid][pMember]);
INI_WriteInt( PlayerAcc, "Rank", PlayerInfo[playerid][pRank]);
INI_WriteInt( PlayerAcc, "Char", PlayerInfo[playerid][pChar]);
GetPlayerHealth(playerid, PlayerInfo[playerid][pHealth]);
INI_WriteFloat( PlayerAcc, "Health", PlayerInfo[playerid][pHealth]);
GetPlayerArmour(playerid, PlayerInfo[playerid][pArmour]);
INI_WriteFloat( PlayerAcc, "Armour", PlayerInfo[playerid][pArmour]);
PlayerInfo[playerid][pInt] = GetPlayerInterior(playerid);
INI_WriteInt( PlayerAcc, "Int", PlayerInfo[playerid][pInt]);
PlayerInfo[playerid][pVirWorld] = GetPlayerVirtualWorld(playerid);
INI_WriteInt( PlayerAcc, "VirWorld", PlayerInfo[playerid][pVirWorld]);
INI_WriteInt( PlayerAcc, "Team", PlayerInfo[playerid][pTeam]);
INI_WriteInt( PlayerAcc, "Model", PlayerInfo[playerid][pModel]);
INI_WriteInt( PlayerAcc, "PhoneNr", PlayerInfo[playerid][pPnumber]);
INI_WriteInt( PlayerAcc, "Minutes", PlayerInfo[playerid][pMinutes]);
INI_WriteInt( PlayerAcc, "MTexto", PlayerInfo[playerid][pMTexto]);
INI_WriteInt( PlayerAcc, "Ipod", PlayerInfo[playerid][pIpod]);
INI_WriteInt( PlayerAcc, "Car", PlayerInfo[playerid][pPcarkey]);
INI_WriteInt( PlayerAcc, "Car2", PlayerInfo[playerid][pPcarkey2]);
INI_WriteInt( PlayerAcc, "TimeCar", PlayerInfo[playerid][pTimeCar]);
INI_WriteInt( PlayerAcc, "TimeCar2", PlayerInfo[playerid][pTimeCar2]);
INI_WriteInt( PlayerAcc, "House", PlayerInfo[playerid][pPhousekey]);
INI_WriteInt( PlayerAcc, "Negocio", PlayerInfo[playerid][pPbizzkey]);
GetPlayerPos(playerid,PlayerInfo[playerid][pPos_x],PlayerInfo[playerid][pPos_y],PlayerInfo[playerid][pPos_z]);
INI_WriteFloat( PlayerAcc, "Pos_x", PlayerInfo[playerid][pPos_x]);
INI_WriteFloat( PlayerAcc, "Pos_y", PlayerInfo[playerid][pPos_y]);
INI_WriteFloat( PlayerAcc, "Pos_z", PlayerInfo[playerid][pPos_z]);
INI_WriteInt( PlayerAcc, "CarLic", PlayerInfo[playerid][pCarLic]);
INI_WriteInt( PlayerAcc, "FlyLic", PlayerInfo[playerid][pFlyLic]);
INI_WriteInt( PlayerAcc, "BoatLic", PlayerInfo[playerid][pBoatLic]);
INI_WriteInt( PlayerAcc, "GunLic", PlayerInfo[playerid][pGunLic]);
INI_WriteInt( PlayerAcc, "Gafas", PlayerInfo[playerid][pGafas]);
INI_WriteInt( PlayerAcc, "Tutorial", PlayerInfo[playerid][pTut]);
INI_WriteString( PlayerAcc, "Antecedente1", PlayerInfo[playerid][pAntecedente1]);
INI_WriteString( PlayerAcc, "Antecedente2", PlayerInfo[playerid][pAntecedente2]);
INI_WriteString( PlayerAcc, "Antecedente3", PlayerInfo[playerid][pAntecedente3]);
INI_WriteString( PlayerAcc, "Note1", PlayerInfo[playerid][pNote1]);
INI_WriteString( PlayerAcc, "Note2", PlayerInfo[playerid][pNote2]);
INI_WriteString( PlayerAcc, "Note3", PlayerInfo[playerid][pNote3]);
INI_WriteString( PlayerAcc, "Note4", PlayerInfo[playerid][pNote4]);
INI_WriteString( PlayerAcc, "Note5", PlayerInfo[playerid][pNote5]);
INI_WriteString( PlayerAcc, "SMS1", PlayerInfo[playerid][pSMS_1]);
INI_WriteString( PlayerAcc, "SMS2", PlayerInfo[playerid][pSMS_2]);
INI_WriteString( PlayerAcc, "SMS3", PlayerInfo[playerid][pSMS_3]);
INI_WriteString( PlayerAcc, "SMS4", PlayerInfo[playerid][pSMS_4]);
INI_WriteString( PlayerAcc, "SMS5", PlayerInfo[playerid][pSMS_5]);
INI_WriteInt( PlayerAcc, "Lighter", PlayerInfo[playerid][pLighter]);
INI_WriteInt( PlayerAcc, "Cigarettes", PlayerInfo[playerid][pCigarettes]);
INI_WriteInt( PlayerAcc, "Mascara", PlayerInfo[playerid][pMask]);
INI_WriteInt( PlayerAcc, "Locked", PlayerInfo[playerid][pLocked]);
INI_WriteInt( PlayerAcc, "Advertencias", PlayerInfo[playerid][pAdvertencias]);
INI_WriteInt( PlayerAcc, "AdminAdver", PlayerInfo[playerid][pAdminAdver]);
INI_WriteInt( PlayerAcc, "DNI", PlayerInfo[playerid][pDNI]);
INI_WriteString( PlayerAcc, "MSN", PlayerInfo[playerid][pMSN]);
INI_WriteString( PlayerAcc, "Estado", PlayerInfo[playerid][pEstado]);
INI_WriteInt( PlayerAcc, "Weapon", PlayerInfo[playerid][pWeapon]);
INI_WriteInt( PlayerAcc, "Ammo", PlayerInfo[playerid][pAmmo]);
INI_WriteInt( PlayerAcc, "Weapon2", PlayerInfo[playerid][pWeapon2]);
INI_WriteInt( PlayerAcc, "Ammo2", PlayerInfo[playerid][pAmmo2]);
INI_WriteInt( PlayerAcc, "Weapon3", PlayerInfo[playerid][pWeapon3]);
INI_WriteInt( PlayerAcc, "Ammo3", PlayerInfo[playerid][pAmmo3]);
INI_WriteInt( PlayerAcc, "Weapon4", PlayerInfo[playerid][pWeapon4]);
INI_WriteInt( PlayerAcc, "Ammo4", PlayerInfo[playerid][pAmmo4]);
INI_WriteInt( PlayerAcc, "Weapon5", PlayerInfo[playerid][pWeapon5]);
INI_WriteInt( PlayerAcc, "Ammo5", PlayerInfo[playerid][pAmmo5]);
INI_WriteInt( PlayerAcc, "Weapon6", PlayerInfo[playerid][pWeapon6]);
INI_WriteInt( PlayerAcc, "Ammo6", PlayerInfo[playerid][pAmmo6]);
INI_WriteInt( PlayerAcc, "Weapon7", PlayerInfo[playerid][pWeapon7]);
INI_WriteInt( PlayerAcc, "Ammo7", PlayerInfo[playerid][pAmmo7]);
INI_WriteInt( PlayerAcc, "Weapon8", PlayerInfo[playerid][pWeapon8]);
INI_WriteInt( PlayerAcc, "Ammo8", PlayerInfo[playerid][pAmmo8]);
INI_WriteInt( PlayerAcc, "Weapon9", PlayerInfo[playerid][pWeapon9]);
INI_WriteInt( PlayerAcc, "Ammo9", PlayerInfo[playerid][pAmmo9]);
INI_WriteInt( PlayerAcc, "Weapon10", PlayerInfo[playerid][pWeapon10]);
INI_WriteInt( PlayerAcc, "Ammo10", PlayerInfo[playerid][pAmmo10]);
INI_WriteInt( PlayerAcc, "Weapon11", PlayerInfo[playerid][pWeapon11]);
INI_WriteInt( PlayerAcc, "Ammo11", PlayerInfo[playerid][pAmmo11]);
INI_WriteInt( PlayerAcc, "Weapon12", PlayerInfo[playerid][pWeapon12]);
INI_WriteInt( PlayerAcc, "Ammo12", PlayerInfo[playerid][pAmmo12]);
INI_WriteInt( PlayerAcc, "Maleta", PlayerInfo[playerid][pMaleta]);
INI_WriteInt( PlayerAcc, "Mochila", PlayerInfo[playerid][pMochila]);
INI_WriteInt( PlayerAcc, "Casco", PlayerInfo[playerid][pCasco]);
INI_WriteInt( PlayerAcc, "SIDA", PlayerInfo[playerid][pSIDA]);
INI_WriteInt( PlayerAcc, "Cancer", PlayerInfo[playerid][pCancer]);
INI_WriteInt( PlayerAcc, "Epilepsia", PlayerInfo[playerid][pEpilepsia]);
INI_WriteInt( PlayerAcc, "DEagle", PlayerInfo[playerid][pDEagle]);
INI_WriteInt( PlayerAcc, "Shotgun", PlayerInfo[playerid][pShotgun]);
INI_WriteInt( PlayerAcc, "MP5", PlayerInfo[playerid][pMP5]);
INI_WriteInt( PlayerAcc, "AK47", PlayerInfo[playerid][pAK47]);
INI_WriteInt( PlayerAcc, "M4", PlayerInfo[playerid][pM4]);
INI_WriteInt( PlayerAcc, "Sniper", PlayerInfo[playerid][pSniper]);
INI_WriteInt( PlayerAcc, "FStyle", PlayerInfo[playerid][pFStyle]);
INI_WriteInt( PlayerAcc, "Leccion", PlayerInfo[playerid][pLeccion]);
INI_WriteInt( PlayerAcc, "Busqueda", PlayerInfo[playerid][pBusqueda]);
INI_WriteInt( PlayerAcc, "AntiSIDA", PlayerInfo[playerid][pAntiSIDA]);
INI_WriteInt( PlayerAcc, "AntiCancer", PlayerInfo[playerid][pAntiCancer]);
INI_WriteInt( PlayerAcc, "AntiEpilepsia", PlayerInfo[playerid][pAntiEpilepsia]);
INI_WriteInt( PlayerAcc, "Rent", PlayerInfo[playerid][pRent]);
INI_WriteInt( PlayerAcc, "Rob", PlayerInfo[playerid][pRob]);
INI_WriteInt( PlayerAcc, "Donate", PlayerInfo[playerid][pDonateT]);
INI_WriteInt( PlayerAcc, "CarPremium", PlayerInfo[playerid][pCarPremium]);
INI_WriteInt( PlayerAcc, "BanDuda", PlayerInfo[playerid][pBanDuda]);
INI_WriteInt( PlayerAcc, "Seguro", PlayerInfo[playerid][pSeguro]);
INI_WriteInt( PlayerAcc, "Walkie", PlayerInfo[playerid][pWalkie]);
INI_WriteInt( PlayerAcc, "Head", PlayerInfo[playerid][pHead]);
INI_WriteInt( PlayerAcc, "Married", PlayerInfo[playerid][pMarried]);
INI_WriteString( PlayerAcc, "MarriedTo", PlayerInfo[playerid][pMarriedTo]);
INI_WriteInt( PlayerAcc, "Entered", PlayerInfo[playerid][pEntered]);
INI_WriteInt( PlayerAcc, "Peces", PlayerInfo[playerid][pPeces]);
INI_WriteInt( PlayerAcc, "Implementos", PlayerInfo[playerid][pImplementos]);
INI_WriteInt( PlayerAcc, "Carnada", PlayerInfo[playerid][pCarnada]);
INI_WriteInt( PlayerAcc, "Fichas", PlayerInfo[playerid][pFichas]);
INI_WriteInt( PlayerAcc, "DNIFalse", PlayerInfo[playerid][pDNIFalse]);
INI_WriteString( PlayerAcc, "DNIName", PlayerInfo[playerid][pDNIName]);
INI_WriteInt( PlayerAcc, "Suciedad", PlayerInfo[playerid][pSuciedad]);
INI_WriteInt( PlayerAcc, "AnilloCom", PlayerInfo[playerid][pAnilloCom]);
INI_WriteInt( PlayerAcc, "AnilloOro", PlayerInfo[playerid][pAnilloOro]);
INI_WriteInt( PlayerAcc, "Collar", PlayerInfo[playerid][pCollar]);
INI_WriteInt( PlayerAcc, "AnilloDia", PlayerInfo[playerid][pAnilloDia]);
INI_WriteInt( PlayerAcc, "Pulsera", PlayerInfo[playerid][pPulsera]);
INI_WriteInt( PlayerAcc, "Aretes", PlayerInfo[playerid][pAretes]);
INI_WriteInt( PlayerAcc, "Reloj", PlayerInfo[playerid][pReloj]);
for(new v = 0; v < MAX_PLAYERTOYS; v++)
{
format(string, 128, "pt%dModelID",v);
INI_WriteInt( PlayerAcc, string, PlayerToyInfo[playerid][v][ptModelID]);
format(string, 128, "pt%dBone",v);
INI_WriteInt( PlayerAcc, string, PlayerToyInfo[playerid][v][ptBone]);
format(string, 128, "pt%dPosX",v);
INI_WriteFloat( PlayerAcc, string, PlayerToyInfo[playerid][v][ptPosX]);
format(string, 128, "pt%dPosY",v);
INI_WriteFloat( PlayerAcc, string, PlayerToyInfo[playerid][v][ptPosY]);
format(string, 128, "pt%dPosZ",v);
INI_WriteFloat( PlayerAcc, string, PlayerToyInfo[playerid][v][ptPosZ]);
format(string, 128, "pt%dRotX",v);
INI_WriteFloat( PlayerAcc, string, PlayerToyInfo[playerid][v][ptRotX]);
format(string, 128, "pt%dRotY",v);
INI_WriteFloat( PlayerAcc, string, PlayerToyInfo[playerid][v][ptRotY]);
format(string, 128, "pt%dRotZ",v);
INI_WriteFloat( PlayerAcc, string, PlayerToyInfo[playerid][v][ptRotZ]);
}
INI_Close( PlayerAcc );
}
return 1;
}