diff --git a/Docs/Thunderstore/README.md b/Docs/Thunderstore/README.md index ac69bb17..71420330 100644 --- a/Docs/Thunderstore/README.md +++ b/Docs/Thunderstore/README.md @@ -61,7 +61,7 @@ Here is a list of LCVR versions and which version(s) of Lethal Company it suppor | LCVR | Lethal Company | |-------------------|-------------------| -| v1.3.2 *(LATEST)* | V62 | +| v1.3.2 *(LATEST)* | V64 | | v1.3.1 | V62 | | v1.3.0 | V56 | | v1.2.5 | V50 | diff --git a/README.md b/README.md index 051ea749..4edb6f14 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ Here is a list of LCVR versions and which version(s) of Lethal Company it suppor | LCVR | Lethal Company | |-------------------|-------------------| -| v1.3.2 *(BETA)* | V62 | +| v1.3.2 *(BETA)* | V64 *(BETA)* | | v1.3.1 *(LATEST)* | V62 | | v1.3.0 | V56 | | v1.2.5 | V50 | diff --git a/Source/Patches/CursorPatches.cs b/Source/Patches/CursorPatches.cs new file mode 100644 index 00000000..c7934a6f --- /dev/null +++ b/Source/Patches/CursorPatches.cs @@ -0,0 +1,29 @@ +using HarmonyLib; +using UnityEngine; + +namespace LCVR.Patches; + +[LCVRPatch] +[HarmonyPatch] +internal static class CursorPatches +{ + /// + /// Prevent the cursor from showing up when playing in VR + /// + [HarmonyPatch(typeof(Cursor), nameof(Cursor.visible), MethodType.Setter)] + [HarmonyPrefix] + private static void PatchCursorVisibility(ref bool value) + { + value = false; + } + + /// + /// Prevent the cursor from getting locked when playing in VR + /// + [HarmonyPatch(typeof(Cursor), nameof(Cursor.lockState), MethodType.Setter)] + [HarmonyPrefix] + private static void PatchCursorLockState(ref CursorLockMode value) + { + value = CursorLockMode.None; + } +}