22.05.2013, 17:22
faz igual o iCastiel disse.
TROQUE MINHAS DEFINES PELA SUA.
Coloca isso na OnDialogResponse.
Olha como fico no meu GM:
pawn Код:
if(strlen (inputtext) < 4 || strlen (inputtext) > 15)
return ShowPlayerDialog( playerid, xRegistro, DIALOG_STYLE_INPUT,"Registro","A senha deve ser entre 4 e 15 caractйrias.","Registro","Sair");
Coloca isso na OnDialogResponse.
Olha como fico no meu GM:
pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
switch ( dialogid )
{
case xRegistro:
{
if(strlen (inputtext) < 4 || strlen (inputtext) > 15)
return ShowPlayerDialog( playerid, xRegistro, DIALOG_STYLE_INPUT,"Registro","Coloca a senha seu CORNO","Registro","Sair");
new Str[202], Nome[21], Float:X, Float:Y, Float:Z;
GetPlayerName(playerid, Nome, 20);
GetPlayerPos(playerid, X, Y, Z);
format(Str, 202, "INSERT INTO `users`( `name`, `password`, `level`, `cash`, `skin`, `money`, `X`, `Y`, `Z`) VALUES ('%s', '%i', '%i', '%i', '%i', '%i', '%f', '%f', '%f') ", Nome, Hash(inputtext), 0, 500, 240, 500, X, Y, Z);
mysql_function_query(Connect, Str, false, #, #);
SendClientMessage(playerid, -1, "Registrado com sucesso.");
ShowPlayerDialog(playerid, DIALOG_SEXO, DIALOG_STYLE_LIST, "{00ff00}» {ffffff}Escolha seu Sexo", "{ff0000}» {ffffff}Masculino \n{FF00F7}» {ffffff}Feminino", "Ok", "Ok");
}