From 86fecf7a59c73b7f9160ae16eb26705ebeb00dae Mon Sep 17 00:00:00 2001 From: martimavocado <39881008+martimavocado@users.noreply.github.com> Date: Sun, 24 Mar 2024 09:15:21 +0000 Subject: Fix: Sensitivity Reducer + Mouse Lock incompatbility (#1253) --- .../at/hannibal2/skyhanni/features/garden/SensitivityReducer.kt | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/main') diff --git a/src/main/java/at/hannibal2/skyhanni/features/garden/SensitivityReducer.kt b/src/main/java/at/hannibal2/skyhanni/features/garden/SensitivityReducer.kt index a613a65f1..a13ca41d3 100644 --- a/src/main/java/at/hannibal2/skyhanni/features/garden/SensitivityReducer.kt +++ b/src/main/java/at/hannibal2/skyhanni/features/garden/SensitivityReducer.kt @@ -106,6 +106,7 @@ object SensitivityReducer { fun onRenderOverlay(event: GuiRenderEvent.GuiOverlayRenderEvent) { if (!(isToggled || isManualToggle)) return if (!config.showGUI) return + if (LockMouseLook.lockedMouse) return config.position.renderString("§eSensitivity Lowered", posLabel = "Sensitivity Lowered") } @@ -136,7 +137,11 @@ object SensitivityReducer { val divisor = config.reducingFactor.get() ChatUtils.debug("dividing by $divisor") - storage.savedMouseloweredSensitivity = gameSettings.mouseSensitivity + if (!LockMouseLook.lockedMouse) { + storage.savedMouseloweredSensitivity = gameSettings.mouseSensitivity + } else { + storage.savedMouseloweredSensitivity = storage.savedMouselockedSensitivity + } val newSens = doTheMath(storage.savedMouseloweredSensitivity) gameSettings?.mouseSensitivity = newSens if (showMessage) ChatUtils.chat("§bMouse sensitivity is now lowered. Type /shsensreduce to restore your sensitivity.") -- cgit