[Portal 2] Extras menu patcher for custom maps

Avatar
Haapavuo
30 Posts
Posted Apr 28, 2011
Hi!

Today I have been working on a program which allows user to add custom maps to the Portal 2 Extras menu!

It is very easy to use: It will automatically get your portal2.exe path & map name in the folder where the patcher is. Just set the ID, title and subtitle. You can also set a picture for your map (not necessary). The map ID can be the same as map name (without any spaces!).

The program can save settings to an ini file to make patching even easier.

In future, I will add new features to the program, such as copying maps to the portal 2 maps folder.

The program is made using Visual C# 2010 Express so I guess it'll need the Visual Runtime to be installed.

Please post your comments & ideas to this topic! Thanks for reading & testing the program!

Download: http://haapavuo.hostcell.net/Portal2ExtrasPatcher.zip

Mirror #2: Portal 2 Extras Menu Patcher

Advertisement
Registered users don’t see ads! Register now!
Avatar
Nightgunner5
75 Posts
Posted Apr 28, 2011
Replied 25 minutes later
This looks like it would require either to be packed with map downloads or to have its configuration file modified by the end user for each map. Would it be possible to store the information other than the Portal 2 path in a different file that can be included with a map?

Also, you may want to use the VGAME environment variable to get an initial value for the Portal 2 path.

Avatar
Haapavuo
30 Posts
Posted Apr 28, 2011
Replied 9 minutes later

Nightgunner5 wrote:
This looks like it would require either to be packed with map downloads or to have its configuration file modified by the end user for each map. Would it be possible to store the information other than the Portal 2 path in a different file that can be included with a map?

Also, you may want to use the VGAME environment variable to get an initial value for the Portal 2 path.

Thanks for your reply!

I was thinking that every map maker could put this program into the same package with their maps with a modified settings.ini. So the end user wouldn't have to change anything else than the Portal 2 executable path. I'll see if I can find the path somehow "automatically".

Avatar
Nightgunner5
75 Posts
Posted Apr 28, 2011
Replied 11 minutes later

Haapavuo wrote:
Nightgunner5 wrote:

This looks like it would require either to be packed with map downloads or to have its configuration file modified by the end user for each map. Would it be possible to store the information other than the Portal 2 path in a different file that can be included with a map?

Also, you may want to use the VGAME environment variable to get an initial value for the Portal 2 path.

Thanks for your reply!

I was thinking that every map maker could put this program into the same package with their maps with a modified settings.ini. So the end user wouldn't have to change anything else than the Portal 2 executable path. I'll see if I can find the path somehow "automatically".

Packaging the program with every map would create the problem of every map having a different version of this program. When you release an update to this program, every map on the site will need to be updated.

Packaging just a configuration file would solve that problem, at least.

Avatar
Player1
212 Posts
Posted Apr 28, 2011
Replied 15 minutes later
Well considering that whatever version of the tool it was packaged with will support what you need there should be no need to update maps later just because of an update to the program.

But unless this can 100% figure out the install path by itself I don't think it's gonna be of much use.

Avatar
Haapavuo
30 Posts
Posted Apr 28, 2011
Replied 16 minutes later
Yes. Packaging only the settings.ini file should be just fine. The program itself could be downloaded externally.

Player1 wrote:
But unless this can 100% figure out the install path by itself I don't think it's gonna be of much use.

I'm going to try to do this by getting the path from a running steam process. To my knowledge, Portal 2 is always installed in the steamapps\common folder.

Avatar
Sidneys1
89 Posts
Posted Apr 28, 2011
Replied 19 minutes later

Haapavuo wrote:
...To my knowledge, Portal 2 is always installed in the steamapps\common folder.

Yes, but what if someone didn't install steam to "Program Files"? It's better to check the steam install path first via the registry:
HKEY_LOCAL_MACHINE\SOFTWARE\Valve\Steam, keyname: InstallPath.

Have a nice day,
~Sidneys1

Avatar
msleeper
4,136 Posts
Admin
Posted Apr 28, 2011
Replied 24 minutes later
Upload files to the Download Database please. Don't link to external sites.
Avatar
Haapavuo
30 Posts
Posted Apr 29, 2011
Replied 10 hours later

Sidneys1 wrote:
Haapavuo wrote:

...To my knowledge, Portal 2 is always installed in the steamapps\common folder.

Yes, but what if someone didn't install steam to "Program Files"? It's better to check the steam install path first via the registry:
HKEY_LOCAL_MACHINE\SOFTWARE\Valve\Steam, keyname: InstallPath.

Have a nice day,
~Sidneys1

I already said that I was going to check the path from the running steam process. But maybe the register is a better idea. Thanks!

I will also add radio buttons so user can select whether he wants the new item to be added on top or to the bottom of the menu.

Avatar
Haapavuo
30 Posts
Posted Apr 29, 2011
Replied 1 hour later
Sorry for the double post but I have now updated the program. It will now automatically get your portal2.exe path from Windows registry and see if there is a map file in the folder where the patcher is. This should make patching very easy!

I will soon release a "simpler" version which could be released with maps.

EDIT: I added the program to the database of this site.

Advertisement
Registered users don’t see ads! Register now!
Avatar
Hober
1,180 Posts
Posted Apr 29, 2011
Replied 7 hours later
This has been uploaded to the Download Database, so I'm locking this. Further comments over there.