diff --git a/GeneralMods/AutoSpeed/manifest.json b/GeneralMods/AutoSpeed/manifest.json index 12f68f4d..8a56305b 100644 --- a/GeneralMods/AutoSpeed/manifest.json +++ b/GeneralMods/AutoSpeed/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Got to go fast!", "UniqueID": "Omegasis.AutoSpeed", "EntryDll": "AutoSpeed.dll" diff --git a/GeneralMods/BillboardAnywhere/manifest.json b/GeneralMods/BillboardAnywhere/manifest.json index a1b264c6..e94ca8f3 100644 --- a/GeneralMods/BillboardAnywhere/manifest.json +++ b/GeneralMods/BillboardAnywhere/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Lets you view the billboard from anywhere.", "UniqueID": "Omegasis.BillboardAnywhere", "EntryDll": "BillboardAnywhere.dll" diff --git a/GeneralMods/BuildEndurance/BuildEndurance.cs b/GeneralMods/BuildEndurance/BuildEndurance.cs index 4a7728af..bd2e1c50 100644 --- a/GeneralMods/BuildEndurance/BuildEndurance.cs +++ b/GeneralMods/BuildEndurance/BuildEndurance.cs @@ -68,7 +68,7 @@ namespace Omegasis.BuildEndurance GameEvents.UpdateTick += this.GameEvents_UpdateTick; GameEvents.OneSecondTick += this.GameEvents_OneSecondTick; SaveEvents.AfterLoad += this.SaveEvents_AfterLoad; - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + TimeEvents.AfterDayStarted += this.TimeEvents_AfterDayStarted; string configPath = Path.Combine(helper.DirectoryPath, "BuildEnduranceConfig.json"); if (!File.Exists(configPath)) @@ -178,10 +178,10 @@ namespace Omegasis.BuildEndurance this.WriteConfig(); } - /// The method invoked when changes. + /// The method invoked when a new day starts. /// The event sender. /// The event data. - public void TimeEvents_DayOfMonthChanged(object sender, EventArgs e) + public void TimeEvents_AfterDayStarted(object sender, EventArgs e) { // reset data this.WasExhausted = false; diff --git a/GeneralMods/BuildEndurance/README.md b/GeneralMods/BuildEndurance/README.md index 59ea89ff..9c3a0674 100644 --- a/GeneralMods/BuildEndurance/README.md +++ b/GeneralMods/BuildEndurance/README.md @@ -35,4 +35,5 @@ Edit `BuildEnduranceConfig.json` to configure the mod settings. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/BuildEndurance/manifest.json b/GeneralMods/BuildEndurance/manifest.json index 6b2a6a3f..4a5e3398 100644 --- a/GeneralMods/BuildEndurance/manifest.json +++ b/GeneralMods/BuildEndurance/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Increase your health as you play.", "UniqueID": "Omegasis.BuildEndurance", "EntryDll": "BuildEndurance.dll" diff --git a/GeneralMods/BuildHealth/BuildHealth.cs b/GeneralMods/BuildHealth/BuildHealth.cs index 20f4efaf..9d8d8f1b 100644 --- a/GeneralMods/BuildHealth/BuildHealth.cs +++ b/GeneralMods/BuildHealth/BuildHealth.cs @@ -65,7 +65,7 @@ namespace Omegasis.BuildHealth GameEvents.UpdateTick += this.GameEvents_UpdateTick; GameEvents.OneSecondTick += this.GameEvents_OneSecondTick; - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + TimeEvents.AfterDayStarted += this.TimeEvents_AfterDayStarted; SaveEvents.AfterLoad += this.SaveEvents_AfterLoaded; var configPath = Path.Combine(helper.DirectoryPath, "BuildHealthConfig.json"); @@ -146,10 +146,10 @@ namespace Omegasis.BuildHealth } } - /// The method invoked when changes. + /// The method invoked after a new day starts. /// The event sender. /// The event data. - public void TimeEvents_DayOfMonthChanged(object sender, EventArgs e) + public void TimeEvents_AfterDayStarted(object sender, EventArgs e) { // reset data this.LastHealth = Game1.player.maxHealth; diff --git a/GeneralMods/BuildHealth/ReadMe.md b/GeneralMods/BuildHealth/ReadMe.md index 7b1adb0b..aaed1534 100644 --- a/GeneralMods/BuildHealth/ReadMe.md +++ b/GeneralMods/BuildHealth/ReadMe.md @@ -36,4 +36,5 @@ Edit `BuildHealthConfig.json` to configure the mod settings. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/BuildHealth/manifest.json b/GeneralMods/BuildHealth/manifest.json index 1361966e..613c6d95 100644 --- a/GeneralMods/BuildHealth/manifest.json +++ b/GeneralMods/BuildHealth/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Increase your health as you play.", "UniqueID": "Omegasis.BuildHealth", "EntryDll": "BuildHealth.dll" diff --git a/GeneralMods/BuyBackCollectables/manifest.json b/GeneralMods/BuyBackCollectables/manifest.json index 691ab228..81806117 100644 --- a/GeneralMods/BuyBackCollectables/manifest.json +++ b/GeneralMods/BuyBackCollectables/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Lets you buy back any obtained collectable.", "UniqueID": "Omegasis.BuyBackCollectables", "EntryDll": "BuyBackCollectables.dll" diff --git a/GeneralMods/CustomShopsRedux/CustomShopsRedux.cs b/GeneralMods/CustomShopsRedux/CustomShopsRedux.cs index f0efc877..100e7d1a 100644 --- a/GeneralMods/CustomShopsRedux/CustomShopsRedux.cs +++ b/GeneralMods/CustomShopsRedux/CustomShopsRedux.cs @@ -51,10 +51,10 @@ namespace Omegasis.CustomShopsRedux ** Public methods *********/ /// The mod entry point, called after the mod is first loaded. - /// The mod arguments. - public override void Entry(params object[] args) + /// Provides simplified APIs for writing mods. + public override void Entry(IModHelper helper) { - PlayerEvents.LoadedGame += this.PlayerEvents_LoadedGame; + SaveEvents.AfterLoad += this.SaveEvents_AfterDayStarted; ControlEvents.KeyPressed += this.ControlEvents_KeyPressed; } @@ -62,10 +62,10 @@ namespace Omegasis.CustomShopsRedux /********* ** Private methods *********/ - /// The method invoked after the player loads a save. + /// The method invoked after a new day starts. /// The event sender. /// The event data. - private void PlayerEvents_LoadedGame(object sender, EventArgsLoadedGameChanged e) + private void SaveEvents_AfterDayStarted(object sender, EventArgs e) { this.IsGameLoaded = true; this.LoadConfig(); @@ -89,10 +89,10 @@ namespace Omegasis.CustomShopsRedux /// Load the configuration settings. private void LoadConfig() { - this.DataPath = Path.Combine(this.PathOnDisk, "Custom_Shops"); + this.DataPath = Path.Combine(this.Helper.DirectoryPath, "Custom_Shops"); Directory.CreateDirectory(this.DataPath); - string path = Path.Combine(this.PathOnDisk, "Custom_Shop_Redux_Config.txt"); + string path = Path.Combine(this.Helper.DirectoryPath, "Custom_Shop_Redux_Config.txt"); if (!File.Exists(path)) this.KeyBinding = "U"; else @@ -105,7 +105,7 @@ namespace Omegasis.CustomShopsRedux /// Save the configuration settings. private void WriteConfig() { - string path = Path.Combine(this.PathOnDisk, "Custom_Shop_Redux_Config.txt"); + string path = Path.Combine(this.Helper.DirectoryPath, "Custom_Shop_Redux_Config.txt"); string[] text = new string[20]; text[0] = "Config: Custom_Shop_Redux. Feel free to mess with these settings."; text[1] = "===================================================================================="; @@ -121,13 +121,13 @@ namespace Omegasis.CustomShopsRedux { // get mod folder DirectoryInfo modFolder = new DirectoryInfo(this.DataPath); - Log.Info(modFolder); + this.Monitor.Log(modFolder.FullName); // get text files FileInfo[] files = modFolder.GetFiles("*.txt"); if (!files.Any()) { - Log.Error("No shop .txt information is found. You should create one."); + this.Monitor.Log("No shop .txt information is found. You should create one.", LogLevel.Error); return; } @@ -136,7 +136,7 @@ namespace Omegasis.CustomShopsRedux this.Options.Add(file.Name); if (!this.Options.Any()) { - Log.Error("No shop .txt information is found. You should create one."); + this.Monitor.Log("No shop .txt information is found. You should create one.", LogLevel.Error); return; } @@ -156,7 +156,7 @@ namespace Omegasis.CustomShopsRedux // validate if (filename == "Custom_Shop_Redux_Config.txt") { - Log.Info("Silly human. The config file is not a shop."); + this.Monitor.Log("Silly human. The config file is not a shop.", LogLevel.Info); return; } @@ -168,8 +168,8 @@ namespace Omegasis.CustomShopsRedux if (i >= lineCount || objType == "" || text[i] == "") break; //read in a line for obj type here - Log.Info(i); - Log.Info(objType); + this.Monitor.Log(i.ToString()); + this.Monitor.Log(objType); int objID; int price; if (objType == "item" || objType == "Item" || objType == "Object" || objType == "object") @@ -177,13 +177,13 @@ namespace Omegasis.CustomShopsRedux objID = Convert.ToInt16(text[i]); i += 2; - Log.Info(i); + this.Monitor.Log(i.ToString()); bool isRecipe = Convert.ToBoolean(text[i]); i += 2; - Log.Info(i); + this.Monitor.Log(i.ToString()); price = Convert.ToInt32(text[i]); i += 2; - Log.Info(i); + this.Monitor.Log(i.ToString()); int quality = Convert.ToInt32(text[i]); @@ -295,7 +295,7 @@ namespace Omegasis.CustomShopsRedux //TODO: //add in support for colored objects //add in support for tools - Log.Success(i); + this.Monitor.Log(i.ToString()); if (i >= lineCount) break; diff --git a/GeneralMods/CustomShopsRedux/ReadMe.md b/GeneralMods/CustomShopsRedux/ReadMe.md index 276bcc66..44c5d022 100644 --- a/GeneralMods/CustomShopsRedux/ReadMe.md +++ b/GeneralMods/CustomShopsRedux/ReadMe.md @@ -59,4 +59,5 @@ Supported item types: * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/CustomShopsRedux/manifest.json b/GeneralMods/CustomShopsRedux/manifest.json index 1911d245..e3dc6b29 100644 --- a/GeneralMods/CustomShopsRedux/manifest.json +++ b/GeneralMods/CustomShopsRedux/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "A nice way to make custom shops.", "UniqueID": "Omegasis.CustomShopReduxGui", "EntryDll": "CustomShopsRedux.dll" diff --git a/GeneralMods/DailyQuestAnywhere/manifest.json b/GeneralMods/DailyQuestAnywhere/manifest.json index 3ee56f4a..e5eccd25 100644 --- a/GeneralMods/DailyQuestAnywhere/manifest.json +++ b/GeneralMods/DailyQuestAnywhere/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Open the daily quest board from anywhere in the game.", "UniqueID": "Omegasis.DailyQuestAnywhere", "EntryDll": "DailyQuestAnywhere.dll" diff --git a/GeneralMods/Fall28SnowDay/Fall28SnowDay.cs b/GeneralMods/Fall28SnowDay/Fall28SnowDay.cs index 71a66016..58d7f373 100644 --- a/GeneralMods/Fall28SnowDay/Fall28SnowDay.cs +++ b/GeneralMods/Fall28SnowDay/Fall28SnowDay.cs @@ -1,4 +1,5 @@ -using StardewModdingAPI; +using System; +using StardewModdingAPI; using StardewModdingAPI.Events; using StardewValley; @@ -14,19 +15,19 @@ namespace Omegasis.Fall28SnowDay /// Provides simplified APIs for writing mods. public override void Entry(IModHelper helper) { - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + SaveEvents.BeforeSave += this.SaveEvents_BeforeSave; } /********* ** Private methods *********/ - /// The method invoked when changes. + /// The method invoked just before the game saves. /// The event sender. /// The event data. - public void TimeEvents_DayOfMonthChanged(object sender, EventArgsIntChanged e) + public void SaveEvents_BeforeSave(object sender, EventArgs e) { - if (Game1.dayOfMonth == 27 && Game1.IsFall) + if (Game1.IsFall && Game1.dayOfMonth == 27) Game1.weatherForTomorrow = Game1.weather_snow; } } diff --git a/GeneralMods/Fall28SnowDay/README.md b/GeneralMods/Fall28SnowDay/README.md index 0dceb197..a4af81c1 100644 --- a/GeneralMods/Fall28SnowDay/README.md +++ b/GeneralMods/Fall28SnowDay/README.md @@ -22,4 +22,5 @@ It automatically snows on fall 28. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/Fall28SnowDay/manifest.json b/GeneralMods/Fall28SnowDay/manifest.json index ac3aff82..07ebb6e4 100644 --- a/GeneralMods/Fall28SnowDay/manifest.json +++ b/GeneralMods/Fall28SnowDay/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 1, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Makes it snow on Fall 28, which makes a good explanation for all the snow on the next day.", "UniqueID": "Omegasis.Fall28SnowDay", "EntryDll": "Fall28SnowDay.dll" diff --git a/GeneralMods/HappyBirthday/HappyBirthday.cs b/GeneralMods/HappyBirthday/HappyBirthday.cs index e4cd87c7..1d169c38 100644 --- a/GeneralMods/HappyBirthday/HappyBirthday.cs +++ b/GeneralMods/HappyBirthday/HappyBirthday.cs @@ -61,7 +61,7 @@ namespace Omegasis.HappyBirthday /// Provides simplified APIs for writing mods. public override void Entry(IModHelper helper) { - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + TimeEvents.AfterDayStarted += this.TimeEvents_AfterDayStarted; GameEvents.UpdateTick += this.GameEvents_UpdateTick; SaveEvents.AfterLoad += this.SaveEvents_AfterLoad; ControlEvents.KeyPressed += this.ControlEvents_KeyPressed; @@ -78,10 +78,10 @@ namespace Omegasis.HappyBirthday /********* ** Private methods *********/ - /// The method invoked when changes. + /// The method invoked after a new day starts. /// The event sender. /// The event data. - private void TimeEvents_DayOfMonthChanged(object sender, EventArgsIntChanged e) + private void TimeEvents_AfterDayStarted(object sender, EventArgs e) { if (Game1.player == null) return; diff --git a/GeneralMods/HappyBirthday/README.md b/GeneralMods/HappyBirthday/README.md index 678b8715..474d26e5 100644 --- a/GeneralMods/HappyBirthday/README.md +++ b/GeneralMods/HappyBirthday/README.md @@ -53,4 +53,5 @@ change based on your friendship with them. Check your mailbox for letters from y * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/HappyBirthday/manifest.json b/GeneralMods/HappyBirthday/manifest.json index 27b198ae..646cf3fa 100644 --- a/GeneralMods/HappyBirthday/manifest.json +++ b/GeneralMods/HappyBirthday/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Adds the farmer's birthday to the game.", "UniqueID": "Omegasis.HappyBirthday", "EntryDll": "HappyBirthday.dll" diff --git a/GeneralMods/MoreRain/MoreRain.cs b/GeneralMods/MoreRain/MoreRain.cs index 792e84d9..186468d6 100644 --- a/GeneralMods/MoreRain/MoreRain.cs +++ b/GeneralMods/MoreRain/MoreRain.cs @@ -52,7 +52,7 @@ namespace Omegasis.MoreRain public override void Entry(IModHelper helper) { SaveEvents.AfterLoad += this.SaveEvents_AfterLoad; - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + SaveEvents.BeforeSave += this.SaveEvents_BeforeSave; this.LoadConfig(); } @@ -69,10 +69,10 @@ namespace Omegasis.MoreRain this.HandleNewDay(); } - /// The method invoked when changes. + /// The method invoked before the game is saved. /// The event sender. /// The event data. - private void TimeEvents_DayOfMonthChanged(object sender, EventArgsIntChanged e) + private void SaveEvents_BeforeSave(object sender, EventArgs e) { if (this.IsGameLoaded) this.HandleNewDay(); @@ -203,7 +203,7 @@ namespace Omegasis.MoreRain } /// Save the configuration settings. - void SaveConfig() + private void SaveConfig() { string path = Path.Combine(Helper.DirectoryPath, "More_Rain_Config.txt"); string[] text = new string[20]; diff --git a/GeneralMods/MoreRain/README.md b/GeneralMods/MoreRain/README.md index 8792b2c5..f1677bae 100644 --- a/GeneralMods/MoreRain/README.md +++ b/GeneralMods/MoreRain/README.md @@ -28,4 +28,5 @@ It won't rain on days where a wedding or a festival would take place. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/MoreRain/manifest.json b/GeneralMods/MoreRain/manifest.json index 80e73196..092cfcd5 100644 --- a/GeneralMods/MoreRain/manifest.json +++ b/GeneralMods/MoreRain/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 2, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Change how much it rains in the game.", "UniqueID": "Omegasis.MoreRain", "EntryDll": "MoreRain.dll" diff --git a/GeneralMods/MuseumRearranger/manifest.json b/GeneralMods/MuseumRearranger/manifest.json index 859717ee..7ac39522 100644 --- a/GeneralMods/MuseumRearranger/manifest.json +++ b/GeneralMods/MuseumRearranger/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Lets you rearrange the museum without needing to donate something.", "UniqueID": "Omegasis.MuseumRearranger", "EntryDll": "MuseumRearranger.dll" diff --git a/GeneralMods/NightOwl/NightOwl.cs b/GeneralMods/NightOwl/NightOwl.cs index 15af7869..b0d065d1 100644 --- a/GeneralMods/NightOwl/NightOwl.cs +++ b/GeneralMods/NightOwl/NightOwl.cs @@ -93,7 +93,7 @@ namespace Omegasis.NightOwl public override void Entry(IModHelper helper) { TimeEvents.TimeOfDayChanged += this.TimeEvents_TimeOfDayChanged; - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + TimeEvents.AfterDayStarted += this.TimeEvents_AfterDayStarted; SaveEvents.AfterLoad += this.SaveEvents_AfterLoad; GameEvents.FourthUpdateTick += this.GameEvents_FourthUpdateTick; } @@ -140,10 +140,10 @@ namespace Omegasis.NightOwl this.JustCollapsed = false; } - /// The method invoked when changes. + /// The method invoked when a new day starts. /// The event sender. /// The event data. - public void TimeEvents_DayOfMonthChanged(object sender, EventArgsIntChanged e) + public void TimeEvents_AfterDayStarted(object sender, EventArgs e) { if (!this.IsGameLoaded) return; diff --git a/GeneralMods/NightOwl/README.md b/GeneralMods/NightOwl/README.md index a2c03b04..c1b25ba6 100644 --- a/GeneralMods/NightOwl/README.md +++ b/GeneralMods/NightOwl/README.md @@ -24,4 +24,5 @@ Edit the `Night_Owl_Config_.txt` to change the mod settings. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/NightOwl/manifest.json b/GeneralMods/NightOwl/manifest.json index e73f21f7..d00b0ed0 100644 --- a/GeneralMods/NightOwl/manifest.json +++ b/GeneralMods/NightOwl/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Lets you stay up all night.", "UniqueID": "Omegasis.NightOwl", "EntryDll": "NightOwl.dll" diff --git a/GeneralMods/NoMorePets/manifest.json b/GeneralMods/NoMorePets/manifest.json index 7323df5e..dda7a06a 100644 --- a/GeneralMods/NoMorePets/manifest.json +++ b/GeneralMods/NoMorePets/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Removes all pets from the game.", "UniqueID": "Omegasis.NoMorePets", "EntryDll": "NoMorePets.dll" diff --git a/GeneralMods/SaveAnywhere/README.md b/GeneralMods/SaveAnywhere/README.md index b45deb61..a6728e4d 100644 --- a/GeneralMods/SaveAnywhere/README.md +++ b/GeneralMods/SaveAnywhere/README.md @@ -36,4 +36,5 @@ Press `K` to save anywhere. Edit `Save_Anywhere_Config.txt` to configure the key * Updated to Stardew Valley 1.2 and SMAPI 1.12. 2.5: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/SaveAnywhere/SaveAnywhere.cs b/GeneralMods/SaveAnywhere/SaveAnywhere.cs index 4231f953..5ef10e07 100644 --- a/GeneralMods/SaveAnywhere/SaveAnywhere.cs +++ b/GeneralMods/SaveAnywhere/SaveAnywhere.cs @@ -41,7 +41,7 @@ namespace Omegasis.SaveAnywhere SaveEvents.AfterLoad += this.SaveEvents_AfterLoad; ControlEvents.KeyPressed += this.ControlEvents_KeyPressed; GameEvents.UpdateTick += this.GameEvents_UpdateTick; - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + TimeEvents.AfterDayStarted += this.TimeEvents_AfterDayStarted; } @@ -79,10 +79,10 @@ namespace Omegasis.SaveAnywhere } } - /// The method invoked when changes. + /// The method invoked after a new day starts. /// The event sender. /// The event data. - private void TimeEvents_DayOfMonthChanged(object sender, EventArgsIntChanged e) + private void TimeEvents_AfterDayStarted(object sender, EventArgs e) { // reload NPC schedules this.ShouldResetSchedules = true; diff --git a/GeneralMods/SaveAnywhere/manifest.json b/GeneralMods/SaveAnywhere/manifest.json index 3501cd06..83f15be8 100644 --- a/GeneralMods/SaveAnywhere/manifest.json +++ b/GeneralMods/SaveAnywhere/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Lets you save almost anywhere.", "UniqueID": "Omegasis.SaveAnywhere", "EntryDll": "SaveAnywhere.dll" diff --git a/GeneralMods/SaveBackup/ReadMe.md b/GeneralMods/SaveBackup/ReadMe.md index b3f8459e..a3477e59 100644 --- a/GeneralMods/SaveBackup/ReadMe.md +++ b/GeneralMods/SaveBackup/ReadMe.md @@ -23,4 +23,5 @@ configure that. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.3: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/SaveBackup/SaveBackup.cs b/GeneralMods/SaveBackup/SaveBackup.cs index 2df899da..d8e44999 100644 --- a/GeneralMods/SaveBackup/SaveBackup.cs +++ b/GeneralMods/SaveBackup/SaveBackup.cs @@ -41,17 +41,17 @@ namespace Omegasis.SaveBackup this.BackupSaves(SaveBackup.PrePlayBackupsPath); - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + SaveEvents.BeforeSave += this.SaveEvents_BeforeSave; } /********* ** Private methods *********/ - /// The method invoked when changes. + /// The method invoked before the save is updated. /// The event sender. /// The event data. - private void TimeEvents_DayOfMonthChanged(object sender, EventArgs e) + private void SaveEvents_BeforeSave(object sender, EventArgs e) { this.BackupSaves(SaveBackup.NightlyBackupsPath); } diff --git a/GeneralMods/SaveBackup/manifest.json b/GeneralMods/SaveBackup/manifest.json index e66d471e..743db5fc 100644 --- a/GeneralMods/SaveBackup/manifest.json +++ b/GeneralMods/SaveBackup/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Backs up your save files at regular intervals.", "UniqueID": "Omegasis.SaveBackup", "EntryDll": "SaveBackup.dll" diff --git a/GeneralMods/StardewSymphony/README.md b/GeneralMods/StardewSymphony/README.md index 46c8b630..29e804da 100644 --- a/GeneralMods/StardewSymphony/README.md +++ b/GeneralMods/StardewSymphony/README.md @@ -33,4 +33,5 @@ This won't mute the music for in-game events or festivals. * Updated to Stardew Valley 1.2 and SMAPI 1.12. 1.4: +* Updated for SMAPI 2.0. * Internal refactoring. diff --git a/GeneralMods/StardewSymphony/StardewSymphony.cs b/GeneralMods/StardewSymphony/StardewSymphony.cs index 241ffca6..9415f819 100644 --- a/GeneralMods/StardewSymphony/StardewSymphony.cs +++ b/GeneralMods/StardewSymphony/StardewSymphony.cs @@ -89,7 +89,7 @@ namespace Omegasis.StardewSymphony this.HexProcessor = new MusicHexProcessor(this.MasterList, this.Reset); SaveEvents.AfterLoad += this.SaveEvents_AfterLoad; - TimeEvents.DayOfMonthChanged += this.TimeEvents_DayOfMonthChanged; + TimeEvents.AfterDayStarted += this.TimeEvents_AfterDayStarted; GameEvents.UpdateTick += this.GameEvents_UpdateTick; LocationEvents.CurrentLocationChanged += this.LocationEvents_CurrentLocationChanged; } @@ -132,10 +132,10 @@ namespace Omegasis.StardewSymphony Game1.nextMusicTrack = ""; //same as above line } - /// The method invoked when changes. + /// The method invoked after a new day starts. /// The event sender. /// The event data. - private void TimeEvents_DayOfMonthChanged(object sender, EventArgsIntChanged e) + private void TimeEvents_AfterDayStarted(object sender, EventArgs e) { if (!this.IsGameLoaded) return; @@ -269,7 +269,7 @@ namespace Omegasis.StardewSymphony string extension = Path.GetExtension(filePath); if (extension == ".xsb") { - Log.AsyncG(filePath); + this.Monitor.Log(filePath); this.HexProcessor.AddSoundBank(filePath); } //if (extension == "xwb") diff --git a/GeneralMods/StardewSymphony/manifest.json b/GeneralMods/StardewSymphony/manifest.json index 1fda8a0c..7719126b 100644 --- a/GeneralMods/StardewSymphony/manifest.json +++ b/GeneralMods/StardewSymphony/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Adding more music to the game one beep at a time.", "UniqueID": "Omegasis.StardewSymphony", "EntryDll": "StardewSymphony.dll" diff --git a/GeneralMods/TimeFreeze/manifest.json b/GeneralMods/TimeFreeze/manifest.json index 9e232982..6d4609bc 100644 --- a/GeneralMods/TimeFreeze/manifest.json +++ b/GeneralMods/TimeFreeze/manifest.json @@ -7,6 +7,7 @@ "PatchVersion": 0, "Build": null }, + "MinimumApiVersion": "1.15", "Description": "Emulates old Harvest Moon-style games where time is frozen inside.", "UniqueID": "Omegasis.TimeFreeze", "EntryDll": "TimeFreeze.dll"