diff options
author | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2020-10-16 17:42:13 -0400 |
---|---|---|
committer | Jesse Plamondon-Willard <Pathoschild@users.noreply.github.com> | 2020-10-16 17:42:13 -0400 |
commit | 534142009d4b94038150827398b9020edebfe4c0 (patch) | |
tree | 1b7e23d7c4ffd8b7b2389ec7af252a4dfa00520d /src/SMAPI | |
parent | c87cd3b0028de6e9b4ed0eaacbc73cb83d64cd46 (diff) | |
download | SMAPI-534142009d4b94038150827398b9020edebfe4c0.tar.gz SMAPI-534142009d4b94038150827398b9020edebfe4c0.tar.bz2 SMAPI-534142009d4b94038150827398b9020edebfe4c0.zip |
reapply the game's town map changes in asset propagation
Diffstat (limited to 'src/SMAPI')
-rw-r--r-- | src/SMAPI/Metadata/CoreAssetPropagator.cs | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/SMAPI/Metadata/CoreAssetPropagator.cs b/src/SMAPI/Metadata/CoreAssetPropagator.cs index 701bc9f2..307bb11b 100644 --- a/src/SMAPI/Metadata/CoreAssetPropagator.cs +++ b/src/SMAPI/Metadata/CoreAssetPropagator.cs @@ -138,6 +138,14 @@ namespace StardewModdingAPI.Metadata { if (!string.IsNullOrWhiteSpace(location.mapPath.Value) && this.NormalizeAssetNameIgnoringEmpty(location.mapPath.Value) == key) { + // reset town caches + if (location is Town town) + { + this.Reflection.GetField<bool>(town, "ccRefurbished").SetValue(false); + this.Reflection.GetField<bool>(town, "isShowingDestroyedJoja").SetValue(false); + this.Reflection.GetField<bool>(town, "isShowingUpgradedPamHouse").SetValue(false); + } + // general updates location.reloadMap(); location.updateSeasonalTileSheets(); |