12.04.2017, 01:40
PHP код:
stock CarregarPlayer(playerid)
{
if(DOF2_FileExists(GetArquivo(playerid)))
{
playerInfo[playerid][Administrador] = DOF2_GetInt(GetArquivo(playerid), "Administrador");
playerInfo[playerid][Level] = DOF2_GetInt(GetArquivo(playerid), "Level");
playerInfo[playerid][Skin] = DOF2_GetInt(GetArquivo(playerid), "Skin");
playerInfo[playerid][Matou] = DOF2_GetInt(GetArquivo(playerid), "Matou");
playerInfo[playerid][Morreu] = DOF2_GetInt(GetArquivo(playerid), "Morreu");
playerInfo[playerid][Dinheiro] = DOF2_GetInt(GetArquivo(playerid), "Dinheiro");
for(new i = 0; i < sizeof(Registro); i++) { TextDrawHideForPlayer(playerid, Registro[i]);}
for(new i = 0; i < sizeof(PlayerRegistro); i++) { PlayerTextDrawHide(playerid, PlayerRegistro[i]);}
playerInfo[playerid][Logado] = true;
TogglePlayerSpectating(playerid, 0);
CancelSelectTextDraw(playerid);
SpawnPlayer(playerid);
GivePlayerMoney(playerid, playerInfo[playerid][Dinheiro]);
SetPlayerSkin(playerid, playerInfo[playerid][Skin]);
GetPlayerScore(playerid, playerInfo[playerid][Level]);
}
return 1;
}