davidgillon: A pair of crutches, hanging from coat hooks, reflected in a mirror (Default)

I've been tweaking Train Sim to my preferences ever since I got it, mostly the way it lays out your choice of trains to run, which is set up as a hierarchical choice of class of train (for instance a Class 158 Express Sprinter, or a German DB BR101), and then the specific train 'consist'  (eg two linked 4 coach Class 158s run by London Midland). Which makes it slightly annoying if they then publish DLC which variously titles the same train class in different ways, for example the Class 158 as a Class 158 Sprinter, Class 158 Express Sprinter, and Class 158 EMU, splitting it into multiple folders.  A handful of DLC even had a separate folder per individual consist. So as the files that arrange this are editable (they're a compiled HTML, but you get the compiler/decompiler) I've been changing them to consistent names/my preferences. Only sometimes it doesn't work. And it wasn't obvious why.

My working hypothesis was there was some sort of hidden database of DLC train names as it didn't happen with fan developed freebies, but then one of those turned up with the same issue and in poking it to find out why I stumbled onto the answer. There is (sometimes) another file associated with the trains called <class name>metadata. I though that was just linking the train to its various sub-folders, but it turns out to be more general project header, and it has a tag in there that completely overwrites the class tag in the individual train file. And to make it even more confusing not only is it sometimes there and sometimes not, but sometimes, for DLC that contains both a route and trains, there isn't separate metadata for some of the trains, but there may be metadata for some of them buried in the metadata for the route. If they'd deliberately set it up to be confusing and annoying they couldn't have done a better job.

I took a pass through the Metadata files yesterday, it works, and I've eliminated something like 40 duplicate folders (and I'm not finished yet). Even better, it seems to make it load faster!

I did once find a similar setup in code at work, the main thread of code being overridden by a completely undocumented hidden one. Worryingly that one was deciding whether or not to drop a bomb (though at least it would fail by not dropping the bomb rather than vice versa).

But it works. Well, most of the time it works. I'm really hoping the places it doesn't work are ones where I've screwed up the fix, because if they aren't then there's a second even further hidden level of naming. *facepalm*

 

davidgillon: A pair of crutches, hanging from coat hooks, reflected in a mirror (Default)

One of the companies I buy computer games stuff from was having a sale, so Wednesday evening I picked up a couple of add-ons for one of my games and went to install them.

Run the installer for the first one and it falls over.

I run it again and pay more attention to what it's saying.

Ah, it's trying to install to drive F. Drive F is the drive that died last month. Fortunately I'd copied my Steam library folder from that to my new drive G before that happened.

So I look at Steam to see what folders it thinks I have. And it says C only. I thought I'd set up the new one on G via Steam, but apparently not.

So set up a Steam folder on G to point to what's already there.

Steam: there's nothing in that folder. *Headdesk*

Check the original game in Steam: Steam thinks its not installed.

Okay, I'll run the installer for the full game. (Wince)

Steam: It's already installed! But I'm going to check every file, and then delete them and install them again!! Even if they're unchanged!!! *Headdesk* *Headdesk*

This took it from about 8PM until 5AM. (It's the biggest game I own)

Thursday morning, try and install the new add-ons. Still trying to put them in F. *Headdesk* *Headdesk* *Headdesk*

So I have a look at the FAQ on the company's website - if something similar happens, it's probably the registry. Try app X from company Y's website to fix it.

So I try that, it resets the registry, new add-ons install. Yay!

Then I notice a few files seem to be missing. The game stores its files, those from the original provider at least, in zip files (it calls them something else, but they're zip files), and runs them directly from the zip, no need to extract them. But if you want to use a third party mod to those files, such as a reskin, you have to unpack the zips so the files can be directly addressed. Over time I've done this for every zip in the game, that's several hundred zip files. Steam has carefully gone through the game, deleting and replacing every zip, and deleting, but not replacing, every file that's been extracted from them. The third-party mod files have been left alone, but without the extracted zip files they won't work. *Headdesk* *Headdesk* *Headdesk* *Headdesk*

I'm almost impressed. Steam has been clever enough to realise that some of the non-zip files in the game folders are from third parties, and some are copies of the files in the zips, and that there's a difference. It just hasn't been clever enough to realise they might all be there for a reason.

If you want me, I'll be extracting zip files....

Profile

davidgillon: A pair of crutches, hanging from coat hooks, reflected in a mirror (Default)
David Gillon

March 2025

S M T W T F S
      1
2345678
9101112131415
1617 18192021 22
2324 2526272829
3031     

Syndicate

RSS Atom

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jul. 1st, 2025 09:50 am
Powered by Dreamwidth Studios