29.11.2014, 12:18
Hello! not works(
Code:
Code:
Код:
stock OnPlayerLogin(playerid,password[]) { new Pass[32],str[1000],string[128],query[256]; format(query, sizeof(query), "SELECT * FROM `players` WHERE `pNick` = '%s' LIMIT 1", sendername(playerid)); if(mysql_query(query) && mysql_store_result()) { if(mysql_num_rows()) { if(mysql_fetch_row_format(str)) { sscanf(str, "p<|>ds[24]s[34]dddd", PlayerInfo[playerid][pID],sendername(playerid), Pass, PlayerInfo[playerid][pScore], PlayerInfo[playerid][pAdminLevel], PlayerInfo[playerid][pMoney], PlayerInfo[playerid][pSkin]); if(!(strcmp(password,Pass,true))) { SpawnPlayer(playerid); gPlayerLogged[playerid] = 1; printf("Logged"); } else { if bad password... } } } } mysql_free_result(); return true; }