From e4276265b8b9e0244b7bc3d019032e423ce33307 Mon Sep 17 00:00:00 2001 From: Juuxel Date: Sun, 28 Jul 2019 13:27:27 +0300 Subject: Fix tooltip position --- src/main/java/io/github/cottonmc/cotton/gui/widget/WWidget.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/main/java/io/github/cottonmc/cotton/gui/widget/WWidget.java b/src/main/java/io/github/cottonmc/cotton/gui/widget/WWidget.java index 4eff4f7..14bb979 100644 --- a/src/main/java/io/github/cottonmc/cotton/gui/widget/WWidget.java +++ b/src/main/java/io/github/cottonmc/cotton/gui/widget/WWidget.java @@ -139,7 +139,7 @@ public class WWidget { @Environment(EnvType.CLIENT) public void paintForeground(int x, int y, int mouseX, int mouseY) { if (mouseX >= x && mouseX < x+getWidth() && mouseY >= y && mouseY < y+getHeight()) { - renderTooltip(mouseX-x+getX(),mouseY-y+getY() ); + renderTooltip(mouseX, mouseY); } } -- cgit