fix: Not being able to mine after closing the storage overlay

This commit is contained in:
Linnea Gräf
2025-03-21 23:46:34 +01:00
parent d42a6c7ad5
commit aa327dcfd0

View File

@@ -357,6 +357,10 @@ class StorageOverlayScreen : Screen(Text.literal("")) {
return super.keyReleased(keyCode, scanCode, modifiers)
}
override fun shouldCloseOnEsc(): Boolean {
return this === MC.screen // Fixes this UI closing the handled screen on Escape press.
}
override fun keyPressed(keyCode: Int, scanCode: Int, modifiers: Int): Boolean {
if (typeMCComponentInPlace(
controlComponent,