24.01.2010, 19:36
Well ok.
Like it.
pawn Код:
if(dialogid == 2)
{
if(response == 1)
{
new sql[128], row[128], PlayerName[128], PlayerPassword[128];
GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
format(sql, sizeof(sql), "SELECT Password FROM jugadores where Name = '%s'", PlayerName);
mysql_query(sql);
mysql_store_result();
mysql_fetch_row(row);
strmid(PlayerPassword, row, 0, strlen(row), 255);
mysql_free_result();
if(strcmp(inputtext, PlayerPassword, true) == 0)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "** Has Sido Logueado Correctamente.");
return 1;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "** Contraseсa Incorrecta.");
Kick(playerid);
}
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "** Has Cancelado. Tienes que loguear Obligatoriamente.");
Kick(playerid);
}
return 1;
}