diff options
author | Juuxel <6596629+Juuxel@users.noreply.github.com> | 2021-02-27 17:09:00 +0200 |
---|---|---|
committer | Juuxel <6596629+Juuxel@users.noreply.github.com> | 2021-02-27 17:09:00 +0200 |
commit | f5e0393c43e8fed42f425a9f621747f2d15fec84 (patch) | |
tree | 507f87746095a5c7078b82bf144e1b4941d90170 /src/main/java | |
parent | 843ca3ed723b8f35c6bdf5aab19a3b63002f3ef8 (diff) | |
download | LibGui-f5e0393c43e8fed42f425a9f621747f2d15fec84.tar.gz LibGui-f5e0393c43e8fed42f425a9f621747f2d15fec84.tar.bz2 LibGui-f5e0393c43e8fed42f425a9f621747f2d15fec84.zip |
Use screenWidth/Height instead of this.width/height in reposition
Diffstat (limited to 'src/main/java')
-rw-r--r-- | src/main/java/io/github/cottonmc/cotton/gui/client/CottonInventoryScreen.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/io/github/cottonmc/cotton/gui/client/CottonInventoryScreen.java b/src/main/java/io/github/cottonmc/cotton/gui/client/CottonInventoryScreen.java index d1cd584..2ddf84a 100644 --- a/src/main/java/io/github/cottonmc/cotton/gui/client/CottonInventoryScreen.java +++ b/src/main/java/io/github/cottonmc/cotton/gui/client/CottonInventoryScreen.java @@ -119,8 +119,8 @@ public class CottonInventoryScreen<T extends SyncedGuiDescription> extends Handl } if (!description.isFullscreen()) { - x = (width / 2) - (backgroundWidth / 2); - y = (height / 2) - (backgroundHeight / 2); + x = (screenWidth / 2) - (backgroundWidth / 2); + y = (screenHeight / 2) - (backgroundHeight / 2); titleX = 0; titleY = 0; } else { |