summaryrefslogtreecommitdiff
path: root/src/SMAPI
diff options
context:
space:
mode:
authorJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2020-10-03 20:49:03 -0400
committerJesse Plamondon-Willard <Pathoschild@users.noreply.github.com>2020-10-03 20:49:03 -0400
commitc87cd3b0028de6e9b4ed0eaacbc73cb83d64cd46 (patch)
tree7c130a6a2b137ec08297ce7a13ebd8142323320c /src/SMAPI
parentde84adb47751c96fc60be66f6fdb186a09160820 (diff)
parent68e9733a856b41c2b74d5c35a4b812e68157fbca (diff)
downloadSMAPI-c87cd3b0028de6e9b4ed0eaacbc73cb83d64cd46.tar.gz
SMAPI-c87cd3b0028de6e9b4ed0eaacbc73cb83d64cd46.tar.bz2
SMAPI-c87cd3b0028de6e9b4ed0eaacbc73cb83d64cd46.zip
Merge branch 'develop' into stable
Diffstat (limited to 'src/SMAPI')
-rw-r--r--src/SMAPI/Constants.cs2
-rw-r--r--src/SMAPI/Framework/ContentPack.cs2
-rw-r--r--src/SMAPI/Framework/SCore.cs5
-rw-r--r--src/SMAPI/Framework/Serialization/RectangleConverter.cs2
-rw-r--r--src/SMAPI/Metadata/CoreAssetPropagator.cs2
-rw-r--r--src/SMAPI/SMAPI.csproj4
6 files changed, 8 insertions, 9 deletions
diff --git a/src/SMAPI/Constants.cs b/src/SMAPI/Constants.cs
index 48428420..3927d477 100644
--- a/src/SMAPI/Constants.cs
+++ b/src/SMAPI/Constants.cs
@@ -51,7 +51,7 @@ namespace StardewModdingAPI
** Public
****/
/// <summary>SMAPI's current semantic version.</summary>
- public static ISemanticVersion ApiVersion { get; } = new Toolkit.SemanticVersion("3.7.3");
+ public static ISemanticVersion ApiVersion { get; } = new Toolkit.SemanticVersion("3.7.4");
/// <summary>The minimum supported version of Stardew Valley.</summary>
public static ISemanticVersion MinimumGameVersion { get; } = new GameVersion("1.4.1");
diff --git a/src/SMAPI/Framework/ContentPack.cs b/src/SMAPI/Framework/ContentPack.cs
index 161fdbe4..a6835dbe 100644
--- a/src/SMAPI/Framework/ContentPack.cs
+++ b/src/SMAPI/Framework/ContentPack.cs
@@ -119,7 +119,7 @@ namespace StardewModdingAPI.Framework
if (!PathUtilities.IsSafeRelativePath(relativePath))
throw new InvalidOperationException($"You must call {nameof(IContentPack)} methods with a relative path.");
- return this.RelativePaths.TryGetValue(relativePath, out string caseInsensitivePath)
+ return !string.IsNullOrWhiteSpace(relativePath) && this.RelativePaths.TryGetValue(relativePath, out string caseInsensitivePath)
? caseInsensitivePath
: relativePath;
}
diff --git a/src/SMAPI/Framework/SCore.cs b/src/SMAPI/Framework/SCore.cs
index e64c2801..f07e41f0 100644
--- a/src/SMAPI/Framework/SCore.cs
+++ b/src/SMAPI/Framework/SCore.cs
@@ -278,15 +278,14 @@ namespace StardewModdingAPI.Framework
);
// add exit handler
- new Thread(() =>
+ this.CancellationToken.Token.Register(() =>
{
- this.CancellationToken.Token.WaitHandle.WaitOne();
if (this.IsGameRunning)
{
this.LogManager.WriteCrashLog();
this.Game.Exit();
}
- }).Start();
+ });
// set window titles
this.SetWindowTitles(
diff --git a/src/SMAPI/Framework/Serialization/RectangleConverter.cs b/src/SMAPI/Framework/Serialization/RectangleConverter.cs
index a5780d8a..8f7318b3 100644
--- a/src/SMAPI/Framework/Serialization/RectangleConverter.cs
+++ b/src/SMAPI/Framework/Serialization/RectangleConverter.cs
@@ -37,7 +37,7 @@ namespace StardewModdingAPI.Framework.Serialization
if (string.IsNullOrWhiteSpace(str))
return Rectangle.Empty;
- var match = Regex.Match(str, @"^\{X:(?<x>\d+) Y:(?<y>\d+) Width:(?<width>\d+) Height:(?<height>\d+)\}$", RegexOptions.IgnoreCase);
+ var match = Regex.Match(str, @"^\{X:(?<x>-?\d+) Y:(?<y>-?\d+) Width:(?<width>-?\d+) Height:(?<height>-?\d+)\}$", RegexOptions.IgnoreCase);
if (!match.Success)
throw new SParseException($"Can't parse {nameof(Rectangle)} from invalid value '{str}' (path: {path}).");
diff --git a/src/SMAPI/Metadata/CoreAssetPropagator.cs b/src/SMAPI/Metadata/CoreAssetPropagator.cs
index 71199d59..701bc9f2 100644
--- a/src/SMAPI/Metadata/CoreAssetPropagator.cs
+++ b/src/SMAPI/Metadata/CoreAssetPropagator.cs
@@ -263,7 +263,7 @@ namespace StardewModdingAPI.Metadata
case "data\\farmanimals": // FarmAnimal constructor
return this.ReloadFarmAnimalData();
- case "data\\moviereactions": // MovieTheater.GetMovieReactions
+ case "data\\moviesreactions": // MovieTheater.GetMovieReactions
this.Reflection
.GetField<List<MovieCharacterReaction>>(typeof(MovieTheater), "_genericReactions")
.SetValue(content.Load<List<MovieCharacterReaction>>(key));
diff --git a/src/SMAPI/SMAPI.csproj b/src/SMAPI/SMAPI.csproj
index 7d2b8199..969071cf 100644
--- a/src/SMAPI/SMAPI.csproj
+++ b/src/SMAPI/SMAPI.csproj
@@ -14,9 +14,9 @@
<ItemGroup>
<PackageReference Include="LargeAddressAware" Version="1.0.5" />
- <PackageReference Include="Mono.Cecil" Version="0.11.2" />
+ <PackageReference Include="Mono.Cecil" Version="0.11.3" />
<PackageReference Include="Newtonsoft.Json" Version="12.0.3" />
- <PackageReference Include="Platonymous.TMXTile" Version="1.3.8" />
+ <PackageReference Include="Platonymous.TMXTile" Version="1.5.6" />
</ItemGroup>
<ItemGroup>