diff options
Diffstat (limited to 'src/SMAPI')
-rw-r--r-- | src/SMAPI/Constants.cs | 2 | ||||
-rw-r--r-- | src/SMAPI/Framework/Input/MouseStateBuilder.cs | 6 | ||||
-rw-r--r-- | src/SMAPI/Metadata/CoreAssetPropagator.cs | 9 |
3 files changed, 13 insertions, 4 deletions
diff --git a/src/SMAPI/Constants.cs b/src/SMAPI/Constants.cs index d66e9d6b..128e23bd 100644 --- a/src/SMAPI/Constants.cs +++ b/src/SMAPI/Constants.cs @@ -20,7 +20,7 @@ namespace StardewModdingAPI ** Public ****/ /// <summary>SMAPI's current semantic version.</summary> - public static ISemanticVersion ApiVersion { get; } = new Toolkit.SemanticVersion("3.4.0"); + public static ISemanticVersion ApiVersion { get; } = new Toolkit.SemanticVersion("3.4.1"); /// <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/Input/MouseStateBuilder.cs b/src/SMAPI/Framework/Input/MouseStateBuilder.cs index cff3e05e..59956feb 100644 --- a/src/SMAPI/Framework/Input/MouseStateBuilder.cs +++ b/src/SMAPI/Framework/Input/MouseStateBuilder.cs @@ -66,9 +66,11 @@ namespace StardewModdingAPI.Framework.Input { foreach (var pair in overrides) { - bool isDown = pair.Value.IsDown(); if (this.ButtonStates.ContainsKey(pair.Key)) - this.ButtonStates[pair.Key] = isDown ? ButtonState.Pressed : ButtonState.Released; + { + this.State = null; + this.ButtonStates[pair.Key] = pair.Value.IsDown() ? ButtonState.Pressed : ButtonState.Released; + } } return this; diff --git a/src/SMAPI/Metadata/CoreAssetPropagator.cs b/src/SMAPI/Metadata/CoreAssetPropagator.cs index 8d5ad3ab..83e553ff 100644 --- a/src/SMAPI/Metadata/CoreAssetPropagator.cs +++ b/src/SMAPI/Metadata/CoreAssetPropagator.cs @@ -949,7 +949,14 @@ namespace StardewModdingAPI.Metadata /// <summary>Get all NPCs in the game (excluding farm animals).</summary> private IEnumerable<NPC> GetCharacters() { - return this.GetLocations().SelectMany(p => p.characters); + foreach (NPC character in this.GetLocations().SelectMany(p => p.characters)) + yield return character; + + if (Game1.CurrentEvent?.actors != null) + { + foreach (NPC character in Game1.CurrentEvent.actors) + yield return character; + } } /// <summary>Get all farm animals in the game.</summary> |