potterr on 3/9/2005 at 11:41
I'm looking for a few FM makers to test a T3 ini file patch system in the next version of GarrettLoader.
The system works like so:
Any of the T3 ini files (with exception to the editorprefs.ini file) are included.If you want to change any ini file settings (like the PCVertexPools) on the end users PC you will need to create a file of the same name as the ini file to be patched but with "
_patch" in the name, e.g.
user.ini becomes
user_patch.ini. This also needs to located in the same location as the original (i.e. for
user.ini in the root of the T3 install for all others in the T3 system folder).
Now in the patch ini file you will need to put the specific sections you require to be patched.
e.g.
Code:
[PCVertexPools]
DynamicVertexPool0=31457280
StaticVertexPool=26214400
StaticShadowVertexPool=15728640
would need to be in the user_patch.ini file if you want to update the vertext pools.
You wouldn't, however, need to include the other details e.g.
Code:
[BlockLoading]
LoadFromResourceBlockFiles=True
[Source Control]
UseSourceSafe=0
[Engine.Engine]
UpdateGameSys=0
Just the ini file items that need to be changed!!When GarrettLoader installs an FM it will unzip your patch ini file to the specified location. Then when the
PLAY button is pressed, GL will do a quick scan for any previously backed up (see below) ini files and restore them.
Then it will do another quick scan for new patch files, if it finds some it will create new backups of the originals (e.g.
user.ini.GLBU), go through the files and update the original ini file sections that you have specified in your patch files.
The reason its done like this is so that peoples tweaks are kept as is (unless you have it specified in your patch ini). So for people with the minimalist project or other lootglint and frob colour tweaks remain the same if all you are wanting to do is adjsut the health bar image.
Anyway I am looking for a couple of people to test this next week in the next beta of GarrettLoader, reply to this post and send me a PM as well.
SIDE NOTE: you will be using a beta version so back up any FMs you are working on (3 times to be on the safe side ;) ).
Also GL was designed for a single install of T3, one of the problems at the moment is that GL uses the registry to specify where save games will end up being taken from and zipped up and unzipped to. The problem there though seems to be that teh registry entry used
HKEY_LOCAL_MACHINE\SOFTWARE\Ion Storm\Thief - Deadly Shadows\SaveGamePath and
HKEY_LOCAL_MACHINE\SOFTWARE\Ion Storm\Thief - Deadly Shadows\ION_ROOT seems to change depending upon if you last used the editor install or the playing install. This is something I need to work out a better way of doing before the next release.
Thanks in advance. :thumb:
potterr on 11/9/2005 at 08:53
I take it no-one has any ini file updates that they require testing?
ProjectX on 11/9/2005 at 09:23
I need to finish my FM first.
ascottk on 11/9/2005 at 15:57
I needed to add settings for hand drawn maps & the ini patch seems to work. The settings show up in the user.ini.
Rantako on 11/9/2005 at 17:05
potterr,
About the registry thing and dual install you mentioned - I assume the problems are caused by the Thief 3 Launcher program. I think it works by specifying your two paths (game and editor) and changes the registry value depending on which you launch - but doesn't change it back to the game path afterwards. Perhaps you could build something into GL that checks the registry value and changes it to the game one whenever GL is started, this way GL would never accidentally overwrite anything in the editor install.
[Long explanation] Alternatively, another way to do the dual install (this is how I work it) is to have your two TDS folders, called C:\Thief3 and C:\Thief3Edit and swap their names to use the different one (so if you want the game, you have that folder called Thief3, and if you want to use the editor, you rename that folder to Thief3 and rename the game folder to something else). This method means you don't have to mess with the registry. Also, you could have GL check if the file Thief3\System\T3Ed.exe exists before installing an FM - if it does, you are currently in the editor folder and GL would swap the folders before doing anything else, if it doesn't exist then you are in the game folder and everything is fine. [/Long explanation]
Just a suggestion...
potterr on 11/9/2005 at 22:07
Quote Posted by Rantako
About the registry thing and dual install you mentioned - I assume the problems are caused by the Thief 3 Launcher program. I think it works by specifying your two paths (game and editor) and changes the registry value depending on which you launch - but doesn't change it back to the game path afterwards. Perhaps you could build something into GL that checks the registry value and changes it to the game one whenever GL is started, this way GL would never accidentally overwrite anything in the editor install.
[Long explanation] Alternatively, another way to do the dual install (this is how I work it) is to have your two TDS folders, called C:\Thief3 and C:\Thief3Edit and swap their names to use the different one (so if you want the game, you have that folder called Thief3, and if you want to use the editor, you rename that folder to Thief3 and rename the game folder to something else). This method means you don't have to mess with the registry. Also, you could have GL check if the file Thief3\System\T3Ed.exe exists before installing an FM - if it does, you are currently in the editor folder and GL would swap the folders before doing anything else, if it doesn't exist then you are in the game folder and everything is fine. [/Long explanation]
Just a suggestion...
This would explain a lot, I will see if I can come up with a checking process for this. Although just for reference GL does not use the registry stuff for FM extraction, it uses the path specified when you choose your T3.exe in GLs settings. It does however only use the registry for save game zipping and unzipping (GL offers to move the saves some people may not take the offer up as they may have saves in a different location) as saves could be anywhere on any hard drive for T3.
GlasWolf on 26/9/2005 at 19:47
I've just installed Gonchong's new version of Special Vintage, and noticed that the ini patch thing seems to be doing something a little odd. I have one non-default setting in my user.ini to stop the intro videos playing, but when I install the FM I lose that setting. In fact, GL appears to install and patch a completely different copy of the user.ini. If I revert back to the OMs then my user.ini reverts fine too. It doesn't appear to be a problem with SV's user_patch.ini, just the source ini file GL is modifying. Am I missing something?
potterr on 26/9/2005 at 20:07
Sounds like it GlasWolf. The process GL uses is that it will unzip the FM then when you click play it will
1) hunt for a user.ini.GLBU file and if found it will delete the user.ini file and restore the user.ini.GLBU to user.ini.
2) hunt for a user_patch.ini (and any other _patch.ini file)
3) if it finds one it will then backup the original user.ini file to be user.ini.GLBU read through the patch ini and pick out the all the title sections (e.g. [PCVERTEXPOOLS]) and sections underneath (ignoring the lines with ; in them) , create an array of these titles and subsections.
4) It will then read the user.ini file with the ini file windows api and get each value for each section and sub section. If any are different it will use the windows api to update the user.ini with each different value.
Now one though is that your user.ini.GLBU file may not have been deleted properly from a previous mission and so was the one restored because it was not needed for anything other the Labyrinth at the moment and so may have remained there after you manually updated your user.ini file. Its also not currently removed when unistalling a FM (which is possibly where the issue lies).
GlasWolf on 26/9/2005 at 20:30
I know there was a user.ini.glbu file, but I removed it after reverting to T3 OMs. However, GL still seems to be getting it from somewhere, which is odd. Presumably this should be in the T3 install directory? If so, it's not there now.
Your response throws up another query - does the play button do anything else other than the ini patching and launching the game? I think it would be advisable if at all possible to do all the patching at install time, otherwise the mission would depend on launching it through GL. That could cause a lot of confusion, and I'm not entirely certain I'm not the first example of that. ;)
potterr on 26/9/2005 at 20:45
The play button does these things:
* Check T2 install directory for convict.osm and darkhooks.dlx and warn if they do not exist (T2 only).
* Checks to see if any plugin tools are specified to start before the currently selected game and start them (e.g. fraps) it will also check to see if the video codec fix is specified to be done before starting the game and does so.
* It will then do the the T3 ini file patching process
* It then does the recently used FM update process if the FM has a GLTitle image or a T1/G/2 menu replacement image.
* It then Launches the game selected game
* It then updates the database with a timestamp of the last time the FM was played.
What you want to do is restore the user.ini.glbu file to user.ini, do any updates you want first off, then make sure you have deleted the user.ini.glbu file and then launch the game via the play button again and see what happens to the user.ini file.