diff --git a/src/main/java/techreborn/blockentity/generator/SolarPanelBlockEntity.java b/src/main/java/techreborn/blockentity/generator/SolarPanelBlockEntity.java index 9f96904db..1e8e16e3f 100644 --- a/src/main/java/techreborn/blockentity/generator/SolarPanelBlockEntity.java +++ b/src/main/java/techreborn/blockentity/generator/SolarPanelBlockEntity.java @@ -57,8 +57,8 @@ public class SolarPanelBlockEntity extends PowerAcceptorBlockEntity implements I public boolean isSunOut() { return canSeeSky && !world.isRaining() && !world.isThundering() && world.isDaylight(); } - - private void updatePanel(){ + + private void updatePanel() { if (world == null) { return; } @@ -135,22 +135,21 @@ public class SolarPanelBlockEntity extends PowerAcceptorBlockEntity implements I // Nope } - // TODO: Translate @Override public void addInfo(List info, boolean isReal, boolean hasData) { - info.add(new LiteralText(Formatting.GRAY + "Internal Energy Storage: " + Formatting.GOLD - + PowerSystem.getLocaliszedPowerFormatted((int) getMaxPower()))); + info.add(new LiteralText(Formatting.GRAY + StringUtils.t("reborncore.tooltip.energy.maxEnergy") + ": " + + Formatting.GOLD + PowerSystem.getLocaliszedPowerFormatted(getMaxPower()))); - info.add(new LiteralText(Formatting.GRAY + "Generation Rate Day: " + Formatting.GOLD - + PowerSystem.getLocaliszedPowerFormatted(panel.generationRateD))); + info.add(new LiteralText(Formatting.GRAY + StringUtils.t("techreborn.tooltip.generationRate.day") + ": " + + Formatting.GOLD + PowerSystem.getLocaliszedPowerFormatted(panel.generationRateD))); - info.add(new LiteralText(Formatting.GRAY + "Generation Rate Night: " + Formatting.GOLD - + PowerSystem.getLocaliszedPowerFormatted(panel.generationRateN))); + info.add(new LiteralText(Formatting.GRAY + StringUtils.t("techreborn.tooltip.generationRate.day") + ": " + + Formatting.GOLD + PowerSystem.getLocaliszedPowerFormatted(panel.generationRateN))); - info.add(new LiteralText(Formatting.GRAY + "Tier: " + Formatting.GOLD - + StringUtils.toFirstCapitalAllLowercase(getTier().toString()))); + info.add(new LiteralText(Formatting.GRAY + StringUtils.t("reborncore.tooltip.energy.tier") + ": " + + Formatting.GOLD + StringUtils.toFirstCapitalAllLowercase(getTier().toString()))); } - + @Override public void fromTag(CompoundTag tag) { if (world == null) { @@ -167,7 +166,7 @@ public class SolarPanelBlockEntity extends PowerAcceptorBlockEntity implements I super.onLoad(); updatePanel(); } - + // IToolDrop @Override public ItemStack getToolDrop(final PlayerEntity playerIn) { diff --git a/src/main/resources/assets/techreborn/lang/en_us.json b/src/main/resources/assets/techreborn/lang/en_us.json index cabfd2f65..67d708aa9 100644 --- a/src/main/resources/assets/techreborn/lang/en_us.json +++ b/src/main/resources/assets/techreborn/lang/en_us.json @@ -617,6 +617,8 @@ "techreborn.tooltip.inventory": "Inventory", "techreborn.tooltip.upgrades": "Upgrades", "techreborn.tooltip.alarm": "Shift rightclick to change sound", + "techreborn.tooltip.generationRate.day": "Generation Rate Day", + "techreborn.tooltip.generationRate.night": "Generation Rate Night", "_comment23": "ManualUI", "techreborn.manual.wiki": "Online wiki",