08.03.2019, 17:12
Recomendo usar include DOF2
Agora vocк chama essas funзхes na
OnPlayerConnected = CarregarVip(playerid)
OnPlayerDiscconect = SalvarVip(playerid)
Quote:
stock SalvarVip(playerid) { if(PlayerVip[playerid] >= 1) { format(_sStr, 35, "Vips/%s.ini", pNome(playerid)); if(INI_Open(_sStr))// Abre o arquivo! { INI_WriteInt("NivelVip", PlayerVip[playerid]); INI_WriteInt("Profissao", Profissao[playerid]); INI_Save(); INI_Close(); } } return 1; } stock CarregarVip(playerid) { format(_sStr, 35, "Vips/%s.ini", pNome(playerid)); if(INI_Open(_sStr))// Abre o arquivo! { PlayerVip[playerid] = INI_ReadInt("NivelVip"); Profissao[playerid] = INI_ReadInt("Profissao"); INI_Close(); } return 1; } |
OnPlayerConnected = CarregarVip(playerid)
OnPlayerDiscconect = SalvarVip(playerid)