diff options
| author | Wyvest <45589059+Wyvest@users.noreply.github.com> | 2022-05-14 00:59:25 -0700 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2022-05-14 09:59:25 +0200 |
| commit | 2c592090b9448203559e01326bc2c2d995b15d53 (patch) | |
| tree | 821d347aefc828c214d817c8b7be8cf3c0b0ea9f /src/main/java/cc/polyfrost/oneconfig/utils | |
| parent | 4b8f98aa1435817c13e7083e30896ef8b5cbdaf0 (diff) | |
| download | OneConfig-2c592090b9448203559e01326bc2c2d995b15d53.tar.gz OneConfig-2c592090b9448203559e01326bc2c2d995b15d53.tar.bz2 OneConfig-2c592090b9448203559e01326bc2c2d995b15d53.zip | |
de-minecraftify a lot of things + use mixin instead of reflection (#11)
* de-minecraftify
* use mixin instead of reflection
* lol
Diffstat (limited to 'src/main/java/cc/polyfrost/oneconfig/utils')
| -rw-r--r-- | src/main/java/cc/polyfrost/oneconfig/utils/InputUtils.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/cc/polyfrost/oneconfig/utils/InputUtils.java b/src/main/java/cc/polyfrost/oneconfig/utils/InputUtils.java index 80f5175..ee0bafd 100644 --- a/src/main/java/cc/polyfrost/oneconfig/utils/InputUtils.java +++ b/src/main/java/cc/polyfrost/oneconfig/utils/InputUtils.java @@ -1,7 +1,7 @@ package cc.polyfrost.oneconfig.utils; -import cc.polyfrost.oneconfig.OneConfig; import cc.polyfrost.oneconfig.gui.OneConfigGui; +import gg.essential.universal.UResolution; import org.lwjgl.input.Mouse; public class InputUtils { @@ -30,7 +30,7 @@ public class InputUtils { } public static int mouseY() { - if (OneConfigGui.INSTANCE == null) return OneConfig.getDisplayHeight() - Math.abs(Mouse.getY()); - return (int) ((OneConfig.getDisplayHeight() - Math.abs(Mouse.getY())) / OneConfigGui.INSTANCE.getScaleFactor()); + if (OneConfigGui.INSTANCE == null) return UResolution.getWindowHeight() - Math.abs(Mouse.getY()); + return (int) ((UResolution.getWindowHeight() - Math.abs(Mouse.getY())) / OneConfigGui.INSTANCE.getScaleFactor()); } } |
