Allow changing of the power cost view in fusion reactor recipes.
This commit is contained in:
parent
55b09da681
commit
c80cc0101f
3 changed files with 6 additions and 4 deletions
|
@ -33,6 +33,7 @@ import net.minecraft.client.gui.FontRenderer;
|
|||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.text.translation.I18n;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import reborncore.common.powerSystem.PowerSystem;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
import javax.annotation.Nullable;
|
||||
|
@ -54,7 +55,7 @@ public class RecipeUtil {
|
|||
int lineSpacing = fontRenderer.FONT_HEIGHT + 1;
|
||||
|
||||
NumberFormat formatter = NumberFormat.getInstance();
|
||||
String startCostEU = formatter.format(startCost);
|
||||
String startCostEU = PowerSystem.getLocaliszedPower(startCost);
|
||||
String startCostString = I18n.translateToLocalFormatted("techreborn.jei.recipe.start.cost", startCostEU);
|
||||
fontRenderer.drawString(startCostString, x, y, color);
|
||||
y += lineSpacing;
|
||||
|
@ -68,7 +69,7 @@ public class RecipeUtil {
|
|||
FontRenderer fontRenderer = minecraft.fontRenderer;
|
||||
int lineSpacing = fontRenderer.FONT_HEIGHT + 1;
|
||||
|
||||
String runningCostString = I18n.translateToLocalFormatted("techreborn.jei.recipe.running.cost", euPerTick);
|
||||
String runningCostString = I18n.translateToLocalFormatted("techreborn.jei.recipe.running.cost",PowerSystem.getDisplayPower().abbreviation.toUpperCase(), PowerSystem.getLocaliszedPowerFormattedNoSuffix(euPerTick));
|
||||
fontRenderer.drawString(runningCostString, x, y, color);
|
||||
y += lineSpacing;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue