Fix all warnings
Add and make use of Lombok Remove Mojang API Remove ZipFileUtils Remove StreamTools in favor of Apache IOUtils Keyframe should be abstract all derivatives final Replace clone in Keyframe with copy Move some constants from GuiReplaySetttings to GuiConstants
This commit is contained in:
@@ -11,8 +11,8 @@ public class MouseUtils {
|
||||
|
||||
public static Point getMousePos() {
|
||||
Point scaled = getScaledDimensions();
|
||||
int width = (int) scaled.getX();
|
||||
int height = (int) scaled.getY();
|
||||
int width = scaled.getX();
|
||||
int height = scaled.getY();
|
||||
|
||||
final int mouseX = (Mouse.getX() * width / mc.displayWidth);
|
||||
final int mouseY = (height - Mouse.getY() * height / mc.displayHeight);
|
||||
@@ -20,17 +20,6 @@ public class MouseUtils {
|
||||
return new Point(mouseX, mouseY);
|
||||
}
|
||||
|
||||
public static void moveMouse(int mouseX, int mouseY) {
|
||||
Point scaled = getScaledDimensions();
|
||||
int width = (int) scaled.getX();
|
||||
int height = (int) scaled.getY();
|
||||
|
||||
int x = (int)Math.round(((mouseX+0.5)*mc.displayWidth)/width);
|
||||
int y = (mouseY*mc.displayHeight)/height;
|
||||
|
||||
Mouse.setCursorPosition(x, y);
|
||||
}
|
||||
|
||||
public static Point getScaledDimensions() {
|
||||
ScaledResolution sr = new ScaledResolution(mc, mc.displayWidth, mc.displayHeight);
|
||||
final int width = sr.getScaledWidth();
|
||||
|
||||
Reference in New Issue
Block a user