PDA

View Full Version : Help me.


Libbyphay
28/07/2018, 10:49 AM
I'm using Gamemode NGG v2, but i updated Mysql R40 for my gamemode.

[MySQL] (Main Pipelines) Connecting to 127.0.0.1...
[MySQL] (MainPipeline) Fatal Error! Could not connect to MySQL: Host 127.0.0.1 - DB: testgm - User: root
[MySQL] Note: Make sure that you have provided the correct connection credentials.
[MySQL] Error number: -1

How to repair it?

JasonRiggs
28/07/2018, 10:50 AM
You're using wrong information to login to the database.. Correct the information.

Libbyphay
28/07/2018, 10:52 AM
You're using wrong information to login to the database.. Correct the information.

Where?

JasonRiggs
28/07/2018, 10:54 AM
Inside your gamemode or a configuration file..

Libbyphay
28/07/2018, 10:57 AM
https://sv1.uphinhnhanh.com/images/2018/07/28/Untitled93a57.png

Gamemode NGG is using mysql.cfg, and i changed it same.

Libbyphay
28/07/2018, 11:05 AM
I changed
if(mysql_errno(MainPipeline) != 0)
{
printf("[MySQL] (MainPipeline) Fatal Error! Could not connect to MySQL: Host %s - DB: %s - User: %s", SQL_HOST, SQL_DB, SQL_USER);
print("[MySQL] Note: Make sure that you have provided the correct connection credentials.");
printf("[MySQL] Error number: %d", mysql_errno(MainPipeline));
SendRconCommand("exit");
}
else print("[MySQL] (MainPipeline) Connection successful toward MySQL Database Server!");

to:

if(mysql_errno(MainPipeline) != -1)
{
printf("[MySQL] (MainPipeline) Fatal Error! Could not connect to MySQL: Host %s - DB: %s - User: %s", SQL_HOST, SQL_DB, SQL_USER);
print("[MySQL] Note: Make sure that you have provided the correct connection credentials.");
printf("[MySQL] Error number: %d", mysql_errno(MainPipeline));
SendRconCommand("exit");
}
else print("[MySQL] (MainPipeline) Connection successful toward MySQL Database Server!");

and it working, i want reply real fine with it.