Moved collections page patch
parent
6730fcceff
commit
2a5baa6770
|
@ -110,7 +110,7 @@ namespace stardew_access
|
||||||
|
|
||||||
harmony.Patch(
|
harmony.Patch(
|
||||||
original: AccessTools.Method(typeof(CollectionsPage), nameof(CollectionsPage.draw), new Type[] { typeof(SpriteBatch) }),
|
original: AccessTools.Method(typeof(CollectionsPage), nameof(CollectionsPage.draw), new Type[] { typeof(SpriteBatch) }),
|
||||||
postfix: new HarmonyMethod(typeof(GameMenuPatches), nameof(GameMenuPatches.CollectionsPagePatch))
|
postfix: new HarmonyMethod(typeof(CollectionsPagePatch), nameof(CollectionsPagePatch.DrawPatch))
|
||||||
);
|
);
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
|
|
@ -18,21 +18,6 @@ namespace stardew_access.Patches
|
||||||
internal static int currentSelectedCraftingRecipe = -1;
|
internal static int currentSelectedCraftingRecipe = -1;
|
||||||
internal static bool isSelectingRecipe = false;
|
internal static bool isSelectingRecipe = false;
|
||||||
|
|
||||||
internal static void CollectionsPagePatch(CollectionsPage __instance)
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
int x = Game1.getMousePosition().X, y = Game1.getMousePosition().Y;
|
|
||||||
if (__instance.letterviewerSubMenu != null)
|
|
||||||
{
|
|
||||||
DialoguePatches.NarrateLetterContent(__instance.letterviewerSubMenu);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
catch (System.Exception e)
|
|
||||||
{
|
|
||||||
MainClass.ErrorLog($"Unable to narrate Text:\n{e.Message}\n{e.StackTrace}");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
internal static void SocialPagePatch(SocialPage __instance, List<ClickableTextureComponent> ___sprites, int ___slotPosition, List<string> ___kidsNames)
|
internal static void SocialPagePatch(SocialPage __instance, List<ClickableTextureComponent> ___sprites, int ___slotPosition, List<string> ___kidsNames)
|
||||||
{
|
{
|
||||||
|
|
|
@ -0,0 +1,21 @@
|
||||||
|
namespace stardew_access.Patches
|
||||||
|
{
|
||||||
|
internal class CollectionsPagePatch
|
||||||
|
{
|
||||||
|
internal static void DrawPatch(StardewValley.Menus.CollectionsPage __instance)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
int x = StardewValley.Game1.getMousePosition().X, y = StardewValley.Game1.getMousePosition().Y;
|
||||||
|
if (__instance.letterviewerSubMenu != null)
|
||||||
|
{
|
||||||
|
DialoguePatches.NarrateLetterContent(__instance.letterviewerSubMenu);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
catch (System.Exception e)
|
||||||
|
{
|
||||||
|
MainClass.ErrorLog($"Unable to narrate Text:\n{e.Message}\n{e.StackTrace}");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in New Issue