From 93cd07cb1da5e928e72dc84553c5913a52db924c Mon Sep 17 00:00:00 2001 From: KlaasWhite <45828001+KlaasWhite@users.noreply.github.com> Date: Thu, 9 Apr 2026 19:35:19 +0200 Subject: [PATCH] Fix OnDrawUi harmony patch for KSA 2026.4.6.4036 (#71) --- StarMap.Core/Patches/ProgramPatcher.cs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/StarMap.Core/Patches/ProgramPatcher.cs b/StarMap.Core/Patches/ProgramPatcher.cs index 5c819d7..33d2f77 100644 --- a/StarMap.Core/Patches/ProgramPatcher.cs +++ b/StarMap.Core/Patches/ProgramPatcher.cs @@ -7,10 +7,11 @@ namespace StarMap.Core.Patches [HarmonyPatch(typeof(Program))] internal static class ProgramPatcher { - private const string OnDrawUiMethodName = "OnDrawUi"; + private const string OnBeforeDrawUiMethodName = "OnDrawUiFrame"; + private const string OnAfterDrawUiMethodName = "OnDrawUiViewports"; private const string OnFrameMethodName = "OnFrame"; - [HarmonyPatch(OnDrawUiMethodName)] + [HarmonyPatch(OnBeforeDrawUiMethodName)] [HarmonyPrefix] public static void BeforeOnDrawUi(double dt) { @@ -22,7 +23,7 @@ public static void BeforeOnDrawUi(double dt) } } - [HarmonyPatch(OnDrawUiMethodName)] + [HarmonyPatch(OnAfterDrawUiMethodName)] [HarmonyPostfix] public static void AfterOnDrawUi(double dt) {