Help me in some errors :D
#1

hi i got like 5 errors in my gang fs
C:\Users\Youssef\Desktop\World of stunts v5 0.3z\filterscripts\TestGang.pwn(15 : error 035: argument type mismatch (argument 3)
C:\Users\Youssef\Desktop\World of stunts v5 0.3z\filterscripts\TestGang.pwn(18 : error 017: undefined symbol "mysql_init"
C:\Users\Youssef\Desktop\World of stunts v5 0.3z\filterscripts\TestGang.pwn(214) : error 017: undefined symbol "mysql_fetch_string"
C:\Users\Youssef\Desktop\World of stunts v5 0.3z\filterscripts\TestGang.pwn(241) : error 035: argument type mismatch (argument 3)
C:\Users\Youssef\Desktop\World of stunts v5 0.3z\filterscripts\TestGang.pwn(284) : error 035: argument type mismatch (argument 3)

ill show u the lines

Lines (153-160)

stock LoadPlayerInfo(playerid)
{
new Query[100]; format(Query, sizeof(Query), "SELECT * FROM users WHERE username = '%s';", GetPlayerNameEx(playerid));
mysql_query(Query);
mysql_store_result();
mysql_fetch_row(Query, "|");
sscanf(Query, "p<|>e<is[25]i>", PlayerInfo[playerid]);
}


Lines (186-192)

stock InitMysqlConnection()
{
mysql_init();
mysql_connect(DB_HOST, DB_USER, DB_PASS, DB_DB);
mysql_query(CREATE_DB_USERS);
mysql_query(CREATE_DB_GANGS);
}


Lines (209-216)

stock GetGangName(GangID)
{
new gName[100], Query[150]; format(Query, sizeof(Query), "SELECT name FROM gangs WHERE id = %d;", GangID);
mysql_query(Query);
mysql_store_result();
mysql_fetch_string(gName);
return gName;
}


Lines (234-245)

stock ShowGangInfoForPlayer(GangID, pID)
{
new tGid, tGname[100], tGOwner[25], Query[150], string[200];
format(Query, sizeof(Query), "SELECT * FROM gangs WHERE id = %d;", GangID);
mysql_query(Query);
mysql_store_result();
if(!mysql_num_rows()) return 0;
mysql_fetch_row(Query, "|");
sscanf(Query, "p<|>is[100]s[25]", tGid, tGname, tGOwner);
format(string, sizeof(string), "Id: %d - Name: %s - Owner: %s - Members: %d", tGid, tGname, tGOwner, GetGangMemberCount(GangID));
return ShowPlayerDialog(pID, DIALOG_GANG_INFO, DIALOG_STYLE_MSGBOX, "Cameltoe's Gang FS", string, "Cancel", "");
}


Lines ()

command(gangs, playerid, params[])
{
new gID, tGid, tGname[100], tGOwner[25], Query[200], string[1000]; // Change this depending on how many gangs you have.
if(sscanf(params, "u", gID))
{
format(Query, sizeof(Query), "SELECT * FROM gangs");
mysql_query(Query);
mysql_store_result();
while(mysql_fetch_row(Query, "|"))
{
if(!mysql_num_rows()) continue;
sscanf(Query, "p<|>is[100]s[25]", tGid, tGname, tGOwner);
format(string, sizeof(string), "%sId: %d - Name: %s - Owner: %s\r\n", string, tGid, tGname, tGOwner);
}
ShowPlayerDialog(playerid, DIALOG_GANG_INFO, DIALOG_STYLE_LIST, "Cameltoe's Gang FS", string, "Info", "Cancel");
}
else
{
if(!ShowGangInfoForPlayer(gID, playerid)) SendClientMessage(playerid, COLOR_YELLOW, "Invalid gang id.");
}
return 1;
}



I got Mysql i tried updating-downgrading-removing it tried all stuff and i gave up -_- so i said to myself lets share my prob. maybe someone had it and found its solution thnx anywayz
any more info u guys want ask me
Reply
#2

pawn Код:
Lines (153-160)

stock LoadPlayerInfo(playerid)
{
new Query[100];
format(Query, sizeof(Query), "SELECT * FROM users WHERE username = '%s';", GetPlayerNameEx(playerid));
mysql_query(Query);
mysql_store_result();
mysql_fetch_row(Query, "|");
sscanf(Query, "p<|>e<is[25]i>", PlayerInfo[playerid]);
}
For the mysql_init error,make sure you have the a_mysql.inc include file. Same with the fetch_row error as well.
Reply
#3

k gonna try thnx mate
Reply
#4

hmmm k can u suggest a version of a_mysql bec i tried like 5 versions the lest i get r those 5 errors at first they were 26 :/ sorry for being noob
Reply
#5

Are you trying to compile with mysql by BlueG? Because the script uses the plugin by StrickenKid.

However, it's recommended not to use StrickenKid's plugin because it's very old. The one by BlueG is updated too often by Pain123/maddinat0r and using threaded queries or ORM is much faster!
Reply
#6

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
Are you trying to compile with mysql by BlueG? Because the script uses the plugin by StrickenKid.

However, it's recommended not to use StrickenKid's plugin because it's very old. The one by BlueG is updated too often by Pain123/maddinat0r and using threaded queries or ORM is much faster!
im using BlueG but my script needs the one by StrickenKid but all links r destroyed i cant find it to download it u got a link?
Reply
#7

http://forum.sa-mp.com/showpost.php?...&postcount=945

But think about switching to R38 version by BlueG, it's worth.
Reply
#8

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
http://forum.sa-mp.com/showpost.php?...&postcount=945

But think about switching to R38 version by BlueG, it's worth.
nw im on R38 and i got these errors and ur link after i click donload it doesnt work :/ can u upload urs?/?
Reply
#9

Hold on, I'm confused.

The links were uploaded by Blacklite and it's for StrickenKid's plugin and the links work by the way.

If you are about to use R38 by BlueG, then you'll have to modify the whole script - it's not just including a_mysql and it will work.

https://sampforum.blast.hk/showthread.php?tid=337810
https://sampwiki.blast.hk/wiki/MySQL/R33
https://sa-mp-mysql-plugin.******cod...le_scripts.rar
https://sampforum.blast.hk/showthread.php?tid=390428
Reply
#10

Quote:
Originally Posted by Konstantinos
Посмотреть сообщение
Hold on, I'm confused.

The links were uploaded by Blacklite and it's for StrickenKid's plugin and the links work by the way.

If you are about to use R38 by BlueG, then you'll have to modify the whole script - it's not just including a_mysql and it will work.

https://sampforum.blast.hk/showthread.php?tid=337810
https://sampwiki.blast.hk/wiki/MySQL/R33
https://sa-mp-mysql-plugin.******cod...le_scripts.rar
https://sampforum.blast.hk/showthread.php?tid=390428
hmmm thats why i wanted the mysql by the strickenkid so u dont got it on ur pc somewhere?
bec the R38 as u know ill have to rescript all the script bec its all working by the srtickenkids plugin that i dont have :/
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)