Whats wrong???!!!
#1

I created this script:
Код:
	if (strcmp("/alogin", cmdtext, true, 10) == 0)
	{
new name[250];
GetPlayerName(playerid ,name, 200);
new query[300];
new pass;
pass = cmdtext[1];
format(query, sizeof(query), "SELECT * FROM admins WHERE name='%s' AND pass='%s'",name,pass);
new num;
num = mysql_num_rows(mysql_query(query));
if(num == 0){
new trys;
trys = mysql_fetch_field_row(query, "trys");
if(trys == 1){
SendClientMessage(playerid, 0xAA3333AA, "You are kicked because you tryed to login into admin area.");
Kick(playerid);
}else{
SendClientMessage(playerid, 0xAA3333AA, "Sorry, try it again");
format(query, sizeof(query), "UPDATE admins SET trys='1' WHERE name='%s'",name);
mysql_query(query);
}
}else{
SendClientMessage(playerid, 0xAA3333AA, "You are now logged in as administrator");
new querya[210];
format(querya, 200, "UPDATE admins SET login='1' WHERE name='%s' AND pass='%s'",name,pass);
mysql_query(querya);
}

		return 1;
	}


And pawno see that everything is fine but when I start exe it shows this:Script[gamemodes/Server.amx]: Run time error 19: "File or function is not found"
on config I have: plugins sampmysql

and on pawno i have: #include <a_samp>
#include <a_mysql>
#include "../include/a_sampmysql.inc"

I dont know what I need to run my serv normal
Reply
#2

pawn Код:
#include "../include/a_sampmysql.inc"
This for what?

pawn Код:
#include <a_samp>
#include <a_mysql>
You should put your include file (a_samp.inc & a_mysql.inc), in your pawno's include folder.
Reply
#3

Put those file on your pawno include folder like ^he said and the errors should go away
Reply
#4

I did what you said but still same problem.
I changed the account. This one is better :P
Reply
#5

Quote:
Originally Posted by sebacol
I created this script:
Код:
	if (strcmp("/alogin", cmdtext, true, 10) == 0)
	{
new name[250];
GetPlayerName(playerid ,name, 200);
new query[300];
new pass;
pass = cmdtext[1];
format(query, sizeof(query), "SELECT * FROM admins WHERE name='%s' AND pass='%s'",name,pass);
new num;
num = mysql_num_rows(mysql_query(query));
if(num == 0){
new trys;
trys = mysql_fetch_field_row(query, "trys");
if(trys == 1){
SendClientMessage(playerid, 0xAA3333AA, "You are kicked because you tryed to login into admin area.");
Kick(playerid);
}else{
SendClientMessage(playerid, 0xAA3333AA, "Sorry, try it again");
format(query, sizeof(query), "UPDATE admins SET trys='1' WHERE name='%s'",name);
mysql_query(query);
}
}else{
SendClientMessage(playerid, 0xAA3333AA, "You are now logged in as administrator");
new querya[210];
format(querya, 200, "UPDATE admins SET login='1' WHERE name='%s' AND pass='%s'",name,pass);
mysql_query(querya);
}

		return 1;
	}


And pawno see that everything is fine but when I start exe it shows this:Script[gamemodes/Server.amx]: Run time error 19: "File or function is not found"
on config I have: plugins sampmysql

and on pawno i have: #include <a_samp>
#include <a_mysql>
#include "../include/a_sampmysql.inc"

I dont know what I need to run my serv normal
Oh, my mistake. I tought you get error at compile.
You must have the Server.amx file inside your 'gamemodes' folder.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)