Some mods/updates need to overwrite files, but to avoid mods overwriting each other by accident we need to specify explicitly which files are supposed to be replacements.
We need some configuration file containing the following information for each object which needs to overwrite something:
Object in question, might be a filepath, might be some deduplicated sub-section of a file
Checksum of the object to replace, to validate we are replacing the correct object (in case it was already overwritten)
We can run into the following mis-configurations:
File to replace does not exists, some mod must be missing.
File to replace has the wrong checksum, either it depends on another mod, or was unexpected already modified by another mod.
We can detect which it is by checking the checksum of all replacements of this file. If it does not contain it, we are missing a mod, if it exists we have a conflict.
However if a mod is missing we still do not know what. Maybe we should have a dependency list of some kind? I'm not sure if it is a good idea to use for resolving anything, I'm more inclined to just use it for a human-readable hint to what might be missing.
A missing mod might be cause of the ordering the mods are loaded in is incorrect. Is it possible to somehow detect the order at runtime, or do we need to specify it manually?
Another issue is with replacing de-duplicated parts. Sometimes you might want to change all of them, sometimes perhaps just for some files. Some way of specifying this might be needed, but I would like to have real examples to design something for.
Some mods/updates need to overwrite files, but to avoid mods overwriting each other by accident we need to specify explicitly which files are supposed to be replacements.
We need some configuration file containing the following information for each object which needs to overwrite something:
We can run into the following mis-configurations:
However if a mod is missing we still do not know what. Maybe we should have a dependency list of some kind? I'm not sure if it is a good idea to use for resolving anything, I'm more inclined to just use it for a human-readable hint to what might be missing.
A missing mod might be cause of the ordering the mods are loaded in is incorrect. Is it possible to somehow detect the order at runtime, or do we need to specify it manually?
Another issue is with replacing de-duplicated parts. Sometimes you might want to change all of them, sometimes perhaps just for some files. Some way of specifying this might be needed, but I would like to have real examples to design something for.