10.07.2013, 14:26
No topo do GM
EM OnPlayerSpawn
Coloque
Aonde ta os arquivos que cria a conta se for em Dialog o sistema de registro coloque em OnDialogResponse.
Exemplo:
Quote:
#define DIALOG_SEXO 1 new novato[MAX_PLAYERS]; |
Quote:
if(novato[playerid] == 1) { ShowPlayerDialog(playerid, DIALOG_SEXO, DIALOG_STYLE_MSGBOX, "Genero", "Escolha seu Sexo.", "Masculino", "Femenino"); } |
Quote:
novato[playerid] = 1; |
Exemplo:
Quote:
if(dialogid == 3) { new nome[MAX_PLAYER_NAME], arquivo[256], string[128]; GetPlayerName(playerid, nome, sizeof(nome)); format(arquivo, sizeof(arquivo), "/Players/%s.ini", PlayerName(playerid)); if(!response) Kick(playerid); if(!strlen(inputtext)) return ShowPlayerDialog(playerid, 1, DIALOG_STYLE_INPUT, "Registre-se", "Registre sua conta colocando a senha abaixo:", "Registrar", "Sair"); dini_Create(arquivo); //dini_IntSet(arquivo, "Senha", udb_hash(inputtext)); novato[playerid] = 1; // coloque essa funзгo.SOmente o novato[playerid] = 1; } |