From 71fa8a9c56aa274ad7dc55a76c55fc36faa9067c Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Sat, 23 Sep 2023 19:40:14 -0500 Subject: [PATCH] [DesktopVRIK] Changed patch location to be compatible with AvatarScaleMod. --- DesktopVRIK/HarmonyPatches.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/DesktopVRIK/HarmonyPatches.cs b/DesktopVRIK/HarmonyPatches.cs index 3b9b541..adb30a3 100644 --- a/DesktopVRIK/HarmonyPatches.cs +++ b/DesktopVRIK/HarmonyPatches.cs @@ -37,19 +37,19 @@ internal class PlayerSetupPatches } [HarmonyPostfix] - [HarmonyPatch(typeof(PlayerSetup), nameof(PlayerSetup.SetupAvatar))] - private static void Postfix_PlayerSetup_SetupAvatar(GameObject inAvatar) + [HarmonyPatch(typeof(PlayerSetup), nameof(PlayerSetup.SetupAvatarDesktop))] + private static void Postfix_PlayerSetup_SetupAvatarDesktop(ref PlayerSetup __instance) { if (!ModSettings.EntryEnabled.Value) return; try { - IKManager.Instance?.OnAvatarInitialized(inAvatar); + IKManager.Instance?.OnAvatarInitialized(__instance._avatar); } catch (Exception e) { - DesktopVRIK.Logger.Error($"Error during the patched method {nameof(Postfix_PlayerSetup_SetupAvatar)}"); + DesktopVRIK.Logger.Error($"Error during the patched method {nameof(Postfix_PlayerSetup_SetupAvatarDesktop)}"); DesktopVRIK.Logger.Error(e); } }