Quote:
Originally Posted by SuperViper
MySQL servers still have PlayerInfo because it's used to store player's data so you don't have to retrieve all of the player's data from the MySQL database all of the time, which is very slow.
To check if a player is banned, use this:
pawn Код:
new query[128]; GetPlayerName(playerid, query, sizeof(query)); format(query, sizeof(query), "SELECT `banned` FROM `users` WHERE `name` = '%s' AND `banned` = '1'", query); mysql_query(query); mysql_store_result();
if(mysql_num_rows()) { // banned return mysql_free_result(); }
mysql_free_result
|
That look eerily similar to my code.