Skip to content

Commit 74c6d0e

Browse files
Fix brewer window progress 0 not empty
1 parent 9dc5df0 commit 74c6d0e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

invui/src/main/java/xyz/xenondevs/invui/internal/menu/CustomBrewingStandMenu.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public void setBrewProgress(double progress) {
2727
if (progress < 0 || progress > 1)
2828
throw new IllegalArgumentException("Brew progress must be between 0 and 1, but was " + progress);
2929

30-
int brewTicks = (int) Math.round((1 - progress) * 400);
30+
int brewTicks = progress == 0.0 ? 0 : (int) Math.round((1 - progress) * 400);
3131
dataSlots[0] = brewTicks;
3232
}
3333

0 commit comments

Comments
 (0)