13.05.2010, 19:45
Here is some of my code, which works.
format(query, sizeof(query), "SELECT * FROM `accounts` WHERE account_name = '%s'", pname);
mysql_query(query);
mysql_store_result();
mysql_fetch_row_format(line, "|");
sscanf(line, "p|dssdddddddffffddddddddddddddddddddddddddddddddddddddd dddsdddddddddddddddddddddffdddddddddddfddfdddddddd dddd",
PlayerInfo[playerid][account_id],
PlayerInfo[playerid][account_name],
PlayerInfo[playerid][account_password],
PlayerInfo[playerid][account_tutorial],
However, I don't need to get account_password, just everything else. How would you recommend doing that?
format(query, sizeof(query), "SELECT * FROM `accounts` WHERE account_name = '%s'", pname);
mysql_query(query);
mysql_store_result();
mysql_fetch_row_format(line, "|");
sscanf(line, "p|dssdddddddffffddddddddddddddddddddddddddddddddddddddd dddsdddddddddddddddddddddffdddddddddddfddfdddddddd dddd",
PlayerInfo[playerid][account_id],
PlayerInfo[playerid][account_name],
PlayerInfo[playerid][account_password],
PlayerInfo[playerid][account_tutorial],
However, I don't need to get account_password, just everything else. How would you recommend doing that?