Raised This Month: $12 Target: $400
 3% 

[ANY] Extended Speed Meter (v1.4, 2017-06-05)


Post New Thread Reply   
 
Thread Tools Display Modes
BoosterGold
Member
Join Date: Nov 2016
Old 12-31-2016 , 01:21   Re: [ANY] Extended Speed Meter (v1.3, 2015-09-08)
Reply With Quote #21

Hi Kiljon,

I've just tried your plugin with my CS:GO server. This is the error I get:

Quote:
L 12/30/2016 - 22:16:20: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
The server crashes and never appears in my server browser, so I'm not able to get in and try the sm plugins list command.

I'm not sure where I'd go to look to see if the table was created in the database.

Thank you for any work you put into this!

EDIT:
Quote:
PS: if you did not configure anything it will use the database in your "default" option in your settings (cstrike/addons/sourcemod/configs/databases.cfg)
I opened that file and I don't see anything relevant to the speedmeter plugin.

Last edited by BoosterGold; 12-31-2016 at 01:23.
BoosterGold is offline
SpicyGamers
Member
Join Date: Feb 2017
Location: Bragança
Old 06-19-2017 , 04:55   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #22

Command to remove HUD speed

Likes that in the near future could create a command to remove the current speed hud, for example activate and deactivate when we want, etc.
__________________
Check My Community www.SpicyGamers.com
SpicyGamers is offline
axelnieves2012
Senior Member
Join Date: Oct 2014
Location: Argentina
Old 08-29-2018 , 00:56   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #23

Working on Left 4 Dead 1, no-steam, last version 29-ago-2018
will report bugs if find any
axelnieves2012 is offline
Acuze
New Member
Join Date: Nov 2018
Old 11-25-2018 , 15:01   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #24

As it stands there are currently no functional versions of this plugin, the official version that has been posted isn't saving correctly to the database as a result of the this error.

L 11/25/2018 - 09:29:49: [SM] Exception reported: Invalid database Handle 0 (error: 4)
L 11/25/2018 - 09:29:49: [SM] Blaming: extendedspeedmeter.smx
L 11/25/2018 - 09:29:49: [SM] Call stack trace:
L 11/25/2018 - 09:29:49: [SM] [0] SQL_LockDatabase
L 11/25/2018 - 09:29:49: [SM] [1] Line 4014, E:\Dev\extended-speed-meter\addons\sourcemod\scripting\extendedspee dmeter.sp::SaveMapRecords
L 11/25/2018 - 09:29:49: [SM] [2] Line 489, E:\Dev\extended-speed-meter\addons\sourcemod\scripting\extendedspee dmeter.sp::OnMapEnd
L 11/25/2018 - 09:29:49: Error log file session closed.

Some of the 'alternate fixes' that we have tried so far have fixed the original issue with the database, but have each had their own individual issues such as not being able to disable the speed hud.

Game - CSGO
SM version - SourceMod 1.10.0.6356
Database - MYSQL

Last edited by Acuze; 11-25-2018 at 15:01.
Acuze is offline
kiljon
Junior Member
Join Date: Aug 2015
Old 11-26-2018 , 16:57   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #25

Quote:
Originally Posted by Acuze View Post
As it stands there are currently no functional versions of this plugin, the official version that has been posted isn't saving correctly to the database as a result of the this error.

L 11/25/2018 - 09:29:49: [SM] Exception reported: Invalid database Handle 0 (error: 4)
L 11/25/2018 - 09:29:49: [SM] Blaming: extendedspeedmeter.smx
L 11/25/2018 - 09:29:49: [SM] Call stack trace:
L 11/25/2018 - 09:29:49: [SM] [0] SQL_LockDatabase
L 11/25/2018 - 09:29:49: [SM] [1] Line 4014, E:\Dev\extended-speed-meter\addons\sourcemod\scripting\extendedspee dmeter.sp::SaveMapRecords
L 11/25/2018 - 09:29:49: [SM] [2] Line 489, E:\Dev\extended-speed-meter\addons\sourcemod\scripting\extendedspee dmeter.sp::OnMapEnd
L 11/25/2018 - 09:29:49: Error log file session closed.

Some of the 'alternate fixes' that we have tried so far have fixed the original issue with the database, but have each had their own individual issues such as not being able to disable the speed hud.

