Skip to content

Commit

Permalink
Fix Heat Capacity not showing in ABS and EBF (#2134)
Browse files Browse the repository at this point in the history
  • Loading branch information
RealKC authored Oct 11, 2024
1 parent 64c99e9 commit e34c72e
Showing 1 changed file with 27 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,12 @@
import com.gregtechceu.gtceu.api.recipe.OverclockingLogic;
import com.gregtechceu.gtceu.common.data.*;
import com.gregtechceu.gtceu.common.machine.multiblock.part.ParallelHatchPartMachine;
import com.gregtechceu.gtceu.utils.FormattingUtil;

import net.minecraft.ChatFormatting;
import net.minecraft.core.Direction;
import net.minecraft.network.chat.Component;
import net.minecraft.network.chat.Style;
import net.minecraft.world.level.block.Blocks;

import java.util.ArrayList;
Expand Down Expand Up @@ -495,6 +498,18 @@ public static void init() {}
})
.workableCasingRenderer(GTCEu.id("block/casings/gcym/high_temperature_smelting_casing"),
GTCEu.id("block/multiblock/gcym/blast_alloy_smelter"))
.additionalDisplay((controller, components) -> {
if (controller instanceof CoilWorkableElectricMultiblockMachine coilMachine && controller.isFormed()) {
components.add(Component.translatable("gtceu.multiblock.blast_furnace.max_temperature",
Component
.translatable(
FormattingUtil
.formatNumbers(coilMachine.getCoilType().getCoilTemperature() +
100L * Math.max(0, coilMachine.getTier() - GTValues.MV)) +
"K")
.setStyle(Style.EMPTY.withColor(ChatFormatting.RED))));
}
})
.compassSections(GTCompassSections.TIER[IV])
.compassNodeSelf()
.register();
Expand Down Expand Up @@ -945,6 +960,18 @@ public static void init() {}
})
.workableCasingRenderer(GTCEu.id("block/casings/gcym/high_temperature_smelting_casing"),
GTCEu.id("block/multiblock/gcym/mega_blast_furnace"))
.additionalDisplay((controller, components) -> {
if (controller instanceof CoilWorkableElectricMultiblockMachine coilMachine && controller.isFormed()) {
components.add(Component.translatable("gtceu.multiblock.blast_furnace.max_temperature",
Component
.translatable(
FormattingUtil
.formatNumbers(coilMachine.getCoilType().getCoilTemperature() +
100L * Math.max(0, coilMachine.getTier() - GTValues.MV)) +
"K")
.setStyle(Style.EMPTY.withColor(ChatFormatting.RED))));
}
})
.compassSections(GTCompassSections.TIER[LuV])
.compassNodeSelf()
.register();
Expand Down

0 comments on commit e34c72e

Please sign in to comment.