-
-
Notifications
You must be signed in to change notification settings - Fork 957
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix #7311: External configuration file does not change directories #7339
Conversation
At least, this makes regression tests pass without patching the script, now that OpenGFX (downloaded from in-game) is found:
|
Hmm I think config_dir should be an extra search dir appended before personal_dir. Would make more sense and keep the current behaviour too. Quote from readme:
|
⚠[EDIT] Mislead comment, keeping it only for reference⚠
|
TL; DR Scratch my long previous comment. It seems the intel I got about nice precendence of directories over others is simply not how the game is working at the moment. OpenTTD/src/saveload/saveload.cpp Line 2771 in c0c8fb2
The paths are built following a combinations of values stored in those structures: Line 110 in c0c8fb2
As I pointed out in my issue (and fixed here), the same If you want to question potential side effects, it is best to take them one by one and either follow their logic into the code, statically, or just dynamically compare trunk & this version builds. |
This pull request has been automatically marked as stale because it has not had any activity in the last month. |
Ping? |
This pull request has been automatically marked as stale because it has not had any activity in the last month. |
Ping? |
I'm going to close this one, as there's been no consensus on the correct solution, other than this is likely just a hack on top of a (much older) hack. Feel free to discuss in #7311 |
_personal_dir
gets replaced byconfig_dir
outside of the XDG triggers if a configuration file is specified.This makes directories path computation fail to find content sitting in normal game arborescence, such as the autoload directory.
This prosposal aims at preventing this behaviour, by not touching the arborescence when a configuration file is specified.
Discovered & loaded files should thus be more consistent across executions.
Any drawback?