reset map overrides when reloading a map (#751)

This commit is contained in:
Jesse Plamondon-Willard 2021-01-18 23:19:34 -05:00
parent 9fb6d67417
commit 00e545715d
No known key found for this signature in database
GPG Key ID: CF8B1456B3E29F49
2 changed files with 2 additions and 0 deletions

View File

@ -18,6 +18,7 @@
* Network messages through the multiplayer API are no longer sent to players who don't have SMAPI installed. This reduces unneeded network traffic (since they can't read it anyway) and avoids an error in some cases.
* Improved asset propagation:
* Added propagation for some `Strings\StringsFromCSFiles` keys (mainly short day names).
* Fixed some town patches not reapplied when the map is reloaded in Stardew Valley 1.5.
* Added an option to disable rewriting mods for compatibility (thanks to Bpendragon!). This prevents older mods from loading but bypasses a Visual Studio debugger crash.
* Game errors shown in the chatbox are now logged.

View File

@ -785,6 +785,7 @@ namespace StardewModdingAPI.Metadata
private void ReloadMap(GameLocation location)
{
// reset patch caches
this.Reflection.GetField<HashSet<string>>(location, "_appliedMapOverrides").GetValue().Clear();
switch (location)
{
case Town _: