Woohoo! Slightly modified, this proposal solves the problems we're having with old savefiles! It boils down to essentially the same hack PopTop used in CtC, but with far less code involved.
Objects are loaded in case-insensitive lexicographic order. In other words, Concrete loads after Coffee and before Corn. If we rename the object, we can change its load order and hence the place where it appears in internal structures. Unfortunately _####Name moves all of the new cargos to the *beginning* of the list, which doesn't help the savefile problem a bit. However, replacing the underscore with a tilde (~) now forces all of the new objects to the ends of their respective lists.
So the new proposed object naming standard is ~####Name, where #### corresponds to an index in the RT3.LNG file. Use this tilde form for .CTY, .BCA, .LCO, .IMB, and probably .CAR files. I don't think it's necessary for .BTY, .DDS, .3DP, or .TGA files, as these either point to or are pointed from the other files.
Example:
~4451Concrete.cty
~4451Concrete.imb
concrete.dds
Downsides:
- Naming inconvenience
- New objects show up at the end of any list rather than where one would expect to find them
- We probably can't install more than one Pack at once, unless we split a given space into "pack type A" and "pack type B".
Upsides:
- Existing savefiles work in 1.06!
- You get to control the display order for anything in a given pack now.
There are a couple of ways to handle index ranges. We could either allocate very large ranges for each type of object (locomotives, buildings, cargos), or we could swap out the relevant sections of RT3.LNG depending on which packs are currently installed. I'm leaning toward the latter to save memory - even if we don't use a thousand message slots between 5000 and 6000, the game would still have to allocate space for all of those slots if there are messages using indices above 6000.
Proposed index ranges:
4355-4424 Locomotives
4425-4449 Buildings
4450-4460 Cargos
4461-4499 Cargo skins
These assume that we don't plan to swap *out* any of the original RT3 or CtC objects. If Bombardiere wants to, say, replace all of the existing American engines with British ones for a long-playing scenario, then we should probably allocate much larger index ranges.