summaryrefslogtreecommitdiff
path: root/src/StardewModdingAPI/Program.cs
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <github@jplamondonw.com>2016-11-16 17:52:49 -0500
committerJesse Plamondon-Willard <github@jplamondonw.com>2016-11-16 17:52:49 -0500
commiteb39f3d5ea28f004ab352113d869ae6d7772bcd5 (patch)
treef9c19a0d12939d822d9e24478b093086b7b9ecc7 /src/StardewModdingAPI/Program.cs
parent962178352b711796ea0962a3fbcaf5b788037719 (diff)
downloadSMAPI-eb39f3d5ea28f004ab352113d869ae6d7772bcd5.tar.gz
SMAPI-eb39f3d5ea28f004ab352113d869ae6d7772bcd5.tar.bz2
SMAPI-eb39f3d5ea28f004ab352113d869ae6d7772bcd5.zip
use interface for IModHelper
Diffstat (limited to 'src/StardewModdingAPI/Program.cs')
-rw-r--r--src/StardewModdingAPI/Program.cs9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/StardewModdingAPI/Program.cs b/src/StardewModdingAPI/Program.cs
index 962a30f8..e60fb6b2 100644
--- a/src/StardewModdingAPI/Program.cs
+++ b/src/StardewModdingAPI/Program.cs
@@ -404,12 +404,15 @@ namespace StardewModdingAPI
modEntry.PathOnDisk = directory;
Program.Monitor.Log($"Loaded mod: {modEntry.Manifest.Name} by {modEntry.Manifest.Author}, v{modEntry.Manifest.Version} | {modEntry.Manifest.Description}", LogLevel.Info);
Program.ModsLoaded += 1;
- modEntry.Entry(); // deprecated
- modEntry.Entry(modEntry.Helper);
+ modEntry.Entry(); // deprecated since 1.0
+ modEntry.Entry((ModHelper)modEntry.Helper); // deprecated since 1.1
+ modEntry.Entry(modEntry.Helper); // deprecated since 1.1
// raise deprecation warning for old Entry() method
- if (Program.DeprecationManager.IsVirtualMethodImplemented(modEntryType, typeof(Mod), nameof(Mod.Entry)))
+ if (Program.DeprecationManager.IsVirtualMethodImplemented(modEntryType, typeof(Mod), nameof(Mod.Entry), new[] { typeof(object[]) }))
Program.DeprecationManager.Warn(manifest.Name, $"an old version of {nameof(Mod)}.{nameof(Mod.Entry)}", "1.0", DeprecationLevel.Notice);
+ if (Program.DeprecationManager.IsVirtualMethodImplemented(modEntryType, typeof(Mod), nameof(Mod.Entry), new[] { typeof(ModHelper) }))
+ Program.DeprecationManager.Warn(manifest.Name, $"an old version of {nameof(Mod)}.{nameof(Mod.Entry)}", "1.1", DeprecationLevel.Notice);
}
}
else