From 74cf2b42d0a6aedbd70a5078207d3b6ee56bac28 Mon Sep 17 00:00:00 2001 From: DBotThePony Date: Sun, 20 Aug 2023 23:44:29 +0700 Subject: [PATCH] Add 4 pixel padding on top of chest frames --- .../dbotthepony/mc/otm/compat/vanilla/MatteryChestScreen.kt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/main/kotlin/ru/dbotthepony/mc/otm/compat/vanilla/MatteryChestScreen.kt b/src/main/kotlin/ru/dbotthepony/mc/otm/compat/vanilla/MatteryChestScreen.kt index 6441ec5ed..e06a76a44 100644 --- a/src/main/kotlin/ru/dbotthepony/mc/otm/compat/vanilla/MatteryChestScreen.kt +++ b/src/main/kotlin/ru/dbotthepony/mc/otm/compat/vanilla/MatteryChestScreen.kt @@ -2,6 +2,7 @@ package ru.dbotthepony.mc.otm.compat.vanilla import net.minecraft.network.chat.Component import net.minecraft.world.entity.player.Inventory +import ru.dbotthepony.mc.otm.client.render.RenderGravity import ru.dbotthepony.mc.otm.client.screen.MatteryScreen import ru.dbotthepony.mc.otm.client.screen.panels.Dock import ru.dbotthepony.mc.otm.client.screen.panels.FramePanel @@ -12,13 +13,14 @@ import ru.dbotthepony.mc.otm.client.screen.panels.util.GridPanel class MatteryChestScreen(menu: MatteryChestMenu, inventory: Inventory, title: Component) : MatteryScreen(menu, inventory, title) { override fun makeMainFrame(): FramePanel> { - val frame = FramePanel.padded(this, AbstractSlotPanel.SIZE * 9f, AbstractSlotPanel.SIZE * menu.rows, title) + val frame = FramePanel.padded(this, AbstractSlotPanel.SIZE * 9f, AbstractSlotPanel.SIZE * menu.rows + 4f, title) frame.makeCloseButton() frame.onClose { onClose() } val grid = GridPanel.slots(this, frame, 9, menu.rows) grid.dock = Dock.FILL + grid.gravity = RenderGravity.BOTTOM_CENTER for (slot in menu.chestSlots) SlotPanel(this, grid, slot)