Fix the underlying problem -- Bad X!

This commit is contained in:
Jason Mitchell committed 2020-02-04 20:11:17 -08:00
1 parent 4375a91220
commit 10c2326184
4 files changed
+11 -14

No files matched your search

+5 -1
View File
@@ -107,6 +107,10 @@ public class ItemPanel extends Widget {
};
}
public int getX(GuiContainer gui) {
return (gui.xSize + gui.width) / 2 + 3;
}
public int getMarginLeft() {
return x + (w % 18) / 2;
}
@@ -177,7 +181,7 @@ public class ItemPanel extends Widget {
pageLabel.text = getLabelText();
y = prev.h + prev.y;
x = (gui.xSize + gui.width) / 2 + 3;
x = getX(gui);
w = getWidth(gui);
h = getHeight(gui);