Hello, I downloaded a gamemode and i am not really good at mysql well i am a noob lets say it like that, accounts are not saving and yes i already did upload .sql file into mysql database but something is wrong with the code any helping out about what it is? here is the code
PHP код:
stock OnPlayerRegister(playerid, password[])
{
new query[500];
new info[300];
new pass[50];
mysql_real_escape_string(password, pass);
mysql_query("SET NAMES cp1251");
strcat(query,"INSERT INTO `Accounts` ");
strcat(query,"(`NickName`,`Password`,`RegIP`,`CheckIP1`,`CheckIP2`,`Level`,`Sex`,`Age`,`Race`,`Referal`,`Mail`,`Telephone`,`Money`,`Bank`,`HouseKey`,`BizKey`,`From`,`OOC`,`Snow`) ");
strcat(query,"VALUE ");
format(info, sizeof(info), "('%s', MD5('%s'), '%s', 'No IP Adress', 'No IP Adress', '1', '%i', '-1', '%i', '%s', 'No Mail Adress', 'No Telephone', '200', '0', '-1', '-1', '-1', '1', '1')",
PN(playerid), pass, PlayerIP(playerid), RegSex[playerid], RegRace[playerid], RegReferal[playerid]);
strcat(query,info);
mysql_query(query);
PI[playerid][pID] = mysql_insert_id();
//format(info, sizeof(info), "INSERT INTO `Passwords` (`Hash`, `Password`) VALUE (MD5('%s'), '%s')", password, password);
//mysql_query(info);
//mysql_query(info, -1, 0, (MySQL:0));
if(IsPlayerNPC(playerid))return 1;
return true;
}