MySQL won't connect + Run Time Errors
#1

I'm using StrickenKid's MySQL plugin: https://sampforum.blast.hk/showthread.php?tid=122983

I can't seem to connect the script with the database, it compiles no problem. What keeps me wondering, is whether WAMP is required to connect to MySQL? I have a MySQL server on my computer installed with Apache, and I run several websites on multiple databases. I have created a database for the server, filled the data in, however it will not connect.

Port for MySQL is 3307, and Apache 8080. This is the error from the debug:

Код:
[13:59:24] >> mysql_connect( )

[13:59:24] CMySQLHandler::CMySQLHandler() - constructor called.

[13:59:24] CMySQLHandler::CMySQLHandler() - Connecting to "localhost:3307" | DB: "satc" | Username: "satc" ...

[13:59:26] CMySQLHandler::Connect() - Unknown MySQL server host 'localhost:3307' (11004) (Error ID: 2005)
And these are the settings inside the script, there is no password for the user.

Код:
#define mysql_host                                            	"localhost:3307"
#define mysql_user                                              "satc"
#define mysql_password                                          " "
#define mysql_database                                          "satc"
I also have an error in the console, Run Time Error 4, which I suspect could have a connection to this, as I have been upgrading only recently to 0.3x. With the old installation, I had no errors. I'll post them just in case

Код:
[13:59:26] Objects loaded from LoadObjects Database.
[13:59:26] 0 owned vehicles loaded from the MySQL Database.
[13:59:26] 0 vehicles loaded from the MySQL Database.
[13:59:26] 0 houses loaded from the MySQL Database.
[13:59:26] [debug] Run time error 4: "Array index out of bounds"
[13:59:26] [debug]   Accessing element at index 50 past array upper bound 49
[13:59:26] [debug] AMX backtrace:
[13:59:26] [debug] #0  000dc13c in ?? () from satc.amx
[13:59:26] [debug] #1  0001d764 in public S@@_OnGameModeInit () from satc.amx
[13:59:26] [debug] #2  native CallLocalFunction () [00471ef0] from samp-server.exe
[13:59:26] [debug] #3  0000ee54 in public ScriptInit_OnGameModeInit () from satc.amx
[13:59:26] [debug] #4  native CallLocalFunction () [00471ef0] from samp-server.exe
[13:59:26] [debug] #5  000098d0 in public RL_OnGameModeInit () from satc.amx
[13:59:26] [debug] #6  native CallLocalFunction () [00471ef0] from samp-server.exe
[13:59:26] [debug] #7  00009368 in public Itter_OnGameModeInit () from satc.amx
[13:59:26] [debug] #8  native CallLocalFunction () [00471ef0] from samp-server.exe
[13:59:26] [debug] #9  000069a4 in public zcmd_OnGameModeInit () from satc.amx
[13:59:26] [debug] #10 native CallLocalFunction () [00471ef0] from samp-server.exe
[13:59:26] [debug] #11 0000624c in ?? () from satc.amx
[13:59:26] [debug] #12 000005b4 in public OnGameModeInit () from satc.amx
[13:59:26] Number of vehicle models: 5
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)