AHeroicLlama / Mappalachia

The complete mapping tool for Fallout 76.
GNU General Public License v3.0
125 stars 8 forks source link

Refactor SettingsManager to use an existing library #89

Open AHeroicLlama opened 1 year ago

AHeroicLlama commented 1 year ago

SettingsManager class was written totally custom originally to support bespoke features such as versioning and custom warnings for malformed settings. It also mocked the .ini file format to be more familiar to technically-minded Fallout players.

However this custom setup causes overhead whenever a new setting is added to the config file.

We should consider refactoring this to use something more standard, eg system.text.json. We must however still maintain a level of control, such that if a feature is removed but users have an "old" config file, there are no errors or confusion caused, for example we might want to control how settings are read in, should a feature change. See fe7cb414f636d0dbc49547c9b8b9c65a675f90dd for previous example of a would-be breaking change being caught.