Game - CSGO
SM version - SourceMod 1.10.0.6356
Database - MYSQL
Well, it seems like something goes wrong while locking the database. It won't be able to correctly save/insert data if it can't lock the database first. Docs for reference

I can see you're running SM 1.10, this plugin has only been tested and verified with SM 1.6.2+ until SM 1.9 (6098-dev). Furthermore SM 1.10 has not been marked as stable yet. Stable builds reference Would it be possible to downgrade to stable SM 1.9 and try it again?

I would also like to know the list of other plugins you're running at the same time. Not trying to shift the blame here, but if they also save data to the database at the end of the map but they don't correctly close their database handle, then this plugin might not be able to correctly lock it. If I can see how this may become a more widespread problem, then I could add some safety checks. So can you give a list of running plugins? Did you also have the problem while only running this plugin + SM admin?

Could you also say what your 'alternate fixes' were? It seems like you are frustrated, I did not create this plugin to make people frustrated.

Can I also ask if this is your first version of the plugin running or did you run 1.0 and upgraded to 1.4 for example?
kiljon is offline
Acuze
New Member
Join Date: Nov 2018
Old 11-26-2018 , 23:34   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #26

Quote:
Originally Posted by kiljon View Post
Well, it seems like something goes wrong while locking the database. It won't be able to correctly save/insert data if it can't lock the database first. Docs for reference

I can see you're running SM 1.10, this plugin has only been tested and verified with SM 1.6.2+ until SM 1.9 (6098-dev). Furthermore SM 1.10 has not been marked as stable yet. Stable builds reference Would it be possible to downgrade to stable SM 1.9 and try it again?

I would also like to know the list of other plugins you're running at the same time. Not trying to shift the blame here, but if they also save data to the database at the end of the map but they don't correctly close their database handle, then this plugin might not be able to correctly lock it. If I can see how this may become a more widespread problem, then I could add some safety checks. So can you give a list of running plugins? Did you also have the problem while only running this plugin + SM admin?

Could you also say what your 'alternate fixes' were? It seems like you are frustrated, I did not create this plugin to make people frustrated.

Can I also ask if this is your first version of the plugin running or did you run 1.0 and upgraded to 1.4 for example?
We aren't able to downgrade to SM1.9 currently as multiple plugins are relying on SM1.10, but i don't see how it could be the cause since the version that you uploaded as a response to Kiljon and nco has a perfectly functioning database lock, but just doesn't have the functionality to disable the speedmeter hud; which in my eyes means that it is not an issue of plugins conflicting either.

The alternate fixes I had mentioned were the hot fixes that you posted in response to other peoples issues.
Acuze is offline
LionKing
Member
Join Date: Jan 2017
Location: Belgium
Old 01-11-2019 , 15:47   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #27

Possible to have plugin without Database?
LionKing is offline
LionKing
Member
Join Date: Jan 2017
Location: Belgium
Old 01-15-2019 , 12:03   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #28

L 01/15/2019 - 18:01:16: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
L 01/15/2019 - 18:01:16: [csgo_items.smx] UTF-8 language file successfully processed, retrieving item schema.
L 01/15/2019 - 18:01:16: [csgo_items.smx] Item Schema successfully retrieved.
L 01/15/2019 - 18:01:17: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
L 01/15/2019 - 18:01:18: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
L 01/15/2019 - 18:01:19: server_cvar: "sm_nextmap" "de_mirage_winter"
L 01/15/2019 - 18:01:19: [randomcycle.smx] RandomCycle has chosen de_mirage_winter for the nextmap.
L 01/15/2019 - 18:01:19: [extendedspeedmeter.smx] Extended Speed meter: Plugin stopped, reconnect counter reached max

// This sets which database config should be used to store the topspeed table in (check addons/sourcemod/configs/databases.cfg)
// -
// Default: "default"
sm_extendedspeedmeter_databaseconfigname "speedmeter"

I've setup a database for it on the database.cfg file. Changed the databaseconfigname in the cfg file, but even after it still remains on 'localhost' how do I fix this?
LionKing is offline
kiljon
Junior Member
Join Date: Aug 2015
Old 01-16-2019 , 03:23   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #29

