summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/StardewModdingAPI/Command.cs6
-rw-r--r--src/StardewModdingAPI/Config.cs2
-rw-r--r--src/StardewModdingAPI/Events/GameEvents.cs8
-rw-r--r--src/StardewModdingAPI/Events/PlayerEvents.cs4
-rw-r--r--src/StardewModdingAPI/Events/TimeEvents.cs8
-rw-r--r--src/StardewModdingAPI/Log.cs2
-rw-r--r--src/StardewModdingAPI/Mod.cs8
-rw-r--r--src/StardewModdingAPI/Program.cs4
8 files changed, 21 insertions, 21 deletions
diff --git a/src/StardewModdingAPI/Command.cs b/src/StardewModdingAPI/Command.cs
index 7613b240..689bb18b 100644
--- a/src/StardewModdingAPI/Command.cs
+++ b/src/StardewModdingAPI/Command.cs
@@ -95,7 +95,7 @@ namespace StardewModdingAPI
/// <param name="monitor">Encapsulates monitoring and logging.</param>
public static void CallCommand(string input, IMonitor monitor)
{
- Command.DeprecationManager.Warn("Command.CallCommand", "1.9", DeprecationLevel.Info);
+ Command.DeprecationManager.Warn("Command.CallCommand", "1.9", DeprecationLevel.PendingRemoval);
Command.CommandManager.Trigger(input);
}
@@ -108,7 +108,7 @@ namespace StardewModdingAPI
name = name?.Trim().ToLower();
// raise deprecation warning
- Command.DeprecationManager.Warn("Command.RegisterCommand", "1.9", DeprecationLevel.Info);
+ Command.DeprecationManager.Warn("Command.RegisterCommand", "1.9", DeprecationLevel.PendingRemoval);
// validate
if (Command.LegacyCommands.ContainsKey(name))
@@ -131,7 +131,7 @@ namespace StardewModdingAPI
/// <param name="name">The command name to find.</param>
public static Command FindCommand(string name)
{
- Command.DeprecationManager.Warn("Command.FindCommand", "1.9", DeprecationLevel.Info);
+ Command.DeprecationManager.Warn("Command.FindCommand", "1.9", DeprecationLevel.PendingRemoval);
if (name == null)
return null;
diff --git a/src/StardewModdingAPI/Config.cs b/src/StardewModdingAPI/Config.cs
index f6fe37d9..e166f414 100644
--- a/src/StardewModdingAPI/Config.cs
+++ b/src/StardewModdingAPI/Config.cs
@@ -126,7 +126,7 @@ namespace StardewModdingAPI
/// <summary>Construct an instance.</summary>
protected Config()
{
- Config.DeprecationManager.Warn("the Config class", "1.0", DeprecationLevel.Info);
+ Config.DeprecationManager.Warn("the Config class", "1.0", DeprecationLevel.PendingRemoval);
Config.DeprecationManager.MarkWarned($"{nameof(Mod)}.{nameof(Mod.BaseConfigPath)}", "1.0"); // typically used to construct config, avoid redundant warnings
}
}
diff --git a/src/StardewModdingAPI/Events/GameEvents.cs b/src/StardewModdingAPI/Events/GameEvents.cs
index c97b2c36..557b451f 100644
--- a/src/StardewModdingAPI/Events/GameEvents.cs
+++ b/src/StardewModdingAPI/Events/GameEvents.cs
@@ -49,7 +49,7 @@ namespace StardewModdingAPI.Events
{
add
{
- GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.Initialize)}", "1.10", DeprecationLevel.Info);
+ GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.Initialize)}", "1.10", DeprecationLevel.PendingRemoval);
GameEvents._Initialize += value;
}
remove => GameEvents._Initialize -= value;
@@ -61,7 +61,7 @@ namespace StardewModdingAPI.Events
{
add
{
- GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.LoadContent)}", "1.10", DeprecationLevel.Info);
+ GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.LoadContent)}", "1.10", DeprecationLevel.PendingRemoval);
GameEvents._LoadContent += value;
}
remove => GameEvents._LoadContent -= value;
@@ -73,7 +73,7 @@ namespace StardewModdingAPI.Events
{
add
{
- GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.GameLoaded)}", "1.12", DeprecationLevel.Info);
+ GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.GameLoaded)}", "1.12", DeprecationLevel.PendingRemoval);
GameEvents._GameLoaded += value;
}
remove => GameEvents._GameLoaded -= value;
@@ -85,7 +85,7 @@ namespace StardewModdingAPI.Events
{
add
{
- GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.FirstUpdateTick)}", "1.12", DeprecationLevel.Info);
+ GameEvents.DeprecationManager.Warn($"{nameof(GameEvents)}.{nameof(GameEvents.FirstUpdateTick)}", "1.12", DeprecationLevel.PendingRemoval);
GameEvents._FirstUpdateTick += value;
}
remove => GameEvents._FirstUpdateTick -= value;
diff --git a/src/StardewModdingAPI/Events/PlayerEvents.cs b/src/StardewModdingAPI/Events/PlayerEvents.cs
index efada876..acbdc562 100644
--- a/src/StardewModdingAPI/Events/PlayerEvents.cs
+++ b/src/StardewModdingAPI/Events/PlayerEvents.cs
@@ -39,7 +39,7 @@ namespace StardewModdingAPI.Events
{
add
{
- PlayerEvents.DeprecationManager.Warn($"{nameof(PlayerEvents)}.{nameof(PlayerEvents.LoadedGame)}", "1.6", DeprecationLevel.Info);
+ PlayerEvents.DeprecationManager.Warn($"{nameof(PlayerEvents)}.{nameof(PlayerEvents.LoadedGame)}", "1.6", DeprecationLevel.PendingRemoval);
PlayerEvents._LoadedGame += value;
}
remove => PlayerEvents._LoadedGame -= value;
@@ -51,7 +51,7 @@ namespace StardewModdingAPI.Events
{
add
{
- PlayerEvents.DeprecationManager.Warn($"{nameof(PlayerEvents)}.{nameof(PlayerEvents.FarmerChanged)}", "1.6", DeprecationLevel.Info);
+ PlayerEvents.DeprecationManager.Warn($"{nameof(PlayerEvents)}.{nameof(PlayerEvents.FarmerChanged)}", "1.6", DeprecationLevel.PendingRemoval);
PlayerEvents._FarmerChanged += value;
}
remove => PlayerEvents._FarmerChanged -= value;
diff --git a/src/StardewModdingAPI/Events/TimeEvents.cs b/src/StardewModdingAPI/Events/TimeEvents.cs
index 520f8b24..f0fdb4f2 100644
--- a/src/StardewModdingAPI/Events/TimeEvents.cs
+++ b/src/StardewModdingAPI/Events/TimeEvents.cs
@@ -49,7 +49,7 @@ namespace StardewModdingAPI.Events
{
add
{
- TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.DayOfMonthChanged)}", "1.14", DeprecationLevel.Info);
+ TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.DayOfMonthChanged)}", "1.14", DeprecationLevel.PendingRemoval);
TimeEvents._DayOfMonthChanged += value;
}
remove => TimeEvents._DayOfMonthChanged -= value;
@@ -61,7 +61,7 @@ namespace StardewModdingAPI.Events
{
add
{
- TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.YearOfGameChanged)}", "1.14", DeprecationLevel.Info);
+ TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.YearOfGameChanged)}", "1.14", DeprecationLevel.PendingRemoval);
TimeEvents._YearOfGameChanged += value;
}
remove => TimeEvents._YearOfGameChanged -= value;
@@ -73,7 +73,7 @@ namespace StardewModdingAPI.Events
{
add
{
- TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.SeasonOfYearChanged)}", "1.14", DeprecationLevel.Info);
+ TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.SeasonOfYearChanged)}", "1.14", DeprecationLevel.PendingRemoval);
TimeEvents._SeasonOfYearChanged += value;
}
remove => TimeEvents._SeasonOfYearChanged -= value;
@@ -85,7 +85,7 @@ namespace StardewModdingAPI.Events
{
add
{
- TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.OnNewDay)}", "1.6", DeprecationLevel.Info);
+ TimeEvents.DeprecationManager.Warn($"{nameof(TimeEvents)}.{nameof(TimeEvents.OnNewDay)}", "1.6", DeprecationLevel.PendingRemoval);
TimeEvents._OnNewDay += value;
}
remove => TimeEvents._OnNewDay -= value;
diff --git a/src/StardewModdingAPI/Log.cs b/src/StardewModdingAPI/Log.cs
index 562fa1f8..46f1caae 100644
--- a/src/StardewModdingAPI/Log.cs
+++ b/src/StardewModdingAPI/Log.cs
@@ -307,7 +307,7 @@ namespace StardewModdingAPI
/// <summary>Raise a deprecation warning.</summary>
private static void WarnDeprecated()
{
- Log.DeprecationManager.Warn($"the {nameof(Log)} class", "1.1", DeprecationLevel.Info);
+ Log.DeprecationManager.Warn($"the {nameof(Log)} class", "1.1", DeprecationLevel.PendingRemoval);
}
/// <summary>Get the name of the mod logging a message from the stack.</summary>
diff --git a/src/StardewModdingAPI/Mod.cs b/src/StardewModdingAPI/Mod.cs
index 302f16ec..cb36c596 100644
--- a/src/StardewModdingAPI/Mod.cs
+++ b/src/StardewModdingAPI/Mod.cs
@@ -40,7 +40,7 @@ namespace StardewModdingAPI
{
get
{
- Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.PathOnDisk)}", "1.0", DeprecationLevel.Info);
+ Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.PathOnDisk)}", "1.0", DeprecationLevel.PendingRemoval);
return this._pathOnDisk;
}
internal set { this._pathOnDisk = value; }
@@ -52,7 +52,7 @@ namespace StardewModdingAPI
{
get
{
- Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.BaseConfigPath)}", "1.0", DeprecationLevel.Info);
+ Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.BaseConfigPath)}", "1.0", DeprecationLevel.PendingRemoval);
Mod.DeprecationManager.MarkWarned($"{nameof(Mod)}.{nameof(Mod.PathOnDisk)}", "1.0"); // avoid redundant warnings
return Path.Combine(this.PathOnDisk, "config.json");
}
@@ -68,7 +68,7 @@ namespace StardewModdingAPI
{
get
{
- Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.PerSaveConfigPath)}", "1.0", DeprecationLevel.Info);
+ Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.PerSaveConfigPath)}", "1.0", DeprecationLevel.PendingRemoval);
Mod.DeprecationManager.MarkWarned($"{nameof(Mod)}.{nameof(Mod.PerSaveConfigFolder)}", "1.0"); // avoid redundant warnings
return Context.IsSaveLoaded ? Path.Combine(this.PerSaveConfigFolder, $"{Constants.SaveFolderName}.json") : "";
}
@@ -113,7 +113,7 @@ namespace StardewModdingAPI
[Obsolete]
private string GetPerSaveConfigFolder()
{
- Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.PerSaveConfigFolder)}", "1.0", DeprecationLevel.Info);
+ Mod.DeprecationManager.Warn($"{nameof(Mod)}.{nameof(Mod.PerSaveConfigFolder)}", "1.0", DeprecationLevel.PendingRemoval);
Mod.DeprecationManager.MarkWarned($"{nameof(Mod)}.{nameof(Mod.PathOnDisk)}", "1.0"); // avoid redundant warnings
if (!((Manifest)this.ModManifest).PerSaveConfigs)
diff --git a/src/StardewModdingAPI/Program.cs b/src/StardewModdingAPI/Program.cs
index d722b43e..10fb5a82 100644
--- a/src/StardewModdingAPI/Program.cs
+++ b/src/StardewModdingAPI/Program.cs
@@ -395,7 +395,7 @@ namespace StardewModdingAPI
// per-save directories
if ((mod.Manifest as Manifest)?.PerSaveConfigs == true)
{
- deprecationWarnings.Add(() => this.DeprecationManager.Warn(mod.DisplayName, $"{nameof(Manifest)}.{nameof(Manifest.PerSaveConfigs)}", "1.0", DeprecationLevel.Info));
+ deprecationWarnings.Add(() => this.DeprecationManager.Warn(mod.DisplayName, $"{nameof(Manifest)}.{nameof(Manifest.PerSaveConfigs)}", "1.0", DeprecationLevel.PendingRemoval));
try
{
string psDir = Path.Combine(mod.DirectoryPath, "psconfigs");
@@ -753,7 +753,7 @@ namespace StardewModdingAPI
// raise deprecation warning for old Entry() methods
if (this.DeprecationManager.IsVirtualMethodImplemented(mod.GetType(), typeof(Mod), nameof(Mod.Entry), new[] { typeof(object[]) }))
- deprecationWarnings.Add(() => this.DeprecationManager.Warn(metadata.DisplayName, $"{nameof(Mod)}.{nameof(Mod.Entry)}(object[]) instead of {nameof(Mod)}.{nameof(Mod.Entry)}({nameof(IModHelper)})", "1.0", DeprecationLevel.Info));
+ deprecationWarnings.Add(() => this.DeprecationManager.Warn(metadata.DisplayName, $"{nameof(Mod)}.{nameof(Mod.Entry)}(object[]) instead of {nameof(Mod)}.{nameof(Mod.Entry)}({nameof(IModHelper)})", "1.0", DeprecationLevel.PendingRemoval));
#endif
}
catch (Exception ex)