From 525ca7c9c99272c5aff557545c285f4307526589 Mon Sep 17 00:00:00 2001 From: Jesse Plamondon-Willard Date: Fri, 24 Jun 2022 02:06:25 -0400 Subject: fix config.user.json overrides no longer applied --- src/SMAPI/Framework/Models/SConfig.cs | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) (limited to 'src/SMAPI/Framework/Models/SConfig.cs') diff --git a/src/SMAPI/Framework/Models/SConfig.cs b/src/SMAPI/Framework/Models/SConfig.cs index baef6144..62b15405 100644 --- a/src/SMAPI/Framework/Models/SConfig.cs +++ b/src/SMAPI/Framework/Models/SConfig.cs @@ -38,45 +38,49 @@ namespace StardewModdingAPI.Framework.Models /******** ** Accessors ********/ + // + // Note: properties must be writable to support merging config.user.json into it. + // + /// Whether to enable development features. - public bool DeveloperMode { get; private set; } + public bool DeveloperMode { get; set; } /// Whether to check for newer versions of SMAPI and mods on startup. - public bool CheckForUpdates { get; } + public bool CheckForUpdates { get; set; } /// Whether to add a section to the 'mod issues' list for mods which which directly use potentially sensitive .NET APIs like file or shell access. - public bool ParanoidWarnings { get; } + public bool ParanoidWarnings { get; set; } /// Whether to show beta versions as valid updates. - public bool UseBetaChannel { get; } + public bool UseBetaChannel { get; set; } /// SMAPI's GitHub project name, used to perform update checks. - public string GitHubProjectName { get; } + public string GitHubProjectName { get; set; } /// The base URL for SMAPI's web API, used to perform update checks. - public string WebApiBaseUrl { get; } + public string WebApiBaseUrl { get; set; } /// The log contexts for which to enable verbose logging, which may show a lot more information to simplify troubleshooting. /// The possible values are "*" (everything is verbose), "SMAPI", (SMAPI itself), or mod IDs. - public HashSet VerboseLogging { get; } + public HashSet VerboseLogging { get; set; } /// Whether SMAPI should rewrite mods for compatibility. - public bool RewriteMods { get; } + public bool RewriteMods { get; set; } /// Whether to use raw image data when possible, instead of initializing an XNA Texture2D instance through the GPU. - public bool UseRawImageLoading { get; } + public bool UseRawImageLoading { get; set; } /// Whether to make SMAPI file APIs case-insensitive, even on Linux. - public bool UseCaseInsensitivePaths { get; } + public bool UseCaseInsensitivePaths { get; set; } /// Whether SMAPI should log network traffic. Best combined with , which includes network metadata. - public bool LogNetworkTraffic { get; } + public bool LogNetworkTraffic { get; set; } /// The colors to use for text written to the SMAPI console. - public ColorSchemeConfig ConsoleColors { get; } + public ColorSchemeConfig ConsoleColors { get; set; } /// The mod IDs SMAPI should ignore when performing update checks or validating update keys. - public HashSet SuppressUpdateChecks { get; } + public HashSet SuppressUpdateChecks { get; set; } /******** -- cgit