public static void Display_Rendered(object sender, EventArgs e)
        {
            intercept = true;
            var g = Game1.currentLocation;

            var  priorColor = Game1.ambientLight;
            bool priorLight = Game1.drawLighting;

            Game1.ambientLight = Microsoft.Xna.Framework.Color.White;
            Game1.drawLighting = false;
            _helper.GetPlatoHelper().SetTickDelayedUpdateAction(2, () => {
                Game1.ambientLight = priorColor;
                Game1.drawLighting = priorLight;
            }
                                                                );

            Game1.currentLocation = CurrentLocation;
            Game1.currentLocation.resetForPlayerEntry();
            pytk?.EnableMoreMapLayers(Game1.currentLocation.Map);

            try
            {
                try {
                    Game1.spriteBatch.End();
                }
                catch {
                }

                if (instance.config.CompatibilityMode || Constants.TargetPlatform == GamePlatform.Android)
                {
                    var fix = new ScreenshotAndroidFix();
                    fix.takeMapScreenshot(Game1.game1, 0.25f, CurrentLocation.isStructure.Value ? CurrentLocation.uniqueName.Value : CurrentLocation.Name);
                }
                else
                {
                    Game1.game1.takeMapScreenshot(0.25f, CurrentLocation.isStructure.Value ? CurrentLocation.uniqueName.Value : CurrentLocation.Name);
                }
                try {
                    Game1.spriteBatch.Begin();
                }
                catch { }
            }
            catch
            {
            }

            Game1.currentLocation            = g;
            _helper.Events.Display.Rendered -= Display_Rendered;
            intercept = false;
            Callback?.Invoke();
        }
        public static void Display_Rendered(object sender, EventArgs e)
        {
            intercept = true;
            var g = Game1.currentLocation;

            var  priorColor = Game1.ambientLight;
            bool priorLight = Game1.drawLighting;

            Game1.ambientLight = Microsoft.Xna.Framework.Color.White;
            Game1.drawLighting = false;
            _helper.GetPlatoHelper().SetTickDelayedUpdateAction(2, () => {
                Game1.ambientLight = priorColor;
                Game1.drawLighting = priorLight;
            }
                                                                );

            Game1.currentLocation = CurrentLocation;
            Game1.currentLocation.resetForPlayerEntry();
            pytk?.EnableMoreMapLayers(Game1.currentLocation.Map);

            try
            {
                try {
                    Game1.spriteBatch.End();
                }
                catch {
                }

                if (instance.config.CompatibilityMode || Constants.TargetPlatform == GamePlatform.Android)
                {
                    var fix = new ScreenshotAndroidFix();
                    fix.takeMapScreenshot(Game1.game1, 0.25f, CurrentLocation.isStructure.Value ? CurrentLocation.uniqueName.Value : CurrentLocation.Name);
                }
                else
                {
#if ANDROID
                    if (Game1.game1.GetType().GetMethod("takeMapScreenshot") is MethodInfo minfo)
                    {
                        if (minfo.GetParameters().Length == 2)
                        {
                            minfo.Invoke(Game1.game1, new object[] { 0.25f, CurrentLocation.isStructure.Value ? CurrentLocation.uniqueName.Value : CurrentLocation.Name });
                        }
                        else
                        {
                            Action c = () => Console.WriteLine("Screenshot taken");
                            minfo.Invoke(Game1.game1, new object[] { 0.25f, CurrentLocation.isStructure.Value ? CurrentLocation.uniqueName.Value : CurrentLocation.Name, c });
                        }
                    }
#else
                    Game1.game1.takeMapScreenshot(0.25f, CurrentLocation.isStructure.Value ? CurrentLocation.uniqueName.Value : CurrentLocation.Name, () => Console.WriteLine("Screenshot taken"));
#endif
                }
                try {
                    Game1.spriteBatch.Begin();
                }
                catch { }
            }
            catch
            {
            }

            Game1.currentLocation            = g;
            _helper.Events.Display.Rendered -= Display_Rendered;
            intercept = false;
            Callback?.Invoke();
        }