This commit is contained in:
Anuken
2025-12-29 10:45:19 -05:00
parent 90d32abd6b
commit 7416bc3bb7

View File

@@ -52,6 +52,7 @@ public class HudFragment{
private long lastToast;
private Seq<Block> blocksOut = new Seq<>();
private Table hudLabel;
private void addBlockSelection(Table cont){
Table blockSelection = new Table();
@@ -183,6 +184,10 @@ public class HudFragment{
Events.on(ResetEvent.class, e -> {
coreItems.resetUsed();
coreItems.clear();
if(hudLabel != null){
hudLabel.color.a = 0f;
}
showHudText = false;
});
//paused table
@@ -500,15 +505,8 @@ public class HudFragment{
}).blink(Color.white).outline(new Color(0, 0, 0, 0.6f), 7f)).grow())
.fillX().width(320f).height(60f).name("boss").visible(() -> state.rules.waves && state.boss() != null && !(mobile && Core.graphics.isPortrait())).padTop(7).row();
t.table(Styles.black3, p -> p.margin(4).label(() -> hudText).style(Styles.outlineLabel)).touchable(Touchable.disabled).with(p -> p.visible(() -> {
p.color.a = Mathf.lerpDelta(p.color.a, Mathf.num(showHudText), 0.2f);
if(state.isMenu()){
p.color.a = 0f;
showHudText = false;
}
return p.color.a >= 0.001f;
}));
t.table(Styles.black3, p -> p.margin(4).label(() -> hudText).style(Styles.outlineLabel)).touchable(Touchable.disabled).with(p -> hudLabel = p)
.with(p -> p.visible(() -> (p.color.a = Mathf.lerpDelta(p.color.a, Mathf.num(showHudText), 0.2f)) >= 0.001f));
});
//spawner warning