Add support for solar energy scaling during day (#2497)
This commit is contained in:
parent
dcca103f9a
commit
56dcc4dd16
4 changed files with 54 additions and 52 deletions
|
@ -48,10 +48,8 @@ public class GuiSolar extends GuiBase<BuiltScreenHandler> {
|
|||
|
||||
builder.drawMultiEnergyBar(matrixStack, this, 156, 19, (int) blockEntity.getEnergy(), (int) blockEntity.getMaxStoredPower(), mouseX, mouseY, 0, layer);
|
||||
|
||||
switch (blockEntity.getSunState()) {
|
||||
case SolarPanelBlockEntity.DAYGEN -> builder.drawText(matrixStack, this, new TranslatableText("techreborn.message.daygen"), 10, 20, 15129632);
|
||||
case SolarPanelBlockEntity.NIGHTGEN -> builder.drawText(matrixStack, this, new TranslatableText("techreborn.message.nightgen"), 10, 20, 7566195);
|
||||
case SolarPanelBlockEntity.ZEROGEN -> builder.drawText(matrixStack, this, new TranslatableText("techreborn.message.zerogen"), 10, 20, 12066591);
|
||||
if (!blockEntity.isGenerating()) {
|
||||
builder.drawText(matrixStack, this, new TranslatableText("techreborn.message.panel_blocked"), 10, 20, 12066591);
|
||||
}
|
||||
|
||||
builder.drawText(matrixStack, this, new LiteralText("Generating: " + blockEntity.getGenerationRate() + " E/t"), 10, 30, 0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue