This site is a testing version, but all data is shared with the live forum.


Raised This Month: $ Target: $400
 0% 

How to find SM & MM Version Number


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Potato Uno
Veteran Member
Join Date: Jan 2014
Location: Atlanta, Georgia
Old 11-01-2015 , 00:08   How to find SM & MM Version Number
Reply With Quote #1

Is there a way to find the version number for SM & MM from within the /addons/ directory alone? Is it stored in some text file just like steam.inf contains the server version?

While I was searching for such a file, I found this on my server: "blacklist.plugins.txt" What is it and why does it exist?

Thanks!
Potato Uno is offline
Squallkins
AlliedModders Donor
Join Date: Mar 2005
Old 11-01-2015 , 01:06   Re: How to find SM & MM Version Number
Reply With Quote #2

If you have sm logs enabled , you will see an entry for sm version at the start of each log file
Squallkins is offline
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 11-01-2015 , 05:14   Re: How to find SM & MM Version Number
Reply With Quote #3

For Windows you can look at the dll files properties, there is no sane way for both on Linux - running something like the following should work

Code:
strings path/to/binary.so | grep '^1\.[0-9]*\.[0-9]*'
Code:
[root@fennec ~]# strings addons/metamod/bin/metamod.2.tf2.so | grep '^1\.[0-9]*\.[0-9]*'
1.11.0-dev+998
[root@fennec ~]# strings addons/sourcemod/bin/sourcemod.2.tf2.so | grep '^1\.[0-9]*\.[0-9]*'
1.8.0.5757
[root@fennec ~]# tar -xzf sourcemod-1.7.3-git5272-linux.tar.gz 
[root@fennec ~]# strings addons/sourcemod/bin/sourcemod.2.tf2.so | grep '^1\.[0-9]*\.[0-9]*'
1.7.3-dev+5272
blacklist.plugins.txt contains the hashes of malicious (those with URLs) or illegally-distributed plugins that are blocked from loading.
__________________
asherkin is offline
Potato Uno
Veteran Member
Join Date: Jan 2014
Location: Atlanta, Georgia
Old 11-01-2015 , 09:59   Re: How to find SM & MM Version Number
Reply With Quote #4

This is on windows. What dll files do I need to peek into to get the version numbers? There are like 40 and opening them in notepad++ isn't exactly pleasant.

I'm searching for this information so that I know if the server has the latest SM/MM version or needs an SM/MM update, etc.

EDIT: The SM VM dll (sourcepawn.jit.x86.dll) has "1.7.3-dev+5272" in it. Need to find metamod next.

EDIT 2: I found it in metamod.2.tf2.dll but it's a mess. Come on guys, can't you do something like add a "version.txt" with the build number in it for newer snapshots? From an automatic upgrading standpoint it would be fantastic.

Last edited by Potato Uno; 11-01-2015 at 10:09.
Potato Uno is offline
asherkin
SourceMod Developer
Join Date: Aug 2009
Location: OnGameFrame()
Old 11-01-2015 , 10:06   Re: How to find SM & MM Version Number
Reply With Quote #5

I quite clearly said properties, not a text editor (and included paths to files that have version info for both in my Linux example.)
Attached Thumbnails
Click image for larger version

Name:	Screenshot 2015-11-01 15.04.56.png
Views:	113
Size:	16.5 KB
ID:	149341  
__________________

Last edited by asherkin; 11-01-2015 at 10:06.
asherkin is offline
Potato Uno
Veteran Member
Join Date: Jan 2014
Location: Atlanta, Georgia
Old 11-01-2015 , 10:11   Re: How to find SM & MM Version Number
Reply With Quote #6

That's not helpful for the automatic SM/MM updater I'm making. I need to be able to get it from file I/O.

So unless there's a way to get that exact information from running something on the OS command line it looks like I have to regex the dll (which is nasty).

Last edited by Potato Uno; 11-01-2015 at 10:13.
Potato Uno is offline
psychonic

BAFFLED
Join Date: May 2008
Old 11-01-2015 , 10:42   Re: How to find SM & MM Version Number
Reply With Quote #7

Quote:
Originally Posted by Potato Uno View Post
That's not helpful for the automatic SM/MM updater I'm making. I need to be able to get it from file I/O.

So unless there's a way to get that exact information from running something on the OS command line it looks like I have to regex the dll (which is nasty).
There are command line tools that will dump it, or since you're on Windows and trying to script something, perhaps you're using PowerShell:
Code:
(Get-Item sourcemod.2.csgo.dll).VersionInfo.FileVersion
1.8.0.5715

Last edited by psychonic; 11-01-2015 at 10:42.
psychonic is offline
Wliu
Veteran Member
Join Date: Apr 2013
Old 11-01-2015 , 16:41   Re: How to find SM & MM Version Number
Reply With Quote #8

addons/sourcemod/scripting/include/version_auto.inc also contains all the info you need.
__________________
~Wliu
Wliu is offline
Reply



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 14:24.


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