11.12.2013, 18:29
(
Последний раз редактировалось AA9; 12.12.2013 в 17:02.
)
I have a little problem, with MySQL. It should check, is there any row, with that player name. But when i checked debug, there was a error message. I have tried a couple of hours, to fix this, but no result.
pawn Код:
CMySQLHandler::NumRows() - You cannot call this function now. (Reason: Dead Connection)
pawn Код:
format(query, sizeof(query), "SELECT status FROM `playerdata` WHERE user = '%s' LIMIT 1", pname);
mysql_query(query);
mysql_store_result();
mysql_fetch_row(staatus);
mysql_free_result();
mysql_store_result();
new rows = mysql_num_rows();
if(rows == 1)
{
if(strval(staatus) != 3) return KickWithMessage(playerid, V_PUNANE, "Test");
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_PASSWORD, "Logi Sisse","Kasutaja eksisteerib andmebaasis. Logimiseks sisesta oma {0000FF}parool{FFFFFF} alla lahtrisse!","Logi Sisse","Katkesta"); //Shows our login dialog :).
}
mysql_free_result();
return 1;
}