Quote:
Originally Posted by LionKing View Post
L 01/15/2019 - 18:01:16: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
L 01/15/2019 - 18:01:16: [csgo_items.smx] UTF-8 language file successfully processed, retrieving item schema.
L 01/15/2019 - 18:01:16: [csgo_items.smx] Item Schema successfully retrieved.
L 01/15/2019 - 18:01:17: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
L 01/15/2019 - 18:01:18: [extendedspeedmeter.smx] Extended Speed meter: Connection to SQL database has failed: [2003]: Can't connect to MySQL server on 'localhost' (10061)
L 01/15/2019 - 18:01:19: server_cvar: "sm_nextmap" "de_mirage_winter"
L 01/15/2019 - 18:01:19: [randomcycle.smx] RandomCycle has chosen de_mirage_winter for the nextmap.
L 01/15/2019 - 18:01:19: [extendedspeedmeter.smx] Extended Speed meter: Plugin stopped, reconnect counter reached max

// This sets which database config should be used to store the topspeed table in (check addons/sourcemod/configs/databases.cfg)
// -
// Default: "default"
sm_extendedspeedmeter_databaseconfigname "speedmeter"

I've setup a database for it on the database.cfg file. Changed the databaseconfigname in the cfg file, but even after it still remains on 'localhost' how do I fix this?
First off about your question without a database, it kind of defeats the purpose of this extension. But I know that the original one is not fixed for CSGO so I can see why you want this. I have to do a lot of changes to make this possible. I'll see if I can get it done in the weekend.

About your question that it continues to use localhost. Are you running MySQL or SQLite on the external server?

And would you mind sharing your config file (without passwords/ip addresses etc)?
It should look something like this:

"Databases"
{
"driver_default" "mysql"

// When specifying "host", you may use an IP address, a hostname, or a socket file path

"default"
{
"driver" "default"
"host" "ip.address.of.server"
"database" "sourcemod"
"user" "YYYYY"
"pass" "ZZZZZ"
//"timeout" "0"
"port" "3306"
}

"speedmeter"
{
"driver" "default"
"host" "ip.address.of.server"
"database" "XXXXX"
"user" "YYYYY"
"pass" "ZZZZZ"
//"timeout" "0"
"port" "3306"
}
}

Are you also sure that the sourcemod server can connect to the MySQL external server? You might have to enable some firewall rules and possibly allow the ip address of your sourcemod server. If you are able to connect with command line to your server (through telnet/SSH), you can try "mysql -u {user} -p {pass} -h {host} -P {port} -D {database}" to verify that the connection works.
kiljon is offline
Xutax_Kamay
Member
Join Date: Feb 2016
Old 03-11-2019 , 21:12   Re: [ANY] Extended Speed Meter (v1.4, 2017-06-05)
Reply With Quote #30

On line 3590~ there is a bug that needs to be solved

Code:
        bool bInitHighestSpeedrecord = false;

	// Get the records if there are any
	if (SQL_GetRowCount(hQuery) > 0)
	{
		// Fetch Data per Row
		while (SQL_FetchRow(hQuery))
		{
			// Fetch the values
			SQL_FetchString(hQuery, 0, clientSteamId, sizeof(clientSteamId));
			SQL_FetchString(hQuery, 1, clientName, sizeof(clientName));
			topspeed = Float:SQL_FetchFloat(hQuery, 2);

			SQL_FetchString(hQuery, 3, topspeedTimeStamp, sizeof(topspeedTimeStamp));
			
			// Easy debug
			PrintToServer("############# GET RECORD #############");
			PrintToServer("%s %s %f %s %s", clientSteamId, clientName, topspeed, topspeedTimeStamp, map);
			PrintToServer("############# ---------- #############");
			
			// Save it locally
			if (StrEqual(map, g_sCurrentMap, false))
			{
				PushArrayString(g_hRecordSteamId, clientSteamId);
				PushArrayString(g_hRecordName, clientName);
				PushArrayCell(g_hRecordMaxSpeed, topspeed);
				PushArrayString(g_hRecordMaxSpeedTimeStamp, topspeedTimeStamp);
				
							
				if (!bInitHighestSpeedrecord)
				{
					g_fHighestSpeedrecord = topspeed;
					bInitHighestSpeedrecord = true;
				}

				// Save the current highest speedrecord
				if (topspeed > g_fHighestSpeedrecord)
				{
					g_fHighestSpeedrecord = topspeed;
				}
			}
The problem before is that it didn't reset the top speed record if it was lower for a different map. Hopefully it's going to help someone

Last edited by Xutax_Kamay; 03-11-2019 at 21:14.
Xutax_Kamay is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 11:38.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode