1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-14 10:12:59 +02:00
vcmi/lib/modding
Ivan Savenko 6056d385ed Always load json configs from mod that references it
This should fix rather common problem with mods, where two unrelated mods
accidentally use same file name for a config file, leading to very unclear
conflict since this result in a file override.

Now all config files referenced in mod.json are loaded specifically from
filesystem of mod that referenced it. In other words, it is no longer
possible for one mod to override config from another mod.

As a side effect, this allows mods to use shorter directory layout, e.g.
`config/modName/xxx.json` can now be safely replaced with `config/
xxx.json` without fear of broken mod if there is another mod with same
path to config. Similarly, now all mods can use `config/translation/
language.json` scheme for translation files

Since this is no longer a problem, I've also simplified directory layout
of our built-in 'vcmi' mod, by moving all files from `config/vcmi`
directory directly to `config` directory.

- Overrides for miscellaneous configs like mainmenu.json should works as
before
- Images / animations (png's or def's) work as before (and may still
result in confict)
- Rebalance mods work as before and can modify another mod via standard
`modName:objectName` syntax
2024-10-31 14:49:11 +00:00
..
ActiveModsInSaveList.cpp Fix #3754, #2316 2024-04-27 13:57:50 +03:00
ActiveModsInSaveList.h Implemented join room dialog 2024-04-23 17:15:59 +03:00
CModHandler.cpp Always load json configs from mod that references it 2024-10-31 14:49:11 +00:00
CModHandler.h Merge pull request #4849 from IvanSavenko/map_encoding 2024-10-31 15:07:36 +02:00
CModInfo.cpp add support for soft dependencies 2024-10-26 19:15:12 +08:00
CModInfo.h add support for soft dependencies 2024-10-26 19:15:12 +08:00
CModVersion.cpp Implemented join room dialog 2024-04-23 17:15:59 +03:00
CModVersion.h Implemented join room dialog 2024-04-23 17:15:59 +03:00
ContentTypeHandler.cpp Update lib/modding/ContentTypeHandler.cpp 2024-10-29 00:35:03 +08:00
ContentTypeHandler.h Merge pull request #4712 from IvanSavenko/detect_conflict 2024-10-07 17:57:52 +03:00
IdentifierStorage.cpp Support for configurable town fortifications 2024-08-28 19:42:14 +00:00
IdentifierStorage.h Support for configurable town fortifications 2024-08-28 19:42:14 +00:00
ModIncompatibility.h Fix some 'new' issues reported by Sonar Cloud 2024-05-06 15:33:30 +00:00
ModScope.h
ModUtility.cpp
ModUtility.h
ModVerificationInfo.cpp Fix save compatibility with 1.4 that was broken by artifact costumes 2024-04-28 20:54:33 +03:00
ModVerificationInfo.h Implemented join room dialog 2024-04-23 17:15:59 +03:00