diff options
author | Jesse Plamondon-Willard <github@jplamondonw.com> | 2018-06-30 16:55:59 -0400 |
---|---|---|
committer | Jesse Plamondon-Willard <github@jplamondonw.com> | 2018-06-30 16:55:59 -0400 |
commit | 8b9d1baaea415dfb3d845e990898c29c024c5c18 (patch) | |
tree | b15c5b6f2e6b7bfe2fcf684cdcbda0b001be1875 | |
parent | 96a8401c03bc38b682a5a793fb4d15766a2663b2 (diff) | |
download | SMAPI-8b9d1baaea415dfb3d845e990898c29c024c5c18.tar.gz SMAPI-8b9d1baaea415dfb3d845e990898c29c024c5c18.tar.bz2 SMAPI-8b9d1baaea415dfb3d845e990898c29c024c5c18.zip |
fix Context.IsPlayerFree being false during festivals (#550)
-rw-r--r-- | docs/release-notes.md | 3 | ||||
-rw-r--r-- | src/SMAPI/Context.cs | 2 |
2 files changed, 3 insertions, 2 deletions
diff --git a/docs/release-notes.md b/docs/release-notes.md index 2b449ac7..ae7f766d 100644 --- a/docs/release-notes.md +++ b/docs/release-notes.md @@ -48,11 +48,12 @@ * Added absolute pixels to `ICursorPosition`. * Added support for reading/writing `ISemanticVersion` to JSON. * Update checks now use the update key order when deciding which to link to. - * Fixed error if a mod loads a PNG while the game is loading (e.g. custom map tilesheets via `IAssetLoader`). * Fixed assets loaded by temporary content managers not being editable by mods. * Fixed assets not reloaded consistently when the player switches language. + * Fixed error if a mod loads a PNG while the game is loading (e.g. custom map tilesheets via `IAssetLoader`). * Fixed input suppression not working consistently for clicks. * Fixed console command input not saved to the log. + * Fixed `Context.IsPlayerFree` being false during festivals. * Fixed `helper.ModRegistry.GetApi` interface validation errors not mentioning which interface caused the issue. * Fixed some common non-mod build output being included in release zip. * Fixed mods able to intercept other mods' assets via the internal asset keys. diff --git a/src/SMAPI/Context.cs b/src/SMAPI/Context.cs index 74def086..3905699e 100644 --- a/src/SMAPI/Context.cs +++ b/src/SMAPI/Context.cs @@ -17,7 +17,7 @@ namespace StardewModdingAPI public static bool IsWorldReady { get; internal set; } /// <summary>Whether <see cref="IsWorldReady"/> is true and the player is free to act in the world (no menu is displayed, no cutscene is in progress, etc).</summary> - public static bool IsPlayerFree => Context.IsWorldReady && Game1.activeClickableMenu == null && !Game1.dialogueUp && !Game1.eventUp; + public static bool IsPlayerFree => Context.IsWorldReady && Game1.activeClickableMenu == null && !Game1.dialogueUp && (!Game1.eventUp || Game1.isFestival()); /// <summary>Whether <see cref="IsPlayerFree"/> is true and the player is free to move (e.g. not using a tool).</summary> public static bool CanPlayerMove => Context.IsPlayerFree && Game1.player.CanMove; |