From f5e0393c43e8fed42f425a9f621747f2d15fec84 Mon Sep 17 00:00:00 2001 From: Juuxel <6596629+Juuxel@users.noreply.github.com> Date: Sat, 27 Feb 2021 17:09:00 +0200 Subject: Use screenWidth/Height instead of this.width/height in reposition --- .../io/github/cottonmc/cotton/gui/client/CottonInventoryScreen.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src') 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 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 { -- cgit