Mod IDs in Steam

Grab your favourite IDE and tinker with the innards of game engines

Mod IDs in Steam

Postby planetphillip on Tue Jul 01, 2014 7:53 am

Hi All,

Many of you may know an application I make available on my site called MapTap (http://www.planetphillip.com/maptap/) which installs maps and mods for Half-Life games.

Its main benefit is that automates the process which is especially useful for people who play lots of maps, but there are others benefits too.

It can install mods but currently can not run them. Users use MapTap to install and then use Steam to run them. It can run maps directly from within the main applciation window

We, myself and Alex the coder, would like to allow users to run the mods from the application too.

The problem is that we can't figure out how Steam creates the ID for each mod. With the ID, we can allow users to install AND play from within the application.

We know it's possible because Desura does it. We haven't contacted them because we thought we would try here first, along with some other avenues of investigation.

So, does anybody know how Steam creates the ID for each mod?

I hope I have explained myself clearly, but if not, please ask for clarification and I or Alex will respond ASAP.

TIA
http://www.planetphillip.com
Finishing Half-Life is just the beginning!
Single Player First Person Shooter Maps and Mods for ALL Half-Life games
User avatar
planetphillip
Regular
Regular
 
Joined: Wed Aug 01, 2007 2:11 pm
Location: Bilbao, Spain

Re: Mod IDs in Steam

Postby Dr. Delta on Tue Jul 01, 2014 9:03 am

I've wondered about this myself too, but sadly enough I know little more than they're always 20 characters long, and it appears to be a random 0-9 number string. Perhaps someone else has any idea?
User avatar
Dr. Delta
Veteran
Veteran
 
Joined: Thu Dec 27, 2007 1:18 pm
Location: People's Republic of Porygon

Re: Mod IDs in Steam

Postby planetphillip on Tue Jul 01, 2014 11:10 am

I don't believe it's random. Alex installed a mod on his system which uses a non-standard location for Steam and I installed the same mod on mine and the ID was exactly the same.
http://www.planetphillip.com
Finishing Half-Life is just the beginning!
Single Player First Person Shooter Maps and Mods for ALL Half-Life games
User avatar
planetphillip
Regular
Regular
 
Joined: Wed Aug 01, 2007 2:11 pm
Location: Bilbao, Spain

Re: Mod IDs in Steam

Postby Surfa on Tue Jul 01, 2014 1:00 pm

I always thought they were just a standard set of 4 depending on which version of the engine is used.

2006: 215
2007: 218
2013 SP: 243730
2013 MP: 243750

I think Alien Swarms is different as well but can't remember/don't have it written down.

Edit: Hang on I think I might have got a little confused as to what you were asking.

Right sorry little mix up. I did get slightly confused there. Could you not just use the open-steamworks library to calculate it for you.
https://github.com/SteamRE/open-steamworks

It looks like it is calculated based on the AppID and the modpath.
Surfa
May Contain Skills
May Contain Skills
 
Joined: Sun Dec 30, 2007 3:04 pm

Re: Mod IDs in Steam

Postby planetphillip on Tue Jul 01, 2014 1:42 pm

Thanks for the link to the Open Steamworks page. We'll follow that up.
http://www.planetphillip.com
Finishing Half-Life is just the beginning!
Single Player First Person Shooter Maps and Mods for ALL Half-Life games
User avatar
planetphillip
Regular
Regular
 
Joined: Wed Aug 01, 2007 2:11 pm
Location: Bilbao, Spain

Re: Mod IDs in Steam

Postby Gambini on Tue Jul 01, 2014 10:04 pm

I think i once figured a way to know that:

Take a screenshot of the mod you want to figure its ID. When the steam screenshot manager pops up, click on "show locals". It will open an explorer window with the location the screenshots are, in the route you will find the mod´s ID. For example: userdata\youruserID\760\remote\11830045335865000356 < This is the mod ID AFAIK.
User avatar
Gambini
Sir Post-a-lot
Sir Post-a-lot
 
Joined: Mon Oct 20, 2008 1:52 am
Location: Buenos Aires, Argentina.

Re: Mod IDs in Steam

Postby [Steve] on Tue Jul 01, 2014 11:28 pm

Sorry if this is a stupid reply, Its possible that I might have not understood correctly, but the aim is to get your 3rd party application to launch various mods?

If so why couldn't you do it the same way it does in say visual studio for example and just launch hl2.exe with the -game parameter to specify the mods folder.
Also this would mean mods wouldnt even need to have been placed in source mods folder. They could be for example be in a maptap/mods/ folder.
I'm assuming your app is already reading the gameinfo.txt for each mod, which would make it even easier.

I'm also not sure what getting the id that steam assigns a mod would achieve?

Perhaps your wanting to do something like

Code: Select all
steam://rungameid/<modsID>


You can also achive the same result doing this

Code: Select all
"Steam.exe" -applaunch 420 -dev -console -game "F:\Program Files (x86)\Steam\steamapps\sourcemods\HobnobsAdventure"


Parse the gameinfo.txt for each mod folder in the directory.
Make use of the title, author and App Id strings, use these to populate your launch options for that specific mod.
This would be my method as you could let the user launch with extra parameters such as window, dev or a specific map straight from your application.
User avatar
[Steve]
Interlopers Staff
Interlopers Staff
 
Joined: Fri Mar 06, 2009 11:25 pm

Re: Mod IDs in Steam

Postby planetphillip on Wed Jul 02, 2014 5:28 am

I think i once figured a way to know that:

Thanks, but I need to do it programmatically. You can quickly do it manually by creating a shortcut of the mod on your desktop in Steam and the shortcut will display the ID.

You can also achive the same result doing this

I can't get your example to work. Obviously, I changed the mod name to one I have and the drive letter, but it just opens a bing search.

Could you be a little more specific in where that code needs to be. I used it in a shortcut on the desktop. TIA

EDIT
I managed to get it to work by putting the full path to Steam, like this:
"C:\Program Files (x86)\Steam\Steam.exe" -applaunch 420 -dev -console -game "C:\Program Files (x86)\Steam\steamapps\sourcemods\DiamondDogsVille"

I'll test it on the non-source mods, but you could just have made our life very easy, thanks.

EDIT 2
Unfortunately, it doesn't seem to work on the non-source mods. I won't do any more testing until Alex has had a chance to test it.
http://www.planetphillip.com
Finishing Half-Life is just the beginning!
Single Player First Person Shooter Maps and Mods for ALL Half-Life games
User avatar
planetphillip
Regular
Regular
 
Joined: Wed Aug 01, 2007 2:11 pm
Location: Bilbao, Spain

Re: Mod IDs in Steam

Postby YokaI on Mon Jul 07, 2014 9:43 am

For various reasons, it would be best to use Steam's browser protocol. Perhaps it isn't in the scope of your software now, but ideally you should target your software for platform independence. Using this:

Code: Select all
"C:\Program Files (x86)\Steam\Steam.exe" -applaunch 420 -dev -console -game "C:\Program Files (x86)\Steam\steamapps\sourcemods\DiamondDogsVille"


...may work for your specific windows machine but will not work in scenarios in which the user is using a custom install directory or if the user is using a non-windows operating system.

Steam Browser Protocol is designed to be cross platform, and once you learn to launch an application on one operating system, it should work in almost every other operating system. Couldn't you fetch a list of all of the users game IDs using steams web API and filter which ones you need based on the mods that the software has installed?
YokaI
Forum Goer Elite™
Forum Goer Elite™
 
Joined: Fri Dec 03, 2004 12:38 am

Re: Mod IDs in Steam

Postby planetphillip on Mon Jul 07, 2014 12:26 pm

Thanks for your reply.

Ideally, we would prefer to use the Steam Browser Protocol, but the software only works with Windows and we know the exact path of the users installation, even if it is non-standard, as we have to install the maps and mods into the right place.

I don't know if the web API will tell us which mods they have installed or exactly how that would help us. We'll look into it.
http://www.planetphillip.com
Finishing Half-Life is just the beginning!
Single Player First Person Shooter Maps and Mods for ALL Half-Life games
User avatar
planetphillip
Regular
Regular
 
Joined: Wed Aug 01, 2007 2:11 pm
Location: Bilbao, Spain

Return to Programming

Who is online

Users browsing this forum: No registered users

cron