diff --git a/core/src/mindustry/ui/fragments/HudFragment.java b/core/src/mindustry/ui/fragments/HudFragment.java index b741a6089a..d0b20fc5a1 100644 --- a/core/src/mindustry/ui/fragments/HudFragment.java +++ b/core/src/mindustry/ui/fragments/HudFragment.java @@ -194,6 +194,21 @@ public class HudFragment{ //.padLeft(dsize * 5 + 4f) to prevent alpha overlap on left }); + //left/right gutter areas + parent.fill((x, y, w, h) -> { + x = 0f; + y = 0f; + w = Core.graphics.getWidth(); + h = Core.graphics.getHeight(); + if(Core.scene.marginLeft > 0){ + paneRight.draw(x, y, Core.scene.marginLeft, h); + } + + if(Core.scene.marginRight > 0){ + paneLeft.draw(x + w - Core.scene.marginRight, y, Core.scene.marginRight, h); + } + }); + //"waiting for players" parent.fill(t -> { t.name = "waiting"; diff --git a/core/src/mindustry/ui/fragments/MenuFragment.java b/core/src/mindustry/ui/fragments/MenuFragment.java index 296f3c5a89..9677a606bb 100644 --- a/core/src/mindustry/ui/fragments/MenuFragment.java +++ b/core/src/mindustry/ui/fragments/MenuFragment.java @@ -66,6 +66,21 @@ public class MenuFragment{ //info icon if(mobile){ + //left/right gutter areas + parent.fill((x, y, w, h) -> { + x = 0f; + y = 0f; + w = Core.graphics.getWidth(); + h = Core.graphics.getHeight(); + if(Core.scene.marginLeft > 0){ + paneRight.draw(x, y, Core.scene.marginLeft, h); + } + + if(Core.scene.marginRight > 0){ + paneLeft.draw(x + w - Core.scene.marginRight, y, Core.scene.marginRight, h); + } + }); + parent.fill(c -> c.bottom().left().button("", new TextButtonStyle(){{ font = Fonts.def; fontColor = Color.white;