This commit is contained in:
Anuken 2022-11-09 08:31:19 -05:00
parent 1842e9d139
commit 8d255b3ccd
2 changed files with 3 additions and 2 deletions

View file

@ -8,7 +8,8 @@ import mindustry.world.blocks.heat.*;
import mindustry.world.meta.*;
/** A crafter that requires contact from heater blocks to craft. */
public class HeatCrafter extends GenericCrafter{
public class
HeatCrafter extends GenericCrafter{
/** Base heat requirement for 100% efficiency. */
public float heatRequirement = 10f;
/** After heat meets this requirement, excess heat will be scaled by this number. */
@ -26,7 +27,7 @@ public class HeatCrafter extends GenericCrafter{
addBar("heat", (HeatCrafterBuild entity) ->
new Bar(() ->
Core.bundle.format("bar.heatpercent", (int)entity.heat, (int)(entity.efficiencyScale() * 100)),
Core.bundle.format("bar.heatpercent", (int)(entity.heat + 0.00001f), (int)(entity.efficiencyScale() * 100 + 0.0001f)),
() -> Pal.lightOrange,
() -> entity.heat / heatRequirement));
}