Skip to content

Commit

Permalink
Fix infinite Energy emitter decrement amperage not working (#94)
Browse files Browse the repository at this point in the history
  • Loading branch information
ALongStringOfNumbers authored Aug 21, 2021
1 parent f0c9a84 commit 63adb22
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ protected ModularUI createUI(EntityPlayer entityPlayer) {
return true;
}));
builder.label(7, 74, "Amperage");
builder.widget(new ClickButtonWidget(7, 87, 20, 20, "-", data -> amps = Math.max(0, amps+1)));
builder.widget(new ClickButtonWidget(7, 87, 20, 20, "-", data -> amps = amps-- == -1 ? 0 : amps--));
builder.widget(new TextFieldWidget(29, 87, 118, 20, true, () -> String.valueOf(amps), value -> {
amps = Integer.parseInt(value);
}).setValidator(value -> {
Expand Down

0 comments on commit 63adb22

Please sign in to comment.