diff --git a/stardew-access/ModEntry.cs b/stardew-access/ModEntry.cs index 6e04ff0..e629e6b 100644 --- a/stardew-access/ModEntry.cs +++ b/stardew-access/ModEntry.cs @@ -257,7 +257,7 @@ namespace stardew_access { if (!manuallyTriggered && prevTile != gt) { - ScreenReader.prevText = " "; + ScreenReader.prevTextTile = " "; } Dictionary> terrainFeature = Game1.currentLocation.terrainFeatures.FieldDict; diff --git a/stardew-access/Patches/DialoguePatcher.cs b/stardew-access/Patches/DialoguePatcher.cs index dd454f8..3d75a61 100644 --- a/stardew-access/Patches/DialoguePatcher.cs +++ b/stardew-access/Patches/DialoguePatcher.cs @@ -84,8 +84,9 @@ namespace stardew_access.Patches ScreenReader.sayWithChecker(toSpeak, true); } } - else + else if(Game1.activeClickableMenu is DialogueBox) { + MainClass.monitor.Log("hereasad ", LogLevel.Debug); // Basic dialogues like `No mails in the mail box` if (currentDialogue != __instance.getCurrentString()) { diff --git a/stardew-access/ScreenReader.cs b/stardew-access/ScreenReader.cs index 7d07558..c3ffd3c 100644 --- a/stardew-access/ScreenReader.cs +++ b/stardew-access/ScreenReader.cs @@ -6,7 +6,7 @@ namespace stardew_access internal class ScreenReader { public static IAccessibleOutput? screenReader = null; - internal static string prevText = ""; + internal static string prevText = "", prevTextTile = " "; public static void initializeScreenReader() { @@ -81,9 +81,9 @@ namespace stardew_access string query = $"{text} x:{x} y:{y}"; - if (prevText != query) + if (prevTextTile != query) { - prevText = query; + prevTextTile = query; screenReader.Speak(text, interrupt); } } diff --git a/stardew-access/manifest.json b/stardew-access/manifest.json index ee990f1..d05e19d 100644 --- a/stardew-access/manifest.json +++ b/stardew-access/manifest.json @@ -1,7 +1,7 @@ { "Name": "Stardew Access", "Author": "Mohammad Shoaib", - "Version": "1.0.8-beta", + "Version": "1.0.9-beta", "Description": "An accessibility mod with screen reader support!", "UniqueID": "shoaib.stardewaccess", "EntryDll": "stardew-access.dll",