summaryrefslogtreecommitdiff
path: root/src/SMAPI/Framework
diff options
context:
space:
mode:
Diffstat (limited to 'src/SMAPI/Framework')
-rw-r--r--src/SMAPI/Framework/SCore.cs10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/SMAPI/Framework/SCore.cs b/src/SMAPI/Framework/SCore.cs
index b4aa3595..801a7237 100644
--- a/src/SMAPI/Framework/SCore.cs
+++ b/src/SMAPI/Framework/SCore.cs
@@ -168,7 +168,8 @@ namespace StardewModdingAPI.Framework
/// <summary>Construct an instance.</summary>
/// <param name="modsPath">The path to search for mods.</param>
/// <param name="writeToConsole">Whether to output log messages to the console.</param>
- public SCore(string modsPath, bool writeToConsole)
+ /// <param name="developerModeValue">null if not modified else whether to use developer mode</param>
+ public SCore(string modsPath, bool writeToConsole, bool? developerModeValue)
{
SCore.Instance = this;
@@ -183,6 +184,13 @@ namespace StardewModdingAPI.Framework
// init basics
this.Settings = JsonConvert.DeserializeObject<SConfig>(File.ReadAllText(Constants.ApiConfigPath));
+
+ // temporary overwrite DeveloperMode Setting
+ if (developerModeValue.HasValue)
+ {
+ this.Settings.DeveloperMode = developerModeValue.Value;
+ }
+
if (File.Exists(Constants.ApiUserConfigPath))
JsonConvert.PopulateObject(File.ReadAllText(Constants.ApiUserConfigPath), this.Settings);