SA-MP Forums Archive
few errors in script help please - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: few errors in script help please (/showthread.php?tid=347075)



few errors in script help please - yvoms - 31.05.2012

I currently am creating my own Cops and robbers,
But since im new to Mysql and so I get a few errors wich i dont know how to fix it.

The script can be found here :
http://pastebin.com/5Xa0FyAQ

And i get the following errors and warnings..
Код:
(127) : error 017: undefined symbol "mysql_init"
(127) : warning 213: tag mismatch
(128) : warning 213: tag mismatch
(128) : warning 202: number of arguments does not match definition
Please help me.


Re: few errors in script help please - zombieking - 31.05.2012

The syntax of mysql_connect is:
pawn Код:
mysql_connect(const host[], const user[], const database[], const password[])
For mysql_init:

You will need SA:MP MySQL Plugin , download that here:

https://sampforum.blast.hk/showthread.php?tid=122983

While you have this version:
https://sampforum.blast.hk/showthread.php?tid=56564

Which lacks mysql_init function


Re: few errors in script help please - yvoms - 31.05.2012

To be honest,
If u can see i defined it as
MYSQL_HOSTNAME
MYSQL_USERNAME
MYSQL_PASSWORD
MYSQL_DATABASE

On top of the script.


Re: few errors in script help please - yvoms - 31.05.2012

https://sampforum.blast.hk/showthread.php?tid=122983


Has no downloadlink for windows :3


Re: few errors in script help please - Nicks - 31.05.2012

You need To Dawland New mysql_init


Re: few errors in script help please - yvoms - 31.05.2012

Found a mirror 2.X
http://www.strickenkid.sacnr.com/mys...indows_2.0.rar

Fixed all errors,
Only on line 128
I get this error:
Код:
warning 202: number of arguments does not match definition
Know how to fix?


Re: few errors in script help please - MadeMan - 31.05.2012

pawn Код:
mysql_connect(MYSQL_HOSTNAME, MYSQL_USERNAME, MYSQL_PASSWORD, MYSQL_DATABASE);



Re: few errors in script help please - zombieking - 31.05.2012

Really?

http://www.strickenkid.sacnr.com/mys...indows_2.1.rar - Download it from here


Re: few errors in script help please - yvoms - 31.05.2012

Somehow i get a error when i start up my server,
I didnt use any plugins but it gives me a Error?
This is my server.txt

Код:
echo Executing Server Config...
lanmode 1
rcon_password Koelkast
maxplayers 500
port 7777
hostname SA-MP 0.3 Server
gamemode0 YCNR 1
filterscripts gl_actions gl_property gl_realtime gl_mapicon ls_elevator test_cmds ls_mall attachments
announce 0
plugins 
query 1
weburl www.sa-mp.com
onfoot_rate 40
incar_rate 40
weapon_rate 40
stream_distance 300.0
stream_rate 1000
maxnpc 0
logtimeformat [%H:%M:%S]
This is the Server_log.txt
Код:
SA-MP Dedicated Server
----------------------
v0.3e, ©2005-2012 SA-MP Team

[13:53:24] 
[13:53:24] Server Plugins
[13:53:24] --------------
[13:53:24]  Loaded 0 plugins.

[13:53:24] 
[13:53:24] Filterscripts
[13:53:24] ---------------
[13:53:24]   Loading filterscript 'gl_actions.amx'...
[13:53:24]   Loading filterscript 'gl_property.amx'...
[13:53:24] 
-----------------------------------
[13:53:24] Grand Larceny Property Filterscript		
[13:53:24] -----------------------------------

[13:53:24]   Loading filterscript 'gl_realtime.amx'...
[13:53:24]   Loading filterscript 'gl_mapicon.amx'...
[13:53:24]   Loading filterscript 'ls_elevator.amx'...
[13:53:24]   Loading filterscript 'test_cmds.amx'...
[13:53:24]   Loading filterscript 'ls_mall.amx'...
[13:53:24]   Loading filterscript 'attachments.amx'...
[13:53:24]   Loaded 8 filterscripts.

[13:53:24] Reading File: blank
[13:53:24] Reading File: properties/houses.txt
[13:53:25] Reading File: properties/businesses.txt
[13:53:25] Reading File: properties/banks.txt
[13:53:25] Reading File: properties/police.txt
[13:53:25] Script[gamemodes/YCNR.amx]: Run time error 19: "File or function is not found"
[13:53:25] Number of vehicle models: 0



Re: few errors in script help please - zombieking - 31.05.2012

You NEED to put the plugins you used in your Gamemode in server.cfg else it wont work