Skip to content

Commit

Permalink
If Amount = 0 in LiquidDisplay, Don't display /sec
Browse files Browse the repository at this point in the history
  • Loading branch information
SomeonesShade committed Sep 11, 2024
1 parent 1c73871 commit 71dffef
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion core/src/mindustry/ui/LiquidDisplay.java
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public LiquidDisplay(Liquid liquid, float amount, boolean perSecond){
}
}}).size(iconMed).padRight(3 + (amount != 0 && Strings.autoFixed(amount, 2).length() > 2 ? 8 : 0));

if(perSecond){
if(perSecond && (amount != 0)){
add(StatUnit.perSecond.localized()).padLeft(2).padRight(5).color(Color.lightGray).style(Styles.outlineLabel);
}

Expand Down

0 comments on commit 71dffef

Please sign in to comment.