MantisBT - VCMI
View Issue Details
0001685VCMIModspublic2014-02-02 08:482014-06-02 09:54
Warmonger 
Ivan 
normalminoralways
closedfixed 
 
0.95b 
0001685: If we use mod to change config/settings.json, all option changes are saved to that file
By default, custom user changes should go to his own confing/settings.json file and not the mod file.
No tags attached.
related to 0001688closed SXX On Windows vcmi must store user-specific data under C:\Users directory 
Issue History
2014-02-02 08:48WarmongerNew Issue
2014-02-02 08:52WarmongerSummaryIf we use mod to change config/settings.json, all option changes are svaed to that file => If we use mod to change config/settings.json, all option changes are saved to that file
2014-02-02 08:54IvanAssigned To => Ivan
2014-02-02 08:54IvanStatusnew => assigned
2014-02-02 08:55IvanNote Added: 0004380
2014-02-02 21:02WarmongerNote Added: 0004401
2014-02-08 12:38IvanNote Added: 0004406
2014-02-08 12:44IvanRelationship addedrelated to 0001688
2014-03-08 13:44IvanNote Added: 0004581
2014-03-08 13:46IvanNote Edited: 0004581bug_revision_view_page.php?bugnote_id=4581#r2547
2014-03-08 16:07IvanNote Added: 0004583
2014-03-08 16:07IvanStatusassigned => resolved
2014-03-08 16:07IvanFixed in Version => 0.95b
2014-03-08 16:07IvanResolutionopen => fixed
2014-06-02 09:54KantorNote Added: 0004719
2014-06-02 09:54KantorStatusresolved => closed

Notes
(0004380)
Ivan   
2014-02-02 08:55   
I think I got an idea on how to fix these. As result both settings.json and modSettings.json from mods will be ignored.
(0004401)
Warmonger   
2014-02-02 21:02   
Well, not all should be ignored - check Launcher my latest minimod that turns on AI logging.
(0004406)
Ivan   
2014-02-08 12:38   
In this case - this issue will have to wait until Tow will implement storing settings somewhere under C:\Users\... on Win.

Because if I'll change priority of "<data>/config" directory to highest this will disallow overriding of files in this directory by mods and will break at least WoG and high-res menu.

Alternatively you can create mod that replaces <data>/config/schemas/settings.json so "AI logging enabled" will be considered as default settings.
(0004581)
Ivan   
2014-03-08 13:44   
(edited on: 2014-03-08 13:46)
Good news: VCMI always saves changes to global file instead of file from mod.

Bad news: All non-default settings will go to this file. So if player uninstalls AI trace mod AI logging will remain because this change is already part of settings.json. And I don't see any easy way to fix this.

I'll commit these changes soon. If you wish - you can create mod that changes schema instead.

BTW - these changes will also fix those problems with mods replacing modSettings.json file.

(0004583)
Ivan   
2014-03-08 16:07   
fixed, rev 3802

Should work as described in my last comment - can't do anything else here.
(0004719)
Kantor   
2014-06-02 09:54   
This one may be closed.