From 1045679be1d833bb3e2fe5b1467a3996149436ae Mon Sep 17 00:00:00 2001 From: NotAKidoS <37721153+NotAKidOnSteam@users.noreply.github.com> Date: Wed, 14 Jun 2023 20:03:50 -0500 Subject: [PATCH] [SmoothRay] Slight change to patch Compiler already would do this, but I figured I'd throw it here too just because I can. --- SmoothRay/HarmonyPatches.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/SmoothRay/HarmonyPatches.cs b/SmoothRay/HarmonyPatches.cs index af5847b..18a4964 100644 --- a/SmoothRay/HarmonyPatches.cs +++ b/SmoothRay/HarmonyPatches.cs @@ -9,9 +9,7 @@ class PlayerSetupPatches [HarmonyPatch(typeof(PlayerSetup), nameof(PlayerSetup.Start))] static void Post_PlayerSetup_Start(ref PlayerSetup __instance) { - var leftSmoother = __instance.vrLeftHandTracker.gameObject.AddComponent(); - leftSmoother.ray = __instance.leftRay; - var rightSmoother = __instance.vrRightHandTracker.gameObject.AddComponent(); - rightSmoother.ray = __instance.rightRay; + __instance.vrLeftHandTracker.gameObject.AddComponent().ray = __instance.leftRay; + __instance.vrRightHandTracker.gameObject.AddComponent().ray = __instance.rightRay; } } \ No newline at end of file