ModOrganizer2 / modorganizer

Mod manager for various PC games. Discord Server: https://discord.gg/ewUVAqyrQX if you would like to be more involved
http://www.nexusmods.com/skyrimspecialedition/mods/6194
GNU General Public License v3.0
2.06k stars 155 forks source link

Use game's default file times as base with LoadOrderMechanism::FileTime #1936

Open AnyOldName3 opened 7 months ago

AnyOldName3 commented 7 months ago

Is your feature request related to a problem? Please describe. When organising a LoadOrderMechanism::FileTime game, MO2 alters the file times such that the earliest-loaded file uses the turn of the millennium, and each file uses a time one day later than its predecessors: https://github.com/ModOrganizer2/modorganizer/blob/04eff9750f0ebce85c64046cbf7d0198a4746247/src/pluginlist.cpp#L716-L730

As this is before any of the games MO2 uses this technique for actually released, this means that if you're making a mod, and you package it as-is, when users who for whatever reason, don't use a mod manager, try to install the mod, its file time cause it to be loaded before the base game ESMs it depends on. Apparently, some people are upset about this and would prefer it if MO2 did something else, presumably because the file-time-based games are old, and the older games have a larger proportion of mod-manager-phobes (side note: if a Greek-speaker can tell me what the Greek for mod manager is, then I can come up with a less clumsy phrase for that concept).

Describe the solution you'd like An obvious solution would be to use a date after each game's release/last update/last DLC release as the base, or even the current time.

Describe alternatives you've considered All the other ideas would wind up the Morrowind people even more.

Additional context

image

Silarn commented 7 months ago

One would think that Morrowind modders who refuse to use mod managers would be used to redating their plugins and wouldn't expect mod plugins to work by simply dropping them in without having to manage those times manually.

Does literally any other Morrowind-compatible plugin manager do this?

Silarn commented 7 months ago

I guess to attempt to actually address this, I think the only real way to do it would be to store the filetimes of the core plugins and then redate based on those. Trying to simply figure it out based on the latest filetime of core / dlc plugins may work but wouldn't 'fix' games which ran on older versions and already had modified dates. But are there any mods that want to load between DLC plugins? This change is something we have to consider for all of the filetime-based games.

AnyOldName3 commented 7 months ago

@Greatness7 see above

Greatness7 commented 7 months ago

One would think that Morrowind modders who refuse to use mod managers would be used to redating their plugins and wouldn't expect mod plugins to work by simply dropping them in without having to manage those times manually.

Does literally any other Morrowind-compatible plugin manager do this?

People not using mod managers are the main audience who do not re-date files at all. You'd be surprised at how many people still install mods the old fashioned way (drag-n-drop into the folder).

Generally authors of important projects will decide on a date upfront and maintain it for all releases. That way other mods can position themselves relative to it and 'just work' without user intervention. Other mod managers preserve file dates, but MO2 re-dating stuff obviously makes this technique no longer work.

I've seen case where people tried installing MO2 just to see what its like, only to have their file dates immediately trashed and no way to get them back, sometimes making their saves unplayable and requiring a full reinstall.

I've seen more cases where MO2 users create a mod unaware that their file dates are wonky and upload it to the Nexus as is, resulting in error messages or incorrect behavior for any users who install their mod without MO2.

The only reason this isn't an absolute disaster for non-MO2 users is that ESMs are hard-coded to load before ESPs, and people making ESMs catch on to this problem quickly. Bad load orders for ESP files is usually less problematic, but still are not a great situation - "patch" mods that are meant to load after popular plugins and overwrite specific changes will often work on the MO2 users machine but not on any others (because their mod loads before the thing they want to overwrite).

I'm not entirely sure why MO2 changes dates at all. If that is indeed necessary, then I suppose the only "true" fix would be to preserve all file dates and restore them when the VFS is destroyed.

Silarn commented 7 months ago

OpenMW Wrye Mash appears to date all plugins between 1026943162 (July 17, 2002) and the current time (but no earlier than Dec 7, 2008). It doesn't appear to differentiate between core / dlc plugins and mods. I'm guessing that's the original date of the main ESM. This seems like it would still break whatever 'assumed' timestamp a mod would use. But in general, if load order matters at all outside of simply being loaded after the main game plugins, relying on the original timestamp of the mod file is problematic no matter how you redate the files.

But I suppose if it starts from whatever the latest possible timestamp of the original files would be then clueless mod authors wouldn't publish files with dates that are earlier than the core game files.

AnyOldName3 commented 7 months ago

OBMM lets you control the load order of ESPs, so if the file dates are the only way the original engine can be told about that, then that's another mod manager that must be meddling with file dates. It's a bit mad that anything other than the order the files are listed in the INI would be used in the games where there's a list in the INI. I'll stick a link to this in the Wrye Bash Discord server in case they've got any wisdom they'd like to share.

Silarn commented 7 months ago

Load order being determined by the timestamp is true up through Fallout NV. Skyrim introduced determining the load order via the plugins.txt file which previously only determined what plugins were enabled.

I believe only Morrowind relies on the INI to determine which plugins to load.

AnyOldName3 commented 7 months ago

I was playing it fast and loose with names of text files as I couldn't remember whether it was plugins.txt or loadorder.txt that Skyrim used to determine load order, and whether the earlier post-Morrowind games were loading the list of files from plugins.txt and just ignoring its order or loading from a differently-named file and also ignoring its order. My point was that it was mad that the pre-Skyrim games all had a list of files in a text file of some form and yet didn't use the order in this file to determine load order.

Silarn commented 7 months ago

If I remember correctly the loadorder.txt was just kind of a community standard for storing the load order that multiple tools could parse but the games never actually used.

Definitely a strange choice by Bethesda to define load order that way.

I guess it was technically used by SLE. The modern unified plugins.txt file started with SSE / FO4.

Greatness7 commented 7 months ago

Assuming preserving the original timestamps is not possible, I think a less problematic alternative to the current situation would be to make the re-dating start from the current-time.

At least with this method newly created mods would have their content behave essentially the same as if they weren't using MO2 at all. That is, their file mtime would be "now", and thus when installed by other users it would load last (rather than first, which is almost always undesirable).