25.01.2012, 15:52
This doesnt work, but it un-bans (without the rows > 1 part), but I wanted to check if the account was valid....How would I get this to work
pawn Код:
format(query, sizeof(query), "SELECT * FROM `accounts` WHERE `PlayerName` = '%s'", string);
mysql_store_result();
new rows = mysql_num_rows();
if(rows > 0)
{
TUnbanPlayer(string);
format(string, sizeof(string), "You have unbanned account(Temp Ban) %s", string);
SendClientMessage(playerid, COLOUR_REALRED, string);
}
if(rows == 0)
{
SendClientMessage(playerid, COLOUR_GREY, "There are no accounts found with that name.");
}
mysql_free_result();