0ad/source
trompetin17 8e255af185
Fix mods configuration stacking and mergin per mod
Previously, the engine only loaded the last mod’s `config/mod.cfg` file,
causing earlier mods' configuration settings to be ignored. This broke
the expectation of stackable mod behavior and affected features relying
on custom config, such as font overrides.

This commit updates the mod mounting and configuration process to:

- Mount each mod's files before attempting to load its config.
- Reload each mod's `config/modname.cfg` via `g_ConfigDB.Reload(CFG_MOD)`
  after mounting.
- Merge configuration keys into the CFG_MOD namespace:
  - If a key exists, its value is updated.
  - If not, the key is added.

This behavior now aligns with the VFS override system, where later mods
take precedence but earlier mods still contribute.

Also adds `_test.mods` for validation.

Fixes edge cases for mod authors who rely on consistent and layered
configuration overrides.

Related: #6383, #1810
Fixes: #8060
2025-06-16 11:03:09 -05:00
..
collada Fix a bunch of spelling mistakes 2025-04-11 06:24:32 +02:00
graphics Fix trailing whitespace and add pre-commit hook 2025-06-15 20:08:48 +02:00
gui Fix trailing whitespace and add pre-commit hook 2025-06-15 20:08:48 +02:00
i18n Get config values without using return parameters 2025-04-09 12:51:21 +02:00
lib Fix trailing whitespace and add pre-commit hook 2025-06-15 20:08:48 +02:00
lobby Fix password change for certain usernames 2025-05-19 17:05:41 +02:00
maths Fix trailing whitespace and add pre-commit hook 2025-06-15 20:08:48 +02:00
mocks Revert non-ASCII characters from source and configuration files introduced in 157c6af18e. 2023-12-03 00:30:12 +00:00
network Stop running shrinking gcs & simplify GC logic. 2025-04-22 17:03:29 +02:00
pch Remove glooxwrapper 2024-11-25 20:01:00 +01:00
ps Fix mods configuration stacking and mergin per mod 2025-06-16 11:03:09 -05:00
renderer Fix trailing whitespace and add pre-commit hook 2025-06-15 20:08:48 +02:00
rlinterface Shutdown mongoose in rl-interface gracefully 2024-06-23 17:26:03 +00:00
scriptinterface Disalow importing some files 2025-06-06 17:36:35 +02:00
simulation2 Make rallypoints moddable. 2025-06-15 07:43:08 +02:00
soundmanager Fix a bunch of spelling mistakes 2025-04-11 06:24:32 +02:00
third_party Fix trailing whitespace and add pre-commit hook 2025-06-15 20:08:48 +02:00
tools Remove the limit of the available graph colors 2025-06-16 08:17:38 +02:00
main.cpp Adds fixed frame frequency. 2025-04-25 19:15:57 +02:00
test_setup.cpp Make the TaskManager a automatic livetime object 2024-11-17 18:03:49 +01:00